Change distribution method
/v2/distribution/change_distribution_method
Target audience: Developers
Release version: 4.5.0
Change distribution method¶
Introduction¶
This endpoint changes the distribution method for a specific distribution identified by distribution_settings_id.
Note that the distribution method can only be modified for user products containing paper products.
URI¶
| Environment | URI |
|---|---|
| Stage | https://payway-api.stage.adeprimo.se/external/api/v2/distribution/change_distribution_method |
| Production | https://backend.worldoftulo.com/external/api/v2/distribution/change_distribution_method |
Requirements¶
| Identity | Scope |
|---|---|
| No | /external/distribution/w |
Parameters¶
| Field | Required | Type | Description |
|---|---|---|---|
| requested_by | Yes | String | Who requested the change. Max length: 25 |
| distribution_settings_id | Yes | String | The id of the distribution to update. Max length: 50 |
| distribution_method | Yes | String | The new distribution method. Max length: 25 |
Curl Example¶
curl --request PUT \
--url https://payway-api.stage.adeprimo.se/external/api/v2/distribution/change_distribution_method \
--header 'accept: application/json' \
--header 'authorization: Bearer <token>' \
--header 'content-type: application/json' \
--data '{
"requested_by": "my_system",
"distribution_settings_id": "60f1a2b3c4d5e6f7a8b9c0d1",
"distribution_method": "postnord"
}'
Response¶
Successful response¶
HTTP 200
{
"item": "60f1a2b3c4d5e6f7a8b9c0d1"
}
Errors¶
This API uses the common error conventions of the Payway API
| Code | Description |
|---|---|
| invalid_user_product | The user product is not a paper product |