openapi: 3.0.3 info: contact: email: engineering@blues.io name: Blues Engineering url: https://dev.blues.io/support/ description: 'The OpenAPI definition for the Notehub.io API. ' title: Notehub alert project API version: 1.2.0 servers: - description: Production server url: https://api.notefile.net tags: - description: Project operations name: project paths: /v1/products/{productUID}/project: get: operationId: GetProjectByProduct description: Get a Project by ProductUID parameters: - name: productUID in: path required: true schema: type: string example: com.blues.airnote responses: '200': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/Project' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects: get: operationId: GetProjects description: Get Projects accessible by the api_key responses: '200': description: Successful operation content: application/json: schema: type: object properties: projects: type: array items: $ref: '#/components/schemas/Project' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read post: operationId: CreateProject description: Create a Project requestBody: description: Project to be created required: true content: application/json: schema: type: object properties: billing_account_uid: description: 'The billing account UID for the project. The caller of the API must be able to create projects within the billing account, otherwise an error will be returned. ' type: string label: description: The label for the project. type: string required: - label - billing_account_uid responses: '201': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/Project' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: create /v1/projects/{projectOrProductUID}: delete: operationId: DeleteProject description: Delete a Project by ProjectUID parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' responses: '200': description: Successful operation default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: delete resource: blues:resources:app:APPSERIAL:settings get: operationId: GetProject description: Get a Project by ProjectUID parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' responses: '200': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/Project' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/aws-role-config: get: operationId: GetAWSRoleConfig summary: Get AWS role configuration for role-based authentication description: 'Returns the AWS Account ID and External ID needed to configure an IAM role trust policy for role-based authentication on AWS routes. ' parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' responses: '200': description: AWS role configuration content: application/json: schema: $ref: '#/components/schemas/AWSRoleConfig' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/clone: post: operationId: CloneProject description: Clone a Project parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' requestBody: description: Project to be cloned required: true content: application/json: schema: type: object properties: billing_account_uid: description: The billing account UID for the project. The caller of the API must be able to create projects within the billing account, otherwise an error will be returned. type: string disable_clone_fleets: description: Whether to disallow the cloning of the fleets from the parent project. Default is false if not specified. type: boolean disable_clone_routes: description: Whether to disallow the cloning of the routes from the parent project. Default is false if not specified. type: boolean label: description: The label for the project. type: string required: - label - billing_account_uid responses: '201': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/Project' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: create resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/devices/{deviceUID}/dfu/{firmwareType}/history: get: operationId: GetDeviceDfuHistory description: Get device DFU history for host or Notecard firmware parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/deviceUIDParam' - $ref: '#/components/parameters/firmwareTypeParam' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/DeviceDfuHistory' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/devices/{deviceUID}/dfu/{firmwareType}/status: get: operationId: GetDeviceDfuStatus description: Get device DFU history for host or Notecard firmware parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/deviceUIDParam' - $ref: '#/components/parameters/firmwareTypeParam' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/DeviceDfuStatus' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/devices/{deviceUID}/fleets: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/deviceUIDParam' delete: operationId: DeleteDeviceFromFleets description: Remove Device from Fleets requestBody: description: 'The fleets to remove from the device. Note that the endpoint takes an array of fleetUIDs, to facilitate multi-fleet devices. Multi-fleet is not yet enabled on all SaaS plans - unless it is supported by the SaaS plan of the project, passing more than a single fleetUID in the array is an error. ' required: true content: application/json: schema: type: object properties: fleet_uids: description: The fleetUIDs to remove from the device. type: array items: type: string required: - fleet_uids responses: '200': $ref: '#/components/responses/FleetsResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: delete resource: blues:resources:app:APPSERIAL:devices get: operationId: GetDeviceFleets description: Get Device Fleets responses: '200': $ref: '#/components/responses/FleetsResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:devices put: operationId: AddDeviceToFleets description: Add Device to Fleets requestBody: description: 'The fleets to add to the device. Note that the endpoint takes an array of fleetUIDs, to facilitate multi-fleet devices. Multi-fleet is not yet enabled on all SaaS plans - unless it is supported by the SaaS plan of the project, passing more than a single fleetUID in the array is an error. ' required: true content: application/json: schema: type: object properties: fleet_uids: description: The fleetUIDs to add to the device. type: array items: type: string required: - fleet_uids responses: '200': $ref: '#/components/responses/FleetsResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:devices /v1/projects/{projectOrProductUID}/dfu/{firmwareType}/{action}: post: operationId: PerformDfuAction description: Update/cancel host or notecard firmware updates parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/firmwareTypeParam' - $ref: '#/components/parameters/dfuActionParam' - $ref: '#/components/parameters/deviceUIDParamQuery' - $ref: '#/components/parameters/tagParam' - $ref: '#/components/parameters/serialNumberParam' - $ref: '#/components/parameters/fleetUIDQueryParam' - $ref: '#/components/parameters/notecardFirmwareParam' - $ref: '#/components/parameters/locationParam' - $ref: '#/components/parameters/hostFirmwareParam' - $ref: '#/components/parameters/productUIDQueryParam' - $ref: '#/components/parameters/skuParam' requestBody: description: Which firmware in the case of an update action required: false content: application/json: schema: $ref: '#/components/schemas/DfuActionRequest' responses: '200': description: Success default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: create resource: blues:resources:app:APPSERIAL:devices /v1/projects/{projectOrProductUID}/dfu/{firmwareType}/history: get: operationId: GetDevicesDfuHistory description: Get host or Notecard DFU history for all devices that match the filter criteria parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/firmwareTypeParam' - $ref: '#/components/parameters/pageSizeParam' - $ref: '#/components/parameters/pageNumParam' - $ref: '#/components/parameters/sortByParam' - $ref: '#/components/parameters/sortOrderParam' - $ref: '#/components/parameters/deviceUIDParamQuery' - $ref: '#/components/parameters/tagParam' - $ref: '#/components/parameters/serialNumberParam' - $ref: '#/components/parameters/fleetUIDQueryParam' - $ref: '#/components/parameters/notecardFirmwareParam' - $ref: '#/components/parameters/locationParam' - $ref: '#/components/parameters/hostFirmwareParam' - $ref: '#/components/parameters/productUIDQueryParam' - $ref: '#/components/parameters/skuParam' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/DeviceDfuHistoryPage' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/dfu/{firmwareType}/status: get: operationId: GetDevicesDfuStatus description: Get host or Notecard DFU history for all devices that match the filter criteria parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/firmwareTypeParam' - $ref: '#/components/parameters/pageSizeParam' - $ref: '#/components/parameters/pageNumParam' - $ref: '#/components/parameters/sortByParam' - $ref: '#/components/parameters/sortOrderParam' - $ref: '#/components/parameters/deviceUIDParamQuery' - $ref: '#/components/parameters/tagParam' - $ref: '#/components/parameters/serialNumberParam' - $ref: '#/components/parameters/fleetUIDQueryParam' - $ref: '#/components/parameters/notecardFirmwareParam' - $ref: '#/components/parameters/locationParam' - $ref: '#/components/parameters/hostFirmwareParam' - $ref: '#/components/parameters/productUIDQueryParam' - $ref: '#/components/parameters/skuParam' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/DeviceDfuStatusPage' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/environment_hierarchy: get: operationId: GetProjectEnvironmentHierarchy summary: Get environment variable hierarchy for a device parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' responses: '200': description: Successfully retrieved project environment hierarchy content: application/json: schema: $ref: '#/components/schemas/EnvTreeJsonNode' '404': description: Project or device not found '500': description: Server error security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/environment_variables: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' get: operationId: GetProjectEnvironmentVariables description: Get environment variables of a project responses: '200': $ref: '#/components/responses/EnvironmentVariablesResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings put: operationId: SetProjectEnvironmentVariables description: Set environment variables of a project requestBody: content: application/json: schema: $ref: '#/components/schemas/EnvironmentVariables' responses: '200': $ref: '#/components/responses/EnvironmentVariablesResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/environment_variables/{key}: delete: operationId: DeleteProjectEnvironmentVariable description: Delete an environment variable of a project by key parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - name: key in: path description: The environment variable key to delete. required: true schema: type: string responses: '200': $ref: '#/components/responses/EnvironmentVariablesResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: delete resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/firmware: get: operationId: GetFirmwareInfo description: Get Available Firmware Information parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/productQueryParam' - $ref: '#/components/parameters/firmwareTypeQueryParam' - $ref: '#/components/parameters/versionQueryParam' - $ref: '#/components/parameters/targetQueryParam' - $ref: '#/components/parameters/filenameQueryParam' - $ref: '#/components/parameters/md5QueryParam' - $ref: '#/components/parameters/unpublishedQueryParam' - $ref: '#/components/parameters/firmwareSortByParam' - $ref: '#/components/parameters/firmwareSortOrderParam' responses: '200': description: Success content: application/json: schema: type: array items: $ref: '#/components/schemas/FirmwareInfo' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:devices /v1/projects/{projectOrProductUID}/firmware/{firmwareType}/{filename}: delete: operationId: DeleteFirmware description: 'Delete a host firmware binary. The filename must be the full stored filename including the timestamp suffix (e.g. test$20260324190911.bin) as returned by the firmware upload or list endpoints. ' parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - name: firmwareType in: path required: true schema: type: string enum: - host - name: filename in: path required: true schema: type: string responses: '204': description: Firmware deleted successfully default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: delete resource: blues:resources:app:APPSERIAL:settings get: operationId: DownloadFirmware description: Download firmware binary parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/firmwareTypeParam' - name: filename in: path required: true schema: type: string responses: '200': description: Firmware binary content: application/octet-stream: schema: type: string format: binary default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings post: operationId: UpdateFirmware description: 'Update the metadata of an existing host firmware entry. The filename must be the full stored filename including the timestamp suffix (e.g. test$20260324190911.bin) as returned by the firmware upload or list endpoints. ' parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - name: firmwareType in: path required: true schema: type: string enum: - host - name: filename in: path required: true schema: type: string requestBody: description: Firmware metadata fields to update. All fields are optional; only provided fields will be updated. required: true content: application/json: schema: $ref: '#/components/schemas/UpdateHostFirmwareRequest' responses: '200': description: Update successful content: application/json: schema: $ref: '#/components/schemas/FirmwareInfo' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:settings put: operationId: UploadFirmware description: Upload firmware binary parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/firmwareTypeParam' - name: filename in: path required: true schema: type: string - name: version in: query description: Firmware version (optional). If not provided, the version will be extracted from firmware binary if available, otherwise left empty required: false schema: type: string - name: notes in: query description: Optional notes describing what's different about this firmware version required: false schema: type: string requestBody: description: contents of the firmware binary required: true content: application/octet-stream: schema: type: string format: binary responses: '200': description: Upload successful content: application/json: schema: $ref: '#/components/schemas/FirmwareInfo' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/fleets: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' get: operationId: GetFleets description: Get Project Fleets responses: '200': $ref: '#/components/responses/FleetsResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:fleets post: operationId: CreateFleet description: Create Fleet requestBody: description: Fleet to be added required: true content: application/json: schema: type: object properties: connectivity_assurance: $ref: '#/components/schemas/FleetConnectivityAssurance' label: description: The label, or name, for the Fleet. type: string smart_rule: $ref: '#/components/schemas/FleetRule' smart_rule_enabled: type: boolean responses: '201': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/Fleet' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: create resource: blues:resources:app:APPSERIAL:fleets /v1/projects/{projectOrProductUID}/fleets/{fleetUID}: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/fleetUIDParam' delete: operationId: DeleteFleet description: Delete Fleet responses: '204': description: Successful operation default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: delete resource: blues:resources:app:APPSERIAL:fleets get: operationId: GetFleet description: Get Fleet responses: '200': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/Fleet' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:fleets put: operationId: UpdateFleet description: Update Fleet requestBody: description: Fleet details to update required: true content: application/json: schema: type: object properties: addDevices: description: List of DeviceUIDs to add to fleet type: array items: type: string connectivity_assurance: $ref: '#/components/schemas/FleetConnectivityAssurance' label: description: The label for the Fleet. type: string removeDevices: description: List of DeviceUIDs to remove from fleet type: array items: type: string smart_rule: $ref: '#/components/schemas/FleetRule' smart_rule_enabled: type: boolean watchdog_mins: description: A watchdog timer is used to generate an event every N minutes of inactivity. 0 means no watchdog type: integer format: int64 responses: '200': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/Fleet' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:fleets /v1/projects/{projectOrProductUID}/fleets/{fleetUID}/environment_hierarchy: get: operationId: GetFleetEnvironmentHierarchy summary: Get environment variable hierarchy for a device parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/fleetUIDParam' responses: '200': description: Successfully retrieved fleet environment hierarchy content: application/json: schema: $ref: '#/components/schemas/EnvTreeJsonNode' '404': description: Project or device not found '500': description: Server error security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:fleets /v1/projects/{projectOrProductUID}/fleets/{fleetUID}/environment_variables: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/fleetUIDParam' get: operationId: GetFleetEnvironmentVariables description: Get environment variables of a fleet responses: '200': $ref: '#/components/responses/EnvironmentVariablesResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:fleets put: operationId: SetFleetEnvironmentVariables description: Set environment variables of a fleet requestBody: description: Environment variables to be added to the fleet required: true content: application/json: schema: $ref: '#/components/schemas/EnvironmentVariables' responses: '200': $ref: '#/components/responses/EnvironmentVariablesResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:fleets /v1/projects/{projectOrProductUID}/fleets/{fleetUID}/environment_variables/{key}: delete: operationId: DeleteFleetEnvironmentVariable description: Delete environment variables of a fleet parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/fleetUIDParam' - name: key in: path description: The environment variable key to delete. required: true schema: type: string responses: '200': $ref: '#/components/responses/EnvironmentVariablesResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: delete resource: blues:resources:app:APPSERIAL:fleets /v1/projects/{projectOrProductUID}/global-transformation: post: operationId: SetGlobalEventTransformation description: Set the project-level event JSONata transformation parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' requestBody: description: JSONata expression which will be applied to each event before it is persisted and routed required: true content: text/plain: schema: type: string responses: '200': description: Successful operation default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/global-transformation/disable: post: operationId: DisableGlobalEventTransformation description: Disable the project-level event JSONata transformation parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' responses: '200': description: Successful operation default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/global-transformation/enable: post: operationId: EnableGlobalEventTransformation description: Enable the project-level event JSONata transformation parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' responses: '200': description: Successful operation default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/members: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' get: operationId: GetProjectMembers description: Get Project Members responses: '200': description: Successful operation content: application/json: schema: type: object properties: members: type: array items: $ref: '#/components/schemas/ProjectMember' required: - members default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:accounts /v1/projects/{projectOrProductUID}/products: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' get: operationId: GetProducts description: Get Products within a Project responses: '200': description: Successful operation content: application/json: schema: type: object properties: products: type: array items: $ref: '#/components/schemas/Product' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:products post: operationId: CreateProduct description: Create Product within a Project requestBody: description: Product to be created required: true content: application/json: schema: type: object properties: auto_provision_fleets: type: array items: type: string disable_devices_by_default: description: If `true`, devices provisioned to this product will be automatically disabled by default. type: boolean label: description: The label for the Product. type: string product_uid: description: The requested uid for the Product. Will be prefixed with the user's reversed email. type: string required: - product_uid - label responses: '201': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/Product' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: create resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/products/{productUID}: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - $ref: '#/components/parameters/productUIDParam' delete: operationId: DeleteProduct description: Delete a product responses: '204': description: Successful operation default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: delete resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/schemas: get: operationId: GetNotefileSchemas summary: Get variable format for a notefile parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' responses: '200': description: List of notefile schema definitions content: application/json: schema: type: array items: $ref: '#/components/schemas/NotefileSchema' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/secrets: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' get: operationId: GetProjectSecrets description: Get all secrets for a project (metadata only, values are never returned) responses: '200': $ref: '#/components/responses/GetProjectSecretsResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: read resource: blues:resources:app:APPSERIAL:settings post: operationId: CreateProjectSecret description: Create a new project secret requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateProjectSecretRequest' responses: '201': description: Secret created successfully content: application/json: schema: $ref: '#/components/schemas/ProjectSecret' '400': $ref: '#/components/responses/ErrorResponse' '409': $ref: '#/components/responses/ErrorResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: create resource: blues:resources:app:APPSERIAL:settings /v1/projects/{projectOrProductUID}/secrets/{secretName}: parameters: - $ref: '#/components/parameters/projectOrProductUIDParam' - name: secretName in: path description: The name of the secret. required: true schema: type: string delete: operationId: DeleteProjectSecret description: Delete a project secret by name responses: '204': description: Secret deleted successfully '404': $ref: '#/components/responses/ErrorResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: delete resource: blues:resources:app:APPSERIAL:settings put: operationId: UpdateProjectSecret description: Update the value of an existing project secret requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateProjectSecretRequest' responses: '200': description: Secret updated successfully content: application/json: schema: $ref: '#/components/schemas/ProjectSecret' '404': $ref: '#/components/responses/ErrorResponse' default: $ref: '#/components/responses/ErrorResponse' security: - personalAccessToken: [] tags: - project x-custom-attributes: permission: update resource: blues:resources:app:APPSERIAL:settings components: schemas: ProjectSecret: description: Metadata for a project secret. The value is never returned. type: object properties: created: description: When the secret was first created. type: string format: date-time created_by: description: The actor who created the secret. type: string modified: description: When the secret was last updated. type: string format: date-time modified_by: description: The actor who last updated the secret. type: string name: description: The secret name (alphanumeric and underscores only). type: string required: - name - created - created_by DeviceDfuStateMachine: description: Represents a single request to update the host or Notecard firmware type: object properties: current_version: description: Version of the firmware that was installed prior to this request type: string initiated: description: RFC3339 datetime of when this update was requested type: string requested_version: description: Version of the firmware that was requested to be installed type: string updates: type: array items: $ref: '#/components/schemas/DeviceDfuStateMachineNode' SchemaProperty: type: object properties: items: description: Used if type is array type: array items: $ref: '#/components/schemas/SchemaProperty' name: description: Name of the field (optional for array/object children) type: string properties: description: Used if type is object type: array items: $ref: '#/components/schemas/SchemaProperty' type: type: string enum: - string - number - boolean - array - object updated_at: type: string format: date-time required: - type - updatedAt UpdateProjectSecretRequest: type: object properties: value: description: The new secret value (encrypted at rest, never returned). type: string required: - value FleetRule: description: JSONata expression that will be evaluated to determine device membership into this fleet, if the expression evaluates to a 1, the device will be included, if it evaluates to -1 it will be removed, and if it evaluates to 0 or errors it will be left unchanged. type: string properties: {} Error: type: object properties: code: description: The HTTP error code associated with the error. type: integer maximum: 599 minimum: 300 debug: type: string details: type: object err: description: Human readable error message. type: string request: type: string status: description: Machine readable representation of the HTTP error code. type: string required: - err - code - status Product: type: object properties: auto_provision_fleets: type: array items: type: string nullable: true disable_devices_by_default: type: boolean label: type: string uid: type: string required: - uid - label - disable_devices_by_default GetProjectSecretsResponse: type: object properties: secrets: type: array items: $ref: '#/components/schemas/ProjectSecret' required: - secrets Fleet: type: object properties: connectivity_assurance: $ref: '#/components/schemas/FleetConnectivityAssurance' created: description: RFC3339 timestamp in UTC type: string format: date-time environment_variables: description: The environment variables for this device that have been set using the Notehub API or UI. type: object additionalProperties: type: string label: description: Fleet label type: string smart_rule: $ref: '#/components/schemas/FleetRule' smart_rule_enabled: type: boolean uid: description: Fleet UID type: string watchdog_mins: description: A watchdog timer is used to generate an event every N minutes of inactivity. 0 means no watchdog type: integer format: int64 required: - uid - label - created EnvironmentVariables: type: object properties: environment_variables: type: object additionalProperties: type: string required: - environment_variables NotefileSchema: type: object properties: notefile: type: string properties: type: array items: $ref: '#/components/schemas/SchemaProperty' required: - notefile - properties CreateProjectSecretRequest: type: object properties: name: description: The secret name (alphanumeric and underscores only). type: string value: description: The secret value (encrypted at rest, never returned after creation). type: string required: - name - value FleetConnectivityAssurance: type: object properties: enabled: description: Whether Connectivity Assurance is enabled for this fleet type: boolean nullable: true example: enabled: true nullable: true Project: type: object properties: administrative_contact: $ref: '#/components/schemas/Contact' created: type: string format: date-time label: type: string role: $ref: '#/components/schemas/Role' technical_contact: $ref: '#/components/schemas/Contact' uid: type: string required: - uid - label - created AWSRoleConfig: description: Configuration needed to set up an IAM role trust policy for role-based authentication on AWS routes type: object properties: aws_account_id: description: The Blues AWS Account ID to trust in your IAM role's trust policy type: string external_id: description: The External ID to use in your IAM role's trust policy condition type: string required: - aws_account_id - external_id EnvTreeJsonNode: type: object properties: app_label: type: string app_uid: type: string children: type: array items: $ref: '#/components/schemas/EnvTreeJsonNode' device_uid: type: string fleet_label: type: string fleet_uid: type: string inherited_var_count: type: integer type: type: string url: type: string format: uri var_count: type: integer variables: type: array items: $ref: '#/components/schemas/EnvVar' required: - var_count - inherited_var_count - type - variables - children DeviceDfuStatus: type: object properties: current: description: Description of the current firmware type: object properties: builder: description: Firmware author type: string built: description: Firmware build date type: string description: description: Firmware description type: string organization: description: Firmware organization type: string product: description: Firmware product type: string version: description: Firmware version type: string device_uid: description: Device UID type: string dfu_in_progress: description: true if there is a DFU currently in progress type: boolean status: $ref: '#/components/schemas/DeviceDfuStateMachine' Contact: type: object properties: email: type: string name: type: string organization: type: string role: type: string nullable: true EnvVar: type: object properties: key: type: string precedence: type: integer used: type: boolean value: type: string DeviceDfuHistoryPage: type: object properties: devices: type: array items: $ref: '#/components/schemas/DeviceDfuHistory' has_more: type: boolean default: false Role: type: string properties: {} enum: - owner - developer - viewer - support - null nullable: true DeviceDfuHistory: type: object properties: current: description: Description of the current firmware type: object properties: builder: description: Firmware author type: string built: description: Firmware build date type: string description: description: Firmware description type: string organization: description: Firmware organization type: string product: description: Firmware product type: string version: description: Firmware version type: string device_uid: description: Device UID type: string history: type: array items: $ref: '#/components/schemas/DeviceDfuStateMachine' DfuActionRequest: type: object properties: filename: description: The name of the firmware file type: string UpdateHostFirmwareRequest: description: 'Request body for updating host firmware metadata. All fields are optional; only provided fields will be updated. ' type: object properties: info: description: Arbitrary JSON metadata associated with this firmware entry. type: object additionalProperties: true notes: description: Notes describing this firmware version. type: string version: description: The firmware version string. type: string FirmwareInfo: type: object properties: built: description: The date the firmware was built. type: string created: description: The date the firmware was created. type: string description: description: A description of the firmware. type: string filename: description: The name of the firmware file. type: string info: description: User-defined metadata type: object md5: description: The MD5 hash of the firmware file. type: string notes: description: User-defined notes type: string organization: description: The organization that owns the firmware. type: string product: description: The product that the firmware is for. type: string published: description: True if the firmware is published. type: boolean tags: description: A list of tags associated with the firmware. type: string target: description: The target device for the firmware. type: string type: description: The type of firmware. type: string version: description: The version of the firmware. type: string ProjectMember: type: object properties: email: description: 'The email address of the project member. This property will only be populated if the viewer is an owner of the project. ' type: string name: type: string role: $ref: '#/components/schemas/Role' required: - name - email - role DeviceDfuStatusPage: type: object properties: devices: type: array items: $ref: '#/components/schemas/DeviceDfuStatus' has_more: type: boolean default: false DeviceDfuStateMachineNode: description: Represents a single request to update the host or Notecard firmware type: object properties: datetime: description: RFC3339 compatible datetime of when this status update happened type: string description: description: Additional information type: string phase: description: Phase for this step in the firmware update process type: string status: description: Status for this step in the firmware update process type: string parameters: firmwareSortOrderParam: description: Sort order (asc for ascending, desc for descending) in: query name: sortOrder required: false schema: type: string default: desc enum: - asc - desc firmwareTypeParam: in: path name: firmwareType required: true schema: type: string enum: - host - notecard dfuActionParam: in: path name: action required: true schema: type: string enum: - update - cancel hostFirmwareParam: description: Host firmware filter explode: true in: query name: hostFirmware required: false schema: type: array items: type: string style: form fleetUIDQueryParam: in: query name: fleetUID required: false schema: type: string unpublishedQueryParam: in: query name: unpublished required: false schema: type: boolean targetQueryParam: in: query name: target required: false schema: type: string serialNumberParam: description: Serial number filter explode: true in: query name: serialNumber required: false schema: type: array items: type: string style: form filenameQueryParam: example: notecard-7.2.2.16518$20240410043100.bin in: query name: filename required: false schema: type: string sortOrderParam: in: query name: sortOrder required: false schema: type: string default: asc enum: - asc - desc locationParam: description: Location filter explode: true in: query name: location required: false schema: type: array items: type: string style: form productQueryParam: in: query name: product required: false schema: type: string pageNumParam: in: query name: pageNum required: false schema: type: integer default: 1 minimum: 1 fleetUIDParam: in: path name: fleetUID required: true schema: type: string firmwareSortByParam: description: Field to sort by in: query name: sortBy required: false schema: type: string default: created enum: - created - name - version - length firmwareTypeQueryParam: in: query name: firmwareType required: false schema: type: string pageSizeParam: in: query name: pageSize required: false schema: type: integer default: 50 maximum: 10000 minimum: 1 notecardFirmwareParam: description: Firmware version filter explode: true in: query name: notecardFirmware required: false schema: type: array items: type: string style: form deviceUIDParamQuery: description: A Device UID. explode: true in: query name: deviceUID required: false schema: type: array items: type: string style: form productUIDParam: example: com.blues.bridge:sensors in: path name: productUID required: true schema: type: string deviceUIDParam: example: dev:000000000000000 in: path name: deviceUID required: true schema: type: string tagParam: description: Tag filter explode: true in: query name: tag required: false schema: type: array items: type: string style: form projectOrProductUIDParam: example: app:2606f411-dea6-44a0-9743-1130f57d77d8 in: path name: projectOrProductUID required: true schema: type: string skuParam: description: SKU filter explode: true in: query name: sku required: false schema: type: array items: type: string style: form md5QueryParam: in: query name: md5 required: false schema: type: string productUIDQueryParam: explode: true in: query name: productUID required: false schema: type: array items: type: string style: form versionQueryParam: in: query name: version required: false schema: type: string sortByParam: in: query name: sortBy required: false schema: type: string default: captured enum: - best_id - device_serial - device_uid - captured - modified - device_location - tower_location - triangulated_location - best_location responses: GetProjectSecretsResponse: description: The response body from a get project secrets request. content: application/json: schema: type: '' properties: {} $ref: '#/components/schemas/GetProjectSecretsResponse' FleetsResponse: description: The response body from a fleets endpoint. content: application/json: schema: type: object properties: fleets: type: array items: $ref: '#/components/schemas/Fleet' required: - fleets ErrorResponse: description: The response body in case of an API error. content: application/json: schema: type: '' properties: {} $ref: '#/components/schemas/Error' EnvironmentVariablesResponse: description: The response body from an environment variables request. content: application/json: schema: type: '' properties: {} $ref: '#/components/schemas/EnvironmentVariables' securitySchemes: personalAccessToken: description: 'Use a personal access token from notehub.io/api-access ' scheme: bearer type: http externalDocs: description: Find out more about Blues url: https://blues.io