Fetch one document (ChatGPT connector contract)
fetchReturns one knowledge record in full, by the string id a search result gave: title, the full text in the source's words, the URL to cite, and metadata with the source, licence and date. It is the ChatGPT connector counterpart of get_entity, which gives only an excerpt. Use it after search, or with a search_knowledge id as a string. Give field, a JSON pointer such as /questIds, to read one value of the record's data: text then holds that value as JSON, and an array comes in pages of up to 48 rows with nextOffset for the next page. A long array in a whole record is cut at 48 rows. The text block is the same JSON as a string.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"id": "<id>"
},
"name": "fetch"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | An id from a search result. | |
| field | No | A JSON pointer into the record's data, such as /criteria or /reagents/0. Without it, the whole record. | |
| limit | No | Rows per answer, default and at most 48. | |
| offset | No | Row to start at when the field is an array; default 0. Use nextOffset from the last answer. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | The record id as a string. | |
| url | Yes | Where the record is read, as in search. | |
| keys | No | Present when field was given and not found: the keys of the deepest object the pointer reached. Empty when the record has no structured data. | |
| text | Yes | The whole record, in the source's words. | |
| field | No | Present when field was given and found. | |
| title | Yes | The record's name. | |
| metadata | Yes |