Retrieve Unit Images
Returns images for the Inventory
Overview
The Retrieve Unit Images request is designed to provide partners with access to images associated with the Inventory. This request enables the Agent to retrieve images for either the entire inventory or a specific unit.
Endpoints Available
Method | Endpoint | Description |
---|---|---|
GET | v2024.07.31/unit_images | Returns content images for units in the inventory. |
GET | v2024.07.31/unit_images/{unit_id} | Returns content images for a specified unit in the inventory. |
Path Parameters
Path Parameter | Required / Optional | Description |
---|---|---|
{unit_id} | Required | Unique Identifier for a unit in the inventory. |
Query String Parameters
Parameter | Required / Optional | Description | Data Type |
---|---|---|---|
page | Optional | The page to be shown (defaults to 1). | int |
page_size | Optional | Limits the number of returned results (defaults to 25). | int |
last_unit_update_date | Optional | Only return units that have been modified after the specified date. | date-time |
last_reservation_update_date | Optional | Only return units that have received a booking (their own or a calendar sync) after the specified date. | date-time |
last_agent_module_property_update_date | Optional | Only return units that have had their agent module property configuration modified after the specified date. | date-time |
last_agent_module_agent_update_date | Optional | Only return units that have had their agent module agent configuration modified after the specified date. | date-time |
unit_id | Optional | Unique Identifier for Unit in Inventory | int |
unit_ids | Optional | Unique Identifier for Units in Inventory | array |
management_company_user_id | Optional | Unique Identifier for Supplier | int |
management_company_user_ids | Optional | Unique Identifiers for Suppliers | array |
enabled | Optional | Use only enabled or disabled units. | boolean |
deleted | Optional | Only show properties that are deleted or not deleted. | boolean |
display_on_website | Optional | Only show properties that are enabled for the management company's website. | boolean |
allocation_on_arrival | Optional | Return the allocation on arrival object. | boolean |
allocation_on_arrival_unit | Optional | Return units that are the representative unit in their group. | boolean |
channel | Optional | Leave empty for general, "airbnb" for airbnb, "vrbo" for vrbo and "bdc" for bdc | string |
Response Definition
Response Item | Description | Data Type |
---|---|---|
"unit_images" | An array containing information about different units. Each element in the array represents unique unit details associated with the unit's Images | array |
"unit_images"
Object
"unit_images"
ObjectResponse Item | Description | Data Type |
---|---|---|
"unit_id" | The unique identifier for the Unit | int |
"management_company_user_id" | The ID of the management company assigned to the unit. | int |
"images" | An array containing details about images associated with the Unit | array |
"error" (Optional) | Error object indicating an issue with the unit (If applicable). | object |
"images"
Object
"images"
ObjectResponse Item | Description | Data Type |
---|---|---|
"id" | The unique identifier for the image. | int |
"sort_order" | The value representing the order of the image in a sequence or gallery. | int |
"resource" | The URL that points to the location of the image resource. | string |
"tag" | A tag or label associated with the image, providing additional context or description (defaults to original filename if not updated by the management company). | string |
"error"
Object
"error"
ObjectResponse Item | Description | Data Type |
---|---|---|
"message" | A descriptive message for the error (e.g., deletion). | string |
Sample Request
curl --location 'https://api.ciiruspartners.com/v2024.07.31/unit_images?page=1&page_size=25' \
--header 'Authorization: Basic {APIUsername:APIPassword}'
Sample Response
{
"unit_images": [
{
"unit_id": 219264,
"management_company_user_id": 42330,
"images": [
{
"id": 1413701,
"sort_order": 2,
"resource": "https://cdn.ciirus.com/properties/42334/219264/images/download(2).jpg",
"tag": "download(2)"
},
{
"id": 1413702,
"sort_order": 3,
"resource": "https://cdn.ciirus.com/properties/42334/219264/images/download.jpg",
"tag": "download"
},
{
"id": 1413703,
"sort_order": 4,
"resource": "https://cdn.ciirus.com/properties/42334/219264/images/images(1).jpg",
"tag": "images(1)"
},
...
...
{
"unit_id": 222003,
"management_company_user_id": 42330,
"images": [
{
"id": 1413735,
"sort_order": 1,
"resource": "https://cdn.ciirus.com/properties/37284/217105/images/download.jpg",
"tag": "download"
},
{
"id": 1413736,
"sort_order": 2,
"resource": "https://cdn.ciirus.com/properties/37284/217105/images/images(1).jpg",
"tag": "images(1)"
},
{
"id": 1413738,
"sort_order": 3,
"resource": "https://cdn.ciirus.com/properties/37284/217105/images/images.jpg",
"tag": "images"
}
],
"error": {
"message": "Property has been deleted."
}
},
]
},
],
"paging": {
"next_page_url": "https://api.ciiruspartners.com/v2024.07.31/unit_images?page=2&page_size=25",
"total_page_count": 13,
"page": 1,
"page_size": 25
}
}
Updated 1 day ago