Context7 Resolve Library ID
10 credits/call
ae_context7_resolve_library_id
Search for libraries to find the correct ID needed for documentation queries.
10 credits/call
Pricing
10 credits/call
| Condition | Charge |
|---|---|
| Each call | 10 credits/call |
Parameters
Optional parameters use the platform defaults when omitted.
| Parameter | Type | Required | Description | Default |
|---|---|---|---|---|
query | string | Yes | The question or task you need help with. This is used to rank library results by relevance to what the user is trying to accomplish. The query is sent to the Context7 API for processing. Do not include any sensitive or confidential information such as API keys, passwords, credentials, personal data, or proprietary code in your query. | — |
libraryName | string | Yes | Library name to search for and retrieve a Context7-compatible library ID. Use the official library name with proper punctuation — e.g., 'Next.js' instead of 'nextjs', 'Customer.io' instead of 'customerio', 'Three.js' instead of 'threejs'. | — |
Invocation example
Copy the request and explore its response example.
POST
/agent-api/v1/tool/executeX-Api-KeyRequest coderequest.sh
curl --request POST \
--url 'https://agentearth.ai/agent-api/v1/tool/execute?tool_name=ae_context7_resolve_library_id' \
--header "X-Api-Key: $AGENTEARTH_API_KEY" \
--header 'Content-Type: application/json' \
--data-raw '{
"params": {
"libraryName": "React",
"query": "React useEffect 清理函数官方文档"
}
}'Response exampleresponse.json
"Available Libraries:\n\n- Title: React\n- Context7-compatible library ID: /reactjs/react.dev\n- Description: React.dev is the official documentation website for React, a JavaScript library for building user interfaces, providing guides, API references, and tut"This example shows part of the response. Copied content is valid JSON.





