Version 1 Compass APIs
You can use the version 1 Compass APIs to
perform these actions:
- Submit a query as an asynchronous job.
- Poll for the status until the query is finished.
- Retrieve the entire results of the query.
This table shows an overview of the available API methods:
Method | Type | Description |
---|---|---|
/v1/compass/ping | GET | Tests whether the Compass service is running. |
/v1/compass/jobs | POST | Use this API to submit a Compass SQL query as an asynchronous job. In the request body parameter provide your SQL statement. The response provides a Query ID. Use the Query ID with the Compass Status API to check the status of the submitted job. |
/v1/compass/jobs/{queryId}/status | GET | Use this API to check the status of a Query ID that was provided
from a Compass job. The response indicates if the query is still processing or has finished. Use the polling parameter to specify the long-polling time-out period. Query statuses:
|
/v1/compass/jobs/{queryId}/result | GET | Use this API to retrieve the results for a Query ID that was
provided by the Compass Jobs API. Initially, check the status of the Query ID using the Compass Status API. Ensure the process has finished running before using this API to retrieve the result. |
/v1/compass/jobs/{queryId}/cancel | PUT | Use this API to cancel the running process for a Query ID. An OK response status indicates a successful invocation of cancel. |