Replace add-on sales channels
const url = 'https://api.wink.travel/api/managing-entity/d5b8a3c2-9e6f-4a1b-8d34-7c2e1f0a5b69/extranet/sales/add-on/example/sales-channel';const options = { method: 'PUT', headers: { 'Wink-Version': '2.0', Authorization: 'Bearer <token>', 'Content-Type': 'application/json' }, body: '{"salesChannelIds":["example"]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://api.wink.travel/api/managing-entity/d5b8a3c2-9e6f-4a1b-8d34-7c2e1f0a5b69/extranet/sales/add-on/example/sales-channel \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --header 'Wink-Version: 2.0' \ --data '{ "salesChannelIds": [ "example" ] }'Replaces the full sales-channel membership of the given add-on with the channel IDs in the request body, then returns the updated list.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The property ID to update sales channels for
Example
d5b8a3c2-9e6f-4a1b-8d34-7c2e1f0a5b69The add-on ID to update sales channels for
Header Parameters
Section titled “Header Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”Replace sales channels request body
Request to replace the full sales-channel membership of a single add-on or master rate.
object
The full set of sales-channel ids this item should be offered on; replaces the stored membership
Example generated
{ "salesChannelIds": [ "example" ]}Responses
Section titled “Responses”Sales channels for the property with membership for the given add-on, after the replace
Immutable value object representing a selectable option with value, label, and selection state.
object
English readable text of the value.
Whether record is selected or not.
The value that should be persisted.
Example
[ { "label": "Free WiFi", "selected": true, "value": "free-wifi" }]Bad Request — missing or invalid request parameter or body
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}Unauthorized — authentication is required or the session has expired
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}Forbidden — authenticated but lacking the required permission or scope
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}Not Found — the requested resource does not exist
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}Method Not Allowed — the HTTP verb is not supported on this endpoint
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}Conflict — the resource was modified by someone else since you read it; re-read it and retry with the new version
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}Unsupported Media Type — use application/json
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}Internal Server Error — an unexpected failure occurred on the server
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}Service Unavailable — a downstream dependency is unreachable
object
object
Example generated
{ "detail": "example", "instance": "https://example.com", "properties": { "additionalProperty": "example" }, "status": 1, "title": "example", "type": "https://example.com"}