For the complete documentation index, see llms.txt. This page is also available as Markdown.

Ask a question in an organization

Ask a question to an AI across spaces that is accessible by the currently authenticated target.

post
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Path parameters
organizationIdstringRequired

A unique entity identifier

Pattern: ^[a-zA-Z0-9_-]+$
Query parameters
formatstring · enumOptional

Output format for the content.

Possible values:
detailsbooleanOptional

Return query details in the result

Body
querystringRequired
previousQueriesstring[] · max: 10OptionalDeprecated
Responses
200

OK

application/json
post/orgs/{organizationId}/ask
POST /v1/orgs/{organizationId}/ask HTTP/1.1
Host: api.gitbook.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 16

{
  "query": "text"
}
200

OK

{
  "answer": {
    "answer": {
      "markdown": "# Hello World\n\nThis is a markdown document linking to [another page](/pages/page_id).\n"
    },
    "followupQuestions": [
      "text"
    ],
    "sources": [
      {
        "type": "page",
        "reason": "text",
        "page": "text",
        "revision": "text",
        "space": "text",
        "sections": [
          "text"
        ]
      }
    ]
  }
}

Last updated

Was this helpful?

Powered by GitBook