Get product sharing
/products/get_product_sharing
Target audience: Developers
Get product sharing option¶
Introduction¶
This endpoint returns the sharing option for a product.
URI¶
Environment | URI |
---|---|
Stage | https://payway-api.stage.adeprimo.se/external/api/v1/products/get_product_sharing |
Production | https://backend.worldoftulo.com/external/api/v1/products/get_product_sharing |
Requirements¶
Identity | Scope |
---|---|
No | /external/product/r |
Parameters¶
Name | Description |
---|---|
id | The id of the product |
code | The code of the product |
Curl Example¶
Get by id¶
curl --request GET \
--url https://payway-api.stage.adeprimo.se/external/api/v1/products/get_product_sharing?id=52a781d6400e06897c00000f \
--header 'accept: application/json' \
--header 'authorization: Bearer <token>' \
Get by product code¶
curl --request GET \
--url https://payway-api.stage.adeprimo.se/external/api/v1/products/get_product_sharing?code=adeprimo_digital \
--header 'accept: application/json' \
--header 'authorization: Bearer <token>' \
Response¶
Successful response¶
HTTP 200
{
"item": [
{
"shareable": true,
"limit": 2,
"sharing_text": "Description of the sharing",
"sharing_title": "Title of the sharing",
"received_product_text": "Description of the product",
"received_product_title": "Title of the product"
}
]
}
Not shareable response¶
HTTP 200
{
"item": [
{
"shareable": false,
"limit": 0,
"sharing_text": null,
"sharing_title": null,
"received_product_text": null,
"received_product_title": null
}
]
}
Errors¶
This API uses the common error conventions of the Payway API