Light Mode
Create Product
POST
/productsLast modified: 24 days ago
Products can be created within your store at Salla by providing the required data in this endpoint.
:::tip[Note]
You can list available categories from List Categories endpoint.
:::
:::caution[Alert]
- Created products status will be set to
hidden
till attaching one image at least. - Created products status will be set to
out
till adding a value in quantity parameter. - Created products type cannot be changed after a product is created.
:::
Request
Body Params application/json
No schema defined
Example
{
"name": "T-Shirt Blue",
"price": 96.33,
"status": "out",
"product_type": "product",
"quantity": 4,
"booking_details": {
"location": "Medina",
"type": "date",
"time_strict_value": 5,
"time_strict_type": "days",
"sessions_count": 10,
"session_gap": 3,
"session_duration": 50,
"availabilities": [
{
"day": "sunday",
"is_available": true,
"times": [
{
"from": "09:30",
"to": "13:00"
},
{
"from": "12:00",
"to": "22:00"
}
]
},
{
"day": "monday",
"is_available": true,
"times": [
{
"from": "10:00",
"to": "12:00"
}
]
}
],
"overrides": [
{
"day": "sunday",
"date": "2023-04-09"
},
{
"day": "monday",
"date": "2023-04-10"
}
]
},
"description": "textophonious",
"categories": [
1032561074,
256950451
],
"min_amount_donating": 1,
"max_amount_donating": 5,
"sale_price": 43,
"cost_price": 35,
"sale_end": "2025-08-13",
"require_shipping": false,
"maximum_quantity_per_order": 0,
"weight": 12,
"weight_type": "kg",
"sku": "23-4324432",
"mpn": "45344432343",
"gtin": "58636897",
"hide_quantity": false,
"enable_upload_image": true,
"enable_note": true,
"pinned": true,
"active_advance": true,
"subtitle": "Collection 2020",
"promotion_title": "New",
"metadata_title": "T-Shirt blue - collection 2020",
"metadata_description": "T-Shirt blue - collection 2020",
"brand_id": 1097509908,
"tags": [
1366932222,
591845887
],
"images": [
{
"original": "https://salla-dev.s3.eu-central-1.amazonaws.com/nWzD/2E0Z2t6Q8FG3ca620rwqcTY2CC2j2PAGrqqeDROY.jpg",
"thumbnail": "https://salla-dev.s3.eu-central-1.amazonaws.com/nWzD/2E0Z2t6Q8FG3ca620rwqcTY2CC2j2PAGrqqeDROY.jpg",
"alt": "image",
"default": true,
"sort": 5
}
],
"options": [
{
"name": "option2",
"display_type": "text",
"values": [
{
"name": "الأزرق",
"price": 120,
"quantity": 10
},
{
"name": "الاحمر",
"price": 120,
"quantity": 10
},
{
"name": "الاصفر",
"price": 120,
"quantity": 10
}
]
},
{
"name": "option3",
"display_type": "text",
"values": [
{
"name": "كبير",
"price": 120,
"quantity": 10
},
{
"name": "صغير",
"price": 120,
"quantity": 10
},
{
"name": "متوسط",
"price": 120,
"quantity": 10
}
]
}
]
}
Request samples
Responses
Created Successfully(201)
Error Validation(422)
Created Successfully
HTTP Code: 201
Content Type : JSONapplication/json
Data Schema
No schema defined
Example
{
"status": 201,
"success": true,
"data": {
"id": 207865447,
"promotion": {
"title": "New",
"sub_title": "Collection 2020"
},
"sku": null,
"mpn": "45344432343",
"gtin": "58636897",
"type": "product",
"name": "T-Shirt Blue",
"short_link_code": "xxwWwo",
"urls": {
"customer": "https://salla.sa/dev-wofftr4xsra5xtlv/t-shirt-blue-collection-2020/p207865447",
"admin": "https://s.salla.sa/products/207865447"
},
"price": {
"amount": 43,
"currency": "SAR"
},
"taxed_price": {
"amount": 43,
"currency": "SAR"
},
"pre_tax_price": {
"amount": 43,
"currency": "SAR"
},
"tax": {
"amount": 0,
"currency": "SAR"
},
"description": "textophonious",
"quantity": 4,
"status": "sale",
"is_available": true,
"views": 0,
"sale_price": {
"amount": 43,
"currency": "SAR"
},
"sale_end": "2025-08-13",
"require_shipping": true,
"cost_price": "35.00",
"weight": 12,
"weight_type": "kg",
"with_tax": true,
"url": "https://salla.sa/dev-wofftr4xsra5xtlv/t-shirt-blue-collection-2020/p207865447",
"main_image": "https://salla-dev.s3.eu-central-1.amazonaws.com/nWzD/2E0Z2t6Q8FG3ca620rwqcTY2CC2j2PAGrqqeDROY.jpg",
"channels": [
"web",
"app"
],
"images": [
{
"id": 712603963,
"url": "https://salla-dev.s3.eu-central-1.amazonaws.com/nWzD/2E0Z2t6Q8FG3ca620rwqcTY2CC2j2PAGrqqeDROY.jpg",
"main": false,
"three_d_image_url": "",
"alt": "image",
"video_url": "",
"type": "image",
"sort": 5
}
],
"sold_quantity": 0,
"rating": {
"total": 0,
"count": 1,
"rate": 0
},
"regular_price": {
"amount": 96.33,
"currency": "SAR"
},
"max_items_per_user": 0,
"maximum_quantity_per_order": null,
"show_in_app": true,
"notify_quantity": null,
"hide_quantity": false,
"unlimited_quantity": false,
"managed_by_branches": false,
"services_blocks": {
"installments": []
},
"calories": null,
"starting_price": null,
"metadata": {
"title": "T-Shirt blue - collection 2020",
"description": "T-Shirt blue - collection 2020"
},
"allow_attachments": false,
"is_pinned": true,
"pinned_date": "2022-06-23 01:04:38",
"sort": 0,
"enable_upload_image": true,
"updated_at": "2022-06-23 01:04:38",
"options": [
{
"id": 319461767,
"name": "option2",
"description": null,
"type": "text",
"required": false,
"associated_with_order_time": 0,
"availability_range": false,
"not_same_day_order": false,
"choose_date_time": null,
"from_date_time": null,
"to_date_time": null,
"sort": null,
"advance": true,
"display_type": "text",
"visibility": "always",
"translations": {
"ar": {
"option_name": "option2",
"description": null
}
},
"values": [
{
"id": 1663429593,
"name": "الأزرق",
"price": {
"amount": 0,
"currency": "SAR"
},
"formatted_price": "(11 ر.س)",
"display_value": null,
"advance": true,
"option_id": 319461767,
"image_url": null,
"hashed_display_value": null,
"translations": {
"ar": {
"option_details_name": "الأزرق"
}
},
"is_default": false,
"is_out_of_stock": false
},
{
"id": 1023544026,
"name": "الاحمر",
"price": {
"amount": 0,
"currency": "SAR"
},
"formatted_price": null,
"display_value": null,
"advance": true,
"option_id": 319461767,
"image_url": null,
"hashed_display_value": null,
"translations": {
"ar": {
"option_details_name": "الاحمر"
}
},
"is_default": false,
"is_out_of_stock": false
},
{
"id": 250554843,
"name": "الاصفر",
"price": {
"amount": 0,
"currency": "SAR"
},
"formatted_price": null,
"display_value": null,
"advance": true,
"option_id": 319461767,
"image_url": null,
"hashed_display_value": null,
"translations": {
"ar": {
"option_details_name": "الاصفر"
}
},
"is_default": false,
"is_out_of_stock": false
}
]
},
{
"id": 1826076800,
"name": "option3",
"description": null,
"type": "text",
"required": false,
"associated_with_order_time": 0,
"availability_range": false,
"not_same_day_order": false,
"choose_date_time": null,
"from_date_time": null,
"to_date_time": null,
"sort": null,
"advance": true,
"display_type": "text",
"visibility": "always",
"translations": {
"ar": {
"option_name": "option3",
"description": null
}
},
"values": [
{
"id": 1488209956,
"name": "كبير",
"price": {
"amount": 0,
"currency": "SAR"
},
"formatted_price": null,
"display_value": null,
"advance": true,
"option_id": 1826076800,
"image_url": null,
"hashed_display_value": null,
"translations": {
"ar": {
"option_details_name": "كبير"
}
},
"is_default": false,
"is_out_of_stock": false
},
{
"id": 714168101,
"name": "صغير",
"price": {
"amount": 0,
"currency": "SAR"
},
"formatted_price": null,
"display_value": null,
"advance": true,
"option_id": 1826076800,
"image_url": null,
"hashed_display_value": null,
"translations": {
"ar": {
"option_details_name": "صغير"
}
},
"is_default": false,
"is_out_of_stock": false
},
{
"id": 75396646,
"name": "متوسط",
"price": {
"amount": 0,
"currency": "SAR"
},
"formatted_price": null,
"display_value": null,
"advance": true,
"option_id": 1826076800,
"image_url": null,
"hashed_display_value": null,
"translations": {
"ar": {
"option_details_name": "متوسط"
}
},
"is_default": false,
"is_out_of_stock": false
}
]
}
],
"skus": [
{
"id": 112657257,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
1663429593,
1488209956
],
"related_option_values": [
1663429593,
1488209956
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
},
{
"id": 1352409706,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
1663429593,
714168101
],
"related_option_values": [
1663429593,
714168101
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
},
{
"id": 578371947,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
1663429593,
75396646
],
"related_option_values": [
1663429593,
75396646
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
},
{
"id": 2084986996,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
1023544026,
1488209956
],
"related_option_values": [
1023544026,
1488209956
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
},
{
"id": 1311543157,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
1023544026,
714168101
],
"related_option_values": [
1023544026,
714168101
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
},
{
"id": 403287670,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
1023544026,
75396646
],
"related_option_values": [
1023544026,
75396646
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
},
{
"id": 1977011575,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
250554843,
1488209956
],
"related_option_values": [
250554843,
1488209956
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
},
{
"id": 1202973808,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
250554843,
714168101
],
"related_option_values": [
250554843,
714168101
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
},
{
"id": 295177073,
"price": {
"amount": 43,
"currency": "SAR"
},
"regular_price": {
"amount": 0,
"currency": "SAR"
},
"sale_price": null,
"has_special_price": false,
"stock_quantity": null,
"unlimited_quantity": true,
"barcode": null,
"sku": null,
"mpn": null,
"gtin": null,
"related_options": [
250554843,
75396646
],
"related_option_values": [
250554843,
75396646
],
"weight": null,
"weight_type": "kg",
"weight_label": "١٢ كجم",
"is_user_subscribed_to_sku": false,
"is_default": true
}
],
"booking_details": {
"id": 1219318081,
"type": "date_time",
"session_duration": 50,
"session_gap": 3,
"sessions_count": 10,
"location": "Medina",
"time_strict_type": "days",
"time_strict": 5,
"overrides": [
{
"id": 520625452,
"date": "2023-04-09"
},
{
"id": 1758805037,
"date": "2023-04-10"
}
],
"availabilities": [
{
"id": 1995455874,
"day": "sunday",
"times": [
{
"from": "09:30",
"to": "13:00"
},
{
"from": "12:00",
"to": "22:00"
}
],
"is_available": true
},
{
"id": 314211212,
"day": "monday",
"times": [
{
"from": "09:30",
"to": "13:00"
}
],
"is_available": true
}
]
},
"categories": [
{
"id": 1032561074,
"name": "الفساتين",
"urls": {
"customer": "https://salla.sa/dev-wofftr4xsra5xtlv/الفساتين/c1032561074",
"admin": "https://s.salla.sa/categories"
},
"items": [],
"parent_id": 0,
"status": "active",
"sort_order": 1,
"update_at": {
"date": "2022-04-25 19:46:26.000000",
"timezone_type": 3,
"timezone": "Asia/Riyadh"
}
},
{
"id": 256950451,
"name": "البلايز",
"urls": {
"customer": "https://salla.sa/dev-wofftr4xsra5xtlv/البلايز/c256950451",
"admin": "https://s.salla.sa/categories"
},
"items": [],
"parent_id": 0,
"status": "active",
"sort_order": 2,
"update_at": {
"date": "2022-01-16 15:35:55.000000",
"timezone_type": 3,
"timezone": "Asia/Riyadh"
}
}
],
"brand": {
"id": 1097509908,
"name": "بوما",
"description": "بوما وصف بالعربي",
"banner": "https://cdn.salla.sa/bYQEn/69QZx9DHUIQDLCoN7YAq9htHBH0tzD5luk5Rob7w.png",
"logo": "https://cdn.salla.sa/bYQEn/QqxF15HPwXw92PPsI7xSZ6F8ONWlOPojoWl48y4W.png",
"ar_char": "ب",
"en_char": "B"
},
"tags": [
{
"id": 1366932222,
"name": "tag1"
},
{
"id": 591845887,
"name": "tag2"
}
]
}
}
Last modified: 24 days ago