curl -X POST https://api.aiql.io/requests \
-H "Authorization: Bearer $AIQL_API_KEY" \
-H "AiQL-Workspace: $AIQL_WORKSPACE_ID" \
-H "Content-Type: application/json" \
-d '{"title": "Add Q3 report", "description": "Ingest the Q3 financial report", "labels": ["finance"]}'import os
from aiql import AiQL
client = AiQL(api_key=os.environ["AIQL_API_KEY"])
request = client.requests.create(
workspace_id="ws_3a1b",
title="Add Q3 report",
description="Ingest the Q3 financial report",
labels=["finance"],
)import { AiQL } from "@aiql.io/sdk";
const client = new AiQL({ apiKey: process.env.AIQL_API_KEY });
const request = await client.requests.create({
workspaceId: "ws_3a1b",
title: "Add Q3 report",
description: "Ingest the Q3 financial report",
labels: ["finance"],
});{
"id": "<string>",
"title": "<string>",
"description": "<string>",
"status": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"labels": [
"<string>"
],
"author": {
"id": "<string>",
"name": "<string>",
"email": "<string>",
"image": "<string>"
},
"assignees": [
{
"id": "<string>",
"name": "<string>",
"email": "<string>",
"image": "<string>"
}
],
"opened_at": "2023-11-07T05:31:56Z",
"changes_requested_at": "2023-11-07T05:31:56Z",
"approved_at": "2023-11-07T05:31:56Z",
"rejected_at": "2023-11-07T05:31:56Z",
"approval_count": 0,
"required_approvals": 0,
"comment_count": 0
}{
"detail": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Create Request
curl -X POST https://api.aiql.io/requests \
-H "Authorization: Bearer $AIQL_API_KEY" \
-H "AiQL-Workspace: $AIQL_WORKSPACE_ID" \
-H "Content-Type: application/json" \
-d '{"title": "Add Q3 report", "description": "Ingest the Q3 financial report", "labels": ["finance"]}'import os
from aiql import AiQL
client = AiQL(api_key=os.environ["AIQL_API_KEY"])
request = client.requests.create(
workspace_id="ws_3a1b",
title="Add Q3 report",
description="Ingest the Q3 financial report",
labels=["finance"],
)import { AiQL } from "@aiql.io/sdk";
const client = new AiQL({ apiKey: process.env.AIQL_API_KEY });
const request = await client.requests.create({
workspaceId: "ws_3a1b",
title: "Add Q3 report",
description: "Ingest the Q3 financial report",
labels: ["finance"],
});{
"id": "<string>",
"title": "<string>",
"description": "<string>",
"status": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"labels": [
"<string>"
],
"author": {
"id": "<string>",
"name": "<string>",
"email": "<string>",
"image": "<string>"
},
"assignees": [
{
"id": "<string>",
"name": "<string>",
"email": "<string>",
"image": "<string>"
}
],
"opened_at": "2023-11-07T05:31:56Z",
"changes_requested_at": "2023-11-07T05:31:56Z",
"approved_at": "2023-11-07T05:31:56Z",
"rejected_at": "2023-11-07T05:31:56Z",
"approval_count": 0,
"required_approvals": 0,
"comment_count": 0
}{
"detail": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
API key or UI session JWT passed as a Bearer token.
Headers
ID of the workspace the request operates on.
Body
Response
Successful Response
Unique identifier of the request.
Title of the request.
Description of the request.
Current status of the request.
Timestamp when the request was created.
Timestamp when the request was last updated.
Labels attached to the request.
Author of the request.
Show child attributes
Show child attributes
Users assigned to the request.
Show child attributes
Show child attributes
Timestamp when the request was opened.
Timestamp when changes were last requested on the request.
Timestamp when the request was approved.
Timestamp when the request was rejected.
Number of reviews in APPROVED status.
Number of reviews if any exist, otherwise the number of assignees.
Number of comments across all reviews.