Limerence
Spaces

Execute Space Query

Execute a SQL query against the space's data source

POST
/spaces/{id}/query

Execute a SQL query against the space's data source

Authorization

X-API-Key<token>

Use X-API-Key: .

In: header

Path Parameters

id*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/spaces/string/query" \  -H "Content-Type: application/json" \  -d '{    "dataSourceId": "string",    "sql": "string"  }'
{  "columns": [    "string"  ],  "data": [    {      "property1": null,      "property2": null    }  ]}
{  "cause": {    "code": "api/invalid-json",    "detail": "string"  },  "message": "The request body is not valid JSON"}
{  "cause": {    "code": "auth/jwt-invalid",    "detail": "malformed"  },  "message": "Token verification failed"}
{  "cause": {    "code": "api/no-active-team",    "detail": "You must have an active team. Please select a team to continue."  },  "message": "No active team"}
{  "cause": {    "code": "spaces/not-found",    "detail": "string"  },  "message": "Space not found"}
{  "cause": {    "code": "api/unsupported-media-type",    "detail": "GET requests cannot have a content type header"  },  "message": "Unsupported Media Type"}