MCP Tools Reference: developerknowledge.googleapis.com

Narzędzie: get_documents

Za pomocą tego narzędzia możesz pobrać pełną treść jednego dokumentu lub maksymalnie 20 dokumentów w ramach jednego wywołania. Nazwy dokumentów powinny pochodzić z pola parent w wynikach wywołania narzędzia search_documents. Ustaw parametr names na listę nazw dokumentów.

Poniższy przykład pokazuje, jak za pomocą znaku curl wywołać narzędzie get_documents MCP.

Żądanie curl
                  
curl --location 'https://developerknowledge.googleapis.com/mcp' \
--header 'content-type: application/json' \
--header 'accept: application/json, text/event-stream' \
--data '{
  "method": "tools/call",
  "params": {
    "name": "get_documents",
    "arguments": {
      // provide these details according to the tool's MCP specification
    }
  },
  "jsonrpc": "2.0",
  "id": 1
}'
                

Schemat wejściowy

Schemat żądania dla get_documents.

GetDocumentsRequest

Zapis JSON
{
  "names": [
    string
  ]
}
Pola
names[]

string

Wymagane. Nazwy dokumentów do pobrania zwrócone przez funkcję search_documents. W jednym wywołaniu można pobrać maksymalnie 20 dokumentów. Dokumenty są zwracane w tej samej kolejności co names w żądaniu. Format: documents/{uri_without_scheme} Przykład: documents/docs.cloud.google.com/storage/docs/creating-buckets

Schemat wyjściowy

Schemat odpowiedzi dla metody get_documents.

GetDocumentsResponse

Zapis JSON
{
  "documents": [
    {
      object (Document)
    }
  ]
}
Pola
documents[]

object (Document)

Wysłano prośbę o dokumenty.

Dokument

Zapis JSON
{
  "name": string,
  "uri": string,
  "content": string,
  "description": string,
  "title": string
}
Pola
name

string

Identyfikator. Nazwa zasobu dokumentu. Format: documents/{uri_without_scheme} Przykład: documents/docs.cloud.google.com/storage/docs/creating-buckets

uri

string

Tylko dane wyjściowe. Identyfikator URI treści, np. https://cloud.google.com/storage/docs/creating-buckets.

content

string

Tylko dane wyjściowe. Treść dokumentu w formacie Markdown.

description

string

Tylko dane wyjściowe. Opis dokumentu.

title

string

Tylko dane wyjściowe. Tytuł dokumentu.

Adnotacje narzędzi

Destructive Hint: ❌ | Idempotent Hint: ✅ | Read Only Hint: ✅ | Open World Hint: ❌