aiWebSearchPassthroughContents
Map aiWebSearchPassthroughContents(AiWebSearchPassthroughContentsRequest)
POST /api/2.0/ai/websearch/v1/contents
Web page contents passthrough
Fetches the contents of web pages on behalf of the document editor's AI plugin, against the portal's active web-search provider, exactly as the search passthrough does — including the entityId / entityKind billing attribution. The portal-wide configuration is used and a portal without one answers 404. The provider's status, body and content type are relayed verbatim, so its 429 and its failures surface unchanged. This is the follow-up to POST api/2.0/ai/websearch/v1/search, which returns the results whose contents this operation retrieves.
Parameters
| Name | In | Type | Description | Notes |
|---|---|---|---|---|
| AiWebSearchPassthroughContentsRequest | body | Map | A page-contents request in the shape the portal's active web-search provider expects, forwarded to it unchanged. The endpoint and the key come from the stored configuration. | [required] |
Responses
| Status code | Description | Type | Response headers |
|---|---|---|---|
| 200 | The provider's own response, relayed verbatim with its status and content type. | Map | - |
| 401 | Missing asc_auth_key cookie or Authorization header. | AiErrorResponse | - |
| 403 | AI is disabled for this portal, the caller is a guest, or the room named by entityId is one the caller cannot open. Relayed from the DocSpace AI service or the Files API. | AiErrorResponse | - |
| 404 | Web search is not configured for this portal. | AiErrorResponse | - |
| 413 | The request body is larger than 100 KB, the JSON parser's limit on this route. | AiErrorResponse | - |
| 429 | Relayed verbatim from the AI provider, which is rate-limiting this portal's key. | AiErrorResponse | - |
| 500 | Unhandled failure. The reason is logged server-side and never echoed back. | AiErrorResponse | - |
| 502 | The AI provider could not be reached, or answered with a failure of its own. | AiErrorResponse | - |
Return type
Map
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json