products.delete
The automation.deleteProducts method allows external systems (such as a PIM or ERP) to remove products data directly from Flipsnack.
Each request must include an apiKey, signature for authentication, a sourceHash to know exactly from which feed will the products be removed and the productHashes to be removed.Depending on the situation there might be the case when a while feed is removed and the results will be available under the Automation tab in the Design Studio.
Note: Requests must be made to https://api.flipsnack.com/v1.
Request parameters
Name
Type
Description
apiKey (required)
string
The API key provided for your user. If it is not specified, the request will return the error code "30 - Missing mandatory parameter". If the key is incorrect the request returns the error code "41 - Invalid credentials".
signature (required)
string
The signature must be calculated by you and added to the request. See How to sign a request for more information.If the parameter is missing the request will return the error code "30 - Missing mandatory parameter". If the signature is incorrect the request will return the error code "44 - Invalid signature".
action (required)
string
The API method that should be called. In this case the value should be products.update . If it is not specified, the request will return the error code "30 - Missing mandatory parameter".
sourceHash (required)
string
This needs to be a unique identifier within flipsnack to be able to update based on it the products and also to have the possibility to create multiple feeds from the same API
productsSKU (required)
array
It’s a list of products SKU. The method accepts one or multiple products SKU to be deleted
Response parameters
Name
Type
Description
code
string
Possible values:
200: When all goes well and action is executed correctly
400: When data submitted has invalid data of wrong format
401: Unauthorized access
Unexpected error
51: When the mac number of products sent is exceeded
30: Missing a mandatory parameter
status
string
Message related to code
Error codes
For complete list of error codes and messages go to API status codes section.
Example
This is an example of how the list of codes should look to be deleted:
SKU-01,SKU-02,SKU-03
We have 3 products to delete. If all the codes are from products, the deletion will be with success. If some of the codes are not correct or there are codes from variation, the deletion will be successful, if at least one is from a product.
Request
# GET
curl -X POST https://api.flipsnack.com/v1/ \
-F action=products.delete \
-F apiKey=<YOUR-API-KEY> \
-F signature=<YOUR-REQUEST-SIGNATURE> \
-F sourceHash=<YOUR-SOURCE-HASH> \
-F productsSKU="<YOUR-PRODUCTS-SKU>”
Response
{
"Code":200,
"status":"",
"data": {
"message":"Products deleted successfully",
"Errors":[]
}
}
{
"code": 30
"status": "Missing mandatory parameter”
"Data": [
Source hash parameter is missing
Products hashes parameter is missing
]
}
Last updated