Example 2: Void Transactions

Steps to recreate

  • Generate initial transactions on Cloudbeds
    • Create fee
    • Create a tax on the fee
    • Create accommodation and room rate
  • Create a reservation for past 1 night
  • Add Exclusive Fee
    • Tax on top of the fee will be added
  • Void Exclusive Fee
  • Void Tax on top of Fee

What Changes

In this example nothing changes. Before and after the void this returns 5 transactions.

Example Request and Response

Transactions from Accounting Service

Curl Request

curl --location 'https://api.cloudbeds-stage.com/accounting/v1.0/transactions'
--header 'content-type: application/json'
--header 'Authorization: Bearer INSERT_TOKEN'
--header 'X-Property-Id: 1137892'
--data '{
"filters": {
"and": [
{
"operator": "equals",
"value": "27975057",
"field": "SOURCE_ID"
},
{
"operator": "equals",
"value": "RESERVATION",
"field": "SOURCE_KIND"
}
]
},
"pageSize": 100,
"orderBy": [
{
"field": "ID",
"direction": "asc"
}
]
}'

JSON Response

[
{
"id": "55021335515274",
"propertyId": "1137892",
"internalTransactionCode": "1000",
"customTransactionCode": null,
"generalLedgerCustomCode": null,
"amount": 50.00,
"currency": "USD",
"customerId": "27007171",
"rootId": "55021335515274",
"parentId": null,
"sourceId": "27975057",
"subSourceId": "40211181",
"sourceKind": "RESERVATION",
"account": null,
"externalRelationId": "40211181",
"externalRelationKind": "ROOM",
"originId": "541285",
"routedFrom": null,
"quantity": 1,
"description": "Room rate - Queen",
"userId": "0",
"sourceDatetime": "2025-01-02T13:52:36.895131Z",
"transactionDatetime": "2025-01-02T13:52:36.895131Z",
"transactionDatetimePropertyTime": "2025-01-02T13:52:36.895131Z",
"serviceDate": "2025-01-01",
"createdAt": "2025-01-02T13:52:36.895567Z"
},
{
"id": "55021335515276",
"propertyId": "1137892",
"internalTransactionCode": "8100",
"customTransactionCode": null,
"generalLedgerCustomCode": null,
"amount": 10.00,
"currency": "USD",
"customerId": "27007171",
"rootId": "55021335515276",
"parentId": null,
"sourceId": "27975057",
"subSourceId": "40211181",
"sourceKind": "RESERVATION",
"account": null,
"externalRelationId": "55052009722024",
"externalRelationKind": "FEE",
"originId": "191015",
"routedFrom": null,
"quantity": 1,
"description": "fee",
"userId": "0",
"sourceDatetime": "2025-01-02T13:53:32.171752Z",
"transactionDatetime": "2025-01-02T13:53:32.171752Z",
"transactionDatetimePropertyTime": "2025-01-02T13:53:32.171752Z",
"serviceDate": "2025-01-02",
"createdAt": "2025-01-02T13:53:32.172816Z"
},
{
"id": "55021335515277",
"propertyId": "1137892",
"internalTransactionCode": "8000",
"customTransactionCode": null,
"generalLedgerCustomCode": null,
"amount": 0.35,
"currency": "USD",
"customerId": "27007171",
"rootId": "55021335515277",
"parentId": "55021335515276",
"sourceId": "27975057",
"subSourceId": "40211181",
"sourceKind": "RESERVATION",
"account": null,
"externalRelationId": "55052009722024",
"externalRelationKind": "FEE",
"originId": "274793",
"routedFrom": null,
"quantity": 1,
"description": "tax",
"userId": "0",
"sourceDatetime": "2025-01-02T13:53:32.171752Z",
"transactionDatetime": "2025-01-02T13:53:32.171752Z",
"transactionDatetimePropertyTime": "2025-01-02T13:53:32.171752Z",
"serviceDate": "2025-01-02",
"createdAt": "2025-01-02T13:53:32.172879Z"
},
{
"id": "55083453173893",
"propertyId": "1137892",
"internalTransactionCode": "8100V",
"customTransactionCode": null,
"generalLedgerCustomCode": null,
"amount": -10.00,
"currency": "USD",
"customerId": "27007171",
"rootId": "55021335515276",
"parentId": null,
"sourceId": "27975057",
"subSourceId": "40211181",
"sourceKind": "RESERVATION",
"account": null,
"externalRelationId": "55052009722024",
"externalRelationKind": "FEE",
"originId": "191015",
"routedFrom": null,
"quantity": 1,
"description": "fee",
"userId": "0",
"sourceDatetime": "2025-01-02T13:53:31Z",
"transactionDatetime": "2025-01-02T14:13:37.431027Z",
"transactionDatetimePropertyTime": "2025-01-02T14:13:37.431027Z",
"serviceDate": "2025-01-02",
"createdAt": "2025-01-02T14:13:37.431089Z"
},
{
"id": "55083453173896",
"propertyId": "1137892",
"internalTransactionCode": "8000V",
"customTransactionCode": null,
"generalLedgerCustomCode": null,
"amount": -0.35,
"currency": "USD",
"customerId": "27007171",
"rootId": "55021335515277",
"parentId": null,
"sourceId": "27975057",
"subSourceId": "40211181",
"sourceKind": "RESERVATION",
"account": null,
"externalRelationId": "55052009722024",
"externalRelationKind": "FEE",
"originId": "274793",
"routedFrom": null,
"quantity": 1,
"description": "tax",
"userId": "0",
"sourceDatetime": "2025-01-02T13:53:31Z",
"transactionDatetime": "2025-01-02T14:13:37.43329Z",
"transactionDatetimePropertyTime": "2025-01-02T14:13:37.43329Z",
"serviceDate": "2025-01-02",
"createdAt": "2025-01-02T14:13:37.433311Z"
}
]



Transactions from Cloudbeds API GetTransactions when property is NOT transitioned to the Cloudbeds Accounting Service


Curl Request

curl --location 'https://hotels.cloudbeds-stage.com/api/v1.1/getTransactions?propertyID=1137892&reservationId=4244170543060&pageSize=20&includeDeleted=true'
--header 'Authorization: Bearer INSERT_TOKEN'
--header 'X-PROPERTY-ID: 1137892'

JSON Response

[{
"propertyID": "1137892",
"reservationID": "4244170543060",
"subReservationID": "4244170543060",
"houseAccountID": null,
"houseAccountName": null,
"guestID": "27007171",
"propertyName": "ACC-TEST-37c15c3d-61c6-4655-a53e-40793c43ef7b",
"transactionDateTime": "2025-01-02 13:53:52",
"transactionDateTimeUTC": "2025-01-02 13:53:52",
"transactionModifiedDateTime": "2025-01-02 13:53:52",
"transactionModifiedDateTimeUTC": "2025-01-02 13:53:52",
"guestCheckIn": "2025-01-01",
"guestCheckOut": "2025-01-02",
"roomTypeID": "541285",
"roomTypeName": "Queen",
"roomName": "QUE1",
"guestName": "Test Vod vod",
"description": "tax (Void)",
"category": "Taxes",
"transactionCode": "Yen",
"notes": "",
"quantity": "1",
"amount": -0.35,
"currency": "USD",
"userName": "SYSTEM",
"transactionType": "debit",
"transactionCategory": "void",
"itemCategoryName": "void",
"transactionID": "55052009722028",
"parentTransactionID": "55052009722025",
"cardType": null,
"isDeleted": false
},
{
"propertyID": "1137892",
"reservationID": "4244170543060",
"subReservationID": "4244170543060",
"houseAccountID": null,
"houseAccountName": null,
"guestID": "27007171",
"propertyName": "ACC-TEST-37c15c3d-61c6-4655-a53e-40793c43ef7b",
"transactionDateTime": "2025-01-02 13:53:40",
"transactionDateTimeUTC": "2025-01-02 13:53:40",
"transactionModifiedDateTime": "2025-01-02 13:53:40",
"transactionModifiedDateTimeUTC": "2025-01-02 13:53:40",
"guestCheckIn": "2025-01-01",
"guestCheckOut": "2025-01-02",
"roomTypeID": "541285",
"roomTypeName": "Queen",
"roomName": "QUE1",
"guestName": "Test Vod vod",
"description": "fee (Void)",
"category": "Fees",
"transactionCode": "Yen",
"notes": "",
"quantity": "1",
"amount": -10,
"currency": "USD",
"userName": "SYSTEM",
"transactionType": "debit",
"transactionCategory": "void",
"itemCategoryName": "void",
"transactionID": "55052009722027",
"parentTransactionID": "55052009722024",
"cardType": null,
"isDeleted": false
},
{
"propertyID": "1137892",
"reservationID": "4244170543060",
"subReservationID": "4244170543060",
"houseAccountID": null,
"houseAccountName": null,
"guestID": "27007171",
"propertyName": "ACC-TEST-37c15c3d-61c6-4655-a53e-40793c43ef7b",
"transactionDateTime": "2025-01-02 13:53:31",
"transactionDateTimeUTC": "2025-01-02 13:53:31",
"transactionModifiedDateTime": "2025-01-02 13:53:31",
"transactionModifiedDateTimeUTC": "2025-01-02 13:53:31",
"guestCheckIn": "2025-01-01",
"guestCheckOut": "2025-01-02",
"roomTypeID": "541285",
"roomTypeName": "Queen",
"roomName": "QUE1",
"guestName": "Test Vod vod",
"description": "tax",
"category": "Taxes",
"transactionCode": "Yen",
"notes": "",
"quantity": "1",
"amount": 0.35,
"currency": "USD",
"userName": "SYSTEM",
"transactionType": "debit",
"transactionCategory": "tax",
"itemCategoryName": "tax",
"transactionID": "55052009722025",
"parentTransactionID": "55052009722024",
"cardType": null,
"isDeleted": false
},
{
"propertyID": "1137892",
"reservationID": "4244170543060",
"subReservationID": "4244170543060",
"houseAccountID": null,
"houseAccountName": null,
"guestID": "27007171",
"propertyName": "ACC-TEST-37c15c3d-61c6-4655-a53e-40793c43ef7b",
"transactionDateTime": "2025-01-02 13:53:31",
"transactionDateTimeUTC": "2025-01-02 13:53:31",
"transactionModifiedDateTime": "2025-01-02 13:53:31",
"transactionModifiedDateTimeUTC": "2025-01-02 13:53:31",
"guestCheckIn": "2025-01-01",
"guestCheckOut": "2025-01-02",
"roomTypeID": "541285",
"roomTypeName": "Queen",
"roomName": "QUE1",
"guestName": "Test Vod vod",
"description": "fee",
"category": "Fees",
"transactionCode": "Yen",
"notes": "",
"quantity": "1",
"amount": 10,
"currency": "USD",
"userName": "SYSTEM",
"transactionType": "debit",
"transactionCategory": "fee",
"itemCategoryName": "fee",
"transactionID": "55052009722024",
"parentTransactionID": "",
"cardType": null,
"isDeleted": false
},
{
"propertyID": "1137892",
"reservationID": "4244170543060",
"subReservationID": "4244170543060",
"houseAccountID": null,
"houseAccountName": null,
"guestID": "27007171",
"propertyName": "ACC-TEST-37c15c3d-61c6-4655-a53e-40793c43ef7b",
"transactionDateTime": "2025-01-01 23:59:00",
"transactionDateTimeUTC": "2025-01-01 23:59:00",
"transactionModifiedDateTime": "2025-01-02 13:52:36",
"transactionModifiedDateTimeUTC": "2025-01-02 13:52:36",
"guestCheckIn": "2025-01-01",
"guestCheckOut": "2025-01-02",
"roomTypeID": "541285",
"roomTypeName": "Queen",
"roomName": "QUE1",
"guestName": "Test Vod vod",
"description": "Room rate - Queen",
"category": "Room Revenue",
"transactionCode": "",
"notes": "",
"quantity": "1",
"amount": 50,
"currency": "USD",
"userName": "SYSTEM",
"transactionType": "debit",
"transactionCategory": "rate",
"itemCategoryName": "rate",
"transactionID": "55052009722022",
"parentTransactionID": "",
"cardType": null,
"isDeleted": false
}
]