Skip to main content

Edit Collection

Method#

/catalogs/collection-edit/{{collection-id}}#

POST https://api.z-api.io/instances/{{instanceId}}/token/{{instanceToken}}/catalogs/collection-edit/{{collection-id}}

Header#

KeyValue
Client-TokenACCOUNT SECURITY TOKEN

Concept#

Using this method, you will be able to edit a product collection in your catalog.


Attributes#

Required#

AttributesTypeDescription
namestringNew collection name

Request Body#

{
"name": "New collection name"
}

Response#

200#

AttributesTypeDescription
successbooleantrue if successful, false in case of failure
collectionIdstringCollection ID

Example

{
"success": true,
"collectionId": "228078660281007"
}

405#

In this case, ensure that you are sending the method specification correctly, i.e., check if you sent the POST or GET as specified at the beginning of this topic.

415#

If you receive a 415 error, make sure to add the "Content-Type" of the object you are sending in the request headers, in most cases, it should be "application/json".


Code#