For the complete documentation index, see llms.txt. This page is also available as Markdown.

Create Room Type API

Create a room type

post
/room_types

Create a room type for a property. The created room type is returned with 201 Created.

Authorizations
user-api-keystringRequired

API key for programmatic access, sent in the user-api-key header.

Body

Request body accepted when creating a room type.

Responses
201

201 Created response wrapping a resource body.

application/json

JSON:API document wrapping a single resource.

post/room_types
POST /api/v1/room_types HTTP/1.1
Host: app.channex.io
user-api-key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 534

{
  "room_type": {
    "title": "Standard Room",
    "count_of_rooms": 20,
    "occ_adults": 3,
    "occ_children": 0,
    "occ_infants": 0,
    "room_kind": "room",
    "capacity": 4,
    "codes": {
      "pms": "RT-42"
    },
    "meta": {},
    "property_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
    "facilities": [
      "716305c4-561a-4561-a187-7f5b8aeb5920"
    ],
    "content": {
      "description": "text",
      "photos": [
        {
          "id": "cc673f90-8d65-498d-9ee7-b4b39f8df3ee",
          "url": "https://example.com/temporaryphotos/a66edb22-47da-4da8-bab5-3b6f4056256f.png",
          "kind": "photo",
          "author": "John Doe",
          "description": "Room View",
          "is_removed": true
        }
      ]
    }
  }
}
{
  "data": {
    "type": "room_type",
    "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
    "attributes": {
      "id": "994d1375-dbbd-4072-8724-b2ab32ce781b",
      "position": 0,
      "title": "Standard Room",
      "count_of_rooms": 20,
      "occ_adults": 3,
      "occ_children": 0,
      "occ_infants": 0,
      "room_kind": "room",
      "capacity": 4,
      "codes": {
        "pms": "RT-42"
      },
      "meta": {},
      "content": {
        "description": "text",
        "photos": [
          {
            "id": "cc673f90-8d65-498d-9ee7-b4b39f8df3ee",
            "property_id": "52397a6e-c330-44f4-a293-47042d3a3607",
            "room_type_id": "716305c4-561a-4561-a187-7f5b8aeb5920",
            "kind": "photo",
            "position": 0,
            "author": "John Doe",
            "description": "Room View",
            "url": "https://images.channex.io/1747b751-28c0-47db-742a-40f62a186a00/"
          }
        ]
      }
    },
    "relationships": {
      "property": {
        "data": {
          "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
          "type": "property"
        }
      },
      "facilities": {
        "data": [
          {
            "type": "facility",
            "id": "716305c4-561a-4561-a187-7f5b8aeb5920",
            "attributes": {
              "id": "864d91a6-3a40-4098-a880-84b841e11adb",
              "category": "general",
              "title": "24-hour front desk"
            }
          }
        ]
      }
    }
  }
}

Last updated