The OpenAPI schema defining the tool’s structure.
{
"openapi": "3.1.0",
"info": {
"title": "FastAPI",
"description": "API for fetching webpage content.",
"version": "0.1.0"
},
"paths": {
"/fetch-content/": {
"post": {
"summary": "Fetch Content",
"description": "Fetches content from the specified webpage URL.",
"operationId": "fetch_content_fetch_content__post",
"parameters": [
{
"name": "webpage_url",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Webpage URL",
"description": "The URL of the webpage from which to fetch content."
}
}
],
"responses": {
"200": {
"description": "Content fetched successfully",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"content": {
"type": "string",
"description": "The content of the webpage."
}
}
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
}
}
},
"components": {
"schemas": {
"HTTPValidationError": {
"type": "object",
"title": "HTTPValidationError",
"description": "Validation error response returned when the request fails validation.",
"properties": {
"detail": {
"type": "array",
"title": "Detail",
"description": "A list of validation errors.",
"items": {
"$ref": "#/components/schemas/ValidationError"
}
}
}
},
"ValidationError": {
"type": "object",
"title": "ValidationError",
"description": "Details about a specific validation error.",
"properties": {
"loc": {
"type": "array",
"title": "Location",
"description": "The location of the error in the request data.",
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
}
},
"msg": {
"type": "string",
"title": "Message",
"description": "A human-readable message describing the error."
},
"type": {
"type": "string",
"title": "Error Type",
"description": "The type of error encountered."
}
},
"required": ["loc", "msg", "type"]
}
}
},
"servers":[
{
"url":"https://fetch.example.com",
"description":"Fetch Content Server"
}
]
}