The Xenia Connect API provides a sandbox environment for testing your integration without affecting production data. The sandbox environment includes special endpoints that allow you to simulate state changes and trigger webhook events for testing purposes.
- Base URL:
https://api-xenia-cisandbox.staysitu.com - Authentication: Use your sandbox API key (same authentication method as production)
The sandbox environment provides two special endpoints under the /external-api/v1/sandbox path that are not available in production. These endpoints are designed to help you test your integration thoroughly.
Endpoint: POST /external-api/v1/sandbox/enquiries/{id}/change-state
This endpoint allows you to programmatically change the state of an enquiry to trigger relevant webhook events and test your integration's handling of different enquiry states.
- Progressive State Changes: You cannot move backwards in states, only forward
- Cascading State Triggers: Specifying a later state (e.g.,
QUOTED) will automatically trigger all eligible intermediate states (e.g.,SHORTLISTINGthenQUOTED) - Exception States: Some states like
CLOSEDcan occur at any point in the journey
Path Parameter:
id(required): Can be either the enquiry'sxeniaReferenceor yourexternalId
Request Body:
{ "enquiryState": "QUOTED", "closureReason": "PRICE" // Optional, only for CLOSED state }
For all available states, please refer to the API specification.
curl -X POST "https://api-xenia-cisandbox.staysitu.com/external-api/v1/sandbox/enquiries/R4E2F3A4/change-state" \
-H "X-Api-Key: your-sandbox-api-key" \
-H "Content-Type: application/json" \
-d '{
"enquiryState": "CLOSED",
"closureReason": "PRICE"
}'Endpoint: POST /external-api/v1/sandbox/enquiries/{id}/trigger-webhook-event
This endpoint allows you to manually trigger specific webhook events for an enquiry without changing its state. This is particularly useful for testing webhook handling and retry logic.
Path Parameter:
id(required): Can be either the enquiry'sxeniaReferenceor yourexternalId
Request Body:
{ "eventType": "ENQUIRY.CREATED" }
For all available webhook event types, please refer to the API specification.
curl -X POST "https://api-xenia-cisandbox.staysitu.com/external-api/v1/sandbox/enquiries/R4E2F3A4/trigger-webhook-event" \
-H "X-Api-Key: your-sandbox-api-key" \
-H "Content-Type: application/json" \
-d '{
"eventType": "ENQUIRY.CREATED"
}'