{ "openapi": "3.0.1", "info": { "title": "Infodeck.io", "description": "Infodeck.io - API documentation", "version": "1.30.2" }, "servers": [ { "url": "https://app.infodeck.io/api" } ], "paths": { "/organizations/{organizationId}/assets/batch": { "post": { "summary": "Batch Get Assets", "description": "Batch get assets", "operationId": "Asset.BatchGetAssets", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "assetIds": { "type": "string", "description": "The id of assets" } }, "required": [ "assetIds" ] }, "example": {}, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetTypeId": { "type": "string" }, "locationId": { "type": "string" }, "integrationServiceId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "chatRoomId": { "type": "string" }, "serialNumber": { "type": "string" }, "modelName": { "type": "string" }, "nameOfManufacturer": { "type": "string" }, "yearOfManufacture": { "type": "number" }, "purchaseCost": { "type": "number" }, "purchaseDate": { "type": "number" }, "warrantyEndDate": { "type": "number" }, "devEui": { "type": "string" }, "uuid": { "type": "string" }, "keepAlive": { "type": "number" }, "connectionStatus": { "type": "boolean" }, "status": { "type": "string" }, "shadows": { "type": "object", "properties": {}, "required": [] }, "createdAtDateString": { "type": "number" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetTypeId", "locationId", "integrationServiceId", "name", "description", "chatRoomId", "serialNumber", "modelName", "nameOfManufacturer", "yearOfManufacture", "purchaseCost", "purchaseDate", "warrantyEndDate", "shadows", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "a-assetId", "organizationId": "o-organizationId", "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "integrationServiceId": "is-integrationServiceId", "name": "IDT-Bot-Asset", "description": "IDT-Bot-Asset-Description", "chatRoomId": "ABCDE", "serialNumber": "123456789", "modelName": "Bot-Model-Name", "nameOfManufacturer": "Bot-Manufacturer", "yearOfManufacture": 2024, "purchaseCost": 12345, "purchaseDate": 1700000000000, "warrantyEndDate": 1800000000000, "devEui": "24e124535b312345", "uuid": "24e124535b312345", "keepAlive": 2592000, "connectionStatus": false, "status": "Normal", "shadows": { "DeviceUplink": { "state": { "reported": { "Payload": { "Temperature": 25.4, "Humidity": 62, "CO2": 869, "rssi": -91, "timestamp": 1711341602287 }, "ExpiredAt": 1711341602287 } }, "metadata": { "reported": { "Payload": { "Temperature": { "timestamp": 1711330802 }, "Humidity": { "timestamp": 1711330802 }, "CO2": { "timestamp": 1711330802 }, "rssi": { "timestamp": 1711330802 } }, "ExpiredAt": { "timestamp": 1711330802 } } }, "version": 21415, "timestamp": 1711330849 } }, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "400": { "description": "The request has invalid data.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has invalid data." }, "message": { "type": "string", "description": "The request has invalid data message." } }, "required": [ "error", "message" ] }, "example": { "error": "Bad Request", "message": "The request cannot be processed due to a bad request." }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/assets": { "post": { "summary": "Create Asset", "description": "Create asset", "operationId": "Asset.CreateAsset", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "assetTypeId": { "type": "string", "description": "The asset type ID." }, "locationId": { "type": "string", "description": "The location ID." }, "integrationServiceId": { "type": "string", "description": "The integration service ID of asset." }, "linkIds": { "type": "array", "items": { "type": "string" }, "description": "The IDs of asset." }, "name": { "type": "string", "description": "The name of asset." }, "description": { "type": "string", "description": "The description of asset." }, "chatRoomId": { "type": "string", "description": "The ID of chat room." }, "serialNumber": { "type": "string", "description": "The serial number of asset." }, "modelName": { "type": "string", "description": "The model of name." }, "nameOfManufacturer": { "type": "string", "description": "The name of manufacturer." }, "yearOfManufacture": { "type": "number", "description": "The year of manufacture of asset." }, "purchaseCost": { "type": "number", "description": "The purchase cost of asset." }, "purchaseDate": { "type": "number", "description": "The purchase date of asset." }, "warrantyEndDate": { "type": "number", "description": "The warranty end date of asset." }, "uuid": { "type": "string", "description": "The uuid of device to filter assets." }, "image": { "type": "string", "description": "The image of asset." }, "files": { "type": "array", "items": { "type": "string" }, "description": "The files of asset." }, "keepAlive": { "type": "number", "description": "The interval of keep alive." } }, "required": [ "assetTypeId", "locationId", "name" ] }, "example": { "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "linkIds": [ "a-assetId" ], "name": "IDT-Bot", "description": "IDT-Description", "chatRoomId": "ABCDE", "serialNumber": "123456789", "modelName": "Bot-Model-Name", "nameOfManufacturer": "Bot-Manufacturer", "yearOfManufacture": 2024, "purchaseCost": 12345, "purchaseDate": 1700000000000, "warrantyEndDate": 1800000000000, "uuid": "24e124535b312345", "image": "Asset-Image.png", "files": [ "Infodeck-Bot-0001.pdf" ], "keepAlive": 2592000 }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetTypeId": { "type": "string" }, "locationId": { "type": "string" }, "integrationServiceId": { "type": "string" }, "linkIds": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "chatRoomId": { "type": "string" }, "serialNumber": { "type": "string" }, "modelName": { "type": "string" }, "nameOfManufacturer": { "type": "string" }, "yearOfManufacture": { "type": "number" }, "purchaseCost": { "type": "number" }, "purchaseDate": { "type": "number" }, "warrantyEndDate": { "type": "number" }, "assetType": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "isIotDevice": { "type": "string" }, "supportedAssetTypeId": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "id", "name", "isIotDevice", "supportedAssetTypeId", "properties" ] }, "location": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" } }, "required": [ "id", "name" ] }, "devEui": { "type": "string" }, "uuid": { "type": "string" }, "image": { "type": "string" }, "files": {}, "keepAlive": { "type": "number" }, "connectionStatus": { "type": "boolean" }, "status": { "type": "string" }, "shadows": { "type": "object", "properties": {}, "required": [] }, "createdAtDateString": { "type": "number" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetTypeId", "locationId", "integrationServiceId", "name", "description", "chatRoomId", "serialNumber", "modelName", "nameOfManufacturer", "yearOfManufacture", "purchaseCost", "purchaseDate", "warrantyEndDate", "assetType", "location", "image", "files", "shadows", "createdAtDateString", "createdAt" ], "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": { "id": "o-organizationId-a-assetId", "organizationId": "o-organizationId", "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "integrationServiceId": "is-integrationServiceId", "linkIds": [ "a-assetId" ], "name": "IDT-Bot-Asset", "description": "IDT-Bot-Asset-Description", "chatRoomId": "ABCDE", "serialNumber": "123456789", "modelName": "Bot-Model-Name", "nameOfManufacturer": "Bot-Manufacturer", "yearOfManufacture": 2024, "purchaseCost": 12345, "purchaseDate": 1700000000000, "warrantyEndDate": 1800000000000, "assetType": { "id": "at-assetType", "name": "assetType", "isIotDevice": true, "supportedAssetTypeId": "Infodeck-NS300-ABC", "properties": [ { "name": "Battery", "unit": "%", "type": "integer", "key": "Battery" } ] }, "location": { "id": "locationId", "name": "location" }, "devEui": "24e124535b312345", "uuid": "24e124535b312345", "image": "Asset-Image.png", "files": [ "Infodeck-Bot-0001.pdf" ], "keepAlive": 2592000, "connectionStatus": false, "status": "Normal", "shadows": {}, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "409": { "description": "The resource already exists.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource already exists." }, "message": { "type": "string", "description": "The resource already exists message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceAlreadyExistsError", "message": "The operation cannot be completed because a resource with the specified identifier already exists." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Assets", "description": "List assets", "operationId": "Asset.ListAssets", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "devEui", "description": "The devEui of device to filter assets.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "uuid", "description": "The uuid of device to filter assets.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "isIotDevice", "description": "List IoT devices assets only.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "assetTypeId", "description": "The ID of asset type to filter assets.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "locationId", "description": "The ID of location to filter assets.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "shadowNames", "description": "Specify shadow names to fetch. (Default: DeviceUplink)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetTypeId": { "type": "string" }, "locationId": { "type": "string" }, "integrationServiceId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "chatRoomId": { "type": "string" }, "serialNumber": { "type": "string" }, "modelName": { "type": "string" }, "nameOfManufacturer": { "type": "string" }, "yearOfManufacture": { "type": "number" }, "purchaseCost": { "type": "number" }, "purchaseDate": { "type": "number" }, "warrantyEndDate": { "type": "number" }, "devEui": { "type": "string" }, "uuid": { "type": "string" }, "keepAlive": { "type": "number" }, "connectionStatus": { "type": "boolean" }, "status": { "type": "string" }, "shadows": { "type": "object", "properties": {}, "required": [] }, "createdAtDateString": { "type": "number" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetTypeId", "locationId", "integrationServiceId", "name", "description", "chatRoomId", "serialNumber", "modelName", "nameOfManufacturer", "yearOfManufacture", "purchaseCost", "purchaseDate", "warrantyEndDate", "shadows", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "a-assetId", "organizationId": "o-organizationId", "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "integrationServiceId": "is-integrationServiceId", "name": "IDT-Bot-Asset", "description": "IDT-Bot-Asset-Description", "chatRoomId": "ABCDE", "serialNumber": "123456789", "modelName": "Bot-Model-Name", "nameOfManufacturer": "Bot-Manufacturer", "yearOfManufacture": 2024, "purchaseCost": 12345, "purchaseDate": 1700000000000, "warrantyEndDate": 1800000000000, "devEui": "24e124535b312345", "uuid": "24e124535b312345", "keepAlive": 2592000, "connectionStatus": false, "status": "Normal", "shadows": { "DeviceUplink": { "state": { "reported": { "Payload": { "Temperature": 25.4, "Humidity": 62, "CO2": 869, "rssi": -91, "timestamp": 1711341602287 }, "ExpiredAt": 1711341602287 } }, "metadata": { "reported": { "Payload": { "Temperature": { "timestamp": 1711330802 }, "Humidity": { "timestamp": 1711330802 }, "CO2": { "timestamp": 1711330802 }, "rssi": { "timestamp": 1711330802 } }, "ExpiredAt": { "timestamp": 1711330802 } } }, "version": 21415, "timestamp": 1711330849 } }, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/asset-categories": { "post": { "summary": "Create Asset Category", "description": "Create asset category", "operationId": "Asset.CreateAssetCategory", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of asset category" }, "description": { "type": "string", "description": "The description of asset category" }, "attributes": { "type": "array", "items": { "type": "string" }, "description": "The custom attributes of asset category" } }, "required": [ "name" ] }, "example": { "name": "IDT-Bot-Asset-Category", "description": "IDT-Asset-Category-Description", "attributes": [ "Test-A", "Test-B", "Test-C" ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "createdAtDateString", "createdAt" ] }, "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": { "id": "ac-assetCategoryId", "organizationid": "o-organizationId", "name": "IDT-Bot-Asset-Category", "description": "IDT-Asset-Category-Description", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Asset Categories", "description": "List asset categories", "operationId": "Asset.ListAssetCategories", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "image": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "number" }, "createdAt": { "type": "number" }, "updatedBt": { "type": "string" }, "updatedAtDateString": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "image", "createdBy", "createdAtDateString", "createdAt", "updatedBt", "updatedAtDateString", "updatedAt" ] }, "description": "Data of the asset categories." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "ac-assetCategoryId", "organizationid": "o-organizationId", "name": "IDT-Bot-Asset-Category-A", "description": "IDT-Asset-Category-A-Description", "image": "Asset-CategoryId-Image.png", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1700000000000, "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1710000000000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/asset-types": { "post": { "summary": "Create Asset Type", "description": "Create asset type", "operationId": "Asset.CreateAssetType", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of asset type" }, "description": { "type": "string", "description": "The description of asset type" }, "supportedAssetTypeId": { "type": "string", "description": "The id of supported model" }, "image": { "type": "string", "description": "The custom image of asset type" }, "encodeCodec": { "type": "string", "description": "The encode codec of asset type" }, "decodeCodec": { "type": "string", "description": "The decode codec of asset type" }, "isIotDevice": { "type": "boolean", "description": "Is the asset an IoT device?" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The properties of asset type" }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The actions of asset type" } }, "required": [ "name", "isIotDevice" ] }, "example": { "name": "IDT-Bot-AssetType", "description": "IDT-AssetType-Description", "supportedAssetTypeId": "Infodeck-NS300-ABC", "image": "Asset-Type-Image.png", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "isIotDevice": true, "properties": [ { "key": "Power", "name": "Power", "type": "integer", "icon": "xxx.svg", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "supportedAssetTypeId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "isIotDevice": { "type": "string" }, "image": { "type": "string" }, "encodeCodec": { "type": "string" }, "decodeCodec": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "properactionsties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "number" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "supportedAssetTypeId", "name", "description", "isIotDevice", "image", "encodeCodec", "decodeCodec", "properties", "properactionsties", "createdBy", "createdAtDateString", "createdAt" ] }, "description": "Data of the asset type." } }, "required": [ "data" ] }, "example": { "data": { "id": "at-assetTypeId", "organizationid": "o-organizationId", "supportedAssetTypeId": "Infodeck-NS300-ABC", "name": "IDT-Bot-AssetType", "description": "IDT-AssetType-Description", "isIotDevice": true, "image": "Asset-Type-Image.png", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "properties": [ { "key": "Power", "name": "Power", "type": "integer", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Asset Types", "description": "List asset types", "operationId": "Asset.ListAssetTypes", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 25 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "supportedAssetTypeId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "isIotDevice": { "type": "string" }, "image": { "type": "string" }, "encodeCodec": { "type": "string" }, "decodeCodec": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedBy": { "type": "string" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "supportedAssetTypeId", "name", "description", "isIotDevice", "image", "encodeCodec", "decodeCodec", "properties", "actions", "createdBy", "createdAtDateString", "createdAt", "updatedBy", "updatedAtDateString", "updatedAt" ] }, "description": "Data of the asset type." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "at-assetTypeId", "organizationId": "o-organizationId", "supportedAssetTypeId": "Infodeck-NS300-ABC", "name": "IDT-Bot-AssetType-A", "description": "IDT-Bot-AssetType-A-Description", "isIotDevice": true, "image": "Asset-Type-A-Image.png", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "properties": [ { "key": "Power", "name": "Power", "type": "integer", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/supported-asset-types": { "post": { "summary": "Create Supported Asset Type", "description": "Create Supported asset type", "operationId": "Asset.CreateSupportedAssetType", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of asset type" }, "description": { "type": "string", "description": "The description of asset type" }, "image": { "type": "string", "description": "The custom image of asset type" }, "encodeCodec": { "type": "string", "description": "The encode codec of asset type" }, "decodeCodec": { "type": "string", "description": "The decode codec of asset type" }, "brand": { "type": "string", "description": "The brand of asset type" }, "model": { "type": "string", "description": "The model of asset type" }, "isIotDevice": { "type": "boolean", "description": "Is the asset an IoT device?" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The properties of asset type" }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The actions of asset type" } }, "required": [ "name", "brand", "model", "isIotDevice" ] }, "example": { "name": "IDT-Bot-SupportedAssetType", "description": "IDT-SupportedAssetType-Description", "image": "Supported-Asset-Type-Image.png", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "brand": "Infodeck", "model": "NS330-PSU", "isIotDevice": true, "properties": [ { "key": "Power", "name": "Power", "type": "integer", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "isIotDevice": { "type": "string" }, "image": { "type": "string" }, "brand": { "type": "string" }, "model": { "type": "string" }, "encodeCodec": { "type": "string" }, "decodeCodec": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "id", "name", "description", "isIotDevice", "image", "brand", "model", "encodeCodec", "decodeCodec", "properties" ], "description": "Data of the supported asset type." } }, "required": [ "data" ] }, "example": { "data": { "id": "Infodeck-NS300-ABC", "organizationid": "o-organizationId", "name": "IDT-Bot-SupportedAssetType", "description": "IDT-SupportedAssetType-Description", "image": "Supported-Asset-Type-Image.png", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "brand": "Infodeck", "model": "NS330-PSU", "isIotDevice": true, "properties": [ { "key": "Power", "name": "Power", "type": "integer", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Supported Asset Types", "description": "List Supported asset types", "operationId": "Asset.ListSupportedAssetTypes", "tags": [ "Asset" ], "parameters": [ { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 25 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "isIotDevice": { "type": "string" }, "image": { "type": "string" }, "brand": { "type": "string" }, "model": { "type": "string" }, "encodeCodec": { "type": "string" }, "decodeCodec": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "id", "name", "description", "isIotDevice", "image", "brand", "model", "encodeCodec", "decodeCodec", "properties", "actions" ], "description": "Data of the supported asset type." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "Infodeck-NS300-ABC", "name": "IDT-Bot-SupportedAssetType", "description": "IDT-SupportedAssetType-Description", "isIotDevice": true, "image": "Supported-Asset-Type-Image.png", "brand": "Infodeck", "model": "NS330-PSU", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "properties": [ { "key": "Power", "name": "Power", "type": "integer", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ] } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/assets/{assetId}": { "delete": { "summary": "Delete Asset", "description": "Delete asset", "operationId": "Asset.DeleteAsset", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of asset", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": {} }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Asset", "description": "Get asset", "operationId": "Asset.GetAsset", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of asset", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "shadowNames", "description": "Specify shadow names to fetch. (Default: DeviceUplink)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetId": { "type": "string" }, "integrationService": { "type": "object", "properties": {}, "required": [] }, "name": { "type": "string" }, "description": { "type": "string" }, "chatRoomId": { "type": "string" }, "serialNumber": { "type": "number" }, "modelName": { "type": "string" }, "nameOfManufacturer": { "type": "string" }, "yearOfManufacture": { "type": "number" }, "purchaseCost": { "type": "number" }, "purchaseDate": { "type": "string" }, "warrantyEndDate": { "type": "string" }, "assetType": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "isIotDevice": { "type": "string" }, "supportedAssetTypeId": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "id", "name", "isIotDevice", "supportedAssetTypeId", "properties" ] }, "location": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" } }, "required": [ "id", "name" ] }, "images": { "type": "string" }, "files": { "type": "string" }, "devEui": { "type": "string" }, "uuid": { "type": "string" }, "keepAlive": { "type": "number" }, "connectionStatus": { "type": "boolean" }, "status": { "type": "string" }, "shadow": { "type": "object", "properties": {}, "required": [] }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetId", "integrationService", "name", "description", "chatRoomId", "serialNumber", "modelName", "nameOfManufacturer", "yearOfManufacture", "purchaseCost", "purchaseDate", "warrantyEndDate", "assetType", "location", "images", "files", "shadow", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": { "id": "o-organizationId-a-assetId", "organizationId": "o-organizationId", "assetId": "a-assetId", "integrationServiceId": "is-integrationServiceId", "name": "IDT-Bot-Asset", "description": "IDT-Bot-Asset-Description", "chatRoomId": "ABCDE", "serialNumber": "123456789", "modelName": "Bot-Model-Name", "nameOfManufacturer": "Bot-Manufacturer", "yearOfManufacture": 2024, "purchaseCost": 12345, "purchaseDate": 1700000000000, "warrantyEndDate": 1800000000000, "assetType": { "id": "at-assetType", "name": "assetType", "isIotDevice": true, "supportedAssetTypeId": "Infodeck-NS300-ABC", "properties": [ { "name": "Battery", "unit": "%", "type": "integer", "key": "Battery" } ] }, "location": { "id": "l-location", "name": "location" }, "image": "Asset-Image.png", "files": [ "Infodeck-Bot-0001.pdf" ], "devEui": "24e124535b312345", "uuid": "24e124535b312345", "keepAlive": 2592000, "connectionStatus": false, "status": "Normal", "shadows": { "DeviceUplink": { "state": { "reported": { "Payload": { "Temperature": 25.4, "Humidity": 62, "CO2": 869, "rssi": -91, "timestamp": 1711341602287 }, "ExpiredAt": 1711341602287 } }, "metadata": { "reported": { "Payload": { "Temperature": { "timestamp": 1711330802 }, "Humidity": { "timestamp": 1711330802 }, "CO2": { "timestamp": 1711330802 }, "rssi": { "timestamp": 1711330802 } }, "ExpiredAt": { "timestamp": 1711330802 } } }, "version": 21415, "timestamp": 1711330849 } }, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Asset", "description": "Update asset", "operationId": "Asset.UpdateAsset", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of asset", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of asset" }, "description": { "type": "string", "description": "The description of asset" }, "chatRoomId": { "type": "string", "description": "The ID of chat room" }, "locationId": { "type": "string", "description": "The locationId of asset" }, "integrationServiceId": { "type": "string", "description": "The integration service ID of asset." }, "linkIds": { "type": "array", "items": { "type": "string" }, "description": "The IDs of asset." }, "serialNumber": { "type": "string", "description": "The serial number of asset" }, "modelName": { "type": "string", "description": "The serial number of asset" }, "nameOfManufacturer": { "type": "string", "description": "The name of manufacturer" }, "yearOfManufacture": { "type": "number", "description": "The year of manufacture of asset" }, "purchaseCost": { "type": "number", "description": "The purchase cost of asset" }, "purchaseDate": { "type": "number", "description": "The purchase date of asset" }, "warrantyEndDate": { "type": "number", "description": "The warranty end date of asset" }, "image": { "type": "string", "description": "The image of asset" }, "files": { "type": "array", "items": { "type": "string" }, "description": "The files of asset" }, "keepAlive": { "type": "number", "description": "The interval of keep alive" } }, "required": [ "name" ] }, "example": { "name": "IDT-Bot", "description": "IDT-Description", "chatRoomId": "ABCDE", "integrationServiceId": "is-integrationServiceId", "linkIds": [ "a-assetId" ], "locationId": "l-locationId", "serialNumber": "123456789", "modelName": "Bot-Model-Name", "nameOfManufacturer": "Bot-Manufacturer", "yearOfManufacture": 2024, "purchaseCost": 12345, "purchaseDate": 1700000000000, "warrantyEndDate": 1800000000000, "image": "Asset-Image.png", "files": [ "Infodeck-Bot-0001.pdf" ], "keepAlive": 2592000 }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "assetTypeId": { "type": "string" }, "locationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "chatRoomId": { "type": "string" }, "serialNumber": { "type": "number" }, "nameOfManufacturer": { "type": "string" }, "yearOfManufacture": { "type": "number" }, "purchaseCost": { "type": "number" }, "purchaseDate": { "type": "string" }, "warrantyEndDate": { "type": "string" }, "images": { "type": "string" }, "files": { "type": "string" }, "integrationServiceId": { "type": "string" }, "devEui": { "type": "string" }, "uuid": { "type": "string" }, "keepAlive": { "type": "number" }, "connectionStatus": {}, "status": { "type": "string" }, "updatedAtDateString": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "assetTypeId", "locationId", "name", "description", "chatRoomId", "serialNumber", "nameOfManufacturer", "yearOfManufacture", "purchaseCost", "purchaseDate", "warrantyEndDate", "images", "files", "updatedAtDateString", "updatedAt" ], "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": { "assetTypeId": "a-assetTypeId", "locationId": "l-locationId", "name": "IDT-Bot", "description": "IDT-Description", "chatRoomId": "ABCDE", "serialNumber": "123456789", "nameOfManufacturer": "Bot-Manufacturer", "yearOfManufacture": 2024, "purchaseCost": 12345, "purchaseDate": 1700000000000, "warrantyEndDate": 1800000000000, "image": "Asset-Image.png", "integrationServiceId": "is-integrationserviceId", "files": [ "Infodeck-Bot-0001.pdf" ], "devEui": "24e124535b312345", "uuid": "24e124535b312345", "keepAlive": 2592000, "connectionStatus": false, "status": "Normal", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/asset-categories/{assetCategoryId}": { "delete": { "summary": "Delete Asset Category", "description": "Delete asset category", "operationId": "Asset.DeleteAssetCategory", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetCategoryId", "description": "The ID of asset", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": {} }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Asset Category", "description": "Get asset category", "operationId": "Asset.GetAssetCategory", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetCategoryId", "description": "The ID of asset", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "image": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "number" }, "createdAt": { "type": "number" }, "updatedBy": { "type": "string" }, "updatedAtDateString": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "image", "createdBy", "createdAtDateString", "createdAt", "updatedBy", "updatedAtDateString", "updatedAt" ], "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": { "id": "ac-assetCategoryId", "organizationid": "o-organizationId", "name": "IDT-Bot-Asset-Category", "description": "IDT-Asset-Category-Description", "image": "Asset-CategoryId-Image.png", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Asset Category", "description": "Update asset category", "operationId": "Asset.UpdateAssetCategory", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetCategoryId", "description": "The ID of asset", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of asset category" }, "description": { "type": "string", "description": "The description of asset category" }, "attributes": { "type": "object", "properties": {}, "required": [], "description": "The custom attributes of asset category" } }, "required": [ "name" ] }, "example": { "name": "IDT-Bot-Asset-Category", "description": "IDT-Asset-Category-Description", "attributes": [ "Test-A", "Test-B", "Test-C" ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" } }, "required": [ "name", "description" ], "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": { "name": "IDT-Bot-Asset-Category", "description": "IDT-Asset-Category-Description" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/asset-types/{assetTypeId}": { "delete": { "summary": "Delete Asset Type", "description": "Delete asset type", "operationId": "Asset.DeleteAssetType", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetTypeId", "description": "The ID of asset type.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": {} }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Asset Type", "description": "Get asset type", "operationId": "Asset.GetAssetType", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetTypeId", "description": "The ID of asset type", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "supportedAssetTypeId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "isIotDevice": { "type": "string" }, "image": { "type": "string" }, "encodeCodec": { "type": "string" }, "decodeCodec": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "createdBy": { "type": "string" }, "createdAt": { "type": "string" }, "createdAtDateString": { "type": "string" }, "updatedBy": { "type": "string" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "supportedAssetTypeId", "name", "description", "isIotDevice", "image", "encodeCodec", "decodeCodec", "properties", "actions", "createdBy", "createdAt", "createdAtDateString", "updatedBy", "updatedAtDateString", "updatedAt" ], "description": "Data of the asset type." } }, "required": [ "data" ] }, "example": { "data": { "id": "at-assetTypeId", "organizationid": "o-organizationId", "name": "IDT-Bot-AssetType", "description": "IDT-AssetType-Description", "supportedAssetTypeId": "Infodeck-NS300-ABC", "image": "Asset-Type-Image.png", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "isIotDevice": true, "properties": [ { "key": "Power", "name": "Power", "type": "integer", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Asset Type", "description": "Update asset type", "operationId": "Asset.UpdateAssetType", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetTypeId", "description": "The ID of asset type.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of asset type" }, "description": { "type": "string", "description": "The description of asset type" }, "supportedAssetTypeId": { "type": "string", "description": "The id of supported model" }, "isIotDevice": { "type": "string", "description": "Is the asset an IoT device?" }, "image": { "type": "string", "description": "The custom image of asset type" }, "encodeCodec": { "type": "string", "description": "The encode codec of asset type" }, "decodeCodec": { "type": "string", "description": "The decode codec of asset type" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The properties of asset type" }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The actions of asset type" } }, "required": [ "name", "isIotDevice" ] }, "example": { "name": "IDT-Bot-AssetType", "description": "IDT-AssetType-Description", "supportedAssetTypeId": "Infodeck-NS300-ABC", "image": "Asset-Type-Image.png", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "isIotDevice": true, "properties": [ { "key": "Power", "name": "Power", "type": "integer", "icon": "xxx.svg", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "supportedAssetTypeId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "isIotDevice": { "type": "string" }, "image": { "type": "string" }, "encodeCodec": { "type": "string" }, "decodeCodec": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "updatedBy": { "type": "string" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "supportedAssetTypeId", "name", "description", "isIotDevice", "image", "encodeCodec", "decodeCodec", "properties", "actions", "updatedBy", "updatedAtDateString", "updatedAt" ], "description": "Data of the asset type." } }, "required": [ "data" ] }, "example": { "supportedAssetTypeId": "Infodeck-NS300-ABC", "name": "IDT-Bot-AssetType", "description": "IDT-AssetType-Description", "isIotDevice": true, "image": "Asset-Type-Image.png", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "properties": [ { "key": "Power", "name": "Power", "type": "integer", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ], "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/assets/{assetId}/enqueue-downlink": { "post": { "summary": "Enqueue Asset Downlink", "description": "Enqueue Asset Downlink", "operationId": "Asset.EnqueueAssetDownlink", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of asset.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "action": { "type": "string", "description": "The name of manufacturer." }, "base64": { "type": "string", "description": "The base64 of asset downlink." } }, "required": [ "action", "base64" ] }, "example": { "action": "Power On" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "received": { "type": "string" } }, "required": [ "received" ], "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": { "received": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "409": { "description": "The resource already exists.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource already exists." }, "message": { "type": "string", "description": "The resource already exists message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceAlreadyExistsError", "message": "The operation cannot be completed because a resource with the specified identifier already exists." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/assets/{assetId}/status-thresholds": { "get": { "summary": "Get Asset status Thresholds", "description": "Get asset status thresholds", "operationId": "Asset.GetAssetStatusThresholds", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of the asset.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "statusThresholds": { "type": "object", "properties": { "critical": { "type": "array", "items": { "type": "object", "properties": { "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "number" }, "operator": { "type": "string" } }, "required": [ "property", "symbol", "valueDataType", "value" ] } }, "warning": { "type": "array", "items": { "type": "object", "properties": { "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "number" }, "operator": { "type": "string" } }, "required": [ "property", "symbol", "valueDataType", "value" ] } } }, "required": [ "critical", "warning" ] } }, "required": [ "statusThresholds" ], "description": "Data of the asset threshold." } }, "required": [ "data" ] }, "example": { "data": { "statusThresholds": { "critical": [ { "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": 40, "operator": "AND" }, { "property": "Current", "symbol": ">", "valueDataType": "float", "value": 10, "operator": "AND" } ], "warning": [ { "property": "Temperature", "symbol": "<", "valueDataType": "integer", "value": 40, "operator": "AND" }, { "property": "Current", "symbol": "<", "valueDataType": "float", "value": 10, "operator": "AND" } ] } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Asset status Thresholds", "description": "Update asset status thresholds", "operationId": "Asset.UpdateAssetStatusThresholds", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of the asset.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "statusThresholds": { "type": "object", "properties": { "critical": { "type": "array", "items": { "type": "object", "properties": { "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "number" }, "operator": { "type": "string" } }, "required": [ "property", "symbol", "valueDataType", "value" ] } }, "warning": { "type": "array", "items": { "type": "object", "properties": { "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "number" }, "operator": { "type": "string" } }, "required": [ "property", "symbol", "valueDataType", "value" ] } } }, "required": [ "critical", "warning" ], "description": "The status of asset threshold." } }, "required": [ "statusThresholds" ] }, "example": { "statusThresholds": { "critical": [ { "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": 40, "operator": "AND" }, { "property": "Current", "symbol": ">", "valueDataType": "float", "value": 10, "operator": "AND" } ], "warning": [ { "property": "Temperature", "symbol": "<", "valueDataType": "integer", "value": 40, "operator": "AND" }, { "property": "Current", "symbol": "<", "valueDataType": "float", "value": 10, "operator": "AND" } ] } }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "statusThresholds": { "type": "object", "properties": { "critical": { "type": "array", "items": { "type": "object", "properties": { "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "number" }, "operator": { "type": "string" } }, "required": [ "property", "symbol", "valueDataType", "value" ] } }, "warning": { "type": "array", "items": { "type": "object", "properties": { "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "number" }, "operator": { "type": "string" } }, "required": [ "property", "symbol", "valueDataType", "value" ] } } }, "required": [ "critical", "warning" ] } }, "required": [ "statusThresholds" ], "description": "Data of the asset threshold." } }, "required": [ "data" ] }, "example": { "data": { "statusThresholds": { "critical": [ { "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": 40 }, { "property": "Current", "symbol": ">", "valueDataType": "float", "value": 10, "operator": "AND" } ], "warning": [ { "property": "Temperature", "symbol": "<", "valueDataType": "integer", "value": 40 }, { "property": "Current", "symbol": "<", "valueDataType": "float", "value": 10, "operator": "AND" } ] } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/assets/{assetId}/metrics": { "get": { "summary": "Get metric data by asset ID", "description": "Get Metric Data By Asset ID for Organization", "operationId": "Asset.GetMetricDataByAssetId", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of asset.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "days", "description": "The day of metric.", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 32 }, "required": true }, { "name": "metricName", "description": "The name of IoT things.", "in": "query", "schema": { "type": "string" }, "required": true }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "timestamp": { "type": "object", "properties": {}, "required": [] } }, "required": [ "timestamp" ], "description": "Data of the asset." }, "errors": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "List of errors (empty if none)." } }, "required": [ "data", "errors" ] }, "example": { "data": { "1708797600000": { "a-24e124148b329013": { "Voltage-average": 115.91 }, "a-24e124148c480389": { "Voltage-average": 248.05 }, "a-24e124148c482498": { "Voltage-average": 247.21 } } }, "errors": [] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/supported-asset-types/{supportedAssetTypeId}": { "get": { "summary": "Get Supported Asset Type", "description": "Get Supported Asset Type", "operationId": "Asset.GetSupportedAssetType", "tags": [ "Asset" ], "parameters": [ { "name": "id", "description": "The ID of supported asset type", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "isIotDevice": { "type": "string" }, "image": { "type": "string" }, "brand": { "type": "string" }, "model": { "type": "string" }, "encodeCodec": { "type": "string" }, "decodeCodec": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "id", "name", "description", "isIotDevice", "image", "brand", "model", "encodeCodec", "decodeCodec", "properties", "actions" ], "description": "Data of the supported asset type." } }, "required": [ "data" ] }, "example": { "data": { "id": "Infodeck-NS300-ABC", "name": "IDT-Bot-SupportedAssetType", "description": "IDT-SupportedAssetType-Description", "isIotDevice": true, "image": "Supported-Asset-Type-Image.png", "brand": "Infodeck", "model": "NS330-PSU", "encodeCodec": "function encodeDownlink(input) {\n const bytes = [];\n\n return {\n bytes,\n };\n}", "decodeCodec": "function decodeUplink(input) {\n const bytes = input.bytes;\n const data = {};\n\n return {\n data,\n };\n}", "properties": [ { "key": "Power", "name": "Power", "type": "integer", "unit": "W" } ], "actions": [ { "confirmed": true, "fPort": 85, "name": "Power On", "payload": "080100ff", "payloadDataType": "Hex" } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/assets/{assetId}/logs": { "get": { "summary": "List Assets Logs", "description": "List assets logs", "operationId": "Asset.ListAssetLogs", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of the asset (Allow all).", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of query.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "endDate", "description": "The end date number of query.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "default": 10 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "assetId": { "type": "string" }, "organizationId": { "type": "string" }, "eventName": { "type": "string" }, "createdAt": { "type": "string" }, "payload": { "type": "object", "properties": {}, "required": [] }, "metadata": { "type": "object", "properties": {}, "required": [] } }, "required": [ "assetId", "organizationId", "eventName", "createdAt", "payload", "metadata" ] }, "description": "Data of the asset log." } }, "required": [ "data" ] }, "example": { "data": [ { "assetId": "a-assetId", "organizationId": "o-organizationId", "eventName": "OnDisconnected", "payload": {}, "createdAt": 1704067200000, "metadata": { "assetName": "24E124FFFEF23685" } } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/assets/{assetId}/rawdata": { "get": { "summary": "List Asset Rawdata.", "description": "List Asset Rawdata", "operationId": "Asset.ListAssetRawdata", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of asset.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of query.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "endDate", "description": "The end date number of query.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "timestamp": { "type": "number" }, "rssi": { "type": "number" }, "Battery": { "type": "number" } }, "required": [ "timestamp", "rssi", "Battery" ] }, "description": "Rawdata of the assets." }, "nextToken": { "type": "string", "description": "The next data token." } }, "required": [ "data" ] }, "example": { "data": [ { "timestamp": 1504569600000, "rssi": -69, "Battery": 100 } ], "nextToken": "eyJ2ZXJzaW9uIjoxLCJzdGFydElkIjoiYXNzZXRJZCIsImFzc2V0SWQiOiJhc3NldElkIn0=" }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/locations/{locationId}/assets": { "get": { "summary": "List Assest from Location ID", "description": "List Assets From LocationId", "operationId": "Asset.ListAssetsFromLocationId", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "locationId", "description": "The ID of location.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "shadowNames", "description": "Specify shadow names to fetch. (Default: DeviceUplink)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 25 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "devEui": { "type": "string" }, "uuid": { "type": "string" }, "shadows": { "type": "object", "properties": {}, "required": [] }, "integrationServiceId": { "type": "string" }, "assetTypeId": { "type": "string" }, "locationId": { "type": "string" }, "chatRoomId": { "type": "string" }, "modelName": { "type": "string" }, "nameOfManufacturer": { "type": "string" }, "yearOfManufacture": { "type": "number" }, "purchaseCost": { "type": "number" }, "purchaseDate": { "type": "number" }, "warrantyEndDate": { "type": "number" }, "image": { "type": "string" }, "files": { "type": "string" }, "keepAlive": { "type": "number" }, "connectionStatus": { "type": "boolean" }, "status": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "shadows", "integrationServiceId", "assetTypeId", "locationId", "chatRoomId", "modelName", "nameOfManufacturer", "yearOfManufacture", "purchaseCost", "purchaseDate", "warrantyEndDate", "image", "files", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "An array of assets within the specified location." } }, "required": [ "data" ] }, "example": { "data": { "id": "l-locationId", "organizationId": "o-organizationId", "name": "IDT-Location", "description": "IDT-Location-Description", "devEui": "24e124535b312345", "shadows": {}, "integrationServiceId": "is-integrationServiceId", "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "chatRoomId": "ABCDE", "modelName": "Bot-Model-Name", "nameOfManufacturer": "Bot-Manufacturer", "yearOfManufacture": 2024, "purchaseCost": 12345, "purchaseDate": 1700000000000, "warrantyEndDate": 1800000000000, "image": "abc.png", "files": [ "Infodeck-Bot-0001.pdf" ], "uuid": "24e124535b312345", "keepAlive": 2592000, "connectionStatus": false, "status": "Normal", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/asset-categories/{assetCategoryId}/assets": { "get": { "summary": "List Asset In Asset Category", "description": "List assets in asset category", "operationId": "Asset.ListAssetsInAssetCategory", "tags": [ "Asset" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetCategoryId", "description": "The ID of asset", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "assetCategory": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" } }, "required": [ "id", "name" ] }, "keepAlive": { "type": "number" }, "connectionStatus": { "type": "boolean" }, "status": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "name", "description", "assetCategory", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Data of the asset." } }, "required": [ "data" ] }, "example": { "data": { "id": "ac-assetCategoryId", "name": "IDT-Bot-AssetCategory", "description": "IDT-Bot-AssetCategory-Description", "assetCategory": { "id": "ac-assetCategory", "name": "assetCategory" }, "keepAlive": 2592000, "connectionStatus": false, "status": "Normal", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/app-clients/{appClientId}": { "get": { "summary": "Get App Client", "description": "Get app client", "operationId": "Authentication.GetAppClient", "tags": [ "Authentication" ], "parameters": [ { "name": "appClientId", "description": "The client id of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "clientId": { "type": "string" }, "clientName": { "type": "string" }, "callbackUrls": { "type": "array", "items": { "type": "string" } }, "logoutUrls": { "type": "array", "items": { "type": "string" } } }, "required": [ "clientId", "clientName", "callbackUrls", "logoutUrls" ], "description": "Data of the app client." } }, "required": [ "data" ] }, "example": { "data": { "clientId": "16tofxxxxxxxxxxm", "clientName": "ApiServiceUserPoolClient", "callbackUrls": [ "http://localhost:8080" ], "logoutUrls": [ "http://localhost:8080" ] } }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } } }, "security": [] } }, "/authentications/tokens": { "post": { "summary": "Get authentication token", "description": "Get authentication token", "operationId": "Authentication.GetAuthenticationToken", "tags": [ "Authentication" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "account": { "type": "string", "description": "The account of user." }, "password": { "type": "string", "description": "The password of user." } }, "required": [ "account", "password" ] }, "example": { "account": "example@infodeck.io", "password": "**********" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "token": { "type": "string" }, "accessToken": { "type": "string" }, "tokenType": { "type": "string" }, "refreshToken": { "type": "string" }, "idToken": { "type": "string" }, "expiresIn": { "type": "string" } }, "required": [ "token", "accessToken", "tokenType", "refreshToken", "idToken", "expiresIn" ], "description": "Data of the token." } }, "required": [ "data" ] }, "example": { "data": { "token": "ABCDEFGHIJKLMNOPQRSTUVWXYZ", "accessToken": "ACCESS_TOKEN", "tokenType": "Bearer", "refreshToken": "REFRESH_TOKEN", "idToken": "Bearer yJhbxxxxxxxxxxb", "expiresIn": "86400000" } }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [] } }, "/organizations/{organizationId}/decks": { "post": { "summary": "Create Deck", "description": "Create Deck", "operationId": "Deck.CreateDeck", "tags": [ "Deck" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "title": { "type": "string", "description": "The title of deck." }, "description": { "type": "string", "description": "The description of deck." }, "weight": { "type": "number", "description": "The weight of deck." }, "widgets": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The widgets of deck." } }, "required": [ "weight" ] }, "example": { "title": "IDT-Deck", "description": "IDT-Deck-Description", "weight": "1", "widgets": [ { "id": "1710000000000", "configuration": { "assetId": "a-assetId", "modeKey": "default" }, "description": "Display a device status", "gridLayout": { "h": 15, "i": 1700000000000, "w": 6, "x": 6, "y": 0 }, "title": "Data Combination", "type": "UtdDc" } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "title": { "type": "string" }, "description": { "type": "string" }, "weight": { "type": "string" }, "widgets": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "configuration": { "type": "object", "properties": { "assetId": { "type": "string" }, "modeKey": { "type": "string" } }, "required": [ "assetId", "modeKey" ] }, "description": { "type": "string" }, "gridLayout": { "type": "object", "properties": { "h": { "type": "number" }, "i": { "type": "string" }, "w": { "type": "number" }, "x": { "type": "number" }, "y": { "type": "number" } }, "required": [ "h", "i", "w", "x", "y" ] }, "title": { "type": "string" }, "type": { "type": "string" } }, "required": [ "id", "configuration", "description", "gridLayout", "title", "type" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "title", "description", "weight", "widgets", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the deck." } }, "required": [ "data" ] }, "example": { "data": { "title": "IDT-Deck", "description": "IDT-Deck-Description", "weight": "1", "widgets": [ { "id": "1710000000000", "configuration": { "assetId": "a-assetId", "modeKey": "default" }, "description": "Display a device status", "gridLayout": { "h": 15, "i": 1700000000000, "w": 6, "x": 6, "y": 0 }, "title": "Data Combination", "type": "UtdDc" } ], "autoRefreshInterval": 0, "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Decks", "description": "List Decks", "operationId": "Deck.ListDecks", "tags": [ "Deck" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "title": { "type": "string" }, "description": { "type": "string" }, "weight": { "type": "string" }, "widgets": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "configuration": { "type": "object", "properties": { "assetId": { "type": "string" }, "modeKey": { "type": "string" } }, "required": [ "assetId", "modeKey" ] }, "description": { "type": "string" }, "gridLayout": { "type": "object", "properties": { "h": { "type": "number" }, "i": { "type": "string" }, "w": { "type": "number" }, "x": { "type": "number" }, "y": { "type": "number" } }, "required": [ "h", "i", "w", "x", "y" ] }, "title": { "type": "string" }, "type": { "type": "string" } }, "required": [ "id", "configuration", "description", "gridLayout", "title", "type" ] } }, "autoRefreshInterval": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "title", "description", "weight", "widgets", "autoRefreshInterval", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Data of the deck." } }, "required": [ "data" ] }, "example": { "data": [ { "title": "IDT-Deck", "description": "IDT-Deck-Description", "weight": "1", "widgets": [ { "id": "1710000000000", "configuration": { "assetId": "a-assetId", "modeKey": "default" }, "description": "Display a device status", "gridLayout": { "h": 15, "i": 1700000000000, "w": 6, "x": 6, "y": 0 }, "title": "Data Combination", "type": "UtdDc" } ], "autoRefreshInterval": 0, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/decks/{deckId}/widgets": { "post": { "summary": "Create Deck Widget", "description": "Create Deck Widget", "operationId": "Deck.CreateDeckWidget", "tags": [ "Deck" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deckId", "description": "The ID of deck.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "widget": { "type": "object", "properties": {}, "required": [], "description": "The widget of deck." } }, "required": [ "widget" ] }, "example": { "id": "1710000000000", "configuration": { "assetId": "a-assetId", "modeKey": "default" }, "title": "Data Combination", "type": "UtdDc" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "title": { "type": "string" }, "description": { "type": "string" }, "weight": { "type": "string" }, "widgets": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "configuration": { "type": "object", "properties": { "assetId": { "type": "string" }, "modeKey": { "type": "string" } }, "required": [ "assetId", "modeKey" ] }, "description": { "type": "string" }, "gridLayout": { "type": "object", "properties": { "h": { "type": "number" }, "i": { "type": "string" }, "w": { "type": "number" }, "x": { "type": "number" }, "y": { "type": "number" } }, "required": [ "h", "i", "w", "x", "y" ] }, "title": { "type": "string" }, "type": { "type": "string" } }, "required": [ "id", "configuration", "description", "gridLayout", "title", "type" ] } }, "autoRefreshInterval": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "title", "description", "weight", "widgets", "autoRefreshInterval", "updatedAtDateString", "updatedAt" ], "description": "Data of the deck." } }, "required": [ "data" ] }, "example": { "data": { "title": "IDT-Deck", "description": "IDT-Deck-Description", "weight": "1", "widgets": [ { "id": "1710000000000", "configuration": { "assetId": "a-assetId", "modeKey": "default" }, "description": "Display a device status", "gridLayout": { "h": 15, "i": 1700000000000, "w": 6, "x": 6, "y": 0 }, "title": "Data Combination", "type": "UtdDc" } ], "autoRefreshInterval": 0, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/decks/{deckId}": { "delete": { "summary": "Delete Deck", "description": "Delete Deck", "operationId": "Deck.DeleteDeck", "tags": [ "Deck" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deckId", "description": "The ID of deck.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the deck." } }, "required": [ "data" ] }, "example": { "data": null }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Deck", "description": "Get Deck", "operationId": "Deck.GetDeck", "tags": [ "Deck" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deckId", "description": "The ID of deck.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "title": { "type": "string" }, "description": { "type": "string" }, "weight": { "type": "string" }, "widgets": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "configuration": { "type": "object", "properties": { "assetId": { "type": "string" }, "modeKey": { "type": "string" } }, "required": [ "assetId", "modeKey" ] }, "description": { "type": "string" }, "gridLayout": { "type": "object", "properties": { "h": { "type": "number" }, "i": { "type": "string" }, "w": { "type": "number" }, "x": { "type": "number" }, "y": { "type": "number" } }, "required": [ "h", "i", "w", "x", "y" ] }, "title": { "type": "string" }, "type": { "type": "string" } }, "required": [ "id", "configuration", "description", "gridLayout", "title", "type" ] } }, "autoRefreshInterval": { "type": "number" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "title", "description", "weight", "widgets", "autoRefreshInterval", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "The title of the deck." } }, "required": [ "data" ] }, "example": { "data": { "title": "IDT-Deck", "description": "IDT-Deck-Description", "weight": "1", "widgets": [ { "id": "1710000000000", "configuration": { "assetId": "a-assetId", "modeKey": "default" }, "description": "Display a device status", "gridLayout": { "h": 15, "i": 1700000000000, "w": 6, "x": 6, "y": 0 }, "title": "Data Combination", "type": "UtdDc" } ], "autoRefreshInterval": 0, "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Deck", "description": "Update Deck", "operationId": "Deck.UpdateDeck", "tags": [ "Deck" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deckId", "description": "The ID of deck.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "title": { "type": "string", "description": "The title of deck." }, "description": { "type": "string", "description": "The description of deck." }, "weight": { "type": "number", "description": "The weight of deck." }, "widgets": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The widgets of deck." }, "autoRefreshInterval": { "type": "number", "description": "The auto refresh interval of deck." } }, "required": [ "weight" ] }, "example": { "title": "IDT-Deck", "description": "IDT-Deck-Description", "weight": "1", "widgets": [ { "id": "1710000000000", "configuration": { "assetId": "a-assetId", "modeKey": "default" }, "description": "Display a device status", "gridLayout": { "h": 15, "i": 1700000000000, "w": 6, "x": 6, "y": 0 }, "title": "Data Combination", "type": "UtdDc" } ], "autoRefreshInterval": 0 }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "title": { "type": "string" }, "description": { "type": "string" }, "weight": { "type": "string" }, "widgets": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "configuration": { "type": "object", "properties": { "assetId": { "type": "string" }, "modeKey": { "type": "string" } }, "required": [ "assetId", "modeKey" ] }, "description": { "type": "string" }, "gridLayout": { "type": "object", "properties": { "h": { "type": "number" }, "i": { "type": "string" }, "w": { "type": "number" }, "x": { "type": "number" }, "y": { "type": "number" } }, "required": [ "h", "i", "w", "x", "y" ] }, "title": { "type": "string" }, "type": { "type": "string" } }, "required": [ "id", "configuration", "description", "gridLayout", "title", "type" ] } }, "autoRefreshInterval": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "title", "description", "weight", "widgets", "autoRefreshInterval", "updatedAtDateString", "updatedAt" ], "description": "Data of the deck." } }, "required": [ "data" ] }, "example": { "data": { "title": "IDT-Deck", "description": "IDT-Deck-Description", "weight": "1", "widgets": [ { "id": "1710000000000", "configuration": { "assetId": "a-assetId", "modeKey": "default" }, "description": "Display a device status", "gridLayout": { "h": 15, "i": 1700000000000, "w": 6, "x": 6, "y": 0 }, "title": "Data Combination", "type": "UtdDc" } ], "autoRefreshInterval": 0, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{edgeGatewayId}/metrics/cpu-memory-usage": { "get": { "summary": "Get CPU & memory usage metric with edge gateway", "description": "Get CPU & memory usage metric with edge gateway", "operationId": "Edge_Gateways.GetCpuMemoryUsageMetricWithEdgeGateway", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge Gateway ID", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "period", "description": "Period of metric(unit: sec).", "in": "query", "schema": { "type": "string", "enum": [ "60", "300", "900", "3600", "86400", "604800", "2592000" ], "default": "300" }, "required": false }, { "name": "periodTime", "description": "Period time of metric(unit: sec).", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 129600, "default": 60 }, "required": false }, { "name": "statistic", "description": "Statistic of metric.", "in": "query", "schema": { "type": "string", "enum": [ "Average", "Minimum", "Maximum" ], "default": "Average" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "cpuUsage": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] }, "memoryUsage": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] } }, "required": [ "cpuUsage", "memoryUsage" ], "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": { "cpuUsage": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 20, 25 ] }, "memoryUsage": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 45, 50 ] } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{edgeGatewayId}/metrics/disk-usage": { "get": { "summary": "Get disk usage metric with edge gateway", "description": "Get disk usage metric with edge gateway", "operationId": "Edge_Gateways.GetDiskUsageMetricWithEdgeGateway", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge Gateway ID", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "diskUsage": { "type": "number" } }, "required": [ "diskUsage" ], "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": { "diskUsage": 75 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{thingName}/connectivity-info": { "get": { "summary": "Get Edge Gateway Connectivity Info", "description": "Get Edge Gateway Connectivity Info", "operationId": "Edge_Gateways.GetEdgeGatewayConnectivityInfo", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge Gateway ID", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "thingName": { "type": "string" }, "connectivityInfo": { "type": "object", "properties": { "macAddress": { "type": "string" }, "ipAddress": { "type": "string" }, "port": { "type": "string" }, "protocol": { "type": "string" } }, "required": [ "macAddress", "ipAddress", "port", "protocol" ] } }, "required": [ "thingName", "connectivityInfo" ], "description": "The container object for the response data." } }, "required": [ "data" ] }, "example": { "data": { "thingName": "IDT-Edge-Gateway-A", "connectivityInfo": { "macAddress": "00000000000000000", "ipAddress": "192.168.0.1", "port": "80", "protocol": "HTTP" } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{edgeGatewayId}/installed-components": { "get": { "summary": "Get installed components in edge gateway", "description": "Get installed components in edge gateway", "operationId": "Edge_Gateways.GetInstalledComponentsInEdgeGateway", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge Gateway ID", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "componentName": { "type": "string" }, "componentVersion": { "type": "string" }, "isRoot": { "type": "boolean" }, "lastInstallationSource": { "type": "string" }, "lastReportedTimestamp": {}, "lastStatusChangeTimestamp": {}, "lifecycleState": { "type": "string" }, "lifecycleStateDetails": { "type": "string" }, "lifecycleStatusCodes": { "type": "array", "items": { "type": "string" } } }, "required": [ "componentName", "componentVersion", "isRoot", "lastInstallationSource", "lastReportedTimestamp", "lastStatusChangeTimestamp", "lifecycleState", "lifecycleStateDetails", "lifecycleStatusCodes" ] }, "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": [ { "componentName": "com.example.ComponentA", "componentVersion": "1.0.0", "isRoot": false, "lastInstallationSource": "https://example.com/components/componentA/1.0.0", "lastReportedTimestamp": 1700000000000, "lastStatusChangeTimestamp": 1704067200000, "lifecycleState": "RUNNING", "lifecycleStateDetails": "The component is currently running.", "lifecycleStatusCodes": [ "NORMAL" ] } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{edgeGatewayId}/lorawan-devices": { "get": { "summary": "Get LoRaWAN devices in edge gateway", "description": "Get LoRaWAN Devices in edge gateway", "operationId": "Edge_Gateways.GetLoRaWANDevicesInEdgeGateway", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge Gateway ID", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "requireThingAttributes", "description": "Also fetch thing attributes.", "in": "query", "schema": { "type": "string", "enum": [ "true", "false" ] }, "required": false }, { "name": "requireThingShadows", "description": "Also fetch thing shadows with shadow names.", "in": "query", "schema": { "type": "string", "enum": [ "true", "false" ] }, "required": false }, { "name": "thingShadowNames", "description": "Specify shadow names to fetch. (Default: optional; Options: DeviceUplink, GatewayUplink)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "thingArn": { "type": "string" }, "thingId": { "type": "string" }, "thingName": { "type": "string" }, "thingTypeName": { "type": "string" }, "attributes": { "type": "object", "properties": {}, "required": [] }, "shadows": { "type": "object", "properties": {}, "required": [] } }, "required": [ "thingArn", "thingId", "thingName", "thingTypeName", "attributes", "shadows" ], "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": { "thingArn": "arn:aws:iot:region:accountId:thing/ThingName", "thingId": "abcd1234", "thingName": "LoRaWAN_Gateway_01", "thingTypeName": "LoRaWAN_Gateway", "attributes": { "Manufacturer": "ExampleCorp", "Model": "LW-Gateway-1000", "SerialNumber": "SN000123456789", "FirmwareVersion": "1.0.5" }, "shadows": { "DeviceUplink": { "state": { "reported": { "Payload": { "Temperature": 25.4, "Humidity": 62, "CO2": 869, "rssi": -91 }, "ExpiredAt": 1711341602287 }, "metadata": { "reported": { "Payload": { "Temperature": { "timestamp": 1711330802 }, "Humidity": { "timestamp": 1711330802 }, "CO2": { "timestamp": 1711330802 }, "rssi": { "timestamp": 1711330802 } }, "ExpiredAt": { "timestamp": 1711330802 } } }, "version": 21415, "timestamp": 1711330849 } } } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{edgeGatewayId}/lorawan-gateways": { "get": { "summary": "Get LoRaWAN gateways in edge gateway", "description": "Get LoRaWAN Gateways in edge gateway", "operationId": "Edge_Gateways.GetLoRaWANGatewaysInEdgeGateway", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge Gateway ID", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "requireThingAttributes", "description": "Also fetch thing attributes.", "in": "query", "schema": { "type": "string", "enum": [ "true", "false" ] }, "required": false }, { "name": "requireThingShadows", "description": "Also fetch thing shadows with shadow names.", "in": "query", "schema": { "type": "string", "enum": [ "true", "false" ] }, "required": false }, { "name": "thingShadowNames", "description": "Specify shadow names to fetch. (Default: optional; Options: DeviceUplink, GatewayUplink)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "thingArn": { "type": "string" }, "thingId": { "type": "string" }, "thingName": { "type": "string" }, "thingTypeName": { "type": "string" }, "attributes": { "type": "object", "properties": {}, "required": [] }, "shadows": { "type": "object", "properties": {}, "required": [] } }, "required": [ "thingArn", "thingId", "thingName", "thingTypeName", "attributes", "shadows" ], "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": { "thingArn": "arn:aws:iot:region:accountId:thing/LoRaWANGateway01", "thingId": "efgh5678", "thingName": "LoRaWAN_Gateway_01", "thingTypeName": "LoRaWAN_Gateway", "attributes": { "Location": "Building 1, Floor 3", "CoverageArea": "Campus A", "NetworkProvider": "LoRaWAN Network A", "DeploymentDate": "2023-06-15" }, "shadows": { "DeviceUplink": { "state": { "reported": { "Payload": { "Temperature": 25.4, "Humidity": 62, "CO2": 869, "rssi": -91 }, "ExpiredAt": 1711341602287 }, "metadata": { "reported": { "Payload": { "Temperature": { "timestamp": 1711330802 }, "Humidity": { "timestamp": 1711330802 }, "CO2": { "timestamp": 1711330802 }, "rssi": { "timestamp": 1711330802 } }, "ExpiredAt": { "timestamp": 1711330802 } } }, "version": 21415, "timestamp": 1711330849 } } } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{edgeGatewayId}/metrics/network": { "get": { "summary": "Get network metric with edge gateway", "description": "Get network metric with edge gateway", "operationId": "Edge_Gateways.GetNetworkMetricWithEdgeGateway", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge Gateway ID", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "period", "description": "Period of metric. (unit: sec)", "in": "query", "schema": { "type": "number", "enum": [ "60", "300", "900", "3600", "86400", "604800", "2592000" ], "default": 300 }, "required": false }, { "name": "periodTime", "description": "Period time of metric. (unit: sec)", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 129600, "default": 60 }, "required": false }, { "name": "statistic", "description": "Statistic of metric.", "in": "query", "schema": { "type": "string", "enum": [ "Average", "Minimum", "Maximum" ], "default": "Average" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "pingMax": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] }, "pingMin": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] }, "pingAverage": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] }, "pingMdev": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] }, "pingTotalPackets": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] }, "pingLossPackets": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] } }, "required": [ "pingMax", "pingMin", "pingAverage", "pingMdev", "pingTotalPackets", "pingLossPackets" ], "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": { "pingMax": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 120, 115 ] }, "pingMin": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 40, 45 ] }, "pingAverage": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 80, 75 ] }, "pingMdev": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 5, 7 ] }, "pingTotalPackets": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 100, 100 ] }, "pingLossPackets": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 0, 1 ] } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{edgeGatewayId}/metrics/temperature": { "get": { "summary": "Get CPU & power temperature metric with edge gateway", "description": "Get CPU & power temperature metric with edge gateway", "operationId": "Edge_Gateways.GetTemperatureMetricWithEdgeGateway", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge Gateway ID", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "period", "description": "Period of metric(unit: sec).", "in": "query", "schema": { "type": "string", "enum": [ "60", "300", "900", "3600", "86400", "604800", "2592000" ], "default": "300" }, "required": false }, { "name": "periodTime", "description": "Period time of metric(unit: sec).", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 129600, "default": 60 }, "required": false }, { "name": "statistic", "description": "Statistic of metric", "in": "query", "schema": { "type": "string", "enum": [ "Average", "Minimum", "Maximum" ] }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "cpuTemperature": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] }, "powerTemperature": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] } }, "required": [ "cpuTemperature", "powerTemperature" ], "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": { "cpuTemperature": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 55, 57 ] }, "powerTemperature": { "timestamps": [ 1704067200000, 1706659200000 ], "values": [ 33, 34 ] } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways": { "get": { "summary": "List edge gateways", "description": "List edge gateways", "operationId": "Edge_Gateways.ListEdgeGateways", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "coreDeviceThingName": { "type": "string" }, "status": { "type": "string" }, "lastStatusUpdateTimestamp": { "type": "number" } }, "required": [ "coreDeviceThingName", "status", "lastStatusUpdateTimestamp" ] }, "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": [ { "coreDeviceThingName": "EdgeGateway001", "status": "ACTIVE", "lastStatusUpdateTimestamp": 1700000000000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/edge-gateways/{edgeGatewayId}/shadows/shadow-manager": { "put": { "summary": "Update Shadow Manager", "description": "Update Shadow Manager", "operationId": "Edge_Gateways.Update_Shadow_Manager", "tags": [ "Edge Gateways" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "edgeGatewayId", "description": "Edge gateway device EUI", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "deploymentId": { "type": "string" }, "iotJobId": { "type": "string" }, "iotJobArn": { "type": "string" } }, "required": [ "deploymentId", "iotJobId", "iotJobArn" ] }, "description": "Data of the edge gateway." } }, "required": [ "data" ] }, "example": { "data": [ { "deploymentId": "dp-0123456789abcdef0", "iotJobId": "job-abcdef1234567890", "iotJobArn": "arn:aws:iot:region:account:job/job-abcdef1234567890" } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/admin/organizations/{organizationId}/feedback": { "get": { "summary": "Admin Get Feedback", "description": "Admin Get Feedback", "operationId": "Feedback.AdminGetFeedback", "tags": [ "Feedback" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "url": { "type": "string" } }, "required": [ "url" ], "description": "Data of the admin feedback link." } }, "required": [ "data" ] }, "example": { "data": { "url": "https://app.feedback.infodeck.io/en/launch?platform=infodeck&access_token=48b1cxxxxxxxxxx6&refresh_token=a4888xxxxxxxxxx2" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/resources/{resourceId}/feedback": { "get": { "summary": "Get Feedback Url", "description": "Get Feedback Url", "operationId": "Feedback.GetFeedbackUrl", "tags": [ "Feedback" ], "parameters": [ { "name": "resourceId", "description": "The ID of resource.(a, l, sl, z)", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "url": { "type": "string" } }, "required": [ "url" ], "description": "Data of the chat room." } }, "required": [ "data" ] }, "example": { "data": { "url": "https://app.feedback.infodeck.io/chatRoomId?name=resourceName" } }, "description": "" } } }, "400": { "description": "The request has invalid data.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has invalid data." }, "message": { "type": "string", "description": "The request has invalid data message." } }, "required": [ "error", "message" ] }, "example": { "error": "Bad Request", "message": "The request cannot be processed due to a bad request." }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [] } }, "/organizations/{organizationId}/integrations": { "post": { "summary": "Create Integration Service", "description": "Create Integration Service", "operationId": "Integration.CreateIntegrationService", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of integration." }, "description": { "type": "string", "description": "The description of integration." }, "type": { "type": "string", "description": "The type of integration." } }, "required": [ "name", "type" ] }, "example": { "name": "IDT-Service", "description": "IDT-Servcie-Description", "type": "InfodeckLNS" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "type": { "type": "string" }, "config": { "type": "object", "properties": { "host": { "type": "string" }, "apiKey": { "type": "string" }, "authorization": { "type": "string" } }, "required": [ "host", "apiKey", "authorization" ] }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "type", "config", "createdBy", "createdAtDateString", "createdAt" ], "description": "Data of the services." } }, "required": [ "data" ] }, "example": { "id": "is-integrationServiceId", "organizationId": "o-organizationId", "name": "LNS-Service", "description": "LNS-Service-Description", "type": "InfodeckLNS", "config": { "host": "lns-hosto:8080", "apiKey": "eyJ0exxxxxxxxxx4", "authorization": "eyJhbxxxxxxxxxxg" }, "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Integration Services", "description": "List Integration Services", "operationId": "Integration.ListIntegrationServices", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "type": { "type": "string" }, "config": { "type": "object", "properties": { "host": { "type": "string" }, "apiKey": { "type": "string" }, "authorization": { "type": "string" } }, "required": [ "host", "apiKey", "authorization" ] }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "type", "config", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Array of integration services." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "is-integrationServiceId", "organizationId": "o-organizationId", "name": "LNS-Service", "description": "LNS-Service-Description", "type": "InfodeckLNS", "config": { "host": "lns-hosto:8080", "apiKey": "eyJ0exxxxxxxxxx4", "authorization": "eyJhbxxxxxxxxxxg" }, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/integrations/{serviceId}": { "delete": { "summary": "Delete Integration Service", "description": "Delete Integration Service", "operationId": "Integration.DeleteIntegrationService", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "serviceId", "description": "The ID of integration.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the services." } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Integration Service", "description": "Get Integration Service", "operationId": "Integration.GetIntegrationService", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "serviceId", "description": "The ID of integration.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "type": { "type": "string" }, "config": { "type": "object", "properties": { "host": { "type": "string" }, "apiKey": { "type": "string" }, "authorization": { "type": "string" } }, "required": [ "host", "apiKey", "authorization" ] }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedBy": { "type": "string" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "type", "config", "createdBy", "createdAtDateString", "createdAt", "updatedBy", "updatedAtDateString", "updatedAt" ], "description": "Data of the integration service." } }, "required": [ "data" ] }, "example": { "data": { "id": "is-integrationServiceId", "organizationId": "o-organizationId", "name": "LNS-Service", "description": "LNS-Service-Description", "type": "InfodeckLNS", "config": { "host": "lns-hosto:8080", "apiKey": "eyJ0exxxxxxxxxx4", "authorization": "eyJhbxxxxxxxxxxg" }, "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Integration Service", "description": "Update Integration Service", "operationId": "Integration.UpdateIntegrationService", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "serviceId", "description": "The ID of integration.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of integration." }, "description": { "type": "string", "description": "The description of integration." }, "config": { "type": "object", "properties": {}, "required": [], "description": "The configuration of integration." } }, "required": [ "name" ] }, "example": { "name": "IDT-Service", "description": "IDT-Servcie-Description", "config": { "apiKey": "eyJ0xxxxxxxxxx4", "host": "abc-edf-ghi.infodeck.io" } }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "type": { "type": "string" }, "config": { "type": "object", "properties": { "host": { "type": "string" }, "apiKey": { "type": "string" }, "authorization": { "type": "string" } }, "required": [ "host", "apiKey", "authorization" ] }, "updatedBy": { "type": "string" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "type", "config", "updatedBy", "updatedAtDateString", "updatedAt" ], "description": "Data of the updated integration service." } }, "required": [ "data" ] }, "example": { "data": { "id": "is-integrationServiceId", "organizationId": "o-organizationId", "name": "LNS-Service", "description": "LNS-Service-Description", "type": "InfodeckLNS", "config": { "host": "lns-hosto:8080", "apiKey": "eyJ0exxxxxxxxxx4", "authorization": "eyJhbxxxxxxxxxxg" }, "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/integrations/actility": { "post": { "summary": "Forward Actility Hook", "description": "Forward Actility Hook", "operationId": "Integration.ForwardActilityHook", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "cmd": { "type": "string", "description": "The cmd of IoT device." }, "seqno": { "type": "string", "description": "The sequence number of uplink message." }, "EUI": { "type": "string", "description": "The EUI of IoT device." }, "ts": { "type": "string", "description": "The timestamp of uplink message." }, "fcnt": { "type": "string", "description": "The frame counter of uplink message." }, "port": { "type": "string", "description": "The port of uplink message." }, "freq": { "type": "string", "description": "The frequency of uplink message." }, "toa": { "type": "string", "description": "The time on air of uplink message." }, "dr": { "type": "string", "description": "The data rate of uplink message." }, "ack": { "type": "boolean", "description": "The ACK bit of uplink message." }, "gws": { "type": "array", "items": { "type": "object", "properties": { "gweui": { "type": "string" }, "rssi": { "type": "number" }, "snr": { "type": "number" }, "ant": { "type": "number" }, "lat": { "type": "number" }, "lon": { "type": "number" }, "time": { "type": "string" } }, "required": [ "gweui", "rssi", "snr", "ant", "lat", "lon", "time" ] }, "description": "The gateways that received the uplink message." }, "bat": { "type": "string", "description": "The battery level of the IoT device." }, "data": { "type": "string", "description": "The payload of the uplink message." } }, "required": [ "cmd", "seqno", "EUI", "ts", "fcnt", "port", "freq", "toa", "dr", "ack", "gws", "bat", "data" ] }, "example": { "DevEUI_uplink": { "-xmlns": "http://uri.actility.com/lora", "Time": "2015-07-09T16:06:38.49+02:00", "DevEUI": "000000000F1D8693", "FPort": "2", "FCntUp": "7011", "ADRbit": "1", "ACKbit": "1", "MType": "4", "FCntDn": "11", "payload_hex": "0027bd00", "mic_hex": "38e7a3b9", "Lrcid": "00000065", "LrrRSSI": "-60.000000", "LrrSNR": "9.750000", "SpFact": "7", "SubBand": "G1", "Channel": "LC2", "DevLrrCnt": "2", "Lrrid": "08040059", "Late": "0", "LrrLAT": "48.874931", "LrrLON": "2.333673", "Lrrs": { "Lrr": [ { "Lrrid": "08040059", "LrrRSSI": "-60.000000", "LrrSNR": "9.750000", "LrrESP": "-59.000000" }, { "Lrrid": "33d13a41", "LrrRSSI": "-73.000000", "LrrSNR": "9.750000", "LrrESP": "-72.000000" } ] }, "CustomerID": "100000507", "CustomerData": { "loc": { "lat": "43.58081", "lon": "1.4421667" }, "alr": { "pro": "STL", "ver": "1" } }, "InstantPER": "0.02", "MeanPER": "0.02", "DevAddr": "0405F519", "UplinkDC": "0.001", "UplinkDCSubBand": "0.009" } }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "forwarded": { "type": "boolean", "description": "forwarded successfully." } }, "required": [ "forwarded" ] }, "example": { "forwarded": true }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/integrations/aws-iot": { "post": { "summary": "Forward AWS IoT Hook", "description": "Forward AWS IoT Hook", "operationId": "Integration.ForwardAwsIotHook", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } }, { "name": "event", "description": "The event to forward.", "in": "query", "schema": { "type": "string", "enum": [ "up" ] }, "required": true } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "timestamp": { "type": "number", "description": "The ID used for deduplication." }, "organizationId": { "type": "string", "description": "The time of the payload in ISO 8601 format." }, "assetId": { "type": "string", "description": "Information about the IoT device." }, "event": { "type": "string", "description": "The ID of the tenant." }, "data": { "type": "object", "properties": {}, "required": [], "description": "The name of the tenant." } }, "required": [ "timestamp", "organizationId", "assetId", "event", "data" ] }, "example": [ { "timestamp": 123456789, "organizationId": "o-213133123", "assetId": "12321441", "event": "status", "data": {} } ], "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "forwarded": { "type": "boolean", "description": "forwarded successfully." } }, "required": [ "forwarded" ] }, "example": { "forwarded": true }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/integrations/chirpstack-v4": { "post": { "summary": "Forward ChirpstackV4 Hook", "description": "Forward ChirpstackV4 Hook", "operationId": "Integration.ForwardChirpstackV4Hook", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } }, { "name": "event", "description": "The event to forward.", "in": "query", "schema": { "type": "string", "enum": [ "up" ] }, "required": true } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "deduplicationId": { "type": "string", "description": "The ID used for deduplication." }, "time": { "type": "string", "description": "The time of the payload in ISO 8601 format." }, "deviceInfo": { "type": "object", "properties": { "tenantId": { "type": "string" }, "tenantName": { "type": "string" }, "applicationId": { "type": "string" }, "applicationName": { "type": "string" }, "deviceProfileId": { "type": "string" }, "deviceProfileName": { "type": "string" }, "deviceName": { "type": "string" }, "devEui": { "type": "string" }, "deviceClassEnabled": { "type": "string" }, "tags": { "type": "object", "properties": {}, "required": [] } }, "required": [ "tenantId", "tenantName", "applicationId", "applicationName", "deviceProfileId", "deviceProfileName", "deviceName", "devEui", "deviceClassEnabled", "tags" ], "description": "Information about the IoT device." }, "devAddr": { "type": "string", "description": "The device address." }, "adr": { "type": "boolean", "description": "Flag indicating if Adaptive Data Rate (ADR) is enabled." }, "dr": { "type": "number", "description": "The data rate used by the device." }, "fCnt": { "type": "number", "description": "The frame counter." }, "fPort": { "type": "number", "description": "The FPort number." }, "confirmed": { "type": "boolean", "description": "Flag indicating if the transmission was confirmed." }, "data": { "type": "string", "description": "The payload data." }, "rxInfo": { "description": "Information about the received packet." }, "rxInfo[]": { "type": "string", "description": ".crcStatus The status of the CRC check." }, "txInfo": { "type": "object", "properties": { "frequency": { "type": "number" }, "modulation": { "type": "object", "properties": { "lora": { "type": "object", "properties": { "bandwidth": { "type": "number" }, "spreadingFactor": { "type": "number" }, "codeRate": { "type": "string" } }, "required": [ "bandwidth", "spreadingFactor", "codeRate" ] } }, "required": [ "lora" ] } }, "required": [ "frequency", "modulation" ], "description": "Information about the transmitted packet." } }, "required": [ "deduplicationId", "time", "deviceInfo", "devAddr", "adr", "dr", "fCnt", "fPort", "confirmed", "data", "rxInfo", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "txInfo" ] }, "example": { "deduplicationId": "0447f96f-xxxx-xxxx-xxxx-d886df897a41", "time": "2024-01-01T12:00:00.000+00:00", "deviceInfo": { "tenantId": "52f14cd4-xxxx-xxxx-xxxx-4025e1d49242", "tenantName": "ChirpStack", "applicationId": "8d757a70-xxxx-xxxx-xxxx-a178bc6edf12", "applicationName": "Development", "deviceProfileId": "78a84f5c-xxxx-xxxx-xxxx-1de32826eca9", "deviceProfileName": "NS330-SBC", "deviceName": "NS330-SBC", "devEui": "24e124535b312345", "deviceClassEnabled": "CLASS_C", "tags": {} }, "devAddr": "0036e085", "adr": true, "dr": 5, "fCnt": 113, "fPort": 85, "confirmed": true, "data": "/y4B", "rxInfo": [ { "gatewayId": "24e124fffef12345", "uplinkId": 534054989, "time": "2023-07-18T10:28:32.267788+00:00", "timeSinceGpsEpoch": "1373711330.267s", "rssi": -55, "snr": 13.5, "location": {}, "context": "j0J2SA==", "metadata": { "region_config_id": "as923", "region_common_name": "AS923" }, "crcStatus": "CRC_OK" } ], "txInfo": { "frequency": 923200000, "modulation": { "lora": { "bandwidth": 125000, "spreadingFactor": 7, "codeRate": "CR_4_5" } } } }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "forwarded": { "type": "boolean", "description": "forwarded successfully." } }, "required": [ "forwarded" ] }, "example": { "forwarded": true }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/integrations/infodeck-lns": { "post": { "summary": "Forward InfodeckLNS Hook", "description": "Forward InfodeckLNS Hook", "operationId": "Integration.ForwardInfodeckLNSHook", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } }, { "name": "event", "description": "The event to forward.", "in": "query", "schema": { "type": "string", "enum": [ "up" ] }, "required": true } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "deduplicationId": { "type": "string", "description": "The ID used for deduplication." }, "time": { "type": "string", "description": "The time of the payload in ISO 8601 format." }, "deviceInfo": { "type": "object", "properties": { "tenantId": { "type": "string" }, "tenantName": { "type": "string" }, "applicationId": { "type": "string" }, "applicationName": { "type": "string" }, "deviceProfileId": { "type": "string" }, "deviceProfileName": { "type": "string" }, "deviceName": { "type": "string" }, "devEui": { "type": "string" }, "deviceClassEnabled": { "type": "string" }, "tags": { "type": "object", "properties": {}, "required": [] } }, "required": [ "tenantId", "tenantName", "applicationId", "applicationName", "deviceProfileId", "deviceProfileName", "deviceName", "devEui", "deviceClassEnabled", "tags" ], "description": "Information about the IoT device." }, "devAddr": { "type": "string", "description": "The device address." }, "adr": { "type": "boolean", "description": "Flag indicating if Adaptive Data Rate (ADR) is enabled." }, "dr": { "type": "number", "description": "The data rate used by the device." }, "fCnt": { "type": "number", "description": "The frame counter." }, "fPort": { "type": "number", "description": "The FPort number." }, "confirmed": { "type": "boolean", "description": "Flag indicating if the transmission was confirmed." }, "data": { "type": "string", "description": "The payload data." }, "rxInfo": { "description": "Information about the received packet." }, "rxInfo[]": { "type": "string", "description": ".crcStatus The status of the CRC check." }, "txInfo": { "type": "object", "properties": { "frequency": { "type": "number" }, "modulation": { "type": "object", "properties": { "lora": { "type": "object", "properties": { "bandwidth": { "type": "number" }, "spreadingFactor": { "type": "number" }, "codeRate": { "type": "string" } }, "required": [ "bandwidth", "spreadingFactor", "codeRate" ] } }, "required": [ "lora" ] } }, "required": [ "frequency", "modulation" ], "description": "Information about the transmitted packet." } }, "required": [ "deduplicationId", "time", "deviceInfo", "devAddr", "adr", "dr", "fCnt", "fPort", "confirmed", "data", "rxInfo", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "rxInfo[]", "txInfo" ] }, "example": { "deduplicationId": "0447f96f-xxxx-xxxx-xxxx-d886df897a41", "time": "2024-01-01T12:00:00.000+00:00", "deviceInfo": { "tenantId": "52f14cd4-xxxx-xxxx-xxxx-4025e1d49242", "tenantName": "InfodeckLNS", "applicationId": "8d757a70-xxxx-xxxx-xxxx-a178bc6edf12", "applicationName": "Development", "deviceProfileId": "78a84f5c-xxxx-xxxx-xxxx-1de32826eca9", "deviceProfileName": "NS330-SBC", "deviceName": "NS330-SBC", "devEui": "24e124535b312345", "deviceClassEnabled": "CLASS_C", "tags": {} }, "devAddr": "0036e085", "adr": true, "dr": 5, "fCnt": 113, "fPort": 85, "confirmed": true, "data": "/y4B", "rxInfo": [ { "gatewayId": "24e124fffef12345", "uplinkId": 534054989, "time": "2023-07-18T10:28:32.267788+00:00", "timeSinceGpsEpoch": "1373711330.267s", "rssi": -55, "snr": 13.5, "location": {}, "context": "j0J2SA==", "metadata": { "region_config_id": "as923", "region_common_name": "AS923" }, "crcStatus": "CRC_OK" } ], "txInfo": { "frequency": 923200000, "modulation": { "lora": { "bandwidth": 125000, "spreadingFactor": 7, "codeRate": "CR_4_5" } } } }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "forwarded": { "type": "boolean", "description": "forwarded successfully." } }, "required": [ "forwarded" ] }, "example": { "forwarded": true }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/integrations/loriot": { "post": { "summary": "Forward Loriot Hook", "description": "Forward Loriot Hook", "operationId": "Integration.ForwardLoriotHook", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "cmd": { "type": "string", "description": "The cmd of IoT device." }, "seqno": { "type": "string", "description": "The sequence number of uplink message." }, "EUI": { "type": "string", "description": "The EUI of IoT device." }, "ts": { "type": "string", "description": "The timestamp of uplink message." }, "fcnt": { "type": "string", "description": "The frame counter of uplink message." }, "port": { "type": "string", "description": "The port of uplink message." }, "freq": { "type": "string", "description": "The frequency of uplink message." }, "toa": { "type": "string", "description": "The time on air of uplink message." }, "dr": { "type": "string", "description": "The data rate of uplink message." }, "ack": { "type": "boolean", "description": "The ACK bit of uplink message." }, "gws": { "type": "array", "items": { "type": "object", "properties": { "gweui": { "type": "string" }, "rssi": { "type": "number" }, "snr": { "type": "number" }, "ant": { "type": "number" }, "lat": { "type": "number" }, "lon": { "type": "number" }, "time": { "type": "string" } }, "required": [ "gweui", "rssi", "snr", "ant", "lat", "lon", "time" ] }, "description": "The gateways that received the uplink message." }, "bat": { "type": "string", "description": "The battery level of the IoT device." }, "data": { "type": "string", "description": "The payload of the uplink message." } }, "required": [ "cmd", "seqno", "EUI", "ts", "fcnt", "port", "freq", "toa", "dr", "ack", "gws", "bat", "data" ] }, "example": { "cmd": "gw", "seqno": 4, "EUI": "24E124141B267890", "ts": 1688114678797, "fcnt": 4, "port": 85, "freq": 923800000, "toa": 371, "dr": "SF10 BW125 4/5", "ack": false, "gws": [ { "rssi": -87, "snr": 12.2, "ts": 1688114678797, "time": "2023-06-30T08:44:38.797Z", "gweui": "24E124FFFFF12345", "ant": 0, "lat": 25.0520483, "lon": 121.5462282 } ], "bat": 2, "data": "017501030001040001" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "forwarded": { "type": "boolean", "description": "forwarded successfully." } }, "required": [ "forwarded" ] }, "example": { "forwarded": true }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/integrations/the-things-network": { "post": { "summary": "Forward Ttn Hook", "description": "Forward Ttn Hook", "operationId": "Integration.ForwardTtnHook", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "forwarded": { "type": "boolean", "description": "forwarded successfully." } }, "required": [ "forwarded" ] }, "example": { "forwarded": true }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/integrations/{serviceId}/devices/{deviceId}": { "get": { "summary": "Get Integration device", "description": "Get Integration Device", "operationId": "Integration.GetIntegrationDevice", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "integrationServiceId", "description": "The ID of integration.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deviceId", "description": "The ID of integration device.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "devEui": { "type": "string" }, "organizationId": { "type": "string" }, "integrationServiceId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "assetTypeId": { "type": "string" }, "locationId": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "devEui", "organizationId", "integrationServiceId", "name", "description", "assetTypeId", "locationId", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the service devices." } }, "required": [ "data" ] }, "example": { "data": { "id": "a-devEui", "devEui": "24e124535b312345", "organizationId": "o-organizationId", "integrationServiceId": "is-integrationServiceId", "name": "IDT-Bot-device", "description": "IDT-Bot-device", "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1700000000000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1710000000000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "delete": { "summary": "Unlink Integration Device", "description": "Unlink Integration Device", "operationId": "Integration.UnlinkIntegrationDevice", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "integrationServiceId", "description": "The ID of integration.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deviceId", "description": "The ID of integration device.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the service devices." } }, "required": [ "data" ] }, "example": { "data": { "unlinked": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Integration Device", "description": "Update Integration Device", "operationId": "Integration.UpdateIntegrationDevice", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "integrationServiceId", "description": "The ID of integration.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deviceId", "description": "The ID of integration device.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "devEui": { "type": "string", "description": "The devEui of integration device." }, "name": { "type": "string", "description": "The name of integration device." }, "description": { "type": "string", "description": "The description of integration." }, "attributes": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The custom attributes of device" } }, "required": [ "devEui", "name" ] }, "example": { "devEui": "24e124535b312345", "name": "IDT-BoT", "description": "IDT-BoT-Description", "attributes": [ "Test-A", "Test-B", "Test-C" ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "integrationServiceId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "devEui": { "type": "string" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "integrationServiceId", "name", "description", "devEui", "updatedAtDateString", "updatedAt" ], "description": "Data of the updated service device." } }, "required": [ "data" ] }, "example": { "data": { "id": "a-24e124535b312345", "organizationId": "o-organizationId", "integrationServiceId": "is-integrationServiceId", "name": "IDT-Bot", "description": "IDT-Bot-Description", "devEui": "24e124535b312345", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/integrations/{serviceId}/devices": { "post": { "summary": "Link Integration Device", "description": "Link Integration Device", "operationId": "Integration.LinkIntegrationDevice", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "integrationServiceId", "description": "The ID of integration.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "devEui": { "type": "string", "description": "The devEui of integration device." }, "name": { "type": "string", "description": "The name of integration device." }, "description": { "type": "string", "description": "The description of device." }, "assetTypeId": { "type": "string", "description": "The ID of asset type." }, "locationId": { "type": "string", "description": "The ID of location." }, "attributes": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The custom attributes of device." } }, "required": [ "devEui", "name", "assetTypeId", "locationId", "attributes" ] }, "example": { "devEui": "24e124535b312345", "name": "IDT-Bot", "description": "IDT-Bot-Description", "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "attributes": [ "Test-A", "Test-B", "Test-C" ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "integrationServiceId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "devEui": { "type": "string" }, "assetTypeId": { "type": "string" }, "locationId": { "type": "string" }, "location": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "address": { "type": "string" }, "chatRoomId": { "type": "string" }, "entities": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "id", "organizationId", "name", "description", "address", "chatRoomId", "entities" ] }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "integrationServiceId", "name", "description", "devEui", "assetTypeId", "locationId", "location", "createdAtDateString", "createdAt" ], "description": "Data of the linked service device." } }, "required": [ "data" ] }, "example": { "data": { "id": "a-24e124535b312345", "organizationId": "o-organizationId", "integrationServiceId": "is-integrationServiceId", "name": "IDT-Bot", "description": "IDT-Bot-Description", "devEui": "24e124535b312345", "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "location": { "id": "l-locationId", "organizationId": "o-organizationId", "name": "office", "description": "location-description", "address": "address", "chatRoomId": "ABCDE", "entities": [] }, "createdAtDateString": "2024-01-01T00:00:00.000Z", "created": 1700000000000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Integration devices", "description": "List Integration Devices", "operationId": "Integration.ListIntegrationDevices", "tags": [ "Integration" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "integrationServiceId", "description": "The ID of integration service.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 25 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "integrationServiceId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "devEui": { "type": "string" }, "assetTypeId": { "type": "string" }, "locationId": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "integrationServiceId", "name", "description", "devEui", "assetTypeId", "locationId", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Array of data for the service devices." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "a-24e124535b312345", "organizationId": "o-organizationId", "integrationServiceId": "is-integrationServiceId", "name": "IDT-Bot", "description": "IDT-Bot-Description", "devEui": "24e124535b312345", "assetTypeId": "at-assetTypeId", "locationId": "l-locationId", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications": { "post": { "summary": "Create Application", "description": "Create application", "operationId": "LNS_Application.CreateApplication", "tags": [ "LNS Application" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of application." }, "description": { "type": "string", "description": "The description of application." } }, "required": [ "name" ] }, "example": {}, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "tenantId": { "type": "string" }, "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" } }, "required": [ "tenantId", "id", "name", "description" ], "description": "Data of the application." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "name": "IDT-Application", "description": "IDT-Application-Description" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Applications", "description": "List applications", "operationId": "LNS_Application.ListApplications", "tags": [ "LNS Application" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "offset", "description": "The offset of application.", "in": "query", "schema": { "type": "number", "minimum": 0, "default": 0 }, "required": false }, { "name": "limit", "description": "The limit of application.", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 100, "default": 20 }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "id", "name", "description", "createdAt", "updatedAt" ] }, "description": "Data of the application." } }, "required": [ "data" ] }, "example": { "data": [ { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "name": "IDT-Application", "description": "IDT-Application-Description", "createdAt": "2024-01-01T00:00:00.000Z", "updatedAt": null } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}": { "delete": { "summary": "Delete Application", "description": "Delete application", "operationId": "LNS_Application.DeleteApplication", "tags": [ "LNS Application" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Application", "description": "Get application", "operationId": "LNS_Application.GetApplication", "tags": [ "LNS Application" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "tenantId": { "type": "string" }, "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "tenantId", "id", "name", "description", "createdAt", "updatedAt" ], "description": "Data of the application." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "name": "IDT-Application", "description": "IDT-Application-Description", "createdAt": "2024-01-01T00:00:00.000Z", "updatedAt": null } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Application", "description": "Update application", "operationId": "LNS_Application.UpdateApplication", "tags": [ "LNS Application" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of application." }, "description": { "type": "string", "description": "The description of application." } }, "required": [ "name" ] }, "example": { "name": "IDT-Application", "description": "IDT-Application-Description" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "tenantId": { "type": "string" }, "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" } }, "required": [ "tenantId", "id", "name", "description" ], "description": "Data of the application." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "name": "IDT-Application", "description": "IDT-Application-Description" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/integration": { "get": { "summary": "Get Http Integration", "description": "Get http integration", "operationId": "LNS_Application.GetHttpIntegration", "tags": [ "LNS Application" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "tenantId": { "type": "string" }, "id": { "type": "string" }, "headersMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "encoding": { "type": "number" }, "eventEndpointUrl": { "type": "string" } }, "required": [ "tenantId", "id", "headersMap", "encoding", "eventEndpointUrl" ], "description": "Data of the application." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "headersMap": [ { "key": "Authorization", "value": "eyJhbxxxxxxxxxxU" } ], "encoding": 0, "eventEndpointUrl": "https://app.infodeck.io/api/integrations/infodeck-lns" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices": { "post": { "summary": "Create Device", "description": "Create device", "operationId": "LNS_Device.CreateDevice", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of device." }, "description": { "type": "string", "description": "The description of device." }, "devEui": { "type": "string", "description": "The ID of device." }, "joinEui": { "type": "string", "description": "The ID of joinEui." }, "deviceProfileId": { "type": "string", "description": "The ID of deviceProfile." }, "isDisabled": { "type": "boolean", "description": "The isDisabled of device." }, "skipFcntCheck": { "type": "boolean", "description": "The skipFcntCheck of device." }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The tagsMsp of device." }, "variablesMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The variablesMap of device." } }, "required": [ "name", "devEui", "deviceProfileId" ] }, "example": { "name": "IDT-Device", "description": "IDT-Device-Description", "devEui": "24e124535b312345", "joinEui": "24e124c0002abcde", "deviceProfileId": "f1b1f383-xxxx-xxxx-xxxx-b656250d225b", "isDisabled": false, "skipFcntCheck": false, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ], "variablesMap": [ { "key": "version", "value": "1.0.2" } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "tenantId": { "type": "string" }, "applicationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "devEui": { "type": "string" }, "joinEui": { "type": "string" }, "deviceProfileId": { "type": "string" }, "isDisabled": { "type": "boolean" }, "skipFcntCheck": { "type": "boolean" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "variablesMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "tenantId", "applicationId", "name", "description", "devEui", "joinEui", "deviceProfileId", "isDisabled", "skipFcntCheck", "tagsMap", "variablesMap" ], "description": "Data of the device." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "applicationId": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "name": "IDT-Device", "description": "IDT-Device-Description", "devEui": "24e124535b312345", "joinEui": "24e124c0002abcde", "deviceProfileId": "f1b1f383-xxxx-xxxx-xxxx-b656250d225b", "isDisabled": false, "skipFcntCheck": false, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ], "variablesMap": [ { "key": "version", "value": "1.0.2" } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Devices", "description": "List devices", "operationId": "LNS_Device.ListDevices", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "offset", "description": "The offset of device.", "in": "query", "schema": { "type": "number", "minimum": 0, "default": 0 }, "required": false }, { "name": "limit", "description": "The limit of device.", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 100, "default": 20 }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" }, "devEui": { "type": "string" }, "deviceProfileId": { "type": "string" }, "deviceProfileName": { "type": "string" }, "deviceStatus": { "type": "object", "properties": {}, "required": [] }, "lastSeenAt": { "type": "number" }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "name", "description", "devEui", "deviceProfileId", "deviceProfileName", "deviceStatus", "lastSeenAt", "createdAt", "updatedAt" ] }, "description": "Data of the device." }, "totalCount": { "type": "number", "description": "Total count of device." } }, "required": [ "data", "totalCount" ] }, "example": { "data": [ { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "applicationId": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "name": "IDT-Device", "description": "IDT-Device-Description", "devEui": "24e124535b312345", "joinEui": "24e124c0002abcde", "deviceProfileId": "f1b1f383-xxxx-xxxx-xxxx-b656250d225b", "isDisabled": false, "skipFcntCheck": false, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ], "variablesMap": [ { "key": "version", "value": "1.0.2" } ] } ], "totalCount": 0 }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices/deviceId/activations": { "post": { "summary": "Create Device Activation", "description": "Create device activation", "operationId": "LNS_Device.CreateDeviceActivation", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "devEui": { "type": "string", "description": "The ID of device." }, "devAddr": { "type": "string", "description": "The devAddr of device activation." }, "appSKey": { "type": "string", "description": "The appSKey of device activation." }, "nwkSEncKey": { "type": "string", "description": "The nwkSEncKey of device activation." }, "sNwkSIntKey": { "type": "string", "description": "The sNwkSIntKey of device activation." }, "fNwkSIntKey": { "type": "string", "description": "The fNwkSIntKey of device activation." }, "fCntUp": { "type": "number", "description": "The fCntUp of device activation." }, "nFCntDown": { "type": "number", "description": "The nFCntDown of device activation." }, "aFCntDown": { "type": "number", "description": "The aFCntDown of device activation." } }, "required": [ "devEui" ] }, "example": { "devEui": "24e124535b318262", "devAddr": "0036e085", "appSKey": "98b81xxxxxxxxxxe", "nwkSEncKey": "be8dexxxxxxxxxxe", "sNwkSIntKey": "be8dexxxxxxxxxxe", "fNwkSIntKey": "be8dexxxxxxxxxxe", "fCntUp": 0, "nFCntDown": 0, "aFCntDown": 0 }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the device activation." } }, "required": [ "data" ] }, "example": { "data": { "created": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "delete": { "summary": "Delete Device Activation", "description": "Delete device activation", "operationId": "LNS_Device.DeleteDeviceActivation", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the device activation." } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Device Activation", "description": "Get device activation", "operationId": "LNS_Device.GetDeviceActivation", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "applicationId": { "type": "string" }, "devEui": { "type": "string" }, "devAddr": { "type": "string" }, "appSKey": { "type": "string" }, "nwkSEncKey": { "type": "string" }, "sNwkSIntKey": { "type": "string" }, "fNwkSIntKey": { "type": "string" }, "fCntUp": { "type": "number" }, "nFCntDown": { "type": "number" }, "aFCntDown": { "type": "number" } }, "required": [ "applicationId", "devEui", "devAddr", "appSKey", "nwkSEncKey", "sNwkSIntKey", "fNwkSIntKey", "fCntUp", "nFCntDown", "aFCntDown" ], "description": "Data of the device." } }, "required": [ "data" ] }, "example": { "data": { "devEui": "24e124535b318262", "devAddr": "0036e085", "appSKey": "98b81xxxxxxxxxx", "nwkSEncKey": "be8dexxxxxxxxxxe", "sNwkSIntKey": "be8dexxxxxxxxxxe", "fNwkSIntKey": "be8dexxxxxxxxxxe", "fCntUp": 0, "nFCntDown": 0, "aFCntDown": 0 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices/{deviceId}": { "delete": { "summary": "Delete Device", "description": "Delete device", "operationId": "LNS_Device.DeleteDevice", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Device", "description": "Update device", "operationId": "LNS_Device.UpdateDevice", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of device." }, "description": { "type": "string", "description": "The description of device." }, "devEui": { "type": "string", "description": "The ID of device." }, "joinEui": { "type": "string", "description": "The ID of joinEui." }, "deviceProfileId": { "type": "string", "description": "The ID of deviceProfile." }, "isDisabled": { "type": "boolean", "description": "The isDisabled of device." }, "skipFcntCheck": { "type": "boolean", "description": "The skipFcntCheck of device." }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The tagsMsp of device." }, "variablesMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The variablesMap of device." } }, "required": [ "name", "devEui", "deviceProfileId" ] }, "example": { "name": "IDT-Device", "description": "IDT-Device-Description", "devEui": "24e124535b312345", "joinEui": "24e124c0002abcde", "deviceProfileId": "f1b1f383-xxxx-xxxx-xxxx-b656250d225b", "isDisabled": false, "skipFcntCheck": false, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ], "variablesMap": [ { "key": "version", "value": "1.0.2" } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "applicationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "devEui": { "type": "string" }, "joinEui": { "type": "string" }, "deviceProfileId": { "type": "string" }, "isDisabled": { "type": "boolean" }, "skipFcntCheck": { "type": "boolean" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "variablesMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "applicationId", "name", "description", "devEui", "joinEui", "deviceProfileId", "isDisabled", "skipFcntCheck", "tagsMap", "variablesMap" ], "description": "Data of the device." } }, "required": [ "data" ] }, "example": { "data": { "applicationId": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "name": "IDT-Device", "description": "IDT-Device-Description", "devEui": "24e124535b312345", "joinEui": "24e124c0002abcde", "deviceProfileId": "f1b1f383-xxxx-xxxx-xxxx-b656250d225b", "isDisabled": false, "skipFcntCheck": false, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ], "variablesMap": [ { "key": "version", "value": "1.0.2" } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices/deviceId/queues": { "post": { "summary": "Enqueue Device Queue Item", "description": "Enqueue device queue item", "operationId": "LNS_Device.EnqueueDeviceQueueItem", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deviceId", "description": "The ID of device.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "id": { "type": "string", "description": "The ID of device queue." }, "confirmed": { "type": "boolean", "description": "The confirmed of device queue." }, "fPort": { "type": "number", "description": "The fPort of device queue." }, "fCntDown": { "type": "number", "description": "The fCntDown of device queue." }, "data": { "type": "string", "description": "The data of device queue." }, "object": { "type": "object", "properties": {}, "required": [], "description": "The object of device queue." }, "isPending": { "type": "boolean", "description": "The isPending of device queue." } }, "required": [] }, "example": { "id": "e61d84ba-xxxx-xxxx-xxxx-776da69aaa13", "devEui": "24e124535b312345", "confirmed": false, "isPending": false, "object": { "codec": "exampleCodec" }, "fCntDown": 0, "fPort": 85 }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "applicationId": { "type": "string" }, "devEui": { "type": "string" }, "id": { "type": "string" }, "confirmed": { "type": "boolean" }, "fPort": { "type": "number" }, "data": { "type": "string" }, "isPending": { "type": "boolean" }, "fCntDown": { "type": "number" } }, "required": [ "applicationId", "devEui", "id", "confirmed", "fPort", "data", "isPending", "fCntDown" ] }, "description": "Data of the device queue." } }, "required": [ "data" ] }, "example": { "data": { "devEui": "24e124535b312345", "id": "e61d84ba-xxxx-xxxx-xxxx-776da69aaa13", "confirmed": false, "isPending": false, "fCntDown": 0, "fPort": 1 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Device Queue Items", "description": "Get device queue items", "operationId": "LNS_Device.GetDeviceQueueItems", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deviceId", "description": "The ID of device.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "countOnly", "description": "The countOnly of device.", "in": "query", "schema": { "type": "string", "enum": [ "true", "false" ], "default": "false" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "applicationId": { "type": "string" }, "devEui": { "type": "string" }, "id": { "type": "string" }, "confirmed": { "type": "boolean" }, "fPort": { "type": "number" }, "data": { "type": "string" }, "isPending": { "type": "boolean" }, "fCntDown": { "type": "number" } }, "required": [ "applicationId", "devEui", "id", "confirmed", "fPort", "data", "isPending", "fCntDown" ] }, "description": "Data of the device queue." } }, "required": [ "data" ] }, "example": { "data": { "id": "e61d84ba-xxxx-xxxx-xxxx-776da69aaa13", "devEui": "24e124535b312345", "confirmed": false, "isPending": false, "object": { "codec": "exampleCodec" }, "fCntDown": 0, "fPort": 85 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices/{deviceId}/nonces": { "delete": { "summary": "Flush Device Nonces", "description": "Flush device nonces", "operationId": "LNS_Device.FlushDeviceNonces", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices/{deviceId}/queues": { "delete": { "summary": "Flush Device queues", "description": "Flush device queues", "operationId": "LNS_Device.FlushDeviceQueues", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices/deviceId": { "get": { "summary": "Get Device", "description": "Get device", "operationId": "LNS_Device.GetDevice", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "devEui", "description": "The ID of device.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "applicationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "devEui": { "type": "string" }, "joinEui": { "type": "string" }, "deviceProfileId": { "type": "string" }, "isDisabled": { "type": "boolean" }, "skipFcntCheck": { "type": "boolean" }, "deviceStatus": { "type": "object", "properties": {}, "required": [] }, "lastSeenAt": { "type": "number" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "variablesMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "applicationId", "name", "description", "devEui", "joinEui", "deviceProfileId", "isDisabled", "skipFcntCheck", "deviceStatus", "lastSeenAt", "tagsMap", "variablesMap", "createdAt", "updatedAt" ], "description": "Data of the device." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "applicationId": "9e9a7f54-xxxx-xxxx-xxxx-a9d6f80c8ba6", "name": "IDT-Device", "description": "IDT-Device-Description", "devEui": "24e124535b312345", "joinEui": "24e124c0002abcde", "deviceProfileId": "f1b1f383-xxxx-xxxx-xxxx-b656250d225b", "isDisabled": false, "skipFcntCheck": false, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ], "variablesMap": [ { "key": "version", "value": "1.0.2" } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices/{deviceId}/keys": { "get": { "summary": "Get Device Keys", "description": "Get device keys", "operationId": "LNS_Device.GetDeviceKeys", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "appkey": { "type": "string" } }, "required": [ "appkey" ], "description": "Data of the device." } }, "required": [ "data" ] }, "example": { "data": { "appKey": "55724xxxxxxxxxx3" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Device Keys", "description": "Update device keys", "operationId": "LNS_Device.UpdateDeviceKeys", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "appKey": { "type": "string", "description": "The app key of device." }, "nwkKey": { "type": "string", "description": "The network key of device." } }, "required": [ "appKey" ] }, "example": { "devEui": "24e124535b318262", "appKey": "55724xxxxxxxxxx3" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "appkey": { "type": "string" }, "nwkKey": { "type": "string" } }, "required": [ "appkey", "nwkKey" ], "description": "Data of the device." } }, "required": [ "data" ] }, "example": { "data": { "appKey": "55724xxxxxxxxxx3" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/applications/{applicationId}/devices/all": { "get": { "summary": "Get Devices", "description": "Get devices", "operationId": "LNS_Device.GetDevices", "tags": [ "LNS Device" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "applicationId", "description": "The ID of application.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "devEui", "description": "The ID of device.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "offset", "description": "The offset of device.", "in": "query", "schema": { "type": "number", "minimum": 0, "default": 0 }, "required": false }, { "name": "limit", "description": "The limit of device.", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 100, "default": 20 }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "devEui": { "type": "string" }, "lastSeenAt": { "type": "number" }, "activateStatus": { "type": "boolean" } }, "required": [ "devEui", "lastSeenAt", "activateStatus" ] }, "description": "Data of the device." }, "totalCount": { "type": "number", "description": "Total count of device." } }, "required": [ "data", "totalCount" ] }, "example": { "data": [ { "devEui": "24e124535b318260", "lastSeenAt": null, "activateStatus": false } ], "totalCount": 1 }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/device-profiles": { "post": { "summary": "Create Device Profile", "description": "Create device profile", "operationId": "LNS_Device_Profile.CreateDeviceProfile", "tags": [ "LNS Device Profile" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of device profile." }, "description": { "type": "string", "description": "The description of device profile." }, "region": { "type": "number", "description": "The region of device profile." }, "macVersion": { "type": "number", "description": "The mac version of device profile." }, "regionConfigId": { "type": "string", "description": "The region config ID of device profile." }, "regParamsRevision": { "type": "number", "description": "The reg params revision of device profile." }, "adrAlgorithmId": { "type": "string", "description": "The ADR algorithm ID of device profile." }, "flushQueueOnActivate": { "type": "boolean", "description": "The flush queue on activate of device profile." }, "uplinkInterval": { "type": "number", "description": "The uplink interval of device profile." }, "deviceStatusReqInterval": { "type": "number", "description": "The device status request interval of device profile." }, "supportsOtaa": { "type": "boolean", "description": "The supports OTAA of device profile." }, "abpRx1Delay": { "type": "number", "description": "The ABP Rx1 delay of device profile." }, "abpRx1DrOffset": { "type": "number", "description": "The ABP Rx1 DR offset of device profile." }, "abpRx2Dr": { "type": "number", "description": "The ABP Rx2 DR of device profile." }, "abpRx2Freq": { "type": "number", "description": "The ABP Rx2 frequency of device profile." }, "supportsClassB": { "type": "boolean", "description": "The supports Class B of device profile." }, "classBTimeout": { "type": "number", "description": "The Class B timeout of device profile." }, "classBPingSlotNbK": { "type": "number", "description": "The Class B ping slot number of device profile." }, "classBPingSlotDr": { "type": "number", "description": "The Class B ping slot DR of device profile." }, "classBPingSlotFreq": { "type": "number", "description": "The Class B ping slot frequency of device profile." }, "supportsClassC": { "type": "boolean", "description": "The supports Class C of device profile." }, "classCTimeout": { "type": "number", "description": "The Class C timeout of device profile." }, "isRelay": { "type": "boolean", "description": "The is relay of device profile." }, "relayEnabled": { "type": "boolean", "description": "The relay enabled of device profile." }, "relayDefaultChannelIndex": { "type": "number", "description": "The relay default channel index of device profile." }, "relaySecondChannelFreq": { "type": "number", "description": "The relay second channel frequency of device profile." }, "relaySecondChannelDr": { "type": "number", "description": "The relay second channel DR of device profile." }, "relaySecondChannelAckOffset": { "type": "number", "description": "The relay second channel ack offset of device profile." }, "relayCadPeriodicity": { "type": "number", "description": "The relay cad periodicity of device profile." }, "relayJoinReqLimitBucketSize": { "type": "number", "description": "The relay join request limit bucket size of device profile." }, "relayJoinReqLimitReloadRate": { "type": "number", "description": "The relay join request limit reload rate of device profile." }, "relayNotifyLimitBucketSize": { "type": "number", "description": "The relay notify limit bucket size of device profile." }, "relayNotifyLimitReloadRate": { "type": "number", "description": "The relay notify limit reload rate of device profile." }, "relayGlobalUplinkLimitBucketSize": { "type": "number", "description": "The relay overall limit bucket size of device profile." }, "relayGlobalUplinkLimitReloadRate": { "type": "number", "description": "The relay overall limit reload rate of device profile." }, "relayOverallLimitBucketSize": { "type": "number", "description": "The relay overall limit bucket size of device profile." }, "relayOverallLimitReloadRate": { "type": "number", "description": "The relay overall limit reload rate of device profile." }, "isRelayEd": { "type": "boolean", "description": "The is relay ED of device profile." }, "relayEdRelayOnly": { "type": "boolean", "description": "The relay ED relay only of device profile." }, "relayEdActivationMode": { "type": "number", "description": "The relay ED activation mode of device profile." }, "relayEdSmartEnableLevel": { "type": "number", "description": "The relay ED smart enable level of device profile." }, "relayEdBackOff": { "type": "number", "description": "The relay ED back off of device profile." }, "relayEdUplinkLimitBucketSize": { "type": "number", "description": "The relay ED uplink limit bucket size of device profile." }, "relayEdUplinkLimitReloadRate": { "type": "number", "description": "The relay ED uplink limit reload rate of device profile." } }, "required": [ "name", "region", "macVersion", "regParamsRevision", "adrAlgorithmId", "uplinkInterval" ] }, "example": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "ff7684e4-xxxx-xxxx-xxxx-6f42763591d1", "name": "AS923-ClassC", "description": "", "region": 7, "macVersion": 3, "regionConfigId": "as923", "regParamsRevision": 0, "adrAlgorithmId": "default", "flushQueueOnActivate": true, "uplinkInterval": 3600, "deviceStatusReqInterval": 30, "supportsOtaa": true, "abpRx1Delay": 0, "abpRx1DrOffset": 0, "abpRx2Dr": 0, "abpRx2Freq": 0, "supportsClassB": false, "classBTimeout": 0, "classBPingSlotNbK": 0, "classBPingSlotDr": 0, "classBPingSlotFreq": 0, "supportsClassC": true, "classCTimeout": 0, "isRelay": false, "relayEnabled": false, "relayDefaultChannelIndex": 0, "relaySecondChannelFreq": 0, "relaySecondChannelDr": 0, "relaySecondChannelAckOffset": 0, "relayCadPeriodicity": 0, "relayJoinReqLimitBucketSize": 0, "relayJoinReqLimitReloadRate": 0, "relayNotifyLimitBucketSize": 0, "relayNotifyLimitReloadRate": 0, "relayGlobalUplinkLimitBucketSize": 0, "relayGlobalUplinkLimitReloadRate": 0, "relayOverallLimitBucketSize": 0, "relayOverallLimitReloadRate": 0, "isRelayEd": false, "relayEdRelayOnly": false, "relayEdActivationMode": 0, "relayEdSmartEnableLevel": 0, "relayEdBackOff": 0, "relayEdUplinkLimitBucketSize": 0, "relayEdUplinkLimitReloadRate": 0, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "tenantId": { "type": "string" }, "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "region": { "type": "number" }, "regionConfigId": { "type": "string" }, "macVersion": { "type": "number" }, "regParamsRevision": { "type": "number" }, "adrAlgorithmId": { "type": "string" }, "flushQueueOnActivate": { "type": "boolean" }, "uplinkInterval": { "type": "boolean" }, "deviceStatusReqInterval": { "type": "number" }, "supportsOtaa": { "type": "boolean" }, "abpRx1Delay": { "type": "number" }, "abpRx1DrOffset": { "type": "number" }, "abpRx2Dr": { "type": "number" }, "abpRx2Freq": { "type": "number" }, "supportsClassB": { "type": "boolean" }, "classBTimeout": { "type": "number" }, "classBPingSlotNbK": { "type": "number" }, "classBPingSlotDr": { "type": "number" }, "classBPingSlotFreq": { "type": "number" }, "supportsClassC": { "type": "boolean" }, "classCTimeout": { "type": "number" }, "isRelay": { "type": "boolean" }, "relayEnabled": { "type": "boolean" }, "relayDefaultChannelIndex": { "type": "number" }, "relaySecondChannelFreq": { "type": "number" }, "relaySecondChannelDr": { "type": "number" }, "relaySecondChannelAckOffset": { "type": "number" }, "relayCadPeriodicity": { "type": "number" }, "relayJoinReqLimitBucketSize": { "type": "number" }, "relayJoinReqLimitReloadRate": { "type": "number" }, "relayNotifyLimitBucketSize": { "type": "number" }, "relayNotifyLimitReloadRate": { "type": "number" }, "relayGlobalUplinkLimitBucketSize": { "type": "number" }, "relayGlobalUplinkLimitReloadRate": { "type": "number" }, "relayOverallLimitBucketSize": { "type": "number" }, "relayOverallLimitReloadRate": { "type": "number" }, "isRelayEd": { "type": "boolean" }, "relayEdRelayOnly": { "type": "boolean" }, "relayEdActivationMode": { "type": "number" }, "relayEdSmartEnableLevel": { "type": "number" }, "relayEdBackOff": { "type": "number" }, "relayEdUplinkLimitBucketSize": { "type": "number" }, "relayEdUplinkLimitReloadRate": { "type": "number" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "tenantId", "id", "name", "description", "region", "regionConfigId", "macVersion", "regParamsRevision", "adrAlgorithmId", "flushQueueOnActivate", "uplinkInterval", "deviceStatusReqInterval", "supportsOtaa", "abpRx1Delay", "abpRx1DrOffset", "abpRx2Dr", "abpRx2Freq", "supportsClassB", "classBTimeout", "classBPingSlotNbK", "classBPingSlotDr", "classBPingSlotFreq", "supportsClassC", "classCTimeout", "isRelay", "relayEnabled", "relayDefaultChannelIndex", "relaySecondChannelFreq", "relaySecondChannelDr", "relaySecondChannelAckOffset", "relayCadPeriodicity", "relayJoinReqLimitBucketSize", "relayJoinReqLimitReloadRate", "relayNotifyLimitBucketSize", "relayNotifyLimitReloadRate", "relayGlobalUplinkLimitBucketSize", "relayGlobalUplinkLimitReloadRate", "relayOverallLimitBucketSize", "relayOverallLimitReloadRate", "isRelayEd", "relayEdRelayOnly", "relayEdActivationMode", "relayEdSmartEnableLevel", "relayEdBackOff", "relayEdUplinkLimitBucketSize", "relayEdUplinkLimitReloadRate", "tagsMap" ] }, "description": "Data of the device profile." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "ff7684e4-xxxx-xxxx-xxxx-6f42763591d1", "name": "AS923-ClassC", "description": "", "region": 7, "macVersion": 3, "regionConfigId": "as923", "regParamsRevision": 0, "adrAlgorithmId": "default", "flushQueueOnActivate": true, "uplinkInterval": 3600, "deviceStatusReqInterval": 30, "supportsOtaa": true, "abpRx1Delay": 0, "abpRx1DrOffset": 0, "abpRx2Dr": 0, "abpRx2Freq": 0, "supportsClassB": false, "classBTimeout": 0, "classBPingSlotNbK": 0, "classBPingSlotDr": 0, "classBPingSlotFreq": 0, "supportsClassC": true, "classCTimeout": 0, "isRelay": false, "relayEnabled": false, "relayDefaultChannelIndex": 0, "relaySecondChannelFreq": 0, "relaySecondChannelDr": 0, "relaySecondChannelAckOffset": 0, "relayCadPeriodicity": 0, "relayJoinReqLimitBucketSize": 0, "relayJoinReqLimitReloadRate": 0, "relayNotifyLimitBucketSize": 0, "relayNotifyLimitReloadRate": 0, "relayGlobalUplinkLimitBucketSize": 0, "relayGlobalUplinkLimitReloadRate": 0, "relayOverallLimitBucketSize": 0, "relayOverallLimitReloadRate": 0, "isRelayEd": false, "relayEdRelayOnly": false, "relayEdActivationMode": 0, "relayEdSmartEnableLevel": 0, "relayEdBackOff": 0, "relayEdUplinkLimitBucketSize": 0, "relayEdUplinkLimitReloadRate": 0, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Device Profiles", "description": "List device profiles", "operationId": "LNS_Device_Profile.ListDeviceProfiles", "tags": [ "LNS Device Profile" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "offset", "description": "The offset of device profile.", "in": "query", "schema": { "type": "number", "minimum": 0, "default": 0 }, "required": false }, { "name": "limit", "description": "The limit of device profile.", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 100, "default": 20 }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "region": { "type": "number" }, "macVersion": { "type": "number" }, "regParamsRevision": { "type": "number" }, "supportsOtaa": { "type": "boolean" }, "supportsClassB": { "type": "boolean" }, "supportsClassC": { "type": "boolean" }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "id", "name", "region", "macVersion", "regParamsRevision", "supportsOtaa", "supportsClassB", "supportsClassC", "createdAt", "updatedAt" ] }, "description": "Data of the device profile." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "04ec75ad-xxxx-xxxx-xxxx-919fb9e45a25", "name": "AS923-ClassB", "region": 7, "macVersion": 3, "regParamsRevision": 0, "supportsOtaa": true, "supportsClassB": false, "supportsClassC": false, "createdAt": 1702868770, "updatedAt": 1702868770 } ], "totalCount": 1 }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/device-profiles/{deviceProfileId}": { "delete": { "summary": "Delete Device Profile", "description": "Delete device profile", "operationId": "LNS_Device_Profile.DeleteDeviceProfile", "tags": [ "LNS Device Profile" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deviceProfileId", "description": "The ID of device profile.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Device Profile", "description": "Get device profile", "operationId": "LNS_Device_Profile.GetDeviceProfile", "tags": [ "LNS Device Profile" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deviceProfileId", "description": "The ID of device profile.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "tenantId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "region": { "type": "number" }, "regionConfigId": { "type": "string" }, "macVersion": { "type": "number" }, "regParamsRevision": { "type": "number" }, "adrAlgorithmId": { "type": "string" }, "flushQueueOnActivate": { "type": "boolean" }, "uplinkInterval": { "type": "boolean" }, "deviceStatusReqInterval": { "type": "number" }, "supportsOtaa": { "type": "boolean" }, "abpRx1Delay": { "type": "number" }, "abpRx1DrOffset": { "type": "number" }, "abpRx2Dr": { "type": "number" }, "abpRx2Freq": { "type": "number" }, "supportsClassB": { "type": "boolean" }, "classBTimeout": { "type": "number" }, "classBPingSlotNbK": { "type": "number" }, "classBPingSlotDr": { "type": "number" }, "classBPingSlotFreq": { "type": "number" }, "supportsClassC": { "type": "boolean" }, "classCTimeout": { "type": "number" }, "isRelay": { "type": "boolean" }, "relayEnabled": { "type": "boolean" }, "relayDefaultChannelIndex": { "type": "number" }, "relaySecondChannelFreq": { "type": "number" }, "relaySecondChannelDr": { "type": "number" }, "relaySecondChannelAckOffset": { "type": "number" }, "relayCadPeriodicity": { "type": "number" }, "relayJoinReqLimitBucketSize": { "type": "number" }, "relayJoinReqLimitReloadRate": { "type": "number" }, "relayNotifyLimitBucketSize": { "type": "number" }, "relayNotifyLimitReloadRate": { "type": "number" }, "relayGlobalUplinkLimitBucketSize": { "type": "number" }, "relayGlobalUplinkLimitReloadRate": { "type": "number" }, "relayOverallLimitBucketSize": { "type": "number" }, "relayOverallLimitReloadRate": { "type": "number" }, "isRelayEd": { "type": "boolean" }, "relayEdRelayOnly": { "type": "boolean" }, "relayEdActivationMode": { "type": "number" }, "relayEdSmartEnableLevel": { "type": "number" }, "relayEdBackOff": { "type": "number" }, "relayEdUplinkLimitBucketSize": { "type": "number" }, "relayEdUplinkLimitReloadRate": { "type": "number" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "id", "tenantId", "name", "description", "region", "regionConfigId", "macVersion", "regParamsRevision", "adrAlgorithmId", "flushQueueOnActivate", "uplinkInterval", "deviceStatusReqInterval", "supportsOtaa", "abpRx1Delay", "abpRx1DrOffset", "abpRx2Dr", "abpRx2Freq", "supportsClassB", "classBTimeout", "classBPingSlotNbK", "classBPingSlotDr", "classBPingSlotFreq", "supportsClassC", "classCTimeout", "isRelay", "relayEnabled", "relayDefaultChannelIndex", "relaySecondChannelFreq", "relaySecondChannelDr", "relaySecondChannelAckOffset", "relayCadPeriodicity", "relayJoinReqLimitBucketSize", "relayJoinReqLimitReloadRate", "relayNotifyLimitBucketSize", "relayNotifyLimitReloadRate", "relayGlobalUplinkLimitBucketSize", "relayGlobalUplinkLimitReloadRate", "relayOverallLimitBucketSize", "relayOverallLimitReloadRate", "isRelayEd", "relayEdRelayOnly", "relayEdActivationMode", "relayEdSmartEnableLevel", "relayEdBackOff", "relayEdUplinkLimitBucketSize", "relayEdUplinkLimitReloadRate", "tagsMap", "createdAt", "updatedAt" ] }, "description": "Data of the device profile." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "ff7684e4-xxxx-xxxx-xxxx-6f42763591d1", "name": "AS923-ClassC", "description": "", "region": 7, "macVersion": 3, "regionConfigId": "as923", "regParamsRevision": 0, "adrAlgorithmId": "default", "flushQueueOnActivate": true, "uplinkInterval": 3600, "deviceStatusReqInterval": 30, "supportsOtaa": true, "abpRx1Delay": 0, "abpRx1DrOffset": 0, "abpRx2Dr": 0, "abpRx2Freq": 0, "supportsClassB": false, "classBTimeout": 0, "classBPingSlotNbK": 0, "classBPingSlotDr": 0, "classBPingSlotFreq": 0, "supportsClassC": true, "classCTimeout": 0, "isRelay": false, "relayEnabled": false, "relayDefaultChannelIndex": 0, "relaySecondChannelFreq": 0, "relaySecondChannelDr": 0, "relaySecondChannelAckOffset": 0, "relayCadPeriodicity": 0, "relayJoinReqLimitBucketSize": 0, "relayJoinReqLimitReloadRate": 0, "relayNotifyLimitBucketSize": 0, "relayNotifyLimitReloadRate": 0, "relayGlobalUplinkLimitBucketSize": 0, "relayGlobalUplinkLimitReloadRate": 0, "relayOverallLimitBucketSize": 0, "relayOverallLimitReloadRate": 0, "isRelayEd": false, "relayEdRelayOnly": false, "relayEdActivationMode": 0, "relayEdSmartEnableLevel": 0, "relayEdBackOff": 0, "relayEdUplinkLimitBucketSize": 0, "relayEdUplinkLimitReloadRate": 0, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Device Profile", "description": "Update device profile", "operationId": "LNS_Device_Profile.UpdateDeviceProfile", "tags": [ "LNS Device Profile" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "deviceProfileId", "description": "The ID of device profile.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of device profile." }, "description": { "type": "string", "description": "The description of device profile." }, "region": { "type": "number", "description": "The region of device profile." }, "macVersion": { "type": "number", "description": "The mac version of device profile." }, "regionConfigId": { "type": "string", "description": "The region config ID of device profile." }, "regParamsRevision": { "type": "number", "description": "The reg params revision of device profile." }, "adrAlgorithmId": { "type": "string", "description": "The ADR algorithm ID of device profile." }, "flushQueueOnActivate": { "type": "boolean", "description": "The flush queue on activate of device profile." }, "uplinkInterval": { "type": "number", "description": "The uplink interval of device profile." }, "deviceStatusReqInterval": { "type": "number", "description": "The device status request interval of device profile." }, "supportsOtaa": { "type": "boolean", "description": "The supports OTAA of device profile." }, "abpRx1Delay": { "type": "number", "description": "The ABP Rx1 delay of device profile." }, "abpRx1DrOffset": { "type": "number", "description": "The ABP Rx1 DR offset of device profile." }, "abpRx2Dr": { "type": "number", "description": "The ABP Rx2 DR of device profile." }, "abpRx2Freq": { "type": "number", "description": "The ABP Rx2 frequency of device profile." }, "supportsClassB": { "type": "boolean", "description": "The supports Class B of device profile." }, "classBTimeout": { "type": "number", "description": "The Class B timeout of device profile." }, "classBPingSlotNbK": { "type": "number", "description": "The Class B ping slot number of device profile." }, "classBPingSlotDr": { "type": "number", "description": "The Class B ping slot DR of device profile." }, "classBPingSlotFreq": { "type": "number", "description": "The Class B ping slot frequency of device profile." }, "supportsClassC": { "type": "boolean", "description": "The supports Class C of device profile." }, "classCTimeout": { "type": "number", "description": "The Class C timeout of device profile." }, "isRelay": { "type": "boolean", "description": "The is relay of device profile." }, "relayEnabled": { "type": "boolean", "description": "The relay enabled of device profile." }, "relayDefaultChannelIndex": { "type": "number", "description": "The relay default channel index of device profile." }, "relaySecondChannelFreq": { "type": "number", "description": "The relay second channel frequency of device profile." }, "relaySecondChannelDr": { "type": "number", "description": "The relay second channel DR of device profile." }, "relaySecondChannelAckOffset": { "type": "number", "description": "The relay second channel ack offset of device profile." }, "relayCadPeriodicity": { "type": "number", "description": "The relay cad periodicity of device profile." }, "relayJoinReqLimitBucketSize": { "type": "number", "description": "The relay join request limit bucket size of device profile." }, "relayJoinReqLimitReloadRate": { "type": "number", "description": "The relay join request limit reload rate of device profile." }, "relayNotifyLimitBucketSize": { "type": "number", "description": "The relay notify limit bucket size of device profile." }, "relayNotifyLimitReloadRate": { "type": "number", "description": "The relay notify limit reload rate of device profile." }, "relayGlobalUplinkLimitBucketSize": { "type": "number", "description": "The relay overall limit bucket size of device profile." }, "relayGlobalUplinkLimitReloadRate": { "type": "number", "description": "The relay overall limit reload rate of device profile." }, "relayOverallLimitBucketSize": { "type": "number", "description": "The relay overall limit bucket size of device profile." }, "relayOverallLimitReloadRate": { "type": "number", "description": "The relay overall limit reload rate of device profile." }, "isRelayEd": { "type": "boolean", "description": "The is relay ED of device profile." }, "relayEdRelayOnly": { "type": "boolean", "description": "The relay ED relay only of device profile." }, "relayEdActivationMode": { "type": "number", "description": "The relay ED activation mode of device profile." }, "relayEdSmartEnableLevel": { "type": "number", "description": "The relay ED smart enable level of device profile." }, "relayEdBackOff": { "type": "number", "description": "The relay ED back off of device profile." }, "relayEdUplinkLimitBucketSize": { "type": "number", "description": "The relay ED uplink limit bucket size of device profile." }, "relayEdUplinkLimitReloadRate": { "type": "number", "description": "The relay ED uplink limit reload rate of device profile." } }, "required": [ "name", "region", "macVersion", "regParamsRevision", "adrAlgorithmId", "uplinkInterval" ] }, "example": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "ff7684e4-xxxx-xxxx-xxxx-6f42763591d1", "name": "AS923-ClassC", "description": "", "region": 7, "macVersion": 3, "regionConfigId": "as923", "regParamsRevision": 0, "adrAlgorithmId": "default", "flushQueueOnActivate": true, "uplinkInterval": 3600, "deviceStatusReqInterval": 30, "supportsOtaa": true, "abpRx1Delay": 0, "abpRx1DrOffset": 0, "abpRx2Dr": 0, "abpRx2Freq": 0, "supportsClassB": false, "classBTimeout": 0, "classBPingSlotNbK": 0, "classBPingSlotDr": 0, "classBPingSlotFreq": 0, "supportsClassC": true, "classCTimeout": 0, "isRelay": false, "relayEnabled": false, "relayDefaultChannelIndex": 0, "relaySecondChannelFreq": 0, "relaySecondChannelDr": 0, "relaySecondChannelAckOffset": 0, "relayCadPeriodicity": 0, "relayJoinReqLimitBucketSize": 0, "relayJoinReqLimitReloadRate": 0, "relayNotifyLimitBucketSize": 0, "relayNotifyLimitReloadRate": 0, "relayGlobalUplinkLimitBucketSize": 0, "relayGlobalUplinkLimitReloadRate": 0, "relayOverallLimitBucketSize": 0, "relayOverallLimitReloadRate": 0, "isRelayEd": false, "relayEdRelayOnly": false, "relayEdActivationMode": 0, "relayEdSmartEnableLevel": 0, "relayEdBackOff": 0, "relayEdUplinkLimitBucketSize": 0, "relayEdUplinkLimitReloadRate": 0, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "tenantId": { "type": "string" }, "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "region": { "type": "number" }, "regionConfigId": { "type": "string" }, "macVersion": { "type": "number" }, "regParamsRevision": { "type": "number" }, "adrAlgorithmId": { "type": "string" }, "flushQueueOnActivate": { "type": "boolean" }, "uplinkInterval": { "type": "boolean" }, "deviceStatusReqInterval": { "type": "number" }, "supportsOtaa": { "type": "boolean" }, "abpRx1Delay": { "type": "number" }, "abpRx1DrOffset": { "type": "number" }, "abpRx2Dr": { "type": "number" }, "abpRx2Freq": { "type": "number" }, "supportsClassB": { "type": "boolean" }, "classBTimeout": { "type": "number" }, "classBPingSlotNbK": { "type": "number" }, "classBPingSlotDr": { "type": "number" }, "classBPingSlotFreq": { "type": "number" }, "supportsClassC": { "type": "boolean" }, "classCTimeout": { "type": "number" }, "isRelay": { "type": "boolean" }, "relayEnabled": { "type": "boolean" }, "relayDefaultChannelIndex": { "type": "number" }, "relaySecondChannelFreq": { "type": "number" }, "relaySecondChannelDr": { "type": "number" }, "relaySecondChannelAckOffset": { "type": "number" }, "relayCadPeriodicity": { "type": "number" }, "relayJoinReqLimitBucketSize": { "type": "number" }, "relayJoinReqLimitReloadRate": { "type": "number" }, "relayNotifyLimitBucketSize": { "type": "number" }, "relayNotifyLimitReloadRate": { "type": "number" }, "relayGlobalUplinkLimitBucketSize": { "type": "number" }, "relayGlobalUplinkLimitReloadRate": { "type": "number" }, "relayOverallLimitBucketSize": { "type": "number" }, "relayOverallLimitReloadRate": { "type": "number" }, "isRelayEd": { "type": "boolean" }, "relayEdRelayOnly": { "type": "boolean" }, "relayEdActivationMode": { "type": "number" }, "relayEdSmartEnableLevel": { "type": "number" }, "relayEdBackOff": { "type": "number" }, "relayEdUplinkLimitBucketSize": { "type": "number" }, "relayEdUplinkLimitReloadRate": { "type": "number" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "tenantId", "id", "name", "description", "region", "regionConfigId", "macVersion", "regParamsRevision", "adrAlgorithmId", "flushQueueOnActivate", "uplinkInterval", "deviceStatusReqInterval", "supportsOtaa", "abpRx1Delay", "abpRx1DrOffset", "abpRx2Dr", "abpRx2Freq", "supportsClassB", "classBTimeout", "classBPingSlotNbK", "classBPingSlotDr", "classBPingSlotFreq", "supportsClassC", "classCTimeout", "isRelay", "relayEnabled", "relayDefaultChannelIndex", "relaySecondChannelFreq", "relaySecondChannelDr", "relaySecondChannelAckOffset", "relayCadPeriodicity", "relayJoinReqLimitBucketSize", "relayJoinReqLimitReloadRate", "relayNotifyLimitBucketSize", "relayNotifyLimitReloadRate", "relayGlobalUplinkLimitBucketSize", "relayGlobalUplinkLimitReloadRate", "relayOverallLimitBucketSize", "relayOverallLimitReloadRate", "isRelayEd", "relayEdRelayOnly", "relayEdActivationMode", "relayEdSmartEnableLevel", "relayEdBackOff", "relayEdUplinkLimitBucketSize", "relayEdUplinkLimitReloadRate", "tagsMap" ] }, "description": "Data of the device profile." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "id": "ff7684e4-xxxx-xxxx-xxxx-6f42763591d1", "name": "AS923-ClassC", "description": "", "region": 7, "macVersion": 3, "regionConfigId": "as923", "regParamsRevision": 0, "adrAlgorithmId": "default", "flushQueueOnActivate": true, "uplinkInterval": 3600, "deviceStatusReqInterval": 30, "supportsOtaa": true, "abpRx1Delay": 0, "abpRx1DrOffset": 0, "abpRx2Dr": 0, "abpRx2Freq": 0, "supportsClassB": false, "classBTimeout": 0, "classBPingSlotNbK": 0, "classBPingSlotDr": 0, "classBPingSlotFreq": 0, "supportsClassC": true, "classCTimeout": 0, "isRelay": false, "relayEnabled": false, "relayDefaultChannelIndex": 0, "relaySecondChannelFreq": 0, "relaySecondChannelDr": 0, "relaySecondChannelAckOffset": 0, "relayCadPeriodicity": 0, "relayJoinReqLimitBucketSize": 0, "relayJoinReqLimitReloadRate": 0, "relayNotifyLimitBucketSize": 0, "relayNotifyLimitReloadRate": 0, "relayGlobalUplinkLimitBucketSize": 0, "relayGlobalUplinkLimitReloadRate": 0, "relayOverallLimitBucketSize": 0, "relayOverallLimitReloadRate": 0, "isRelayEd": false, "relayEdRelayOnly": false, "relayEdActivationMode": 0, "relayEdSmartEnableLevel": 0, "relayEdBackOff": 0, "relayEdUplinkLimitBucketSize": 0, "relayEdUplinkLimitReloadRate": 0, "tagsMap": [ { "key": "Rooftop", "value": "Weather monitoring" } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/gateways": { "post": { "summary": "Create Gateway", "description": "Create gateway", "operationId": "LNS_Gateway.CreateGateway", "tags": [ "LNS Gateway" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "gatewayId": { "type": "string", "description": "The ID of gateway." }, "name": { "type": "string", "description": "The name of gateway." }, "description": { "type": "string", "description": "The description of gateway." }, "statsInterval": { "type": "number", "description": "The stats interval of gateway." }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The tagsMsp of gateway." } }, "required": [ "gatewayId", "name", "statsInterval" ] }, "example": { "gatewayId": "24e124fffef23456", "name": "24E124FFFEF23456", "description": "IDT-Gateway-Description", "statsInterval": 30, "tagsMap": [] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "tenantId": { "type": "string" }, "gatewayId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "statsInterval": { "type": "number" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "tenantId", "gatewayId", "name", "description", "statsInterval", "tagsMap" ], "description": "Data of the gateway." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "gatewayId": "24e124fffef23456", "name": "24E124FFFEF23456", "description": "IDT-Gateway-Description", "statsInterval": 30, "tagsMap": [] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Gateways", "description": "List gateways", "operationId": "LNS_Gateway.ListGateways", "tags": [ "LNS Gateway" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "offset", "description": "The offset of gateway.", "in": "query", "schema": { "type": "number", "minimum": 0, "default": 0 }, "required": false }, { "name": "limit", "description": "The limit of gateway.", "in": "query", "schema": { "type": "number", "minimum": 1, "maximum": 100, "default": 20 }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "tenantId": { "type": "string" }, "gatewayId": { "type": "string" }, "name": { "type": "string" }, "state": { "type": "object", "properties": {}, "required": [] }, "propertiesMap": { "type": "object", "properties": {}, "required": [] }, "lastSeenAt": { "type": "number" }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "tenantId", "gatewayId", "name", "state", "propertiesMap", "lastSeenAt", "createdAt", "updatedAt" ] }, "description": "Data of the gateway." }, "totalCount": { "type": "number", "description": "The total count of gateway." } }, "required": [ "data", "totalCount" ] }, "example": { "data": [ { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "gatewayId": "24e124fffef23456", "name": "24E124FFFEF23456", "state": 2, "propertiesMap": { "region_common_name": "AS923", "region_config_id": "as923" }, "lastSeenAt": 1710838741, "createdAt": 1705578047, "updatedAt": 1705578047 } ], "totalCount": 1 }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/lns/tenants/{tenantId}/gateways/{gatewayId}": { "delete": { "summary": "Delete Gateway", "description": "Delete gateway", "operationId": "LNS_Gateway.DeleteGateway", "tags": [ "LNS Gateway" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "gatewayId", "description": "The ID of gateway.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Empty object" } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Gateway", "description": "Get gateway", "operationId": "LNS_Gateway.GetGateway", "tags": [ "LNS Gateway" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "gatewayId", "description": "The ID of gateway.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "tenantId": { "type": "string" }, "gatewayId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "statsInterval": { "type": "number" }, "lastSeenAt": { "type": "number" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" } }, "required": [ "tenantId", "gatewayId", "name", "description", "statsInterval", "lastSeenAt", "tagsMap", "createdAt", "updatedAt" ], "description": "Data of the gateway." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "gatewayId": "24e124fffef23456", "name": "24E124FFFEF23456", "description": "IDT-Gateway-Description", "statsInterval": 30, "tagsMap": [] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Gateway", "description": "Update gateway", "operationId": "LNS_Gateway.UpdateGateway", "tags": [ "LNS Gateway" ], "parameters": [ { "name": "tenantId", "description": "The ID of tenant.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "gatewayId", "description": "The ID of gateway.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of gateway." }, "description": { "type": "string", "description": "The description of gateway." }, "statsInterval": { "type": "number", "description": "The stats interval of gateway." }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The tagsMsp of gateway." } }, "required": [ "name", "statsInterval" ] }, "example": { "name": "24E124FFFEF23456", "description": "IDT-Gateway-Description", "statsInterval": 30, "tagsMap": [] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "tenantId": { "type": "string" }, "gatewayId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "statsInterval": { "type": "number" }, "tagsMap": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } } }, "required": [ "tenantId", "gatewayId", "name", "description", "statsInterval", "tagsMap" ], "description": "Data of the gateway." } }, "required": [ "data" ] }, "example": { "data": { "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "gatewayId": "24e124fffef23456", "name": "24E124FFFEF23456", "description": "IDT-Gateway-Description", "statsInterval": 30, "tagsMap": [] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/locations": { "post": { "summary": "Create Location", "description": "Create location", "operationId": "Location.CreateLocation", "tags": [ "Location" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "parentId": { "type": "string", "description": "The parent location ID" }, "name": { "type": "string", "description": "The name of location" }, "description": { "type": "string", "description": "The description of location" }, "address": { "type": "string", "description": "The address of location" }, "chatRoomId": { "type": "string", "description": "The ID of chat room" }, "entities": { "type": "array", "items": { "type": "string" }, "description": "The entities of location" }, "image": { "type": "string", "description": "The image of location" } }, "required": [ "name" ] }, "example": { "parentId": "l-locationId", "name": "IDT-Location", "description": "IDT-Location-Description", "address": "Taipei City", "chatRoomId": "ABCDE", "entities": [], "image": "abc.png" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "address": { "type": "string" }, "chatRoomId": { "type": "string" }, "entities": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "image": { "type": "string" } }, "required": [ "id", "organizationId", "name", "description", "address", "chatRoomId", "entities", "image" ], "description": "Data of the created location." } }, "required": [ "data" ] }, "example": { "data": { "id": "l-locationId", "organizationId": "o-organizationId", "name": "IDT-Location", "description": "IDT-Location-Description", "address": "Taipei City", "chatRoomId": "ABCDE", "entities": [], "image": "abc.png" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Locations", "description": "List locations", "operationId": "Location.ListLocations", "tags": [ "Location" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "parentId", "description": "The parent location ID", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "address": { "type": "string" }, "chatRoomId": { "type": "string" }, "entities": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "image": { "type": "string" } }, "required": [ "id", "organizationId", "name", "description", "address", "chatRoomId", "entities", "image" ] }, "description": "An array of assets within the specified location." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "l-locationId", "organizationId": "o-organizationId", "name": "IDT-Location", "description": "IDT-Location-Description", "address": "Taipei City", "chatRoomId": "ABCDE", "entities": [], "image": "abc.png" } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/locations/{locationId}": { "delete": { "summary": "Delete Location", "description": "Delete location", "operationId": "Location.DeleteLocation", "tags": [ "Location" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "locationId", "description": "The ID of location", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the location." } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Location", "description": "Get location", "operationId": "Location.GetLocation", "tags": [ "Location" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "locationId", "description": "The ID of location", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "address": { "type": "string" }, "chatRoomId": { "type": "string" }, "entities": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "image": { "type": "string" } }, "required": [ "id", "organizationId", "name", "description", "address", "chatRoomId", "entities", "image" ], "description": "Data of the location retrieved." } }, "required": [ "data" ] }, "example": { "data": { "id": "l-locationId", "organizationId": "o-organizationId", "name": "IDT-Location", "description": "IDT-Location-Description", "address": "Taipei City", "chatRoomId": "ABCDE", "entities": [], "image": "abc.png" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Location", "description": "Update location", "operationId": "Location.UpdateLocation", "tags": [ "Location" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "locationId", "description": "The ID of location", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of location" }, "description": { "type": "string", "description": "The description of location" }, "address": { "type": "string", "description": "The address of location" }, "chatRoomId": { "type": "string", "description": "The ID of chat room" }, "entities": { "type": "array", "items": { "type": "string" }, "description": "The entities of location" }, "image": { "type": "string", "description": "The image of location" } }, "required": [ "name" ] }, "example": { "name": "IDT-Location", "description": "IDT-Location-Description", "address": "Taipei City", "chatRoomId": "ABCDE", "entities": [], "image": "abc.png" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "address": { "type": "string" }, "chatRoomId": { "type": "string" }, "entities": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "image": { "type": "string" } }, "required": [ "id", "organizationId", "name", "description", "address", "chatRoomId", "entities", "image" ], "description": "An array of assets within the specified location." } }, "required": [ "data" ] }, "example": { "data": { "id": "l-locationId", "organizationId": "o-organizationId", "name": "IDT-Location", "description": "IDT-Location-Description", "address": "Taipei City", "chatRoomId": "ABCDE", "entities": [], "image": "abc.png" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/notifications": { "post": { "summary": "Create User Device Endpoint", "description": "Create User Device Endpoint", "operationId": "Notification.CreateUserDeviceEndpoint", "tags": [ "Notification" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "endpoint": { "type": "string", "description": "The equivalent endpoint of phone or browser." }, "platform": { "type": "string", "description": "The notification platform(GCM, APNS, APNS_SANDBOX, BROWSER)." } }, "required": [ "endpoint", "platform" ] }, "example": {}, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Registration success." } }, "required": [ "data" ] }, "example": {}, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "delete": { "summary": "Delete User Device Endpoint", "description": "Delete User Device Endpoint", "operationId": "Notification.DeleteUserDeviceEndpoint", "tags": [ "Notification" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Cancel registration success." } }, "required": [ "data" ] }, "example": {}, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Notifications", "description": "List notifications", "operationId": "Notification.ListNotifications", "tags": [ "Notification" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The Id of asset.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "startDate", "description": "The start date number of query.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "endDate", "description": "The end date number of query.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "assetId": { "type": "string" }, "source": { "type": "string" }, "sourceId": { "type": "string" }, "title": { "type": "string" }, "description": { "type": "string" }, "address": { "type": "string" }, "chatRoomId": { "type": "string" }, "entities": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "image": { "type": "string" } }, "required": [ "id", "assetId", "source", "sourceId", "title", "description", "address", "chatRoomId", "entities", "image" ] }, "description": "An array of notifications data." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "ABCDE", "assetId": "a-assetId", "source": "Asset", "sourceId": "ABCDE", "title": "IDT-Asset-Title", "description": "IDT-Asset-Description", "address": "Taipei City", "chatRoomId": "ABCDE", "entities": [], "image": "abc.png" } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/teams/{teamId}/assets/{assetId}": { "put": { "summary": "Add Asset To Team", "description": "Add asset to team for organization", "operationId": "Organization.AddAssetToTeam", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The ID of team.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of asset.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the result." } }, "required": [ "data" ] }, "example": { "data": { "added": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "delete": { "summary": "Remove Asset From Team", "description": "Remove asset from team for organization", "operationId": "Organization.RemoveAssetFromTeam", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The ID of team.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "assetId", "description": "The ID of asset.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the result." } }, "required": [ "data" ] }, "example": { "data": { "removed": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/teams/{teamId}/users/{userId}": { "put": { "summary": "Add User To Team", "description": "Add user to team for organization", "operationId": "Organization.AddUserToTeam", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The ID of team.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the result." } }, "required": [ "data" ] }, "example": { "data": { "added": true } }, "description": "" } } }, "400": { "description": "The request has invalid data.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has invalid data." }, "message": { "type": "string", "description": "The request has invalid data message." } }, "required": [ "error", "message" ] }, "example": { "error": "Bad Request", "message": "The request cannot be processed due to a bad request." }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "delete": { "summary": "Remove User From Team", "description": "Remove user from team for organization", "operationId": "Organization.RemoveUserFromTeam", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The ID of team.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the result." } }, "required": [ "data" ] }, "example": { "data": { "removed": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/invitations/{code}": { "put": { "summary": "Cancel Invitation", "description": "Cancel invitation for organization", "operationId": "Organization.CancelInvitation", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "code", "description": "The code of invitation.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the invitaion." } }, "required": [ "data" ] }, "example": { "data": { "canceled": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Invitation", "description": "Get invitation for user", "operationId": "Organization.GetInvitation", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "code", "description": "The code of invitation.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "code": { "type": "string" }, "familyName": { "type": "string" }, "givenName": { "type": "string" }, "email": { "type": "string" }, "appRole": { "type": "string" }, "organizationId": { "type": "string" }, "origin": { "type": "string" }, "expiredTime": { "type": "number" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "code", "familyName", "givenName", "email", "appRole", "organizationId", "origin", "expiredTime", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the user who received the invitation." } }, "required": [ "data" ] }, "example": { "data": { "code": "l9CgQxxxxxxxxxx=", "familyName": "Ashton", "givenName": "Kevin", "email": "example@infodeck.io", "appRole": "RequesterAndViewer", "organizationId": "o-organizationId", "origin": "owner", "expiredTime": 86400, "createdAtDateString": "2021-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2021-02-01T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/invitations": { "post": { "summary": "Create Invitation", "description": "Create invitation for organization", "operationId": "Organization.CreateInvitation", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "email": { "type": "string", "description": "The email of user." }, "familyName": { "type": "string", "description": "The family name of user." }, "givenName": { "type": "string", "description": "The given name of user." }, "teamIds": { "type": "array", "items": { "type": "string" }, "description": "The team ids of user." } }, "required": [ "email", "familyName", "givenName", "teamIds" ] }, "example": { "familyName": "Ashton", "givenName": "Kevin", "email": "example@infodeck.io" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "code": { "type": "string" }, "familyName": { "type": "string" }, "givenName": { "type": "string" }, "email": { "type": "string" }, "appRole": { "type": "string" }, "organizationId": { "type": "string" }, "origin": { "type": "string" }, "expiredTime": { "type": "number" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "code", "familyName", "givenName", "email", "appRole", "organizationId", "origin", "expiredTime", "createdAtDateString", "createdAt" ], "description": "Data of the user who received the invitation." } }, "required": [ "data" ] }, "example": { "data": { "code": "l9CgQxxxxxxxxxx=", "familyName": "Ashton", "givenName": "Kevin", "email": "example@infodeck.io", "appRole": "RequesterAndViewer", "organizationId": "o-organizationId", "origin": "owner", "expiredTime": 86400, "createdAtDateString": "2021-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Invitations", "description": "List invitations for organization", "operationId": "Organization.ListInvitations", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "code": { "type": "string" }, "organizationId": { "type": "string" }, "appRole": { "type": "string" }, "origin": { "type": "string" }, "email": { "type": "string" }, "metadata": { "type": "object", "properties": {}, "required": [] }, "expiredAt": { "type": "string" }, "usedAt": { "type": "string" }, "canceledAt": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": {} }, "required": [ "code", "organizationId", "appRole", "origin", "email", "metadata", "expiredAt", "usedAt", "canceledAt", "createdAtDateString", "createdAt" ] }, "description": "Array of invitation data objects." } }, "required": [ "data" ] }, "example": { "data": [ { "code": "l9CgQxxxxxxxxxx==", "organizationId": "o-organizationId", "appRole": "RequesterAndViewer", "origin": "Owner", "email": "example@infodeck.io", "metadata": {}, "expiredAt": "2024-01-03T00:00:00.000Z", "usedAt": null, "canceledAt": null, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations": { "post": { "summary": "Create Organization", "description": "Create Organization", "operationId": "Organization.CreateOrganization", "tags": [ "Organization" ], "parameters": [], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "companyName": { "type": "string", "description": "The company name of organization." }, "companyAddress": { "type": "string", "description": "The company address of organization." }, "companyVat": { "type": "string", "description": "The company VAT of organization." }, "customUrl": { "type": "string", "description": "The URL of organization." }, "timezone": { "type": "string", "description": "The timezone of organization." }, "finance": { "type": "object", "properties": { "address": { "type": "object", "properties": { "city": { "type": "string" }, "country": { "type": "string" }, "line1": { "type": "string" }, "line2": { "type": "string" }, "postalCode": { "type": "string" }, "state": { "type": "string" } }, "required": [] } }, "required": [], "description": "Financial information of the organization." } }, "required": [ "companyName", "customUrl", "timezone" ] }, "example": { "companyName": "Infodeck", "companyVat": "VAT-XXXXX", "companyAddress": "Taipei City", "customUrl": "infodeck", "timezone": "Asia/Taipei", "finance": { "address": { "city": "Taipei", "country": "TW", "line1": "6F, No. 287, Section 3, Nanjing East Road", "line2": "Songshan District", "postalCode": "10595", "state": "Taipei City" } } }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "type": { "type": "string" }, "awsAccountId": { "type": "string" }, "awsRegion": { "type": "string" }, "ownerEmail": { "type": "string" }, "emailDomain": { "type": "string" }, "customerId": { "type": "string" }, "customUrl": { "type": "string" }, "companyName": { "type": "string" }, "companyVat": { "type": "string" }, "companyAddress": { "type": "string" }, "iotEndpoint": { "type": "string" }, "timezone": { "type": "string" }, "statistics": { "type": "object", "properties": { "assetType": { "type": "number" }, "deck": { "type": "number" }, "eventRule": { "type": "number" }, "eventSchedule": { "type": "number" }, "integrationService": { "type": "number" }, "location": { "type": "number" }, "team": { "type": "number" }, "thing": { "type": "number" }, "user": { "type": "number" }, "workOrder": { "type": "number" }, "workRequest": { "type": "number" } }, "required": [ "assetType", "deck", "eventRule", "eventSchedule", "integrationService", "location", "team", "thing", "user", "workOrder", "workRequest" ] }, "subscriptionPlan": { "type": "string" }, "subscriptionStatus": { "type": "string" }, "finance": { "type": "object", "properties": { "email": { "type": "string" }, "phoneNumber": { "type": "string" }, "address": { "type": "object", "properties": { "city": { "type": "string" }, "country": { "type": "string" }, "line1": { "type": "string" }, "line2": { "type": "string" }, "postalCode": { "type": "string" }, "state": { "type": "string" } }, "required": [ "city", "country", "line1", "line2", "postalCode", "state" ] } }, "required": [ "email", "phoneNumber", "address" ] }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "type", "awsAccountId", "awsRegion", "ownerEmail", "emailDomain", "customerId", "customUrl", "companyName", "companyVat", "companyAddress", "iotEndpoint", "timezone", "statistics", "subscriptionPlan", "subscriptionStatus", "finance", "createdAtDateString", "createdAt" ], "description": "Data of the organization subscribed" } }, "required": [ "data" ] }, "example": { "data": { "id": "o-organizationId", "type": "MultiTenant", "awsAccountId": "965578212345", "awsRegion": "ap-northeast-1", "ownerEmail": "ownerEmail@infodeck.io", "emailDomain": "infodeck.io", "customerId": "cus_PniZJxxxxxxxxxxC", "customUrl": "infodeck", "companyName": "Infodeck", "companyVat": "VAT-XXXXX", "companyAddress": "Taipei City", "iotEndpoint": "a3m4oxxxxxxxxxx-ats.iot.ap-northeast-1.amazonaws.com", "timezone": "Asia/Taipei", "statistics": { "assetType": 2, "deck": 3, "eventRule": 0, "eventSchedule": 0, "integrationService": 1, "location": 2, "team": 0, "thing": 0, "user": 2, "workOrder": 0, "workRequest": 0 }, "subscriptionPlan": "price_1OyTQxxxxxxxxxxE", "subscriptionStatus": "active", "finance": { "email": "dev+stripetest@infodeck.io", "phoneNumber": "+886912345678", "address": { "city": "Taipei", "country": "TW", "line1": "6F, No. 287, Section 3, Nanjing East Road", "line2": "Songshan District", "postalCode": "10595", "state": "Taiwan" } }, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/users/{userId}": { "delete": { "summary": "Delete User", "description": "Delete user for organization", "operationId": "Organization.DeleteUser", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the user." } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "400": { "description": "The request has invalid data.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has invalid data." }, "message": { "type": "string", "description": "The request has invalid data message." } }, "required": [ "error", "message" ] }, "example": { "error": "Bad Request", "message": "The request cannot be processed due to a bad request." }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get User", "description": "Get user for organization", "operationId": "Organization.GetUser", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "sub": { "type": "string" }, "organizationId": { "type": "string" }, "emailVerified": { "type": "string" }, "familyName": { "type": "string" }, "givenName": { "type": "string" }, "email": { "type": "string" }, "appRole": { "type": "string" }, "status": { "type": "string" }, "picture": { "type": "string" }, "team": {}, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "sub", "organizationId", "emailVerified", "familyName", "givenName", "email", "appRole", "status", "team", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the user." } }, "required": [ "data" ] }, "example": { "data": { "id": "53abe59e-xxxx-xxxx-xxxx-11aa5d05dd6e", "sub": "53abe59e-xxxx-xxxx-xxxx-11aa5d05dd6e", "organizationId": "o-organizationId", "emailVerified": "true", "familyName": "Kevin", "givenName": "Ashton", "email": "example@infodeck.io", "appRole": "RequesterAndViewer", "status": "ACTIVE", "picture": "https://app.infodeck.io/public/organizations/o-orgId/users/userId/defaultimage.jpg", "teams": [ { "id": "t-teamId", "organizationId": "o-organizationId", "name": "Administrator Team", "description": "Administrator team created by the system, cannot be deleted", "users": [ "d59a2a9a-xxxx-xxxx-xxxx-4cc2186a01f1" ], "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } ], "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/iot-endpoint-and-credentials": { "get": { "summary": "Get Organization IoT Endpoint And Credentials", "description": "Get Organization IoT Endpoint And Credentials", "operationId": "Organization.GetOrganizationIotEndpointAndCredentials", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "awsRegion": { "type": "string" }, "iotEndpoint": { "type": "string" }, "credentials": { "type": "object", "properties": { "accessKeyId": { "type": "string" }, "secretAccessKey": { "type": "string" }, "sessionToken": { "type": "string" }, "expiration": { "type": "string" } }, "required": [ "accessKeyId", "secretAccessKey", "sessionToken", "expiration" ] } }, "required": [ "awsRegion", "iotEndpoint", "credentials" ], "description": "Data of the organization credentials." } }, "required": [ "data" ] }, "example": { "data": { "iotEndpoint": "a3m4oxxxxxxxxxx-ats.iot.ap-northeast-1.amazonaws.com", "awsRegion": "ap-northeast-1", "credentials": { "accessKeyId": "ABCDEFGHIJKLMNOPQRST", "secretAccessKey": "p9+7+f/ABCDEFGHIJKLMNO/ABCDEFGHIJKLMNOPQ", "sessionToken": "ABCDEFGHIJKLMNOPQRS//////////", "expiration": "2024-01-01T00:00:00.000Z" } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/usage": { "get": { "summary": "Get usage", "description": "Get usage for organization", "operationId": "Organization.GetUsage", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "Start date for usage request.", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "endDate", "description": "End date for usage request.", "in": "query", "schema": { "type": "number" }, "required": true } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "usageSms": { "type": "number" }, "usageWhatsapp": { "type": "number" }, "usageEmail": { "type": "number" }, "usageSage": { "type": "number" } }, "required": [ "usageSms", "usageWhatsapp", "usageEmail", "usageSage" ], "description": "Organization usage object." } }, "required": [ "data" ] }, "example": { "data": { "usageSms": 1, "usageWhatsapp": 1, "usageEmail": 1, "usageSage": 1 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}": { "get": { "summary": "Get current user organization", "description": "Get current user organization", "operationId": "Organization.Get_current_user_organization", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": false, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "type": { "type": "string" }, "awsAccountId": { "type": "string" }, "awsRegion": { "type": "string" }, "ownerEmail": { "type": "string" }, "emailDomain": { "type": "string" }, "customerId": { "type": "string" }, "customUrl": { "type": "string" }, "companyName": { "type": "string" }, "companyVat": { "type": "string" }, "companyAddress": { "type": "string" }, "iotEndpoint": { "type": "string" }, "timezone": { "type": "string" }, "statistics": { "type": "object", "properties": {}, "required": [] }, "subscriptionPlan": { "type": "string" }, "subscriptionStatus": { "type": "string" }, "finance": { "type": "object", "properties": { "email": { "type": "string" }, "phoneNumber": { "type": "string" }, "address": { "type": "object", "properties": { "city": { "type": "string" }, "country": { "type": "string" }, "line1": { "type": "string" }, "line2": { "type": "string" }, "postalCode": { "type": "string" }, "state": { "type": "string" } }, "required": [ "city", "country", "line1", "line2", "postalCode", "state" ] } }, "required": [ "email", "phoneNumber", "address" ] }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "type", "awsAccountId", "awsRegion", "ownerEmail", "emailDomain", "customerId", "customUrl", "companyName", "companyVat", "companyAddress", "iotEndpoint", "timezone", "statistics", "subscriptionPlan", "subscriptionStatus", "finance", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the organization." } }, "required": [ "data" ] }, "example": { "data": { "id": "o-organizationId", "type": "MultiTenant", "awsAccountId": "965578212345", "awsRegion": "ap-northeast-1", "ownerEmail": "ownerEmail@infodeck.io", "emailDomain": "infodeck.io", "customerId": "cus_PniZJxxxxxxxxxxC", "customUrl": "infodeck", "companyName": "Infodeck", "companyVat": "VAT-XXXXX", "companyAddress": "Taipei City", "iotEndpoint": "a3m4oxxxxxxxxxx-ats.iot.ap-northeast-1.amazonaws.com", "timezone": "Asia/Taipei", "statistics": { "assetType": 2, "deck": 3, "eventRule": 0, "eventSchedule": 0, "integrationService": 1, "location": 2, "team": 0, "thing": 0, "user": 2, "workOrder": 0, "workRequest": 0 }, "subscriptionPlan": "price_1OyTQxxxxxxxxxxE", "subscriptionStatus": "active", "finance": { "email": "dev+stripetest@infodeck.io", "phoneNumber": "+886912345678", "address": { "city": "Taipei", "country": "TW", "line1": "6F, No. 287, Section 3, Nanjing East Road", "line2": "Songshan District", "postalCode": "10595", "state": "Taiwan" } }, "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Organization", "description": "Update Organization", "operationId": "Organization.UpdateOrganization", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "companyName": { "type": "string", "description": "The company name of organization." }, "companyVat": { "type": "string", "description": "The company VAT of organization." }, "customUrl": { "type": "string", "description": "The URL of organization." }, "companyAddress": { "type": "string", "description": "The address of organization." }, "finance": { "type": "object", "properties": { "phoneNumber": { "type": "string" }, "email": { "type": "string" }, "address": { "type": "object", "properties": { "city": { "type": "string" }, "country": { "type": "string" }, "line1": { "type": "string" }, "line2": { "type": "string" }, "postalCode": { "type": "string" }, "state": { "type": "string" } }, "required": [] } }, "required": [], "description": "Financial information of the organization (optional)." } }, "required": [ "companyName", "customUrl" ] }, "example": { "companyName": "Infodeck", "companyVat": "VAT-XXXXX", "companyAddress": "Taipei City", "customUrl": "infodeck", "timezone": "Asia/Taipei" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "type": { "type": "string" }, "awsAccountId": { "type": "string" }, "awsRegion": { "type": "string" }, "ownerEmail": { "type": "string" }, "emailDomain": { "type": "string" }, "customerId": { "type": "string" }, "customUrl": { "type": "string" }, "companyName": { "type": "string" }, "companyVat": { "type": "string" }, "companyAddress": { "type": "string" }, "iotEndpoint": { "type": "string" }, "timezone": { "type": "string" }, "statistics": { "type": "object", "properties": {}, "required": [] }, "subscriptionPlan": { "type": "string" }, "subscriptionStatus": { "type": "string" }, "finance": { "type": "object", "properties": { "email": { "type": "string" }, "phoneNumber": { "type": "string" }, "address": { "type": "object", "properties": { "city": { "type": "string" }, "country": { "type": "string" }, "line1": { "type": "string" }, "line2": { "type": "string" }, "postalCode": { "type": "string" }, "state": { "type": "string" } }, "required": [ "city", "country", "line1", "line2", "postalCode", "state" ] } }, "required": [ "email", "phoneNumber", "address" ] }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "type", "awsAccountId", "awsRegion", "ownerEmail", "emailDomain", "customerId", "customUrl", "companyName", "companyVat", "companyAddress", "iotEndpoint", "timezone", "statistics", "subscriptionPlan", "subscriptionStatus", "finance", "updatedAtDateString", "updatedAt" ], "description": "Data of the organization." } }, "required": [ "data" ] }, "example": { "data": { "id": "o-organizationId", "type": "MultiTenant", "awsAccountId": "965578212345", "awsRegion": "ap-northeast-1", "ownerEmail": "ownerEmail@infodeck.io", "emailDomain": "infodeck.io", "customerId": "cus_PniZJxxxxxxxxxxC", "customUrl": "infodeck", "companyName": "Infodeck", "companyVat": "VAT-XXXXX", "companyAddress": "Taipei City", "iotEndpoint": "a3m4oxxxxxxxxxx-ats.iot.ap-northeast-1.amazonaws.com", "timezone": "Asia/Taipei", "statistics": { "assetType": 2, "deck": 3, "eventRule": 0, "eventSchedule": 0, "integrationService": 1, "location": 2, "team": 0, "thing": 0, "user": 2, "workOrder": 0, "workRequest": 0 }, "subscriptionPlan": "price_1OyTQxxxxxxxxxxE", "subscriptionStatus": "active", "finance": { "email": "dev+stripetest@infodeck.io", "phoneNumber": "+886912345678", "address": { "city": "Taipei", "country": "TW", "line1": "6F, No. 287, Section 3, Nanjing East Road", "line2": "Songshan District", "postalCode": "10595", "state": "Taiwan" } }, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/stats": { "get": { "summary": "List Stats", "description": "List stats for organization", "operationId": "Organization.ListStats", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "assetType": { "type": "number" }, "deck": { "type": "number" }, "eventRule": { "type": "number" }, "eventSchedule": { "type": "number" }, "integrationService": { "type": "number" }, "location": { "type": "number" }, "team": { "type": "number" }, "thing": { "type": "number" }, "user": { "type": "number" }, "workOrder": { "type": "number" }, "workRequest": { "type": "number" } }, "required": [ "assetType", "deck", "eventRule", "eventSchedule", "integrationService", "location", "team", "thing", "user", "workOrder", "workRequest" ], "description": "Organization stats object." } }, "required": [ "data" ] }, "example": { "data": { "assetType": 0, "deck": 0, "eventRule": 0, "eventSchedule": 0, "integrationService": 0, "location": 0, "team": 0, "thing": 0, "user": 0, "workOrder": 0, "workRequest": 0 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/teams": { "get": { "summary": "List Teams", "description": "List teams for organization", "operationId": "Organization.ListTeams", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "user": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "email": { "type": "string" }, "firstName": { "type": "string" }, "lastName": { "type": "string" } }, "required": [ "id", "email", "firstName", "lastName" ] } }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "user", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Array of team data objects." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef", "organizationId": "o-organizationId", "name": "IDT-Team", "description": "IDT-Team-Description", "user": [ { "id": "53abe59e-xxxx-xxxx-xxxx-11aa5d05dd6e", "email": "example@infodeck.io", "firstName": "Ashton", "lastName": "Kevin" } ], "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "post": { "summary": "Create Team", "description": "Create team for organization", "operationId": "Organization_Team.CreateTeam", "tags": [ "Organization Team" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of team." }, "description": { "type": "string", "description": "The description of team." }, "image": { "type": "string", "description": "The image file name of team." } }, "required": [ "name", "description" ] }, "example": { "name": "IDT-Team", "description": "IDT-Team-Description", "image": "image.png" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "createdAtDateString", "createdAt" ], "description": "Data of the team." } }, "required": [ "data" ] }, "example": { "data": { "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef", "organizationId": "o-organizationId", "name": "IDT-Team", "description": "IDT-Team-Description", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/users": { "get": { "summary": "List Users", "description": "List users for organization", "operationId": "Organization.ListUsers", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "joinRequest", "description": "Return join request users.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "sub": { "type": "string" }, "organizationId": { "type": "string" }, "emailVerified": { "type": "string" }, "familyName": { "type": "string" }, "givenName": { "type": "string" }, "email": { "type": "string" }, "appRole": { "type": "string" }, "status": { "type": "string" }, "picture": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "sub", "organizationId", "emailVerified", "familyName", "givenName", "email", "appRole", "status", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Array of user data objects." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "53abe59e-xxxx-xxxx-xxxx-11aa5d05dd6e", "sub": "53abe59e-xxxx-xxxx-xxxx-11aa5d05dd6e", "organizationId": "o-organizationId", "emailVerified": "true", "familyName": "Kevin", "givenName": "Ashton", "email": "example@infodeck.io", "appRole": "RequesterAndViewer", "status": "ACTIVE", "picture": "https://app.infodeck.io/public/organizations/o-orgId/users/userId/defaultimage.jpg", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/teams/{teamId}/users": { "get": { "summary": "List Users In Team", "description": "List users in team for organization", "operationId": "Organization.ListUsersInTeam", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The ID of team.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "sub": { "type": "string" }, "organizationId": { "type": "string" }, "emailVerified": { "type": "string" }, "familyName": { "type": "string" }, "givenName": { "type": "string" }, "email": { "type": "string" }, "appRole": { "type": "string" }, "status": { "type": "string" }, "picture": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "sub", "organizationId", "emailVerified", "familyName", "givenName", "email", "appRole", "status", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Array of user data objects within a team." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "53abe59e-xxxx-xxxx-xxxx-11aa5d05dd6e", "sub": "53abe59e-xxxx-xxxx-xxxx-11aa5d05dd6e", "organizationId": "o-organizationId", "emailVerified": "true", "familyName": "Kevin", "givenName": "Ashton", "email": "example@infodeck.io", "appRole": "RequesterAndViewer", "status": "ACTIVE", "picture": "https://app.infodeck.io/public/organizations/o-orgId/users/userId/defaultimage.jpg", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/teams/{teamId}": { "put": { "summary": "Update Team", "description": "Update team for organization", "operationId": "Organization.UpdateTeam", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The ID of team", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of team." }, "description": { "type": "string", "description": "The description of team." }, "image": { "type": "string", "description": "The image file name of team." } }, "required": [ "name", "description" ] }, "example": { "name": "IDT-Team", "description": "IDT-Team-Description", "image": "image.png" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": {} }, "required": [ "id", "organizationId", "name", "description", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the team." } }, "required": [ "data" ] }, "example": { "data": { "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef", "organizationId": "o-organizationId", "name": "IDT-Team", "description": "IDT-Team-Description", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "delete": { "summary": "Delete Team", "description": "Delete team for organization", "operationId": "Organization_Team.DeleteTeam", "tags": [ "Organization Team" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The ID of team.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the team." } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get team", "description": "Get team for organization", "operationId": "Organization_Team.GetTeam", "tags": [ "Organization Team" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The ID of team.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" }, "user": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "email": { "type": "string" }, "firstName": { "type": "string" }, "lastName": { "type": "string" } }, "required": [ "id", "email", "firstName", "lastName" ] } }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "description", "user", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the team." } }, "required": [ "data" ] }, "example": { "data": { "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef", "organizationId": "o-organizationId", "name": "IDT-Team", "description": "IDT-Team-Description", "user": [ { "id": "53abe59e-xxxx-xxxx-xxxx-11aa5d05dd6e", "email": "example@infodeck.io", "firstName": "Ashton", "lastName": "Kevin" } ], "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/users/{userId}/status": { "put": { "summary": "Update User Status", "description": "Update status for organization user", "operationId": "Organization.UpdateUserStatus", "tags": [ "Organization" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "status": { "type": "string", "description": "SUCCESS, CONFIRM_JOIN, PENDING_ACCEPT." } }, "required": [ "status" ] }, "example": { "status": "CONFIRM_JOIN" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Status of the user." } }, "required": [ "data" ] }, "example": { "data": { "status": "CONFIRM_JOIN" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/add-ons": { "get": { "summary": "Get add-ons for organization", "description": "Get add-ons for organization", "operationId": "Organization_Addons.GetAddOnsForOrganization", "tags": [ "Organization Addons" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "infodeckLns": { "type": "object", "properties": { "status": { "type": "string" }, "tenantId": { "type": "string" }, "apiKey": { "type": "string" } }, "required": [ "status", "tenantId", "apiKey" ] }, "anyFeedback": { "type": "object", "properties": { "status": { "type": "string" } }, "required": [ "status" ] } }, "required": [ "infodeckLns", "anyFeedback" ], "description": "Data container for the add-ons information." } }, "required": [ "data" ] }, "example": { "data": { "infodeckLns": { "status": "Success", "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "apiKey": "eyJ0exxxxxxxxxx4" }, "anyFeedback": { "status": "Success" } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update add-ons for organization", "description": "Update add-ons for organization", "operationId": "Organization_Addons.UpdateAddOnsForOrganization", "tags": [ "Organization Addons" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "infodeckLns": { "type": "object", "properties": { "status": { "type": "string" }, "tenantId": { "type": "string" }, "apiKey": { "type": "string" } }, "required": [ "status", "tenantId", "apiKey" ], "description": "The infodeckLns of organization." }, "anyFeedback": { "type": "object", "properties": { "status": { "type": "string" } }, "required": [ "status" ], "description": "The anyFeedback of organization." } }, "required": [ "infodeckLns", "anyFeedback" ] }, "example": { "infodeckLns": { "status": "Success", "tenantId": "52f14cd4-xxxx-xxxx-xxxx-4025e1d49242", "apiKey": "eyJ0xxxxxxxxxxxxxxxxxxxxxx4" }, "anyFeedback": { "status": "Success" } }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "infodeckLns": { "type": "object", "properties": { "status": { "type": "string" }, "tenantId": { "type": "string" }, "apiKey": { "type": "string" } }, "required": [ "status", "tenantId", "apiKey" ] }, "anyFeedback": { "type": "object", "properties": { "status": { "type": "string" } }, "required": [ "status" ] } }, "required": [ "infodeckLns", "anyFeedback" ], "description": "Data container for the add-ons information." } }, "required": [ "data" ] }, "example": { "data": { "infodeckLns": { "status": "Success", "tenantId": "b004ebe0-xxxx-xxxx-xxxx-dacd251b6f00", "apiKey": "eyJ0exxxxxxxxxx4" }, "anyFeedback": { "status": "Success" } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/subscription": { "get": { "summary": "Get Subscription", "description": "Get Subscription", "operationId": "Organization_Stripe.GetSubscription", "tags": [ "Organization Stripe" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "organizationIdd": { "type": "string" }, "plan": { "type": "object", "properties": { "active": { "type": "boolean" }, "aggregate_usage": { "type": "string" }, "amount": { "type": "number" }, "amount_decimal": { "type": "string" }, "billing_scheme": { "type": "string" }, "created_at": { "type": "number" }, "currency": { "type": "string" }, "id": { "type": "string" }, "interval": { "type": "string" }, "interval_count": { "type": "number" }, "livemode": { "type": "boolean" }, "metadata": { "type": "object", "properties": {}, "required": [] }, "nickname": { "type": "string" }, "object": { "type": "string" }, "product": { "type": "string" }, "tiers_mode": { "type": "string" }, "transform_usage": { "type": "object", "properties": {}, "required": [] }, "trial_period_days": { "type": "number" }, "usage_type": { "type": "string" } }, "required": [ "active", "aggregate_usage", "amount", "amount_decimal", "billing_scheme", "created_at", "currency", "id", "interval", "interval_count", "livemode", "metadata", "nickname", "object", "product", "tiers_mode", "transform_usage", "trial_period_days", "usage_type" ] }, "planId": { "type": "string" }, "price": { "type": "object", "properties": { "active": { "type": "boolean" }, "billing_scheme": { "type": "string" }, "created_at": { "type": "number" }, "currency": { "type": "string" }, "custom_unit_amount": { "type": "string" }, "id": { "type": "string" }, "livemode": { "type": "boolean" }, "lookup_key": { "type": "string" }, "metadata": { "type": "object", "properties": {}, "required": [] }, "nickname": { "type": "string" }, "object": { "type": "string" }, "product": { "type": "string" }, "recurring": { "type": "object", "properties": { "aggregate_usage": { "type": "string" }, "interval": { "type": "string" }, "interval_count": { "type": "number" }, "usage_type": { "type": "string" } }, "required": [ "aggregate_usage", "interval", "interval_count", "usage_type" ] }, "tax_behavior": { "type": "string" }, "tiers_mode": { "type": "number" }, "transform_quantity": { "type": "object", "properties": {}, "required": [] }, "type": { "type": "string" }, "unit_amount": { "type": "number" }, "unit_amount_decimal": { "type": "string" } }, "required": [ "active", "billing_scheme", "created_at", "currency", "custom_unit_amount", "id", "livemode", "lookup_key", "metadata", "nickname", "object", "product", "recurring", "tax_behavior", "tiers_mode", "transform_quantity", "type", "unit_amount", "unit_amount_decimal" ] }, "priceId": { "type": "string" }, "status": { "type": "string" }, "subscription": { "type": "object", "properties": { "application": { "type": "string" }, "application_fee_percent": { "type": "string" }, "automatic_tax": { "type": "object", "properties": { "enabled": { "type": "object", "properties": {}, "required": [] }, "liability": { "type": "object", "properties": {}, "required": [] } }, "required": [ "enabled", "liability" ] }, "billing_cycle_anchor": { "type": "number" }, "billing_cycle_anchor_config": { "type": "string" }, "billing_thresholds": { "type": "string" }, "canceled_at": { "type": "string" }, "cancellation_details": { "type": "object", "properties": { "comment": { "type": "string" }, "feedback": { "type": "string" }, "reason": { "type": "string" } }, "required": [ "comment", "feedback", "reason" ] }, "cancel_at": { "type": "string" }, "cancel_at_period_end": { "type": "boolean" }, "collection_method": { "type": "string" }, "created": { "type": "number" }, "currency": { "type": "string" }, "current_period_end": { "type": "number" }, "current_period_start": { "type": "number" }, "days_until_due": { "type": "string" }, "default_payment_method": { "type": "string" }, "default_source": { "type": "string" }, "default_tax_rates": { "type": "string" }, "description": { "type": "string" }, "discount": { "type": "string" }, "ended_at": { "type": "string" }, "invoice_settings": { "type": "object", "properties": { "account_tax_ids": { "type": "string" }, "issuer": { "type": "object", "properties": { "type": { "type": "string" } }, "required": [ "type" ] } }, "required": [ "account_tax_ids", "issuer" ] }, "lastest_invoice": { "type": "string" }, "livemode": { "type": "boolean" }, "metadata": { "type": "object", "properties": {}, "required": [] }, "next_pending_invoice_item_invoice": { "type": "string" }, "object": { "type": "string" }, "on_behalf_of": { "type": "string" }, "pause_collection": { "type": "string" }, "payment_settings": { "type": "object", "properties": { "payment_method_options": { "type": "string" }, "payment_method_types": { "type": "string" }, "save_default_payment_method": { "type": "string" } }, "required": [ "payment_method_options", "payment_method_types", "save_default_payment_method" ] }, "pending_invoice_item_interval": { "type": "string" }, "pending_setup_intent": { "type": "string" }, "pending_update": { "type": "string" }, "quantity": { "type": "number" }, "schedule": { "type": "string" }, "start_date": { "type": "number" }, "status": { "type": "string" }, "test_clock": { "type": "string" }, "transfer_data": { "type": "string" }, "trial_end": { "type": "number" }, "trial_settings": { "type": "object", "properties": { "end_behavior": { "type": "object", "properties": { "missing_payment_method": { "type": "string" } }, "required": [ "missing_payment_method" ] } }, "required": [ "end_behavior" ] }, "trial_start": { "type": "number" } }, "required": [ "application", "application_fee_percent", "automatic_tax", "billing_cycle_anchor", "billing_cycle_anchor_config", "billing_thresholds", "canceled_at", "cancellation_details", "cancel_at", "cancel_at_period_end", "collection_method", "created", "currency", "current_period_end", "current_period_start", "days_until_due", "default_payment_method", "default_source", "default_tax_rates", "description", "discount", "ended_at", "invoice_settings", "lastest_invoice", "livemode", "metadata", "next_pending_invoice_item_invoice", "object", "on_behalf_of", "pause_collection", "payment_settings", "pending_invoice_item_interval", "pending_setup_intent", "pending_update", "quantity", "schedule", "start_date", "status", "test_clock", "transfer_data", "trial_end", "trial_settings", "trial_start" ] }, "subscriptionId": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "organizationIdd", "plan", "planId", "price", "priceId", "status", "subscription", "subscriptionId", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the organization subscription." } }, "required": [ "data" ] }, "example": { "data": { "organizationId": "o-organizationId", "createdAt": 1704067200000, "customerId": "cus_PoBsnxxxxxxxxxxE", "plan": { "active": true, "aggregate_usage": null, "amount": 60000, "amount_decimal": "60000", "billing_scheme": "per_unit", "created": 1710000000, "currency": "usd", "id": "price_1OwL8xxxxxxxxxx6", "interval": "month", "interval_count": 1, "livemode": false, "metadata": { "LOL": "PEANUT" }, "nickname": null, "object": "plan", "product": { "active": true, "attributes": [], "created": 1710000000, "default_price": "price_1OwL85xxxxxxxxxx6", "description": "Regular plan with limitations", "features": [ { "name": "No priority support" } ], "id": "prod_PlstGxxxxxxxxxxTM", "images": [ "https://files.stripe.com/links/xxxxxxxxxx" ], "livemode": false, "metadata": { "MAX_LIMIT_DECK": "3" }, "name": "Basic Plan", "object": "product", "package_dimensions": null, "shippable": null, "statement_descriptor": null, "tax_code": "txcd_10103001", "type": "service", "unit_label": null, "updated": 1720000000, "url": null }, "tiers_mode": null, "transform_usage": null, "trial_period_days": null, "usage_type": "licensed" }, "planId": "price_1OwL8xxxxxxxxxx6", "price": { "active": true, "billing_scheme": "per_unit", "created": 1710000000, "currency": "usd", "custom_unit_amount": null, "id": "price_1OwL8xxxxxxxxxx6", "livemode": false, "lookup_key": null, "metadata": { "LOL": "PEANUT" }, "nickname": null, "object": "price", "product": "prod_PlstGxxxxxxxxxxM", "recurring": { "aggregate_usage": null, "interval": "month", "interval_count": 1, "trial_period_days": null, "usage_type": "licensed" }, "tax_behavior": "unspecified", "tiers_mode": null, "transform_quantity": null, "type": "recurring", "unit_amount": 60000, "unit_amount_decimal": "60000" }, "priceId": "price_1OwL8xxxxxxxxxx6", "status": "trialing", "subscription": { "application": null, "application_fee_percent": null, "automatic_tax": { "enabled": false, "liability": null }, "billing_cycle_anchor": 1720000000, "billing_cycle_anchor_config": null, "billing_thresholds": null, "canceled_at": null, "cancellation_details": { "comment": null, "feedback": null, "reason": null }, "cancel_at": null, "cancel_at_period_end": false, "collection_method": "charge_automatically", "created": 1710000000, "currency": "usd", "current_period_end": 1720000000, "current_period_start": 1710000000, "days_until_due": null, "default_payment_method": null, "default_source": null, "default_tax_rates": [], "description": null, "discount": null, "ended_at": null, "invoice_settings": { "account_tax_ids": null, "issuer": { "type": "self" } }, "latest_invoice": "in_1OyZUxxxxxxxxxxt", "livemode": false, "metadata": {}, "next_pending_invoice_item_invoice": null, "object": "subscription", "on_behalf_of": null, "pause_collection": null, "payment_settings": { "payment_method_options": null, "payment_method_types": null, "save_default_payment_method": "off" }, "pending_invoice_item_interval": null, "pending_setup_intent": "seti_1OyZUxxxxxxxxxxV", "pending_update": null, "quantity": 1, "schedule": null, "start_date": 1710000000, "status": "trialing", "test_clock": "clock_1OymAxxxxxxxxxx9", "transfer_data": null, "trial_end": 1720000000, "trial_settings": { "end_behavior": { "missing_payment_method": "cancel" } }, "trial_start": 1710000000 }, "subscriptionId": "sub_1OyZUxxxxxxxxxxX", "createdAtDateString": "2024-01-01T00:00:00.000Z", "created": 1720000000000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1720000000000 } }, "description": "" } } }, "400": { "description": "The request has invalid data.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has invalid data." }, "message": { "type": "string", "description": "The request has invalid data message." } }, "required": [ "error", "message" ] }, "example": { "error": "Bad Request", "message": "The request cannot be processed due to a bad request." }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [] } }, "/organizations/{organizationId}/permissions": { "get": { "summary": "List permissions", "description": "List Permissions", "operationId": "Permissions.ListPermissions", "tags": [ "Permissions" ], "parameters": [ { "name": "organizationId", "description": "", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "description": { "type": "string" }, "groups": { "type": "array", "items": { "type": "string" } }, "categoryId": { "type": "string" }, "actionId": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAt": { "type": "number" }, "createdBy": { "type": "string" }, "updatedBy": { "type": "string" } }, "required": [ "id", "description", "groups", "categoryId", "actionId", "createdAt", "updatedAt", "createdBy", "updatedBy" ] }, "description": "Array of permission objects, each representing a specific set of permissions granted or available." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "prm-lns:tenants:device-profiles:delete", "description": "Permission to delete lns:tenants:device-profiles", "groups": [ "Team can Manage Assets, Asset type, Integrations, Smart workflows and Infodeck LNS" ], "categoryId": "lns", "actionId": "lns:tenants:device-profiles:delete", "createdAt": 1714365479329, "updatedAt": 1714365479329, "createdBy": "system", "updatedBy": "system" } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/roles": { "post": { "summary": "Create Role", "description": "Create Role", "operationId": "Role.CreateRole", "tags": [ "Role" ], "parameters": [ { "name": "organizationId", "description": "The ID of the organization where the role is to be created.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of the role." }, "description": { "type": "string", "description": "The description of the role." }, "policies": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The policies associated with the role. Each policy defines actions, effects, and resources." } }, "required": [ "name", "policies" ] }, "example": { "name": "Administrator", "description": "Full access to all resources.", "policies": [ { "actions": [ "create:*", "delete:*" ], "effect": "allow", "resources": [ "*" ] } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "description": { "type": "string" }, "policies": { "type": "array", "items": { "type": "object", "properties": { "resources": { "type": "array", "items": { "type": "string" } }, "actions": { "type": "array", "items": { "type": "string" } }, "effect": { "type": "string" } }, "required": [ "resources", "actions", "effect" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "description", "policies", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the created role including its ID, description, policies, and timestamps." } }, "required": [ "data" ] }, "example": { "data": { "id": "rl-admin", "description": "Admin role", "policies": [ { "resources": [ "*" ], "actions": [ "*" ], "effect": "allow" } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Roles", "description": "List Roles", "operationId": "Role.ListRoles", "tags": [ "Role" ], "parameters": [ { "name": "organizationId", "description": "The ID of the organization whose roles are to be listed.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "A token to retrieve the next set of results, used for pagination.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "description": { "type": "string" }, "policies": { "type": "array", "items": { "type": "object", "properties": { "resources": { "type": "array", "items": { "type": "string" } }, "actions": { "type": "array", "items": { "type": "string" } }, "effect": { "type": "string" } }, "required": [ "resources", "actions", "effect" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "description", "policies", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "Data of the created role including its ID, description, policies, and timestamps.." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "rl-admin", "description": "Admin role", "policies": [ { "resources": [ "*" ], "actions": [ "*" ], "effect": "allow" } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/roles/{roleId}": { "delete": { "summary": "Delete Role", "description": "Delete Role", "operationId": "Role.DeleteRole", "tags": [ "Role" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "roleId", "description": "The ID of role.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "deleted": { "type": "boolean" } }, "required": [ "deleted" ], "description": "Data of the role." } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Role", "description": "Get Role", "operationId": "Role.GetRole", "tags": [ "Role" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "roleId", "description": "The ID of role.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "description": { "type": "string" }, "policies": { "type": "array", "items": { "type": "object", "properties": { "resources": { "type": "array", "items": { "type": "string" } }, "actions": { "type": "array", "items": { "type": "string" } }, "effect": { "type": "string" } }, "required": [ "resources", "actions", "effect" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "description", "policies", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the created role including its ID, description, policies, and timestamps." } }, "required": [ "data" ] }, "example": { "data": { "id": "rl-admin", "description": "Admin role", "policies": [ { "resources": [ "*" ], "actions": [ "*" ], "effect": "allow" } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Role", "description": "Update Role", "operationId": "Role.UpdateRole", "tags": [ "Role" ], "parameters": [ { "name": "organizationId", "description": "The ID of the organization where the role is located.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "roleId", "description": "The ID of the role to update.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The new name of the role, if updating." }, "description": { "type": "string", "description": "The new description of the role, if updating." }, "policies": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The new policies for the role, if updating." } }, "required": [] }, "example": { "name": "Team Leader", "description": "Manages team of developers.", "policies": [ { "actions": [ "edit:*" ], "effect": "allow", "resources": [ "*" ] } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "description": { "type": "string" }, "policies": { "type": "array", "items": { "type": "object", "properties": { "resources": { "type": "array", "items": { "type": "string" } }, "actions": { "type": "array", "items": { "type": "string" } }, "effect": { "type": "string" } }, "required": [ "resources", "actions", "effect" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "description", "policies", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the created role including its ID, description, policies, and timestamps." } }, "required": [ "data" ] }, "example": { "data": { "id": "rl-admin", "description": "Admin role", "policies": [ { "resources": [ "*" ], "actions": [ "*" ], "effect": "allow" } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/services/lorawan-services": { "post": { "summary": "Get LoRaWAN Services", "description": "Get LoRaWAN Services", "operationId": "Services.GetLoRaWANServices", "tags": [ "Services" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "componentNames": { "type": "array", "items": { "type": "string" }, "description": "Edge gateway component name list." } }, "required": [ "componentNames" ] }, "example": { "componentNames": [ "IDT-BoT" ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the LoRaWAN services." } }, "required": [ "data" ] }, "example": { "data": { "type": "cloud", "name": "Infodeck Cloud" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/statistics/work-orders/status": { "get": { "summary": "Count Work Orders By Date", "description": "Count Work Orders By Date", "operationId": "Statistics.CountWorkOrdersByDate", "tags": [ "Statistics" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of query", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "endDate", "description": "The end date number of query", "in": "query", "schema": { "type": "number" }, "required": true } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "statusName": { "type": "string" }, "value": { "type": "number" } }, "required": [ "statusName", "value" ] }, "description": "Data of the work order status statistic." } }, "required": [ "data" ] }, "example": { "data": { "statusName": "Open", "value": 2 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/statistics/work-orders/status/{status}": { "get": { "summary": "Count Work Orders By Status", "description": "Count Work Orders By Status", "operationId": "Statistics.CountWorkOrdersByStatus", "tags": [ "Statistics" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "status", "description": "The status of work order.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of query", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "endDate", "description": "The end date number of query", "in": "query", "schema": { "type": "number" }, "required": true } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "statusName": { "type": "string" }, "value": { "type": "number" } }, "required": [ "statusName", "value" ], "description": "Work order status count statistics during the period." } }, "required": [ "data" ] }, "example": { "data": { "statusName": "Open", "value": 2 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/statistics/assets/metrics": { "post": { "summary": "Get Asset Metrics.", "description": "Get Asset Metrics", "operationId": "Statistics.GetAssetMetrics", "tags": [ "Statistics" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "startTime": { "type": "number", "description": "The startTime of metrics statistic." }, "endTime": { "type": "number", "description": "The endTime of metrics statistic." }, "period": { "type": "number", "description": "The period of metrics statistic." }, "metrics": { "type": "array", "items": { "type": "object", "properties": { "assetId": { "type": "string" }, "properties": { "type": "object", "properties": { "key": { "type": "string" }, "aggregation": { "type": "string" }, "alias": { "type": "string" } }, "required": [ "key", "aggregation" ] } }, "required": [ "assetId", "properties" ] }, "description": "The metrics of statistic." } }, "required": [ "startTime", "endTime", "period", "metrics" ] }, "example": { "startTime": 1700000000000, "endTime": 1800000000000, "period": 300, "metrics": [ { "assetId": "a-assetId", "properties": [ { "key": "Temperature", "aggregation": "average", "alias": "Temperature" } ] } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "startTime": { "type": "number" }, "endTime": { "type": "number" }, "period": { "type": "number" }, "metrics": { "type": "array", "items": { "type": "object", "properties": { "assetId": { "type": "string" }, "properties": { "type": "array", "items": { "type": "object", "properties": { "key": { "type": "string" }, "aggregation": { "type": "string" }, "alias": { "type": "string" } }, "required": [ "key", "aggregation" ] } } }, "required": [ "assetId", "properties" ] } } }, "required": [ "startTime", "endTime", "period", "metrics" ], "description": "Data of the metrics statistic." } }, "required": [ "data" ] }, "example": { "data": { "startTime": 1700000000000, "endTime": 1800000000000, "period": 300, "metrics": [ { "assetId": "a-assetId", "properties": [ { "key": "Temperature", "aggregation": "average", "alias": "Temperature" } ] } ] } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/statistics/assets/properties/{property}": { "post": { "summary": "Get Assets Property Metrics.", "description": "Get assets property metrics", "operationId": "Statistics.GetAssetsPropertyMetrics", "tags": [ "Statistics" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "property", "description": "The property of assets.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "startDate": { "type": "number", "description": "The startDate of metrics statistic." }, "endDate": { "type": "number", "description": "The endDate of metrics statistic." }, "assetIds": { "type": "array", "items": { "type": "string" }, "description": "The ID of assets." } }, "required": [ "startDate", "endDate", "assetIds" ] }, "example": { "startDate": 1700000000000, "endDate": 1800000000000, "assetIds": [ "a-assetId" ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "assetId": { "type": "object", "properties": { "timestamps": { "type": "array", "items": { "type": "number" } }, "values": { "type": "array", "items": { "type": "number" } } }, "required": [ "timestamps", "values" ] } }, "required": [ "assetId" ], "description": "Metrics of the assets." } }, "required": [ "data" ] }, "example": { "data": { "a-823572394723947900": { "timestamps": [ 1721703000000 ], "values": [ 37 ] } } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/statistics/assets/rawdata": { "post": { "summary": "Get Assets Rawdata.", "description": "Get Assets Rawdata", "operationId": "Statistics.GetAssetsRawdata", "tags": [ "Statistics" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "startTime": { "type": "number", "description": "The startTime of metrics statistic." }, "endTime": { "type": "number", "description": "The endTime of metrics statistic." }, "assetTypeId": { "type": "string", "description": "The ID of asset type." }, "assetIds": { "type": "array", "items": { "type": "string" }, "description": "The ID of assets." }, "properties": { "type": "array", "items": { "type": "string" }, "description": "The properties of asset type." }, "exportFormat": { "type": "string", "description": "The format of export file." } }, "required": [ "startTime", "endTime", "properties" ] }, "example": { "startTime": 1700000000000, "endTime": 1800000000000, "assetTypeId": "at-assetTypeId", "assetIds": [ "a-assetId" ], "properties": [ "Temperature" ], "exportFormat": "CSV" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "startTime": { "type": "number" }, "endTime": { "type": "number" }, "assetTypeId": { "type": "string" }, "assetIds": { "type": "array", "items": { "type": "string" } }, "properties": { "type": "array", "items": { "type": "string" } }, "exportFormat": { "type": "string" } }, "required": [ "startTime", "endTime", "assetTypeId", "assetIds", "properties", "exportFormat" ], "description": "Rawdata of the assets." } }, "required": [ "data" ] }, "example": { "data": { "startTime": 1700000000000, "endTime": 1800000000000, "assetTypeId": "at-assetTypeId", "assetIds": [ "a-assetId" ], "properties": [ "Temperature" ], "exportFormat": "CSV" } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/statistics/assets/summary": { "get": { "summary": "Get Assets Summary", "description": "Get Assets Summary", "operationId": "Statistics.GetAssetsSummary", "tags": [ "Statistics" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "staticAssetTotal": { "type": "number" }, "iotDeviceTotal": { "type": "number" }, "iotDeviceOnlineTotal": { "type": "number" } }, "required": [ "staticAssetTotal", "iotDeviceTotal", "iotDeviceOnlineTotal" ], "description": "Data of the asset summary." } }, "required": [ "data" ] }, "example": { "data": { "staticAssetTotal": 1, "iotDeviceTotal": 2, "iotDeviceOnlineTotal": 3 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/statistics/integrations/summary": { "get": { "summary": "Get Integration Services Summary", "description": "Get Integration Services Summary", "operationId": "Statistics.GetIntegrationServicesSummary", "tags": [ "Statistics" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "total": { "type": "number" } }, "required": [ "total" ], "description": "Data of the integration." } }, "required": [ "data" ] }, "example": { "data": { "total": 0 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/things/{thingName}": { "get": { "summary": "Get Thing", "description": "Get thing", "operationId": "Thing.GetThing", "tags": [ "Thing" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "thingName", "description": "The name of IoT device", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "thingArn": { "type": "string" }, "thingName": { "type": "string" }, "thingTypeName": { "type": "string" }, "attributes": { "type": "object", "properties": {}, "required": [] }, "shadows": { "type": "object", "properties": {}, "required": [] }, "version": { "type": "number" } }, "required": [ "thingArn", "thingName", "thingTypeName", "attributes", "shadows", "version" ] }, "description": "Data of the things." } }, "required": [ "data" ] }, "example": { "data": { "thingArn": "arn:aws:iot:ap-northeast-1:012345678901:thing/o-organizationId-a-24e124148b323456", "thingName": "o-organizationId-a-24e124148b323456", "thingTypeName": "o-organizationId-Default", "attributes": { "assetTypeId": "o-organizationId-at-assetType", "createdAt": "2024-01-01T00:00:00.000Z", "integrationId": "o-organizationId-is-integrationId", "locationId": "o-organizationId-l-locationId" }, "shadows": { "DeviceUplink": { "state": { "reported": { "Payload": { "Temperature": 25.4, "Humidity": 62, "CO2": 869, "rssi": -91 }, "ExpiredAt": 1711341602287 } }, "metadata": { "reported": { "Payload": { "Temperature": { "timestamp": 1711330802 }, "Humidity": { "timestamp": 1711330802 }, "CO2": { "timestamp": 1711330802 }, "rssi": { "timestamp": 1711330802 } }, "ExpiredAt": { "timestamp": 1711330802 } } }, "version": 21415, "timestamp": 1711330849 }, "version": 1 } } }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/thing-groups": { "get": { "summary": "List thing groups", "description": "List thing groups", "operationId": "Thing.ListThingGroups", "tags": [ "Thing" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "thingTypeName", "description": "The name of IoT type", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "string", "default": "10" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "groupArn": { "type": "string" }, "groupName": { "type": "string" } }, "required": [ "groupArn", "groupName" ] }, "description": "Data of the thing groups." }, "nextToken": { "type": "string", "description": "To retrieve the next set of results." } }, "required": [ "data" ] }, "example": { "data": [ { "groupArn": "arn:aws:iot:ap-northeast-1:012345678901:thing/o-organizationId-a-24e124148b323456", "groupName": "o-organizationId-a-24e124148b323456" } ] }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/things": { "get": { "summary": "List things", "description": "List things", "operationId": "Thing.ListThings", "tags": [ "Thing" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "thingTypeName", "description": "The name of IoT type", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "string", "default": "10" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "thingArn": { "type": "string" }, "thingName": { "type": "string" }, "thingTypeName": { "type": "string" }, "attributes": { "type": "object", "properties": {}, "required": [] }, "version": { "type": "number" } }, "required": [ "thingArn", "thingName", "thingTypeName", "attributes", "version" ] }, "description": "Data of the things." }, "nextToken": { "type": "string", "description": "To retrieve the next set of results." } }, "required": [ "data" ] }, "example": { "data": [ { "thingArn": "arn:aws:iot:ap-northeast-1:012345678901:thing/o-organizationId-a-24e124148b323456", "thingName": "o-organizationId-a-24e124148b323456", "thingTypeName": "o-organizationId-Default", "attributes": { "assetTypeId": "o-organizationId-at-assetType", "createdAt": "2024-01-01T00:00:00.000Z", "integrationId": "o-organizationId-is-integrationId", "locationId": "o-organizationId-l-locationId" }, "shadows": { "DeviceUplink": { "state": { "reported": { "Payload": { "Temperature": 25.4, "Humidity": 62, "CO2": 869, "rssi": -91 }, "ExpiredAt": 1711341602287 } }, "metadata": { "reported": { "Payload": { "Temperature": { "timestamp": 1711330802 }, "Humidity": { "timestamp": 1711330802 }, "CO2": { "timestamp": 1711330802 }, "rssi": { "timestamp": 1711330802 } }, "ExpiredAt": { "timestamp": 1711330802 } } }, "version": 21415, "timestamp": 1711330849 }, "version": 1 } } ] }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/users/{userId}/notifications": { "post": { "summary": "Create User Device Endpoint", "description": "Create User Device Endpoint", "operationId": "User_Notification.CreateUserDeviceEndpoint", "tags": [ "User Notification" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "endpoint": { "type": "string", "description": "The equivalent endpoint of phone or browser." }, "platform": { "type": "string", "description": "The notification platform(GCM, APNS, APNS_SANDBOX, BROWSER)." } }, "required": [ "endpoint", "platform" ] }, "example": {}, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Registration success." } }, "required": [ "data" ] }, "example": {}, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "delete": { "summary": "Delete User Device Endpoint", "description": "Delete User Device Endpoint", "operationId": "User_Notification.DeleteUserDeviceEndpoint", "tags": [ "User Notification" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Cancel registration success." } }, "required": [ "data" ] }, "example": {}, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List User Notifications", "description": "List user notifications", "operationId": "User_Notification.ListUserNotifications", "tags": [ "User Notification" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "endDate", "description": "The end date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "notificationId": { "type": "string" }, "userId": { "type": "string" }, "source": { "type": "string" }, "sourceId": { "type": "string" }, "title": { "type": "string" }, "description": { "type": "string" }, "address": { "type": "string" }, "chatRoomId": { "type": "string" }, "entities": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] } }, "image": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "notificationId", "userId", "source", "sourceId", "title", "description", "address", "chatRoomId", "entities", "image", "createdAtDateString", "createdAt" ] }, "description": "An array of user notification data." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "ABCDE", "notificationId": "nf-notificationId", "userId": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50dd", "source": "Asset", "sourceId": "ABCDE", "title": "IDT-Asset-Title", "description": "IDT-Asset-Description", "address": "Taipei City", "chatRoomId": "ABCDE", "entities": [], "image": "abc.png", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/event-rules": { "post": { "summary": "Create Event Rule", "description": "Create new event rule", "operationId": "Workflows.CreateEventRule", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of event rule." }, "description": { "type": "string", "description": "The description of event rule." }, "stage": { "type": "string", "description": "The stage of event rule." }, "expression": { "type": "string", "description": "The expression of event rule." }, "conditions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The conditions of event rule." }, "devices": { "type": "array", "items": { "type": "string" }, "description": "The devices of event rule." }, "period": { "type": "object", "properties": {}, "required": [], "description": "The period of event rule." }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The actions of event rule." }, "hashtags": { "type": "array", "items": { "type": "string" }, "description": "The hashtags of event rule." }, "status": { "type": "string", "description": "The status of event rule." } }, "required": [ "name", "stage", "period", "actions", "status" ] }, "example": { "name": "IDT-EventRule", "description": "IDT-EventRule-Description", "stage": "IoTCore", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expression": "IoTCore-Expression", "hashtags": [ "Important" ], "conditions": [ { "assetId": "a-assetId", "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": "25", "operator": "AND" } ], "devices": [ "a-assetId" ], "period": { "startTime": { "hour": 20, "minute": 34 }, "endTime": { "hour": 21, "minute": 34 }, "dayOfWeek": [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], "dayOfMonth": [ 31 ] }, "actions": [ { "type": "enqueue", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" }, "stage": { "type": "string" }, "status": { "type": "string" }, "targetName": { "type": "string" }, "expression": { "type": "string" }, "hashtags": { "type": "array", "items": { "type": "string" } }, "conditions": { "type": "array", "items": { "type": "object", "properties": { "assetId": { "type": "string" }, "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "string" }, "operator": { "type": "string" } }, "required": [ "assetId", "property", "symbol", "valueDataType", "value", "operator" ] } }, "devices": { "type": "array", "items": { "type": "string" } }, "period": { "type": "object", "properties": { "startTime": { "type": "object", "properties": {}, "required": [] }, "endTime": { "type": "object", "properties": {}, "required": [] }, "dayOfWeek": { "type": "array", "items": { "type": "string" } }, "dayOfMonth": { "type": "array", "items": { "type": "number" } } }, "required": [ "startTime", "endTime", "dayOfWeek", "dayOfMonth" ] }, "actions": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "parameters": { "type": "object", "properties": {}, "required": [] } }, "required": [ "type", "parameters" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "name", "description", "stage", "status", "targetName", "expression", "hashtags", "conditions", "devices", "period", "actions", "createdBy", "createdAtDateString", "createdAt" ], "description": "Data of the event rule." } }, "required": [ "data" ] }, "example": { "data": { "name": "IDT-EventRule", "description": "IDT-EventRule-Description", "stage": "IoTCore", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expression": "IoTCore-Expression", "hashtags": [ "Important" ], "conditions": [ { "assetId": "a-assetId", "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": "25", "operator": "AND" } ], "devices": [ "a-assetId" ], "period": { "startTime": { "hour": 20, "minute": 34 }, "endTime": { "hour": 21, "minute": 34 }, "dayOfWeek": [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], "dayOfMonth": [ 31 ] }, "actions": [ { "type": "enqueue", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Event Rules", "description": "List event rules", "operationId": "Workflows.ListEventRules", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "stage", "description": "The stage of event rule.", "in": "query", "schema": { "type": "string", "enum": [ "Edge", "IoTCore" ] }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "name": { "type": "string" }, "stage": { "type": "string" }, "status": { "type": "string" }, "targetName": { "type": "string" }, "expression": { "type": "string" }, "hashtags": { "type": "array", "items": { "type": "string" } }, "conditions": { "type": "array", "items": { "type": "object", "properties": { "assetId": { "type": "string" }, "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "string" }, "operator": { "type": "string" } }, "required": [ "assetId", "property", "symbol", "valueDataType", "value", "operator" ] } }, "devices": { "type": "array", "items": { "type": "string" } }, "actions": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "parameters": { "type": "object", "properties": {}, "required": [] } }, "required": [ "type", "parameters" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "name", "stage", "status", "targetName", "expression", "hashtags", "conditions", "devices", "actions", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "An array of event rule objects." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "er_eventRuleId", "organizationId": "o-organizationId", "name": "IDT-EventRule", "stage": "IoTCore", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expression": "IoTCore-Expression", "hashtags": [ "Important" ], "conditions": [ { "assetId": "a-assetId", "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": "25", "operator": "AND" } ], "devices": [ "a-assetId" ], "actions": [ { "type": "enqueue", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/event-schedules": { "post": { "summary": "Create Event Schedule", "description": "Create new event rule", "operationId": "Workflows.CreateEventSchedule", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of event schedule." }, "description": { "type": "string", "description": "The description of event schedule." }, "stage": { "type": "string", "description": "The stage of event schedule." }, "targetName": { "type": "string", "description": "The target name of event schedule, when stage is edge." }, "expressionType": { "type": "string", "description": "The expression type of event schedule." }, "oneTimeExpression": { "type": "number", "description": "The one-time expression of event schedule." }, "cronExpression": { "type": "object", "properties": {}, "required": [], "description": "The cron expression of event schedule." }, "rateExpression": { "type": "object", "properties": {}, "required": [], "description": "The rate expression of event schedule." }, "timezone": { "type": "number", "description": "The timezone of event schedule." }, "startDate": { "type": "number", "description": "The start date of event schedule." }, "endDate": { "type": "number", "description": "The end date of event schedule." }, "actions": { "type": "array", "items": { "type": "string" }, "description": "The actions of event schedule." }, "hashtags": { "type": "array", "items": { "type": "string" }, "description": "The hashtags of event rule." }, "status": { "type": "string", "description": "The status of event schedule." } }, "required": [ "name", "stage", "expressionType", "actions", "status" ] }, "example": { "name": "IDT-EventSchedule", "description": "IDT-EventSchedule-Description", "stage": "EventBridgeScheduler", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expressionType": "cron", "hashtags": [ "Important" ], "cronExpression": { "atHours": 11, "atMinutes": 47, "dayOfMonth": [ 7 ] }, "actions": [ { "type": "EnqueueDevice", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" }, "stage": { "type": "string" }, "status": { "type": "string" }, "targetName": { "type": "string" }, "expressionType": { "type": "string" }, "hashtags": { "type": "array", "items": { "type": "string" } }, "cronExpression": { "type": "object", "properties": { "atHours": { "type": "number" }, "atMinutes": { "type": "number" }, "dayOfMonth": { "type": "array", "items": { "type": "number" } } }, "required": [ "atHours", "atMinutes", "dayOfMonth" ] }, "actions": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "parameters": { "type": "object", "properties": { "name": { "type": "string" }, "assetId": { "type": "string" }, "confirmed": { "type": "boolean" }, "fPort": { "type": "number" }, "payload": { "type": "string" }, "payloadDataType": { "type": "string" } }, "required": [ "name", "assetId", "confirmed", "fPort", "payload", "payloadDataType" ] } }, "required": [ "type", "parameters" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "name", "description", "stage", "status", "targetName", "expressionType", "hashtags", "cronExpression", "actions", "createdBy", "createdAtDateString", "createdAt" ], "description": "Data of the event schedule." } }, "required": [ "data" ] }, "example": { "data": { "name": "IDT-EventSchedule", "description": "IDT-EventSchedule-Description", "stage": "EventBridgeScheduler", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expressionType": "cron", "hashtags": [ "Important" ], "cronExpression": { "atHours": 11, "atMinutes": 47, "dayOfMonth": [ 7 ] }, "actions": [ { "type": "EnqueueDevice", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Event Schedules", "description": "List event schedules", "operationId": "Workflows.ListEventSchedules", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "stage", "description": "The stage of event schedule.", "in": "query", "schema": { "type": "string", "enum": [ "Edge", "EventBridgeScheduler" ] }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" }, "stage": { "type": "string" }, "status": { "type": "string" }, "targetName": { "type": "string" }, "expressionType": { "type": "string" }, "hashtags": { "type": "array", "items": { "type": "string" } }, "cronExpression": { "type": "object", "properties": { "atHours": { "type": "number" }, "atMinutes": { "type": "number" }, "dayOfMonth": { "type": "array", "items": { "type": "number" } } }, "required": [ "atHours", "atMinutes", "dayOfMonth" ] }, "actions": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "parameters": { "type": "object", "properties": { "name": { "type": "string" }, "assetId": { "type": "string" }, "confirmed": { "type": "boolean" }, "fPort": { "type": "number" }, "payload": { "type": "string" }, "payloadDataType": { "type": "string" } }, "required": [ "name", "assetId", "confirmed", "fPort", "payload", "payloadDataType" ] } }, "required": [ "type", "parameters" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "name", "description", "stage", "status", "targetName", "expressionType", "hashtags", "cronExpression", "actions", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ] }, "description": "An array of event schedule objects." } }, "required": [ "data" ] }, "example": { "data": [ { "name": "IDT-EventSchedule", "description": "IDT-EventSchedule-Description", "stage": "EventBridgeScheduler", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expressionType": "cron", "hashtags": [ "Important" ], "cronExpression": { "atHours": 11, "atMinutes": 47, "dayOfMonth": [ 7 ] }, "actions": [ { "type": "EnqueueDevice", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/event-rules/{eventRuleId}": { "delete": { "summary": "Delete Event Rule", "description": "Delete event rule", "operationId": "Workflows.DeleteEventRule", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "eventRuleId", "description": "The ID of event rule.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the event rule." } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Event Rule", "description": "Get event rule", "operationId": "Workflows.GetEventRule", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "eventRuleId", "description": "The ID of event rule.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" }, "stage": { "type": "string" }, "status": { "type": "string" }, "targetName": { "type": "string" }, "expression": { "type": "string" }, "hashtags": { "type": "array", "items": { "type": "string" } }, "conditions": { "type": "array", "items": { "type": "object", "properties": { "assetId": { "type": "string" }, "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "string" }, "operator": { "type": "string" } }, "required": [ "assetId", "property", "symbol", "valueDataType", "value", "operator" ] } }, "devices": { "type": "array", "items": { "type": "string" } }, "period": { "type": "object", "properties": { "startTime": { "type": "object", "properties": {}, "required": [] }, "endTime": { "type": "object", "properties": {}, "required": [] }, "dayOfWeek": { "type": "array", "items": { "type": "string" } }, "dayOfMonth": { "type": "array", "items": { "type": "number" } } }, "required": [ "startTime", "endTime", "dayOfWeek", "dayOfMonth" ] }, "actions": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "parameters": { "type": "object", "properties": { "name": { "type": "string" }, "assetId": { "type": "string" }, "confirmed": { "type": "boolean" }, "fPort": { "type": "number" }, "payload": { "type": "string" }, "payloadDataType": { "type": "string" } }, "required": [ "name", "assetId", "confirmed", "fPort", "payload", "payloadDataType" ] } }, "required": [ "type", "parameters" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "name", "description", "stage", "status", "targetName", "expression", "hashtags", "conditions", "devices", "period", "actions", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the event rule." } }, "required": [ "data" ] }, "example": { "data": { "name": "IDT-EventRule", "description": "IDT-EventRule-Description", "stage": "IoTCore", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expression": "IoTCore-Expression", "hashtags": [ "Important" ], "conditions": [ { "assetId": "a-assetId", "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": "25", "operator": "AND" } ], "devices": [ "a-assetId" ], "period": { "startTime": { "hour": 20, "minute": 34 }, "endTime": { "hour": 21, "minute": 34 }, "dayOfWeek": [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], "dayOfMonth": [ 31 ] }, "actions": [ { "type": "enqueue", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Event Rule", "description": "Update event rule", "operationId": "Workflows.UpdateEventRule", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "eventRuleId", "description": "The ID of event rule.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of event rule." }, "description": { "type": "string", "description": "The description of event rule." }, "expression": { "type": "string", "description": "The expression of event rule." }, "conditions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The conditions of event rule." }, "devices": { "type": "array", "items": { "type": "string" }, "description": "The devices of event rule." }, "period": { "type": "object", "properties": {}, "required": [], "description": "The period of event rule." }, "actions": { "type": "array", "items": { "type": "object", "properties": {}, "required": [] }, "description": "The actions of event rule." }, "hashtags": { "type": "array", "items": { "type": "string" }, "description": "The hashtags of event rule." }, "status": { "type": "string", "description": "The status of event rule." } }, "required": [ "name", "period", "actions", "status" ] }, "example": { "name": "IDT-EventRule", "description": "IDT-EventRule-Description", "stage": "IoTCore", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expression": "IoTCore-Expression", "hashtags": [ "Important" ], "conditions": [ { "assetId": "a-assetId", "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": "25", "operator": "AND" } ], "devices": [ "a-assetId" ], "period": { "startTime": { "hour": 20, "minute": 34 }, "endTime": { "hour": 21, "minute": 34 }, "dayOfWeek": [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], "dayOfMonth": [ 31 ] }, "actions": [ { "type": "enqueue", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" }, "stage": { "type": "string" }, "status": { "type": "string" }, "targetName": { "type": "string" }, "expression": { "type": "string" }, "hashtags": { "type": "array", "items": { "type": "string" } }, "conditions": { "type": "array", "items": { "type": "object", "properties": { "assetId": { "type": "string" }, "property": { "type": "string" }, "symbol": { "type": "string" }, "valueDataType": { "type": "string" }, "value": { "type": "string" }, "operator": { "type": "string" } }, "required": [ "assetId", "property", "symbol", "valueDataType", "value", "operator" ] } }, "devices": { "type": "array", "items": { "type": "string" } }, "period": { "type": "object", "properties": { "startTime": { "type": "object", "properties": {}, "required": [] }, "endTime": { "type": "object", "properties": {}, "required": [] }, "dayOfWeek": { "type": "array", "items": { "type": "string" } }, "dayOfMonth": { "type": "array", "items": { "type": "number" } } }, "required": [ "startTime", "endTime", "dayOfWeek", "dayOfMonth" ] }, "actions": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "parameters": { "type": "object", "properties": { "name": { "type": "string" }, "assetId": { "type": "string" }, "confirmed": { "type": "boolean" }, "fPort": { "type": "number" }, "payload": { "type": "string" }, "payloadDataType": { "type": "string" } }, "required": [ "name", "assetId", "confirmed", "fPort", "payload", "payloadDataType" ] } }, "required": [ "type", "parameters" ] } }, "updatedBy": { "type": "string" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "name", "description", "stage", "status", "targetName", "expression", "hashtags", "conditions", "devices", "period", "actions", "updatedBy", "updatedAtDateString", "updatedAt" ], "description": "Data of the updated event rule." } }, "required": [ "data" ] }, "example": { "data": { "name": "IDT-EventRule", "description": "IDT-EventRule-Description", "stage": "IoTCore", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expression": "IoTCore-Expression", "hashtags": [ "Important" ], "conditions": [ { "assetId": "a-assetId", "property": "Temperature", "symbol": ">", "valueDataType": "integer", "value": "25", "operator": "AND" } ], "devices": [ "a-assetId" ], "period": { "startTime": { "hour": 20, "minute": 34 }, "endTime": { "hour": 21, "minute": 34 }, "dayOfWeek": [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], "dayOfMonth": [ 31 ] }, "actions": [ { "type": "enqueue", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ], "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/event-schedules/{eventScheduleId}": { "delete": { "summary": "Delete Event Schedule", "description": "Delete event schedule", "operationId": "Workflows.DeleteEventSchedule", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "eventScheduleId", "description": "The ID of event schedule.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the event schedule." } }, "required": [ "data" ] }, "example": { "data": { "deleted": true } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Event Schedule", "description": "Get event schedule", "operationId": "Workflows.GetEventSchedule", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "eventScheduleId", "description": "The ID of event schedule.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" }, "stage": { "type": "string" }, "status": { "type": "string" }, "targetName": { "type": "string" }, "expressionType": { "type": "string" }, "hashtags": { "type": "array", "items": { "type": "string" } }, "cronExpression": { "type": "object", "properties": { "atHours": { "type": "number" }, "atMinutes": { "type": "number" }, "dayOfMonth": { "type": "array", "items": { "type": "number" } } }, "required": [ "atHours", "atMinutes", "dayOfMonth" ] }, "actions": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "parameters": { "type": "object", "properties": { "name": { "type": "string" }, "assetId": { "type": "string" }, "confirmed": { "type": "boolean" }, "fPort": { "type": "number" }, "payload": { "type": "string" }, "payloadDataType": { "type": "string" } }, "required": [ "name", "assetId", "confirmed", "fPort", "payload", "payloadDataType" ] } }, "required": [ "type", "parameters" ] } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "name", "description", "stage", "status", "targetName", "expressionType", "hashtags", "cronExpression", "actions", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the event schedule." } }, "required": [ "data" ] }, "example": { "data": { "name": "IDT-EventSchedule", "description": "IDT-EventSchedule-Description", "stage": "EventBridgeScheduler", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expressionType": "cron", "hashtags": [ "Important" ], "cronExpression": { "atHours": 11, "atMinutes": 47, "dayOfMonth": [ 7 ] }, "actions": [ { "type": "EnqueueDevice", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Event Schedule", "description": "Update event schedule", "operationId": "Workflows.UpdateEventSchedule", "tags": [ "Workflows" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "eventScheduleId", "description": "The ID of event schedule.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of event schedule." }, "description": { "type": "string", "description": "The description of event schedule." }, "expressionType": { "type": "string", "description": "The expression type of event schedule." }, "oneTimeExpression": { "type": "number", "description": "The one-time expression of event schedule." }, "cronExpression": { "type": "object", "properties": {}, "required": [], "description": "The cron expression of event schedule." }, "rateExpression": { "type": "object", "properties": {}, "required": [], "description": "The rate expression of event schedule." }, "timezone": { "type": "number", "description": "The timezone of event schedule." }, "startDate": { "type": "number", "description": "The start date of event schedule." }, "endDate": { "type": "number", "description": "The end date of event schedule." }, "actions": { "type": "array", "items": { "type": "string" }, "description": "The actions of event schedule." }, "hashtags": { "type": "array", "items": { "type": "string" }, "description": "The hashtags of event schedule." }, "status": { "type": "string", "description": "The status of event schedule." } }, "required": [ "expressionType", "actions", "status" ] }, "example": { "name": "IDT-EventSchedule", "description": "IDT-EventSchedule-Description", "stage": "EventBridgeScheduler", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expressionType": "cron", "hashtags": [ "Important" ], "cronExpression": { "atHours": 11, "atMinutes": 47, "dayOfMonth": [ 7 ] }, "actions": [ { "type": "EnqueueDevice", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "name": { "type": "string" }, "description": { "type": "string" }, "stage": { "type": "string" }, "status": { "type": "string" }, "targetName": { "type": "string" }, "expressionType": { "type": "string" }, "hashtags": { "type": "array", "items": { "type": "string" } }, "cronExpression": { "type": "object", "properties": { "atHours": { "type": "number" }, "atMinutes": { "type": "number" }, "dayOfMonth": { "type": "array", "items": { "type": "number" } } }, "required": [ "atHours", "atMinutes", "dayOfMonth" ] }, "actions": { "type": "array", "items": { "type": "object", "properties": { "type": { "type": "string" }, "parameters": { "type": "object", "properties": { "name": { "type": "string" }, "assetId": { "type": "string" }, "confirmed": { "type": "boolean" }, "fPort": { "type": "number" }, "payload": { "type": "string" }, "payloadDataType": { "type": "string" } }, "required": [ "name", "assetId", "confirmed", "fPort", "payload", "payloadDataType" ] } }, "required": [ "type", "parameters" ] } }, "updatedBy": { "type": "string" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "name", "description", "stage", "status", "targetName", "expressionType", "hashtags", "cronExpression", "actions", "updatedBy", "updatedAtDateString", "updatedAt" ], "description": "Data of the updated event schedule." } }, "required": [ "data" ] }, "example": { "data": { "name": "IDT-EventSchedule", "description": "IDT-EventSchedule-Description", "stage": "EventBridgeScheduler", "status": "Enabled", "targetName": "IoTCore-Target-Name", "expressionType": "cron", "hashtags": [ "Important" ], "cronExpression": { "atHours": 11, "atMinutes": 47, "dayOfMonth": [ 7 ] }, "actions": [ { "type": "EnqueueDevice", "parameters": { "name": "Power Off", "assetId": "a-assetId", "confirmed": true, "fPort": 85, "payload": "080000ff", "payloadDataType": "string" } } ], "updatedBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-requests/{workRequestId}/accept": { "put": { "summary": "Accept Work Request", "description": "Accept work request to order", "operationId": "Works.AcceptWorkRequest", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workRequestId", "description": "The ID of work request.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetIds": { "type": "array", "items": { "type": "string" } }, "locationId": { "type": "string" }, "isTemplate": { "type": "boolean" }, "subject": { "type": "string" }, "description": { "type": "string" }, "workflowId": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "priority": { "type": "string" }, "reason": { "type": "string" }, "status": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetIds", "locationId", "isTemplate", "subject", "description", "workflowId", "images", "priority", "reason", "status", "createdAtDateString", "createdAt" ], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": { "id": "wr-workRequestId", "organizationId": "o-organizationId", "assetIds": [ "a-24e124535b312345" ], "locationId": "l-locationId", "isTemplate": false, "subject": "Accept Work Request", "description": "", "workflowId": "er_eventRuleId", "images": [], "priority": "None", "reason": "test", "status": "Accept", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-requests/{workRequestId}/cancel": { "put": { "summary": "Cancel Work Request", "description": "Cancel work request", "operationId": "Works.CancelWorkRequest", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workRequestId", "description": "The ID of work request.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetIds": { "type": "array", "items": { "type": "string" } }, "locationId": { "type": "string" }, "isTemplate": { "type": "boolean" }, "subject": { "type": "string" }, "description": { "type": "string" }, "workflowId": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "priority": { "type": "string" }, "reason": { "type": "string" }, "status": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetIds", "locationId", "isTemplate", "subject", "description", "workflowId", "images", "priority", "reason", "status", "createdAtDateString", "createdAt" ], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": { "id": "wr-workRequestId", "organizationId": "o-organizationId", "assetIds": [ "a-24e124535b312345" ], "locationId": "l-locationId", "isTemplate": false, "subject": "Work Request", "description": "Cancel Wokr Request", "workflowId": "er_eventRuleId", "images": [], "priority": "None", "reason": "test", "status": "Cancel", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-orders": { "post": { "summary": "Create Work Order", "description": "Create work order", "operationId": "Works.CreateWorkOrder", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "type": { "type": "string", "description": "The type of work order(Normal, Template)." }, "subject": { "type": "string", "description": "The subject of work order." }, "description": { "type": "string", "description": "The description of work order." }, "expiredAt": { "type": "number", "description": "The expired time of work order(Must be a multiple of 15 minutes)." }, "workTime": { "type": "number", "description": "The workTime of work order, when type is template." }, "scheduleType": { "type": "string", "description": "The schedule type of work order." }, "daysOfWeek": { "type": "array", "items": { "type": "boolean" }, "description": "Days of week, ex: [false, true, false, false, false, true, false] is monday and friday of week." }, "everyWeeks": { "type": "number", "description": "How many weeks interval, ex: 1 is every week, 2 is interval of one week." }, "dayOfMonth": { "type": "number", "description": "Day of month, ex: 22 is 22th day of every month." }, "everyMonths": { "type": "number", "description": "How many months interval, ex: 1 is every month, 2 is interval of one month(1/22, 3/22, 5/22 etc...)." }, "everyYears": { "type": "number", "description": "How many years interval, ex: 1 is every year, 2 is interval of one year(2023/01/22, 2025/01/22, 2027/01/22 etc...)." }, "aheadOfTime": { "type": "number", "description": "Ahead of time(seconds) to available in the list." }, "assignee": { "type": "object", "properties": {}, "required": [], "description": "The assignee of work order." }, "priority": { "type": "string", "description": "The priority of work order." }, "workRequestId": { "type": "string", "description": "The ID of work request." }, "locationId": { "type": "string", "description": "The location ID of work order." }, "procedures": { "type": "string", "description": "The procedures of work order." }, "images": { "type": "array", "items": { "type": "string" }, "description": "The images of work order." }, "files": { "type": "array", "items": { "type": "string" }, "description": "The files of work order." }, "partIds": { "type": "array", "items": { "type": "string" }, "description": "The ID list of part." }, "assetIds": { "type": "array", "items": { "type": "string" }, "description": "The ID list of asset." }, "enableNotify": { "type": "boolean", "description": "Enable/Disable notification." }, "timeTrackingType": { "type": "string", "description": "The time tracking type for the status update (manual, automatic)." } }, "required": [ "type", "subject", "expiredAt", "priority", "timeTrackingType" ] }, "example": { "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "locationId": "l-locationId", "type": "Normal", "priority": "Low", "scheduleType": "Daily", "aheadOfTime": 3600, "enableNotify": true, "files": [ "Infodeck-Bot-0001.pdf" ], "images": [ "Asset-Image.png" ], "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "expiredAt": 1704067200000, "timeTrackingType": "automatic" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "type": { "type": "string" }, "subject": { "type": "string" }, "description": { "type": "string" }, "expiredAt": { "type": "string" }, "workTime": { "type": "number" }, "scheduleType": { "type": "string" }, "daysOfWeek": { "type": "array", "items": { "type": "boolean" } }, "everyWeeks": { "type": "number" }, "dayOfMonth": { "type": "number" }, "everyMonths": { "type": "number" }, "everyYears": { "type": "number" }, "locationId": { "type": "string" }, "aheadOfTime": { "type": "number" }, "assignee": { "type": "object", "properties": {}, "required": [] }, "priority": { "type": "string" }, "workRequestId": { "type": "string" }, "procedures": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "partIds": { "type": "array", "items": { "type": "string" } }, "assetIds": { "type": "array", "items": { "type": "string" } }, "enableNotify": { "type": "boolean" }, "status": { "type": "string" }, "timeTrackingType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "type", "subject", "description", "expiredAt", "workTime", "scheduleType", "daysOfWeek", "everyWeeks", "dayOfMonth", "everyMonths", "everyYears", "locationId", "aheadOfTime", "assignee", "priority", "workRequestId", "procedures", "images", "files", "partIds", "assetIds", "enableNotify", "status", "timeTrackingType", "createdBy", "createdAtDateString", "createdAt" ], "description": "Data of the work order." } }, "required": [ "data" ] }, "example": { "data": { "id": "o-organizationId-wo-workOrderId", "organizationId": "o-organizationId", "type": "Normal", "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "expiredAt": "2024-02-01T00:00:00.000Z", "workTime": 3600000, "scheduleType": "Daily", "daysOfWeek": "", "everyWeeks": "", "dayOfMonth": "", "everyMonths": "", "everyYears": "", "locationId": "l-locationId", "aheadOfTime": 3600, "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "priority": "Low", "workRequestId": "wr-workRequestId", "procedures": [], "images": [ "Asset-Image.png" ], "files": [ "Infodeck-Bot-0001.pdf" ], "partIds": [], "assetIds": [], "enableNotify": false, "status": "Open", "timeTrackingType": "automatic", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Work Orders", "description": "List work orders", "operationId": "Works.ListWorkOrders", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "type", "description": "The type of work order.", "in": "query", "schema": { "type": "string", "enum": [ "Normal", "Template" ] }, "required": true }, { "name": "assetId", "description": "The Id of asset.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "startDate", "description": "The start date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "endDate", "description": "The end date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string" }, "subject": { "type": "string" }, "description": { "type": "string" }, "expiredAt": { "type": "string" }, "workTime": { "type": "number" }, "scheduleType": { "type": "string" }, "daysOfWeek": { "type": "array", "items": { "type": "boolean" } }, "everyWeeks": { "type": "number" }, "dayOfMonth": { "type": "number" }, "everyMonths": { "type": "number" }, "everyYears": { "type": "number" }, "aheadOfTime": { "type": "number" }, "assignee": { "type": "object", "properties": {}, "required": [] }, "priority": { "type": "string" }, "workRequestId": { "type": "string" }, "locationId": { "type": "string" }, "procedures": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "partIds": { "type": "array", "items": { "type": "string" } }, "assetIds": { "type": "array", "items": { "type": "string" } }, "enableNotify": { "type": "boolean" }, "status": { "type": "string" }, "timeTrackingType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "type", "subject", "description", "expiredAt", "workTime", "scheduleType", "daysOfWeek", "everyWeeks", "dayOfMonth", "everyMonths", "everyYears", "aheadOfTime", "assignee", "priority", "workRequestId", "locationId", "procedures", "images", "files", "partIds", "assetIds", "enableNotify", "status", "timeTrackingType", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work order." }, "nextToken": { "description": "To retrieve the next set of results." } }, "required": [ "data", "nextToken" ] }, "example": { "data": [ { "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "locationId": "l-locationId", "type": "Normal", "priority": "Low", "scheduleType": "Daily", "aheadOfTime": 3600, "enableNotify": true, "files": [ "Infodeck-Bot-0001.pdf" ], "images": [ "Asset-Image.png" ], "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "expiredAt": "2024-02-01T00:00:00.000Z", "status": "Open", "timeTrackingType": "automatic", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-orders/{workOrderId}/statuses": { "post": { "summary": "Update Work Order Statuses", "description": "Update Work Order Statuses", "operationId": "Works.UpdateWorkOrderStatuses", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workOrderId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "originalStartDate": { "type": "number", "description": "The original start date in milliseconds since epoch." }, "originalEndDate": { "type": "number", "description": "The original end date in milliseconds since epoch." }, "startDate": { "type": "number", "description": "The start date in milliseconds since epoch." }, "endDate": { "type": "number", "description": "The end date in milliseconds since epoch." }, "status": { "type": "string", "description": "The status of the work order (OnHold, InProgress, Completed)." }, "triggerType": { "type": "string", "description": "The trigger type for the status update (manual, automatic)." } }, "required": [ "originalStartDate", "originalEndDate", "startDate", "endDate", "status", "triggerType" ] }, "example": { "originalStartDate": "1704067200000", "originalEndDate": "1706659200000", "startDate": "1704067200000", "endDate": "1706659200000", "status": "OnHold", "triggerType": "manual" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "workOrderId": { "type": "string" }, "organizationId": { "type": "string" }, "manualId": { "type": "string" }, "status": { "type": "string" }, "triggerType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "workOrderId", "organizationId", "manualId", "status", "triggerType", "createdBy", "createdAtDateString", "createdAt" ] }, "description": "Data of the work order." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "wo-workOrderId", "workOrderId": "wo-workOrderId", "organizationId": "o-organizationId", "manualId": "uuid", "status": "InProgress", "triggerType": "manual", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 }, { "id": "wo-workOrderId", "workOrderId": "wo-workOrderId", "organizationId": "o-organizationId", "manualId": "uuid", "status": "OnHold", "triggerType": "manual", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "delete": { "summary": "Delete Work Order Statuses", "description": "Delete work order statuses", "operationId": "Works.DeleteWorkOrderStatuses", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workOrderId", "description": "The ID of work order.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date in milliseconds since epoch.", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "endDate", "description": "The end date in milliseconds since epoch.", "in": "query", "schema": { "type": "number" }, "required": true } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the work order statuses." } }, "required": [ "data" ] }, "example": { "data": {} }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Work Order Statuses", "description": "List work order statuses", "operationId": "Works.ListWorkOrderStatuses", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workOrderId", "description": "The Id of work order.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "triggerType", "description": "The trigger type for the status update (manual, automatic).", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number", "minimum": 10, "maximum": 100 }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "workOrderId": { "type": "string" }, "organizationId": { "type": "string" }, "status": { "type": "string" }, "manualId": { "type": "string" }, "triggerType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "workOrderId", "organizationId", "status", "manualId", "triggerType", "createdBy", "createdAtDateString", "createdAt" ] }, "description": "Array of work order statuses." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "wo-workOrderId", "workOrderId": "wo-workOrderId", "organizationId": "o-organizationId", "status": "Inprogress", "manualId": "uuid", "triggerType": "manual", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-requests": { "post": { "summary": "Create Work Request", "description": "Create work request", "operationId": "Works.CreateWorkRequest", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "isTemplate": { "type": "boolean", "description": "The work request is template." }, "subject": { "type": "string", "description": "The subject of work request." }, "description": { "type": "string", "description": "The description of work request." }, "locationId": { "type": "string", "description": "The location ID of work order." }, "images": { "type": "array", "items": { "type": "string" }, "description": "The images of work request." }, "files": { "type": "array", "items": { "type": "string" }, "description": "The files of work request." }, "assetId": { "type": "array", "items": { "type": "string" }, "description": "The assetId of work request." }, "priority": { "type": "string", "description": "The priority of work order." } }, "required": [ "subject", "priority" ] }, "example": { "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "locationId": "l-locationId", "priority": "Medium", "isTemplate": false, "assetIds": [ "a-assetId" ], "images": [ "Asset-Image.png" ], "files": [ "Infodeck-Bot-0001.pdf" ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "isTemplate": { "type": "boolean" }, "subject": { "type": "string" }, "description": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "assetIds": { "type": "array", "items": { "type": "string" } }, "reason": { "type": "string" }, "status": { "type": "string" }, "priority": { "type": "string" }, "locationId": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "isTemplate", "subject", "description", "images", "assetIds", "reason", "status", "priority", "locationId", "createdBy", "createdAtDateString", "createdAt" ], "description": "Data of the newly created work request." } }, "required": [ "data" ] }, "example": { "data": { "id": "wr-workOrderId", "organizationId": "o-organizationId", "isTemplate": false, "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "images": [ "Asset-Image.png" ], "assetIds": [ "a-assetId" ], "reason": "reason", "status": "Pending", "priority": "Medium", "locationId": "l-locationId", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "List Work Requests", "description": "List work requests", "operationId": "Works.ListWorkRequests", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "isTemplate", "description": "Retuen templates of work request.", "in": "query", "schema": { "type": "string", "enum": [ "true", "false" ] }, "required": false }, { "name": "assetId", "description": "The Id of asset.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "startDate", "description": "The start date number of query.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "endDate", "description": "The end date number of query.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "reason": { "type": "string", "description": "The reason of reject work request." } }, "required": [ "reason" ] }, "example": {}, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetIds": { "type": "string" }, "locationId": { "type": "string" }, "workflowId": {}, "subject": { "type": "string" }, "description": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "isTemplate": { "type": "boolean" }, "reason": { "type": "string" }, "status": { "type": "string" }, "priority": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetIds", "locationId", "workflowId", "subject", "description", "images", "isTemplate", "reason", "status", "priority", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "wr-workRequestId", "organizationId": "o-organizationId", "assetIds": "a-assetId", "locationId": "l-locationId", "workflowId": "er_eventRuleId", "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "images": [ "Asset-Image.png" ], "isTemplate": false, "reason": "test", "status": "Reject", "priority": "Medium", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-orders/{workOrderId}": { "delete": { "summary": "Delete Work Order", "description": "Delete work order", "operationId": "Works.DeleteWorkOrder", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workOrderId", "description": "The ID of work order.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the work order." } }, "required": [ "data" ] }, "example": { "data": {} }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Work Order", "description": "Get work order", "operationId": "Works.GetWorkOrder", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workOrderId", "description": "The ID of work order.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string" }, "subject": { "type": "string" }, "description": { "type": "string" }, "expiredAt": { "type": "string" }, "workTime": { "type": "number" }, "scheduleType": { "type": "string" }, "daysOfWeek": { "type": "array", "items": { "type": "boolean" } }, "everyWeeks": { "type": "number" }, "dayOfMonth": { "type": "number" }, "everyMonths": { "type": "number" }, "everyYears": { "type": "number" }, "aheadOfTime": { "type": "number" }, "assignee": { "type": "object", "properties": {}, "required": [] }, "priority": { "type": "string" }, "workRequestId": { "type": "string" }, "locationId": { "type": "string" }, "procedures": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "partIds": { "type": "array", "items": { "type": "string" } }, "assetIds": { "type": "array", "items": { "type": "string" } }, "enableNotify": { "type": "boolean" }, "status": { "type": "string" }, "timeTrackingType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "type", "subject", "description", "expiredAt", "workTime", "scheduleType", "daysOfWeek", "everyWeeks", "dayOfMonth", "everyMonths", "everyYears", "aheadOfTime", "assignee", "priority", "workRequestId", "locationId", "procedures", "images", "files", "partIds", "assetIds", "enableNotify", "status", "timeTrackingType", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work order." } }, "required": [ "data" ] }, "example": { "data": { "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "locationId": "l-locationId", "type": "Normal", "priority": "Low", "scheduleType": "Daily", "aheadOfTime": 3600, "enableNotify": true, "files": [ "Infodeck-Bot-0001.pdf" ], "images": [ "Asset-Image.png" ], "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "expiredAt": "2024-02-01T00:00:00.000Z", "status": "Open", "timeTrackingType": "automatic", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Work Order", "description": "Update work order", "operationId": "Works.UpdateWorkOrder", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workOrderId", "description": "The ID of work order.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "subject": { "type": "string", "description": "The subject of work order." }, "description": { "type": "string", "description": "The description of work order." }, "expiredAt": { "type": "number", "description": "The expired time of work order." }, "workTime": { "type": "number", "description": "The workTime of work order, when type is template." }, "scheduleType": { "type": "string", "description": "The schedule type of work order." }, "daysOfWeek": { "type": "array", "items": { "type": "boolean" }, "description": "Days of week, ex: [false, true, false, false, false, true, false] is monday and friday of week." }, "everyWeeks": { "type": "number", "description": "How many weeks interval, ex: 1 is every week, 2 is interval of one week." }, "dayOfMonth": { "type": "number", "description": "Day of month, ex: 22 is 22th day of every month." }, "everyMonths": { "type": "number", "description": "How many months interval, ex: 1 is every month, 2 is interval of one month(1/22, 3/22, 5/22 etc...)." }, "everyYears": { "type": "number", "description": "How many years interval, ex: 1 is every year, 2 is interval of one year(2023/01/22, 2025/01/22, 2027/01/22 etc...)." }, "aheadOfTime": { "type": "number", "description": "Ahead of time(seconds) to available in the list." }, "assignee": { "type": "object", "properties": {}, "required": [], "description": "The assignee of work order." }, "priority": { "type": "string", "description": "The priority of work order." }, "workRequestId": { "type": "string", "description": "The ID of work request." }, "locationId": { "type": "string", "description": "The location ID of work order." }, "procedures": { "type": "string", "description": "The procedures of work order." }, "images": { "type": "array", "items": { "type": "string" }, "description": "The images of work order." }, "files": { "type": "array", "items": { "type": "string" }, "description": "The files of work order." }, "partIds": { "type": "array", "items": { "type": "string" }, "description": "The ID list of part." }, "assetIds": { "type": "array", "items": { "type": "string" }, "description": "The ID list of asset." }, "enableNotify": { "type": "boolean", "description": "Enable/Disable notification." } }, "required": [] }, "example": { "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "locationId": "l-locationId", "type": "Normal", "priority": "Low", "scheduleType": "Daily", "aheadOfTime": 3600, "enableNotify": true, "files": [ "Infodeck-Bot-0001.pdf" ], "images": [ "Asset-Image.png" ], "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "expiredAt": 1704067200000 }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string" }, "subject": { "type": "string" }, "description": { "type": "string" }, "expiredAt": { "type": "string" }, "workTime": { "type": "number" }, "scheduleType": { "type": "string" }, "daysOfWeek": { "type": "array", "items": { "type": "boolean" } }, "everyWeeks": { "type": "number" }, "dayOfMonth": { "type": "number" }, "everyMonths": { "type": "number" }, "everyYears": { "type": "number" }, "aheadOfTime": { "type": "number" }, "assignee": { "type": "object", "properties": {}, "required": [] }, "priority": { "type": "string" }, "workRequestId": { "type": "string" }, "locationId": { "type": "string" }, "procedures": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "partIds": { "type": "array", "items": { "type": "string" } }, "assetIds": { "type": "array", "items": { "type": "string" } }, "enableNotify": { "type": "boolean" }, "status": { "type": "string" }, "timeTrackingType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "number" }, "createdAt": { "type": "number" } }, "required": [ "type", "subject", "expiredAt", "priority", "status", "timeTrackingType", "createdBy", "createdAtDateString", "createdAt" ], "description": "Data of the work order." } }, "required": [ "data" ] }, "example": { "data": { "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "locationId": "l-locationId", "type": "Normal", "priority": "Low", "scheduleType": "Daily", "aheadOfTime": 3600, "enableNotify": true, "files": [ "Infodeck-Bot-0001.pdf" ], "images": [ "Asset-Image.png" ], "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "expiredAt": "2024-02-01T00:00:00.000Z", "status": "Open", "timeTrackingType": "automatic", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-requests/{workRequestId}": { "delete": { "summary": "Delete Work Request", "description": "Delete work request", "operationId": "Works.DeleteWorkRequest", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workRequestId", "description": "The ID of work request.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": {}, "required": [], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": {} }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "get": { "summary": "Get Work Request", "description": "Get work request", "operationId": "Works.GetWorkRequest", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workRequestId", "description": "The ID of work request.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "subject": { "type": "string" }, "description": { "type": "string" }, "locationId": { "type": "string" }, "priority": { "type": "string" }, "isTemplate": { "type": "boolean" }, "assetIds": { "type": "array", "items": { "type": "string" } }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "subject", "description", "locationId", "priority", "isTemplate", "assetIds", "images", "files", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": { "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "locationId": "l-locationId", "priority": "Medium", "isTemplate": false, "assetIds": [ "a-assetId" ], "images": [ "Asset-Image.png" ], "files": [ "Infodeck-Bot-0001.pdf" ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] }, "put": { "summary": "Update Work Request", "description": "Update work request", "operationId": "Works.UpdateWorkRequest", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workRequestId", "description": "The ID of work request.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "isTemplate": { "type": "boolean", "description": "The work request is template." }, "subject": { "type": "string", "description": "The subject of work request." }, "description": { "type": "string", "description": "The description of work request." }, "locationId": { "type": "string", "description": "The location ID of work order." }, "images": { "type": "array", "items": { "type": "string" }, "description": "The images of work request." }, "priority": { "type": "string", "description": "The priority of work order." } }, "required": [] }, "example": { "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "locationId": "l-locationId", "priority": "Medium", "isTemplate": false, "images": [ "Asset-Image.png" ] }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "subject": { "type": "string" }, "description": { "type": "string" }, "locationId": { "type": "string" }, "priority": { "type": "string" }, "isTemplate": { "type": "boolean" }, "assetIds": { "type": "array", "items": { "type": "string" } }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "string" } }, "required": [ "subject", "description", "locationId", "priority", "isTemplate", "assetIds", "images", "files", "createdBy", "createdAtDateString", "createdAt" ], "description": "Data of the updated work request." } }, "required": [ "data" ] }, "example": { "data": { "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "locationId": "l-locationId", "priority": "Medium", "isTemplate": false, "assetIds": [ "a-assetId" ], "images": [ "Asset-Image.png" ], "files": [ "Infodeck-Bot-0001.pdf" ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/users/{userId}/work-orders/all": { "get": { "summary": "Get Work Orders By User", "description": "Get work orders by user", "operationId": "Works.GetWorkOrdersByUser", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "endDate", "description": "The end date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "filterStatus", "description": "The status of work order. (Default: optional ; Options: Open, Accept, InProgress, OnHold, Complete, Close)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string" }, "subject": { "type": "string" }, "description": { "type": "string" }, "expiredAt": { "type": "string" }, "workTime": { "type": "number" }, "scheduleType": { "type": "string" }, "daysOfWeek": { "type": "array", "items": { "type": "boolean" } }, "everyWeeks": { "type": "number" }, "dayOfMonth": { "type": "number" }, "everyMonths": { "type": "number" }, "everyYears": { "type": "number" }, "aheadOfTime": { "type": "number" }, "assignee": { "type": "object", "properties": {}, "required": [] }, "priority": { "type": "string" }, "workRequestId": { "type": "string" }, "locationId": { "type": "string" }, "procedures": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "partIds": { "type": "array", "items": { "type": "string" } }, "assetIds": { "type": "array", "items": { "type": "string" } }, "enableNotify": { "type": "boolean" }, "status": { "type": "string" }, "timeTrackingType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "type", "subject", "description", "expiredAt", "workTime", "scheduleType", "daysOfWeek", "everyWeeks", "dayOfMonth", "everyMonths", "everyYears", "aheadOfTime", "assignee", "priority", "workRequestId", "locationId", "procedures", "images", "files", "partIds", "assetIds", "enableNotify", "status", "timeTrackingType", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work order." } }, "required": [ "data" ] }, "example": { "data": { "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "locationId": "l-locationId", "type": "Normal", "priority": "Low", "scheduleType": "Daily", "aheadOfTime": 3600, "enableNotify": true, "files": [ "Infodeck-Bot-0001.pdf" ], "images": [ "Asset-Image.png" ], "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "expiredAt": "2024-02-01T00:00:00.000Z", "status": "Open", "timeTrackingType": "automatic", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/users/{userId}/work-requests/all": { "get": { "summary": "Get Work Requests By User", "description": "Get work requests by user", "operationId": "Works.GetWorkRequestsByUser", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of timestamp", "in": "query", "schema": { "type": "string" }, "required": true }, { "name": "endDate", "description": "The end date number of timestamp", "in": "query", "schema": { "type": "string" }, "required": true } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "subject": { "type": "string" }, "description": { "type": "string" }, "locationId": { "type": "string" }, "priority": { "type": "string" }, "isTemplate": { "type": "boolean" }, "assetIds": { "type": "array", "items": { "type": "string" } }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "subject", "description", "locationId", "priority", "isTemplate", "assetIds", "images", "files", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": { "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "locationId": "l-locationId", "priority": "Medium", "isTemplate": false, "assetIds": [ "a-assetId" ], "images": [ "Asset-Image.png" ], "files": [ "Infodeck-Bot-0001.pdf" ], "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/locations/{locationId}/work-orders": { "get": { "summary": "List Work Orders By Location Id", "description": "List Work Orders By Location Id", "operationId": "Works.ListWorkOrdersByLocationId", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "locationId", "description": "The ID of location.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "endDate", "description": "The end date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "statuses", "description": "The status of work order. (Default: optional ; Options: Open, Accept, InProgress, OnHold, Complete, Close)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false }, { "name": "priorities", "description": "The status of work order. (Default: optional ; Options: Low, Medium, High, None)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "workOrderId": { "type": "string" }, "workRequestId": { "type": "string" }, "organizationId": { "type": "string" }, "locationId": { "type": "string" }, "subject": { "type": "string" }, "description": { "type": "string" }, "type": { "type": "string" }, "priority": { "type": "string" }, "scheduleType": { "type": "string" }, "assignee": { "type": "object", "properties": {}, "required": [] }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "status": { "type": "string" }, "timeTrackingType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "workOrderId", "workRequestId", "organizationId", "locationId", "subject", "description", "type", "priority", "scheduleType", "assignee", "images", "files", "status", "timeTrackingType", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work order." }, "nextToken": { "description": "To retrieve the next set of results." } }, "required": [ "data", "nextToken" ] }, "example": { "data": [ { "workOrderId": "wo-workOrderId", "workRequestId": "wr-workRequestId", "organizationId": "o-organizationId", "locationId": "l-locationId", "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "type": "Normal", "priority": "Low", "scheduleType": "Daily", "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "images": [ "Asset-Image.png" ], "files": [ "Infodeck-Bot-0001.pdf" ], "status": "Open", "timeTrackingType": "automatic", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/users/{userId}/work-orders": { "get": { "summary": "List Work Orders By User", "description": "List work orders by user", "operationId": "Works.ListWorkOrdersByUser", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "teamId", "description": "The id of team.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false }, { "name": "filterStatus", "description": "The status of work order. (Default: optional ; Options: Open, Accept, InProgress, OnHold, Complete, Close)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "type": "string" }, "subject": { "type": "string" }, "description": { "type": "string" }, "expiredAt": { "type": "string" }, "workTime": { "type": "number" }, "scheduleType": { "type": "string" }, "daysOfWeek": { "type": "array", "items": { "type": "boolean" } }, "everyWeeks": { "type": "number" }, "dayOfMonth": { "type": "number" }, "everyMonths": { "type": "number" }, "everyYears": { "type": "number" }, "aheadOfTime": { "type": "number" }, "assignee": { "type": "object", "properties": {}, "required": [] }, "priority": { "type": "string" }, "workRequestId": { "type": "string" }, "locationId": { "type": "string" }, "procedures": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "files": { "type": "array", "items": { "type": "string" } }, "partIds": { "type": "array", "items": { "type": "string" } }, "assetIds": { "type": "array", "items": { "type": "string" } }, "enableNotify": { "type": "boolean" }, "status": { "type": "string" }, "timeTrackingType": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "type", "subject", "description", "expiredAt", "workTime", "scheduleType", "daysOfWeek", "everyWeeks", "dayOfMonth", "everyMonths", "everyYears", "aheadOfTime", "assignee", "priority", "workRequestId", "locationId", "procedures", "images", "files", "partIds", "assetIds", "enableNotify", "status", "timeTrackingType", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work order." }, "nextToken": { "description": "To retrieve the next set of results." } }, "required": [ "data", "nextToken" ] }, "example": { "data": [ { "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "locationId": "l-locationId", "type": "Normal", "priority": "Low", "scheduleType": "Daily", "aheadOfTime": 3600, "enableNotify": true, "files": [ "Infodeck-Bot-0001.pdf" ], "images": [ "Asset-Image.png" ], "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "expiredAt": "2024-02-01T00:00:00.000Z", "status": "Open", "timeTrackingType": "automatic", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/locations/{locationId}/work-requests": { "get": { "summary": "List Work Requests By Location Id", "description": "List Work Requests By Location Id", "operationId": "Works.ListWorkRequestsByLocationId", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "locationId", "description": "The ID of location.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "startDate", "description": "The start date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "endDate", "description": "The end date number of timestamp. (Default: 1700000000000)", "in": "query", "schema": { "type": "number" }, "required": true }, { "name": "statuses", "description": "The status of work request. (Default: optional ; Options: Pending, Accept, InProgress, Done, Reject, Cancel)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false }, { "name": "priorities", "description": "The status of work request. (Default: optional ; Options: Low, Medium, High, None)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetIds": { "type": "string" }, "locationId": { "type": "string" }, "workflowId": {}, "subject": { "type": "string" }, "description": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "isTemplate": { "type": "boolean" }, "reason": { "type": "string" }, "status": { "type": "string" }, "priority": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetIds", "locationId", "workflowId", "subject", "description", "images", "isTemplate", "reason", "status", "priority", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "wr-workRequestId", "organizationId": "o-organizationId", "assetIds": "a-assetId", "locationId": "l-locationId", "workflowId": "er_eventRuleId", "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "images": [ "Asset-Image.png" ], "isTemplate": false, "reason": "test", "status": "Reject", "priority": "Medium", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/users/{userId}/work-requests": { "get": { "summary": "List Work Requests By User", "description": "List work requests by user", "operationId": "Works.ListWorkRequestsByUser", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "userId", "description": "The ID of user.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "filterStatus", "description": "The status of work order. (Default: optional ; Options: Open, Accept, InProgress, OnHold, Complete, Close)", "in": "query", "schema": { "type": "array", "items": { "type": "string" } }, "required": false }, { "name": "maxResults", "description": "The maximum number of results to return.", "in": "query", "schema": { "type": "number" }, "required": false }, { "name": "nextToken", "description": "To retrieve the next set of results.", "in": "query", "schema": { "type": "string" }, "required": false } ], "success": [], "requestBody": {}, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetIds": { "type": "string" }, "locationId": { "type": "string" }, "workflowId": {}, "subject": { "type": "string" }, "description": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "isTemplate": { "type": "boolean" }, "reason": { "type": "string" }, "status": { "type": "string" }, "priority": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" }, "updatedAtDateString": { "type": "string" }, "updatedAt": { "type": "number" } }, "required": [ "id", "organizationId", "assetIds", "locationId", "workflowId", "subject", "description", "images", "isTemplate", "reason", "status", "priority", "createdBy", "createdAtDateString", "createdAt", "updatedAtDateString", "updatedAt" ], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": [ { "id": "wr-workRequestId", "organizationId": "o-organizationId", "assetIds": "a-assetId", "locationId": "l-locationId", "workflowId": "er_eventRuleId", "subject": "IDT-WorkRequest", "description": "IDT-WorkRequest-Description", "images": [ "Asset-Image.png" ], "isTemplate": false, "reason": "test", "status": "Reject", "priority": "Medium", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000, "updatedAtDateString": "2024-01-31T00:00:00.000Z", "updatedAt": 1706659200000 } ] }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-requests/{workRequestId}/reject": { "put": { "summary": "Reject Work Request", "description": "Reject work request", "operationId": "Works.RejectWorkRequest", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workRequestId", "description": "The ID of work request.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "reason": { "type": "string", "description": "The reason of reject work request." } }, "required": [ "reason" ] }, "example": { "reason": "IDT-Reject-Reason" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "assetIds": { "type": "array", "items": { "type": "string" } }, "locationId": { "type": "string" }, "isTemplate": { "type": "boolean" }, "subject": { "type": "string" }, "description": { "type": "string" }, "workflowId": { "type": "string" }, "images": { "type": "array", "items": { "type": "string" } }, "priority": { "type": "string" }, "reason": { "type": "string" }, "status": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "string" } }, "required": [ "id", "organizationId", "assetIds", "locationId", "isTemplate", "subject", "description", "workflowId", "images", "priority", "reason", "status", "createdAtDateString", "createdAt" ], "description": "Data of the work request." } }, "required": [ "data" ] }, "example": { "data": { "id": "wr-workRequestId", "organizationId": "o-organizationId", "assetIds": [ "a-24e124535b312345" ], "locationId": "l-locationId", "isTemplate": false, "subject": "Work Request", "description": "Reject Work Request", "workflowId": "er_eventRuleId", "images": [], "priority": "None", "reason": "test", "status": "Reject", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } }, "/organizations/{organizationId}/work-orders/{workOrderId}/status": { "put": { "summary": "Update Work Order status", "description": "Update work order", "operationId": "Works.UpdateWorkOrderStatus", "tags": [ "Works" ], "parameters": [ { "name": "organizationId", "description": "The ID of organization.", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "workOrderId", "description": "The ID of work order.", "in": "path", "required": true, "schema": { "type": "string" } } ], "success": [], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "properties": { "status": { "type": "string", "description": "The status of work order." } }, "required": [ "status" ] }, "example": { "status": "InProgress" }, "description": "" } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "type": "object", "properties": { "data": { "type": "object", "properties": { "id": { "type": "string" }, "organizationId": { "type": "string" }, "locationId": { "type": "string" }, "location": { "type": "object", "properties": { "id": { "type": "string" }, "name": { "type": "string" }, "description": { "type": "string" } }, "required": [ "id", "name", "description" ] }, "workRequestId": { "type": "string" }, "type": { "type": "string" }, "subject": { "type": "string" }, "description": { "type": "string" }, "workTime": { "type": "number" }, "scheduleType": { "type": "string" }, "aheadOfTime": { "type": "number" }, "assignee": { "type": "object", "properties": {}, "required": [] }, "priority": { "type": "string" }, "procedures": { "type": "string" }, "files": { "type": "array", "items": { "type": "string" } }, "partIds": { "type": "array", "items": { "type": "string" } }, "assetIds": { "type": "array", "items": { "type": "string" } }, "status": { "type": "string" }, "timeTrackingType": { "type": "string" }, "enableNotify": { "type": "boolean" }, "images": { "type": "array", "items": { "type": "string" } }, "notifiedAt": { "type": "string" }, "expiredAt": { "type": "string" }, "createdBy": { "type": "string" }, "createdAtDateString": { "type": "string" }, "createdAt": { "type": "number" } }, "required": [ "id", "organizationId", "locationId", "location", "workRequestId", "type", "subject", "description", "workTime", "scheduleType", "aheadOfTime", "assignee", "priority", "procedures", "files", "partIds", "assetIds", "status", "timeTrackingType", "enableNotify", "images", "notifiedAt", "expiredAt", "createdBy", "createdAtDateString", "createdAt" ], "description": "Data of the work order." } }, "required": [ "data" ] }, "example": { "data": { "id": "o-organizationId-wo-workOrderId", "organizationId": "o-organizationId", "locationId": "l-locationId", "location": { "id": "l-locationId", "name": "Location ", "description": "Location-Description" }, "workRequestId": "wr-workRequestId", "type": "Normal", "subject": "IDT-WorkOrder", "description": "IDT-WorkOrder-Description", "workTime": 3600000, "scheduleType": "Daily", "aheadOfTime": 3600, "assignee": [ { "type": "Team", "id": "6d708f0e-xxxx-xxxx-xxxx-f0d9c59488ef" }, { "type": "User", "id": "593b34c0-xxxx-xxxx-xxxx-a454c6f9f50d" } ], "priority": "Low", "procedures": [], "files": [ "Infodeck-Bot-0001.pdf" ], "partIds": [], "assets": [], "assetIds": [], "status": "InProgress", "timeTrackingType": "automatic", "enableNotify": true, "images": [ "Asset-Image.png" ], "notifiedAt": "2024-01-30T00:00:00.000Z", "expiredAt": "2024-02-01T00:00:00.000Z", "createdBy": "d6b0e137-xxxx-xxxx-xxxx-c944cc12a5f4", "createdAtDateString": "2024-01-01T00:00:00.000Z", "createdAt": 1704067200000 } }, "description": "" } } }, "401": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Unauthenticated", "message": "Authentication is required and has failed or has not yet been provided." }, "description": "" } } }, "403": { "description": "The request has not permission.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The request has not permission." }, "message": { "type": "string", "description": "The request has not permission message." } }, "required": [ "error", "message" ] }, "example": { "error": "Forbidden", "message": "Access to the requested resource is forbidden." }, "description": "" } } }, "404": { "description": "The resource hasn't found.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The resource hasn't found." }, "message": { "type": "string", "description": "The resource hasn't found message." } }, "required": [ "error", "message" ] }, "example": { "error": "ResourceNotFound", "message": "The requested resource could not be found." }, "description": "" } } }, "422": { "description": "The input data has invalid.", "content": { "application/json": { "schema": { "type": "object", "properties": { "error": { "type": "string", "description": "The input data has invalid." }, "message": { "type": "string", "description": "The input data has invalid message." } }, "required": [ "error", "message" ] }, "example": { "error": "ValidationError", "message": "Input data validation failed." }, "description": "" } } } }, "security": [ { "user": [] } ] } } }, "components": { "securitySchemes": { "user": { "type": "http", "scheme": "bearer", "bearerFormat": "JWT", "description": "Get your API token via POST /authentications/tokens" } } }, "security": [ { "user": [] } ], "tags": [ { "name": "Asset" }, { "name": "Authentication" }, { "name": "Deck" }, { "name": "Edge Gateways" }, { "name": "Feedback" }, { "name": "Integration" }, { "name": "LNS Application" }, { "name": "LNS Device" }, { "name": "LNS Device Profile" }, { "name": "LNS Gateway" }, { "name": "Location" }, { "name": "Notification" }, { "name": "Organization" }, { "name": "Organization Addons" }, { "name": "Organization Stripe" }, { "name": "Organization Team" }, { "name": "Permissions" }, { "name": "Role" }, { "name": "Services" }, { "name": "Statistics" }, { "name": "Thing" }, { "name": "User Notification" }, { "name": "Workflows" }, { "name": "Works" } ] }