{
  "openapi": "3.0.0",
  "info": {
    "title": "nbadmin",
    "version": "0.0.1",
    "description": "NBAdmin project is product management tool",
    "contact": {
      "name": "mohammadfaisal1",
      "email": "mohammad@nextbraintech.com"
    }
  },
  "paths": {
    "/meeting-room/{uid}": {
      "patch": {
        "x-controller-name": "MeetingRoomController",
        "x-operation-name": "updateMeetingRoomById",
        "tags": [
          "MeetingRoomController"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "description": "Update meeting room"
                }
              }
            }
          }
        },
        "parameters": [
          {
            "name": "uid",
            "in": "path",
            "schema": {
              "type": "string"
            },
            "required": true
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "roomName",
                  "roomCode",
                  "locationId",
                  "seatingCapacity"
                ],
                "properties": {
                  "roomName": {
                    "type": "string"
                  },
                  "roomCode": {
                    "type": "string"
                  },
                  "roomDescription": {
                    "type": "string"
                  },
                  "locationId": {
                    "type": "string"
                  },
                  "blockName": {
                    "type": "string"
                  },
                  "roomFloor": {
                    "type": "string"
                  },
                  "seatingCapacity": {
                    "type": "integer"
                  },
                  "amentiesIds": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    }
                  },
                  "roomPhotos": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "maxAdvanceBooking": {
                    "type": "integer"
                  },
                  "maxBookingDuration": {
                    "type": "integer"
                  },
                  "bookingBuffer": {
                    "type": "integer"
                  },
                  "checkInGrace": {
                    "type": "integer"
                  },
                  "allowVisitorBooking": {
                    "type": "boolean"
                  },
                  "allowRecurringBooking": {
                    "type": "boolean"
                  },
                  "maxRecurringSpan": {
                    "type": "integer"
                  }
                }
              }
            }
          },
          "description": "Edit meeting room",
          "required": true,
          "x-parameter-index": 1
        },
        "operationId": "MeetingRoomController.updateMeetingRoomById"
      },
      "get": {
        "x-controller-name": "MeetingRoomController",
        "x-operation-name": "getMeetingRoomDetailsById",
        "tags": [
          "MeetingRoomController"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "description": "Delete meeting room"
                }
              }
            }
          }
        },
        "parameters": [
          {
            "name": "uid",
            "in": "path",
            "schema": {
              "type": "string"
            },
            "required": true
          }
        ],
        "operationId": "MeetingRoomController.getMeetingRoomDetailsById"
      },
      "delete": {
        "x-controller-name": "MeetingRoomController",
        "x-operation-name": "deleteMeetingRoomById",
        "tags": [
          "MeetingRoomController"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "description": "Delete meeting room"
                }
              }
            }
          }
        },
        "parameters": [
          {
            "name": "uid",
            "in": "path",
            "schema": {
              "type": "string"
            },
            "required": true
          }
        ],
        "operationId": "MeetingRoomController.deleteMeetingRoomById"
      }
    },
    "/meeting-room": {
      "post": {
        "x-controller-name": "MeetingRoomController",
        "x-operation-name": "create",
        "tags": [
          "MeetingRoomController"
        ],
        "responses": {
          "200": {
            "description": "Add meeting room",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MeetingRoom"
                }
              }
            }
          }
        },
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "roomName",
                  "roomCode",
                  "locationId",
                  "seatingCapacity"
                ],
                "properties": {
                  "roomName": {
                    "type": "string"
                  },
                  "roomCode": {
                    "type": "string"
                  },
                  "roomDescription": {
                    "type": "string"
                  },
                  "locationId": {
                    "type": "string"
                  },
                  "blockName": {
                    "type": "string"
                  },
                  "roomFloor": {
                    "type": "string"
                  },
                  "seatingCapacity": {
                    "type": "integer"
                  },
                  "amentiesIds": {
                    "type": "array",
                    "items": {
                      "type": "integer"
                    }
                  },
                  "roomPhotos": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "maxAdvanceBooking": {
                    "type": "integer"
                  },
                  "maxBookingDuration": {
                    "type": "integer"
                  },
                  "bookingBuffer": {
                    "type": "integer"
                  },
                  "checkInGrace": {
                    "type": "integer"
                  },
                  "allowVisitorBooking": {
                    "type": "boolean"
                  },
                  "allowRecurringBooking": {
                    "type": "boolean"
                  },
                  "maxRecurringSpan": {
                    "type": "integer"
                  }
                }
              }
            }
          },
          "description": "Add meeting room",
          "required": true
        },
        "operationId": "MeetingRoomController.create"
      },
      "get": {
        "x-controller-name": "MeetingRoomController",
        "x-operation-name": "find",
        "tags": [
          "MeetingRoomController"
        ],
        "responses": {
          "200": {
            "description": "List of meeting rooms",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/MeetingRoomWithRelations"
                  }
                }
              }
            }
          }
        },
        "operationId": "MeetingRoomController.find"
      }
    }
  },
  "servers": [
    {
      "url": "https://dev-meroom.khayash.com"
    }
  ],
  "components": {
    "schemas": {
      "MeetingRoom": {
        "title": "MeetingRoom",
        "type": "object",
        "properties": {
          "id": {
            "type": "number"
          },
          "uid": {
            "type": "string"
          },
          "roomName": {
            "type": "string"
          },
          "roomCode": {
            "type": "string"
          },
          "blockName": {
            "type": "string"
          },
          "roomFloor": {
            "type": "string"
          },
          "seatingCapacity": {
            "type": "number"
          },
          "roomDescription": {
            "type": "string"
          },
          "bookingStatus": {
            "type": "string"
          },
          "isDeleted": {
            "type": "boolean"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "createdBy": {
            "type": "string"
          },
          "updatedBy": {
            "type": "string"
          },
          "locationId": {
            "type": "string"
          },
          "orgId": {
            "type": "number"
          }
        },
        "required": [
          "uid",
          "roomName",
          "roomCode",
          "bookingStatus",
          "createdBy",
          "updatedBy",
          "locationId",
          "orgId"
        ],
        "additionalProperties": false
      },
      "Location": {
        "title": "Location",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "uid": {
            "type": "string"
          },
          "name": {
            "type": "string",
            "maxLength": 255,
            "minLength": 3,
            "errorMessage": "Name should be atleast 3 and 255 characters"
          },
          "latitude": {
            "type": "string"
          },
          "longitude": {
            "type": "string"
          },
          "address": {
            "type": "string"
          },
          "status": {
            "type": "number"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "is_deleted": {
            "type": "boolean"
          },
          "is_default": {
            "type": "boolean"
          },
          "org_id": {
            "type": "number"
          },
          "created_by": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "latitude",
          "longitude",
          "status"
        ],
        "additionalProperties": false
      },
      "Organization": {
        "title": "Organization",
        "type": "object",
        "properties": {
          "id": {
            "type": "number"
          },
          "uid": {
            "type": "string"
          },
          "logo_image": {
            "type": "string"
          },
          "currency": {
            "type": "number"
          },
          "time_zone": {
            "type": "string"
          },
          "org_name": {
            "type": "string"
          },
          "address_line1": {
            "type": "string"
          },
          "address_line2": {
            "type": "string"
          },
          "city": {
            "type": "string"
          },
          "state": {
            "type": "string"
          },
          "mobile": {
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "country_id": {
            "type": "number"
          },
          "pincode": {
            "type": "string"
          },
          "gst_number": {
            "type": "string"
          },
          "website_url": {
            "type": "string"
          },
          "category_id": {
            "type": "number"
          },
          "created_by": {
            "type": "string"
          },
          "status": {
            "type": "number"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "is_primary": {
            "type": "number"
          },
          "subscription_count": {
            "type": "number"
          },
          "trial_ends_at": {
            "type": "string",
            "format": "date-time"
          },
          "subscription_id": {
            "type": "string"
          },
          "subscription_status": {
            "type": "string"
          },
          "customer_id": {
            "type": "string"
          },
          "plan_id": {
            "type": "string"
          },
          "plan_count": {
            "type": "number"
          },
          "subscribe_id": {
            "type": "number"
          },
          "subscription_cancelled_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "uid"
        ],
        "additionalProperties": false
      },
      "MeetingRoomWithRelations": {
        "title": "MeetingRoomWithRelations",
        "type": "object",
        "description": "(tsType: MeetingRoomWithRelations, schemaOptions: { includeRelations: true })",
        "properties": {
          "id": {
            "type": "number"
          },
          "uid": {
            "type": "string"
          },
          "roomName": {
            "type": "string"
          },
          "roomCode": {
            "type": "string"
          },
          "blockName": {
            "type": "string"
          },
          "roomFloor": {
            "type": "string"
          },
          "seatingCapacity": {
            "type": "number"
          },
          "roomDescription": {
            "type": "string"
          },
          "bookingStatus": {
            "type": "string"
          },
          "isDeleted": {
            "type": "boolean"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "createdBy": {
            "type": "string"
          },
          "updatedBy": {
            "type": "string"
          },
          "locationId": {
            "type": "string"
          },
          "orgId": {
            "type": "number"
          },
          "locationData": {
            "$ref": "#/components/schemas/Location"
          },
          "foreignKey": {},
          "orgData": {
            "$ref": "#/components/schemas/Organization"
          }
        },
        "required": [
          "uid",
          "roomName",
          "roomCode",
          "bookingStatus",
          "createdBy",
          "updatedBy",
          "locationId",
          "orgId"
        ],
        "additionalProperties": false,
        "x-typescript-type": "MeetingRoomWithRelations"
      }
    },
    "securitySchemes": {
      "jwt": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    }
  },
  "security": [
    {
      "jwt": []
    }
  ]
}