Download OpenAPI specification:
Core DB Query-Specific API
If the above download is not available, please download openapi.json from the following link.
openapi.json
Executes a DB query and returns the result.
If the query results in an error, a response of result-type:error is returned with the status code 200.
If the query itself cannot be executed, a status code other than 200 is returned.
| X-hive-api-key | string The token string to specify when token authentication is enabled. |
DB query
| query required | string Query string |
| timeout | int [ 1 .. 180 ] Default: 30 Query processing timeout (seconds), a timeout occurs after specified time |
| timestamp_unit | string Default: "nanosecond" Enum: "nanosecond" "microsecond" "millisecond" "second" Unit of return result timestamp |
| omit_option | string Default: 0 Enum: 0 1 2 Specify whether to omit data absence or null value data (0= Null and data absence are omitted, 1 or 2= Not omitted) |
{- "query": "SELECT \"comp1:data1\", \"comp2:dataA\" FROM SPDB;",
- "timeout": 15,
- "timestamp_unit": "nanosecond"
}{- "query": "SELECT \"comp1:data1\", \"comp2:dataA\" FROM SPDB;",
- "timestamp_unit": "nanosecond",
- "success": true,
- "result": {
- "record_columns": [
- {
- "name": "comp1:data1",
- "data_type": "int32",
- "data_array": 1
}, - {
- "name": "comp2:dataA",
- "data_type": "string",
- "data_array": 1
}
], - "records": [
- {
- "timestamp": 1685431077073000000,
- "record_type": "D",
- "data": [
- {
- "name": "comp1:data1",
- "value": 24,
- "data_type": "int32"
}, - {
- "name": "comp2:dataA",
- "value": "ABCDEF",
- "data_type": "string"
}
]
}, - {
- "timestamp": 1685431078073000000,
- "record_type": "D",
- "data": [
- {
- "name": "comp1:data1",
- "value": 35,
- "data_type": "int32"
}
]
}
]
}
}Executes a DB query and returns the result in stream format.
This API only supports queries that do not change the state of the server, such as SELECT.
Not supported at this time. (May be added in the future)
DB query
| query required | string Query string |
| timeout | int [ 1 .. 180 ] Default: 30 Query processing timeout (seconds), a timeout occurs after specified time |
| timestamp_unit | string Default: "nanosecond" Enum: "nanosecond" "microsecond" "millisecond" "second" Unit of return result timestamp |
| omit_option | string Default: 0 Enum: 0 1 2 Specify whether to omit data absence or null value data (0= Null and data absence are omitted, 1 or 2= Not omitted) |
{- "query": "SELECT \"comp1:data1\", \"comp2:dataA\" FROM SPDB;",
- "timeout": 15,
- "timestamp_unit": "nanosecond"
}[- {
- "timestamp": null,
- "record_type": "D",
- "data": [
- {
- "name": "string",
- "value": null,
- "data_type": "bool",
- "data_array": 1
}
]
}
]