- Get a site token from the manager:
[POST] - {domain}/external/category/
{domain**}=admin.ecom.md
- Add a token to headers
All fields that are returned are also available for updating.
Categories:
[GET] - {domain}/external/category/ - get all site categories
{
"id": 2964, (INT) - ID in our database
"position": 10, INT - position of the category on the website in the menu
"name_ro": "Telefoane",
"name_ru": "Phones",
"name_en": null,
"name_uk": null,
"slug_ro": "telefoane-1",
"slug_ru": "telefony",
"slug_en": "telefoane-1",
"slug_uk": "telefoane-1",
"hide": false, Hidden\Open
"description_ro": null,
"description_ru": null,
"description_en": null,
"description_uk": null,
"description_position": null,
"group_category_id": "testing-phone-cat-id", (STR) - Any convenient identifier for you (ID from your database, code, etc.)
"meta_description_ro": null,
"meta_description_ru": null,
"meta_description_en": null,
"meta_description_uk": null,
"meta_title_ro": null,
"meta_title_en": null,
"meta_title_en": null,
"meta_title_uk": null,
"meta_keywords_ro": null,
"meta_keywords_ru": null,
"meta_keywords_en": null,
"meta_keywords_uk": null,
"show_18_popup": true,
"category_id": null - ID of the parent category (int)
}
[GET] - {domain}/external/category/{id} - get one category
[PUT] - {domain}/external/category/{id}/ - update 1 category
[POST] - {domain}/external/category/bulk-create/ - Create multiple categories
*[PUT] - {domain}/external/category/bulk-update/ -Update multiple categories*
{
"id": 27,
"position": 9,
"name_ro": "Acustica de casa Hi-Fi",
"name_ru": "Home Hi-Fi speakers",
"name_en": "",
"name_uk": "",
"slug_ro": "acustica-de-casa",
"slug_ru": "acustica-de-casa",
"slug_en": "acustica-de-casa",
"slug_uk": null,
"hide": false,
...
}
[PUT] - {domain}/external/category/{id}/bulk-update/
[
{
"id": 27,
"position": 9,
"name_ro": "Acustica de casa Hi-Fi",
"name_ru": "Home Hi-Fi speakers",
"name_en": "",
"name_uk": "",
"slug_ro": "acustica-de-casa",
"slug_ru": "acustica-de-casa",
"slug_en": "acustica-de-casa",
"slug_uk": null,
"hide": false,
...
},
{
"id": 28,
"position": 9,
"name_ro": "Acustica de casa Hi-Fi",
"name_ru": "Home Hi-Fi speakers",
"name_en": "",
"name_uk": "",
"slug_ro": "acustica-de-casa",
"slug_ru": "acustica-de-casa",
"slug_en": "acustica-de-casa",
"slug_uk": null,
"hide": false,
...
}
]
5. Creating\updating characteristics:
[GET] - {domain}/external/specification/ - get all site specifications
[GET] - {domain}/external/specification/{id} - get one specification
[PUT] - {domain}/external/specification/{id}/ - update 1 specification
[POST] - {domain}/external/specification/bulk-create/ - *create*several specifications
[PUT] - {domain}/external/specification/bulk-update/ - *update several specifications*
*6.*Creating/updating characteristic values:
[GET] - {domain}/external/specification-value/ - get all site specification values
*[GET] - {domain}/external/specification-value/{id} -get one specification value*
[PUT] - {domain}/external/specification-value/{id}/ - update 1 specification values
[POST] - {domain}/external/specification-value/bulk-create/ - create multiple characteristic values
[PUT] - {domain}/external/specification-value/bulk-update/ - *update multiple specification values*
7.Products** :
[GET] - {domain}/external/product/ - get all site products
[GET] - {domain}/external/product/{id} - get one product
[POST] - {domain}/external/product/bulk-create/ - create several products**
In the object it is necessary to pass groupproductid or ID from our database.
Payload example:
[
{
"bookmark": true,
"price": "1399.00",
"qty": 9,
"sort_priority": 0,
"old_price": "1099.00",
"group_product_id": "new_product_testt",
"weight": null,
"height": null,
"width": null,
"length": null,
"brand_id": null,
"keywords": "",
"specifications": [
{
"id": 1540, "specificationid": 22, "specificationvalueid": 181 }, { "id": 1541, "specificationid": 38, "specificationvalueid": 225 }, { "id": 1542, "specificationid": 28, "specificationvalueid": 175 }, { "id": 1543, "specificationid": 74, "specificationvalueid": 224 }, { "id": 1544, "specificationid": 87, "specificationvalueid": 671 }, { "id": 1545, "specificationid": 15, "specificationvalueid": 226 }, { "id": 1546, "specificationid": 76, "specificationvalueid": 214 } ], "namero": "JBL Tune 720 BT White", "nameru": "JBL Tune 720 BT White", "nameen": "", "nameuk": null, "slugro": "jbl-jbl-tune-720-bt-white1", "slugru": "jbl-jbl-tune-720-bt-white1", "slugen": "jbl-jbl-tune-720-bt-white1", "sluguk": null, "shortdescriptionro": null, "shortdescriptionru": null, "shortdescriptionen": null, "shortdescriptionuk": null, "descriptionro": "test test", "descriptionen": "test test", "descriptionen": null, "descriptionuk": null, "unitmeasurementro": null, "unitmeasurementru": null, "unitmeasurementen": null, "unitmeasurementuk": null, "seotitlero": null, "seotitleru": null, "seotitleen": null, "seotitleuk": null, "seodescriptionro": null, "seodescriptionru": null, "seodescriptionen": null, "seodescriptionuk": null, "seokeywordsro": null, "seokeywordsru": null, "seokeywordsen": null, "seokeywordsuk": null, "code": "qwer12344", "category": [ 1020 ], "images": [ { "order": 1, "originalname": "2e0b4c7e383f463687a9e66fb3dc66a2.jpg" }, { "order": 2, "original_name": "6d44a748-d164-11ee-ae36-0025905ed821.jpg" } ] } ]
"promo": [], - ID of shares to which to link the product
"product_group": [574] - ID of the groups to which to link the product
8. Product groups:
[GET] external/product-group/ - all site groups
[GET] external/product-group/{service_id} - one group
[PUT] external/product-group/bulk-update/ - update multiple groups
[POST] external/product-group/bulk-create/ - create several groups
[
{
"id": 134,
"code": null,
"name": "test",
"select_specifications": [42,43], - characteristics id for the group
"images_specifications": [45,46] - characteristics ID for the group
}
]
9. Endpoint for stocks
*[GET] external/promo/ -all site promotions*
[GET] external/promo/{promo_id} - one promotion
[PUT] external/promo/{promo_id} - update 1 promotion
[POST] external/promo/bulk-update/ - update several promotions
[
{
"id": 26,
"name_ro": "Toamna ta - reducerile noastre! Boxenew",
"name_ru": "Autumn good discounts! Boxe5",
"name_en": "Promo name",
"name_uk": "Promo Name",
"hide": false,
"info": null,
"expire_date": "2024-03-04T08:15:00",
"position": 10,
"priority": 0,
"slug": "toamna-ta-reducerile-noastre-boxenew",
"show_in_promo_block": false,
"show_is_slider": false,
"show_on": null
},
{
"id": 25,
"name_ro": "smartpromonew",
"name_ru": "smartpromoru5",
"name_en": "Promo nameEN",
"name_uk": "Promo Name",
"hide": false,
"info": null,
"expire_date": "2025-02-28T17:30:00",
"position": 1,
"priority": 10,
"slug": "smartpromonew",
"show_in_promo_block": false,
"show_is_slider": false,
"show_on": "start"
}
]
[POST] external/promo/bulk-create/ - create several shares
[
{
"name_ro": "Toamna ta - reducerile noastre! Boxenew",
"name_ru": "Autumn good discounts! Boxe5",
"name_en": "Promo name",
"name_uk": "Promo Name",
"hide": false,
"info": null,
"expire_date": "2024-03-04T08:15:00",
"position": 10,
"priority": 0,
"slug": "toamna-ta-reducerile-noastre-boxenew",
"show_in_promo_block": false,
"show_is_slider": false,
"show_on": null
},
{
"name_ro": "smartpromonew",
"name_ru": "smartpromoru5",
"name_en": "Promo nameEN",
"name_uk": "Promo Name",
"hide": false,
"info": null,
"expire_date": "2025-02-28T17:30:00",
"position": 1,
"priority": 10,
"slug": "smartpromonew",
"showinpromoblock": false, "showisslider": false, "showon": "start" } ]
10. Phone numbers
[GET] external/phone/ - all site phones
{
"count": 5,
"next": null,
"previous": null,
"results": [
{
"id": 254,
"phone": "+373 60 11 11 11 11"
},
{
"id": 277,
"phone": "+373 60 11 11 11 12"
},
{
"id": 278,
"phone": "+373 60 11 11 11 13"
}
]
}
[GET] external/phone/{service_id} - one phone
[PUT] external/phone/bulk-update/ - update multiple phones
[
{
"id": 1,
"phone": "+373 60 11 11 11 11"
},
{
"id": 2,
"phone": "+373 60 11 11 11 12"
}
]
[POST] external/phone/bulk-create/ - create several phones
[
{
"phone": "+373 60 11 11 11 11"
},
{
"phone": "+373 60 11 11 11 12"
}
]
11. Endpoint for companies
[GET] external/company/ - all companies on the site
Filtering by lastupdate is available
For example:
/external/company?lastupdate=1749798794 - will return all updated companies after a specified time
[GET] external/company/{id} - one company
[PUT] external/company/bulk-update/ - update multiple companies
[POST] external/company/bulk-create/ - create several companies
[
{
"company_owner_id": 177581,
"company_name": "Test",
"vat_rate": "55.55",
"vat_number": "555555",
"legal_address": "Socoleni 9",
"physical_address": "",
"bank_name": "MICB",
"fiscal_code":"FISCAL_CODE_123",
"bank_code": "BANK_CODE_123",
"iban": "QWEWRTYU12345",
"cif": "20000000000",
"registration_number": "2900000000",
"region": "Ciocana",
"locality": "Chisinau",
"use_vat": false,
"credit_limit": "555.00",
"balance": "55555.00",
}
]
12. Endpoint for stores (branches)
[GET] external/shop/ - all stores on the site
[GET] external/shop/{id} - one store
[PUT] external/shop/bulk-update/ - update several stores
[
{
"id": 333,
"lat": "47.04425769408643",
"lon": "28.8317133350053",
"tooltip_pin_text": "test test",
"email": "[[email protected]](https://docs.ecom.md/cdn-cgi/l/email-protection)",
"order": 55,
"description_ro": null,
"description_ru": null,
"description_en": null,
"description_uk": null,
"iframe": "",
"company_id": null,
"is_active": true,
"phones": [
{
"id": 4,
"phone": "+373 60 11 11 14"
},
{
"id": 3,
"phone": "+373 60 11 11 13"
}
],
"addresses": {
"region_id": 3,
"locality_id": 70,
"sector_id": 10,
"address": "Vadul lui Voda 78/2",
"house": null,
"entrance": null,
"apartment": null,
"zip_code": null
}
}
]
[POST] external/shop/bulk-create/ - create severalshops**
[
{
"lat": "47.04425769408643",
"lon": "28.8317133350053",
"tooltip_pin_text": "test test",
"email": "[[email protected]](https://docs.ecom.md/cdn-cgi/l/email-protection)",
"order": 55,
"description_ro": null,
"description_ru": null,
"description_en": null,
"description_uk": null,
"iframe": "",
"company_id": null,
"is_active": true,
"phones": [
{
"id": 1,
"phone": "+373 60 11 11 11"
},
{
"id": 2,
"phone": "+373 60 11 11 12"
}
]
}
]
[POST] external/product/user-price-update/ - updating/creating prices for different types of users
[
{
"user_type_id": 10,
"price": 8888,
"group_product_id": “349254”
}
]
[POST] external/product/shop-update/ - update/create availability in stores
[
{
"shop_id": 281,
"qty": 9999,
"group_product_id": “349254”
}
]
13. Endpoint for discount cards
[GET] external/discount-card/ - all site cards
[GET] external/discount-card/{id} - one card
[PUT] external/discount-card/{id} - update 1 card
[PUT] external/discount-card/bulk-update/ - update multiple cards
[POST] external/discount-card/bulk-create/ - create several cards
{
"id": 1,
"user_id": null,
"code": "1234567890123",
"legal_entity_name": "test address",
"first_name": "Test",
"last_name": "Test",
"barcode": "123456789012378476234768", #unique field "accumulatedamount": "5166.00", "sex": "m", "dateof_birth": "2006-07-08", "address": "test address" }
14.Endpoint “Custom Entities”**
If the site requires some of its own additional entities, for example Author, Publisher, etc., they can be created, updated and linked to products.
[GET] external/custom-instance/ - all custom site entities
[GET] external/custom-instance/{id} - one custom site entity
[PUT] external/custom-instance/{id} - update custom site entity
[PUT] external/custom-instance/bulk-update/ - update several custom entities
*[POST] external/custom-instance/bulk-create/ - *create several custom entities
{
"slug": "author22",
"active": true,
"group_code_id": "code25",
"order": 4,
"name_ro": "Author_ro2",
"name_ru": "Author_ru2",
"name_en": "Author_en2",
"name_uk": "Author2",
"plural_name_ro": "Author_ro2",
"plural_name_ru": "Author_ru2",
"plural_name_en": "Author_en2",
"plural_name_uk": "Author_uk2",
"seo_title_ro": "int",
"seo_title_ru": "int",
"seo_title_en": "int",
"seo_title_uk": "int",
"seo_keywords_ro": "int",
"seo_keywords_ru": "int",
"seo_keywords_en": "int",
"seo_keywords_uk": "int",
"seo_description_ro": "int",
"seo_description_ru": "int",
"seo_description_en": "int",
"seo_description_uk": "int"
}
*
*
15. Endpoint “Elements of custom entities”
If the site requires some of its own additional entities, for example Author, Publisher, etc.
The “Author” entity is created and the elements of this entity themselves can be inserted into it, for example “Author1”, “Author2”.
[GET] external/custom-instance-item/ - all elements are custom site entities
[GET] external/custom-instance-item/{id} - one element of a custom site entity
[PUT] external/custom-instance-item/{id} - update custom site entity elements
[PUT] external/custom-instance-item/bulk-update/ - update multiple items custom entities
[POST] external/custom-instance-item/bulk-create/ - create several custom entity items
{
"id": 1,
"slug": "author3556",
"active": true,
"group_code_id": "12455",
"order": 5,
"custom_instance": 1, # ID of the element from “Custom Entities” for example “Author”
"name_ro": "Author_name_ro3",
"name_ru": "Author_name_ro3",
"name_en": "Author_name_ro3",
"name_uk": "Author_name_ro3",
"description_ro": "Author_description_ro3",
"description_ru": "Author_description_ro3",
"description_en": "Author_description_ro3",
"description_uk": "Author_description_ro3",
"seo_title_ro": "seo_title3",
"seo_title_ru": "seo_title3",
"seo_title_en": "seo_title3",
"seo_title_uk": "seo_title3",
"seo_keywords_ro": "seo_keywords3",
"seo_keywords_ru": "seo_keywords3",
"seo_keywords_en": "seo_keywords3",
"seo_keywords_uk": "seo_keywords3",
"seo_description_ro": "seo_description3",
"seo_description_ru": "seo_description3",
"seo_description_en": "seo_description3",
"seo_description_uk": "seo_description3"
}
Was the article helpful?
Yes, thank you! Unfortunately no