This is an old revision of the document!
Teamamerica Delta API Documentation
Overview
This API provides access to a list of hotels and rooms that have been created, updated, or deleted within a specific time frame. The response is formatted in XML and contains detailed information about each record, including date ranges for changes.
## Request Structure
To retrieve updated data, send an XML request formatted as follows:
### Request XML Example
```xml <RetrieveUpdatedData>
<UserName>username</UserName> <Password>********</Password> <OrderCode></OrderCode> <!-- Optional --> <ListID></ListID> <!-- Optional --> <LastSynced>2023-10-02T12:00:00Z</LastSynced> <IncludeDeleted>0</IncludeDeleted>
</RetrieveUpdatedData> ```
### Request Parameters
| Parameter | Type | Required | Description |
| ————– | ——- | ——– | ——————————————————– |
| UserName | String | Yes | API username for authentication |
| Password | String | Yes | API password for authentication |
| OrderCode | String | No | Filter records by order code |
| ListID | String | No | Filter records by list ID |
| LastSynced | String | Yes | Timestamp of the last synchronization in ISO 8601 format |
| IncludeDeleted | Integer | No | Whether to include deleted records (0 = No, 1 = Yes) |
## Response Structure
The response XML contains a timestamp and a list of updated records.
### Response XML Example
```xml <TimeStamp>2023-10-02T12:00:00Z</TimeStamp> <Lists>
<List id="1">
<ListItem code="ASDFG">
<Created>
<DateRange>
<From>2025-09-11</From>
<To>2025-09-30</To>
</DateRange>
<DateRange>
<From>2025-10-15</From>
<To>2025-10-31</To>
</DateRange>
</Created>
<Updated>
<Rate>
<DateRange>
<From>2025-07-11</From>
<To>2025-07-15</To>
</DateRange>
<DateRange>
<From>2025-07-19</From>
<To>2025-07-25</To>
</DateRange>
</Rate>
<Inventory>
<Status Type="AS">
<DateRange>
<From>2025-07-11</From>
<To>2025-07-15</To>
</DateRange>
</Status>
<Status Type="SE">
<DateRange>
<From>2025-07-11</From>
<To>2025-07-15</To>
</DateRange>
</Status>
</Inventory>
</Updated>
<Deleted>
<DateRange>
<From>2025-07-11</From>
<To>2025-07-15</To>
</DateRange>
</Deleted>
</ListItem>
</List>
</Lists> ```
### Response Elements
| Element | Description |
| ——— | ———————————————————- |
| TimeStamp | The timestamp of the response in ISO 8601 format |
| Lists | Container for all record lists |
| List | A collection of items, each identified by an ID |
| ListItem | A specific item within a list, identified by a unique code |
| Created | Contains date ranges indicating when the item was created |
| Updated | Contains details about rate and inventory changes |
| Deleted | Contains date ranges indicating when the item was deleted |
### Updated Data
- Rate: Changes in pricing, with associated date ranges. - Inventory: Status updates with specified types (e.g., “AS”, “SE”).
## Error Handling
If an error occurs, the API will return an error message in XML format:
```xml <Error>
<Code>401</Code> <Message>Unauthorized Access</Message>
</Error> ```
### Common Error Codes
| Code | Description |
| —- | —————————————- |
| 400 | Bad Request - Invalid input parameters |
| 401 | Unauthorized - Invalid credentials |
| 403 | Forbidden - Access denied |
| 500 | Internal Server Error - Unexpected error |
## Notes
- The API requires authentication using a valid username and password. - Date fields follow the format `YYYY-MM-DD`. - Ensure `LastSynced` is provided to fetch only the necessary changes.
For further assistance, contact API support.