> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.bentoweb.com/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# ขั้นตอนการสร้าง Product ประเภท Attribute (Type 3)

1. ใช้ API เพื่อสร้าง Product โดย ระบุ type มีค่าเป็น 3

Sandbox
https://app.swaggerhub.com/apis/SemanticTouch/BentoSandboxProduct/1.0.0-oas3#/Products/post_product

Production
https://app.swaggerhub.com/apis/SemanticTouch/BentowebProduct/1.0.0-oas3#/Products/post_product

Data ตัวอย่าง:
```json
{
  "name": "Product name",
  "active": 0,
  "price": 30,
  "store_id":{store_id},
  "type": 3
}
```

2. ทำการ Init attribute

Sandbox
https://app.swaggerhub.com/apis/SemanticTouch/BentoSandboxProduct/1.0.0-oas3#/Products/post_product_init_attribute__product_id_

Production
https://app.swaggerhub.com/apis/SemanticTouch/BentowebProduct/1.0.0-oas3#/Products/post_product_init_attribute__product_id_

Data ตัวอย่าง:
```json
{
  "attr1name": "Colour",
  "attr2name": "Size",
  "store_id": {store_id}
}
```

3. เพิ่มสินค้าลงใน attribute

Sandbox
https://app.swaggerhub.com/apis/SemanticTouch/BentoSandboxProduct/1.0.0-oas3#/Products/post_product_variant_set_attribute__product_id_

Product
https://app.swaggerhub.com/apis/SemanticTouch/BentowebProduct/1.0.0-oas3#/Products/post_product_variant_set_attribute__product_id_

Data ตัวอย่าง:
```json
{
  "attr1": "Blue",
  "attr2": "M",
  "price": 25,
  "store_id": {store_id},
  "stock": 100,
  "barcode": "123456789",
  "sku": "001a"
}
```
