application/json

Body

Request for creating/updating a room

  • name string Required

    Name

  • locationId string Required

    Location ID

Responses

  • 200 application/json

    successful operation

    Hide response attributes Show response attributes object
    • id string Required

      id

    • companyId string Required

      Company ID

    • locationId string Required

      Location ID

    • name string Required

      Name

    • archivedAt string(date-time) | null

      Archived at date

    • createdAt string(date-time)

      Created at date

    • updatedAt string(date-time)

      Updated at date

  • 403 application/json

    Not authorized

    Hide response attributes Show response attributes object

    Error schema

    • statusCode number Required

      Status Code

    • messages array[string] Required

      List of error messages

    • exception object

      Exception

  • 422 application/json

    Validation error

    Hide response attributes Show response attributes object
    • statusCode number Required

      Status Code

    • messages array[string] Required

      List of error messages

    • exception object

      Exception

POST /v1/rooms/
curl \
 --request POST 'https://classmanager.test/v1/rooms/' \
 --header "Content-Type: application/json" \
 --data '{"name":"Room 101","locationId":"loc_123123123123"}'
Request examples
{
  "name": "Room 101",
  "locationId": "loc_123123123123"
}
Response examples (200)
{
  "id": "room_xxxxxxxxxxx",
  "companyId": "co_123123123123",
  "locationId": "loc_123123123123",
  "name": "Main Room",
  "archivedAt": "2023-12-05 14:30:41",
  "createdAt": "2023-12-05 14:30:41",
  "updatedAt": "2023-12-05 14:30:41"
}
Response examples (403)
{
  "statusCode": 42.0,
  "messages": [
    "string"
  ],
  "exception": {}
}
Response examples (422)
{
  "statusCode": 42.0,
  "messages": [
    "string"
  ],
  "exception": {}
}