Toggle Promotion

Toggle Promotion

POST /cm/promotion/toggle

Description

This section outlines the feature to activate or deactivate a promotion.

Body parameter

HotelPromotionToggle_RQ must be supplied.

Name : body
Flags : required
Type : HotelPromotionToggle_RQ

Responses

HTTP Code Description Schema

200

The promotion has been toggled successfully

No Content

204

The promotion has been toggled already

No Content

400

The request content was malformed

No Content

401

The supplier was unauthorized

No Content

Consumes

application/xml

Produces

application/xml

Tags

PromotionToggle

Security

Type Name

apiKey

Example HTTP request

Request Path

/cm/promotion/toggle

Request body

<?xml version="1.0" encoding="UTF-8"?>
<HotelPromotionToggle_RQ HotelId="680674" IsActive="true" PromotionId="750566" Timestamp="1605243776"/>

Example HTTP response

Response 200

<?xml version="1.0" encoding="UTF-8"?>
<HotelPromotion_RS Tuid="000-000-0000" PromotionId=12345>
  <Success/>
</HotelPromotion_RS>

Response 204

<?xml version="1.0" encoding="UTF-8"?>
<HotelPromotion_RS>
<Errors>
  <Error Code="444" ShortText="The promotion has been toggled already" Status="NotProcessed"/>
</Errors>
</HotelPromotion_RS>

Response 400

<?xml version="1.0" encoding="UTF-8"?>
<HotelPromotion_RS>
<Errors>
  <Error Code="321" ShortText="Required field missing" Status="NotProcessed"/>
</Errors>
</HotelPromotion_RS>

Response 401

<?xml version="1.0" encoding="UTF-8"?>
<HotelPromotion_RS>
<Errors>
  <Error Code="497" ShortText="Authorization error" Status="NotProcessed"/>
</Errors>
</HotelPromotion_RS>