openapi: 3.0.0 info: title: Soracom and Query Analysis DataEntry API description: Run SQL queries against Soracom Query, fetch query schemas, and search SIMs, Inventory devices, and Sigfox devices. version: 20250903-043502 servers: - description: Japan coverage production API endpoint url: https://api.soracom.io/v1 - description: Global coverage production API endpoint url: https://g.api.soracom.io/v1 tags: - description: '[Soracom Harvest Data](/en/docs/harvest/)' name: DataEntry paths: /data/{resource_type}/{resource_id}: get: description: 'Returns a list of data entries sent to Harvest Data from a device that match certain criteria. If the total number of entries does not fit in one page, a URL for accessing the next page is returned in the `link` header of the response. ' operationId: getDataEntries parameters: - description: Type of data source resource. in: path name: resource_type required: true schema: enum: - Subscriber - LoraDevice - Sim - SigfoxDevice - Device - SoraCam type: string - description: 'ID of data source resource. The ID to be specified depends on the value of `resource_type`. | `resource_type` | The ID you specify | |-|-| | `Subscriber` | IMSI of the IoT SIM | | `LoraDevice` | ID of the LoRaWAN device | | `Sim` | SIM ID of the IoT SIM | | `SigfoxDevice` | ID of the Sigfox device | | `Device` | ID of the Inventory device | | `SoraCam` | Device ID of the compatible camera device | ' in: path name: resource_id required: true schema: type: string - description: Start time for the data entries search range (UNIX time in milliseconds). in: query name: from required: false schema: type: integer - description: End time for the data entries search range (UNIX time in milliseconds). in: query name: to required: false schema: type: integer - description: Sort order of the data entries. Either descending (latest data entry first) or ascending (oldest data entry first). in: query name: sort required: false schema: default: desc enum: - desc - asc type: string - description: Maximum number of data entries to retrieve (value range is 1 to 1000). The default is `10`. in: query name: limit required: false schema: maximum: 1000 minimum: 1 type: integer - description: The value of the `x-soracom-next-key` header from the previous response. Specify this to retrieve the next page. in: query name: last_evaluated_key required: false schema: type: string responses: '200': content: application/json: schema: items: $ref: '#/components/schemas/DataEntry' type: array description: A list of data entries sent to Harvest Data from the specified resource. security: - api_key: [] api_token: [] summary: Get data sent to Harvest Data from a resource. tags: - DataEntry x-soracom-cli: - data get-entries x-soracom-cli-pagination: request: param: last_evaluated_key response: header: x-soracom-next-key /data/{resource_type}/{resource_id}/{time}: delete: description: Deletes a data entry identified with resource ID and timestamp operationId: deleteDataEntry parameters: - description: Type of data source resource. in: path name: resource_type required: true schema: enum: - Subscriber - LoraDevice - Sim - SigfoxDevice - Device - SoraCam type: string - description: 'ID of data source resource. The ID to be specified depends on the value of `resource_type`. | `resource_type` | The ID you specify | |-|-| | `Subscriber` | IMSI of the IoT SIM | | `LoraDevice` | ID of the LoRaWAN device | | `Sim` | SIM ID of the IoT SIM | | `SigfoxDevice` | ID of the Sigfox device | | `Device` | ID of the Inventory device | | `SoraCam` | Device ID of the compatible camera device | ' in: path name: resource_id required: true schema: type: string - description: Timestamp of the target data entry to delete (UNIX time in milliseconds). in: path name: time required: true schema: type: integer responses: '204': description: The data entry has been successfully deleted security: - api_key: [] api_token: [] summary: Deletes a data entry tags: - DataEntry x-soracom-cli: - data delete-entry get: description: Gets a data entry identified with resource ID and timestamp operationId: getDataEntry parameters: - description: Type of data source resource. in: path name: resource_type required: true schema: enum: - Subscriber - LoraDevice - Sim - SigfoxDevice - Device - SoraCam type: string - description: 'ID of data source resource. The ID to be specified depends on the value of `resource_type`. | `resource_type` | The ID you specify | |-|-| | `Subscriber` | IMSI of the IoT SIM | | `LoraDevice` | ID of the LoRaWAN device | | `Sim` | SIM ID of the IoT SIM | | `SigfoxDevice` | ID of the Sigfox device | | `Device` | ID of the Inventory device | | `SoraCam` | Device ID of the compatible camera device | ' in: path name: resource_id required: true schema: type: string - description: Timestamp of the target data entry to get (UNIX time in milliseconds). in: path name: time required: true schema: type: integer responses: '200': content: application/json: schema: $ref: '#/components/schemas/DataEntry' description: The data entry specified with resource ID and timestamp '404': description: No such entry found security: - api_key: [] api_token: [] summary: Gets a data entry tags: - DataEntry x-soracom-cli: - data get-entry /data/categories/{category}: get: description: 'Returns a list of data entries that belong to a specific category. If the total number of entries does not fit in one page, a URL for accessing the next page is returned in the `link` header of the response. ' operationId: getDataEntriesByCategory parameters: - description: Name of the category to filter data entries. in: path name: category required: true schema: type: string - description: Start time for the data entries search range (UNIX time in milliseconds). in: query name: from required: false schema: type: integer - description: End time for the data entries search range (UNIX time in milliseconds). in: query name: to required: false schema: type: integer - description: Sort order of the data entries. Either descending (latest data entry first) or ascending (oldest data entry first). in: query name: sort required: false schema: default: desc enum: - desc - asc type: string - description: Maximum number of data entries to retrieve (value range is 1 to 1000). The default is `10`. in: query name: limit required: false schema: maximum: 1000 minimum: 1 type: integer - description: The value of the `x-soracom-next-key` header from the previous response. Specify this to retrieve the next page. in: query name: last_evaluated_key required: false schema: type: string responses: '200': content: application/json: schema: items: $ref: '#/components/schemas/DataEntry' type: array description: A list of data entries belonging to the specified category. security: - api_key: [] api_token: [] summary: Get data entries for a specific category tags: - DataEntry x-soracom-cli: - data get-entries-by-category x-soracom-cli-pagination: request: param: last_evaluated_key response: header: x-soracom-next-key /data/metadata/resources: get: description: 'Returns a list of data source resources that have sent data. If the total number of data source resources does not fit in one page, a URL for accessing the next page is returned in the `link` header of the response. ' operationId: listDataResourceMetadata parameters: - description: 'Type of data source resource. - `Subscriber`: IoT SIM. - `LoraDevice`: LoRaWAN device. - `Sim`: IoT SIM. - `SigfoxDevice`: Sigfox device. - `Device`: Inventory device. - `SoraCam`: Compatible camera device. ' in: query name: resource_type required: false schema: enum: - Subscriber - LoraDevice - Sim - SigfoxDevice - Device - SoraCam type: string - description: Maximum number of data entries to retrieve. in: query name: limit required: false schema: type: integer - description: The value of the `x-soracom-next-key` header from the previous response. Specify this to retrieve the next page. in: query name: last_evaluated_key required: false schema: type: string responses: '200': content: application/json: schema: items: $ref: '#/components/schemas/DataResourceMetadata' type: array description: A list of data source resources that have sent data to Harvest Data. security: - api_key: [] api_token: [] summary: Get the list of data source resources tags: - DataEntry x-soracom-cli: - data list-resource-metadata x-soracom-cli-pagination: request: param: last_evaluated_key response: header: x-soracom-next-key /data/resources: get: deprecated: true description: 'Returns a list of data source resources that have sent data. If the total number of data source resources does not fit in one page, a URL for accessing the next page is returned in the `link` header of the response. ' operationId: listDataSourceResources parameters: - description: 'Type of data source resource. - `Subscriber`: IoT SIM. - `LoraDevice`: LoRaWAN device. - `Sim`: IoT SIM. - `SigfoxDevice`: Sigfox device. - `Device`: Inventory device. - `SoraCam`: Compatible camera device. ' in: query name: resource_type required: false schema: enum: - Subscriber - LoraDevice - Sim - SigfoxDevice - Device - SoraCam type: string - description: Maximum number of data entries to retrieve. in: query name: limit required: false schema: type: integer - description: The value of the `x-soracom-next-key` header from the previous response. Specify this to retrieve the next page. in: query name: last_evaluated_key required: false schema: type: string responses: '200': content: application/json: schema: items: $ref: '#/components/schemas/DataResourceMetadata' type: array description: A list of data source resources that have sent data to Harvest Data. security: - api_key: [] api_token: [] summary: Get the list of data source resources tags: - DataEntry x-soracom-cli: - data list-source-resources x-soracom-cli-pagination: request: param: last_evaluated_key response: header: x-soracom-next-key components: schemas: DataEntry: properties: category: type: string content: type: string contentType: type: string resourceId: type: string resourceType: enum: - Subscriber - LoraDevice - Sim - SigfoxDevice - Device - SoraCam type: string time: format: int64 type: integer type: object DataResourceMetadata: properties: attributeNames: items: type: string type: array lastModifiedTime: format: int64 type: integer resourceId: type: string resourceType: type: string type: object securitySchemes: api_key: description: 'API key for authentication. Obtain this from the Soracom User Console or via the Auth API. Required in combination with an API token for all authenticated requests. ' in: header name: X-Soracom-API-Key type: apiKey api_token: description: 'API token for authentication. This token has an expiration time and must be refreshed periodically. Required in combination with an API key for all authenticated requests.' in: header name: X-Soracom-Token type: apiKey