The API Loader is a document loader that fetches data from an API endpoint and converts the response into a document format suitable for processing in a language model pipeline.
Text Splitter (optional)
Method
URL
Headers (optional)
Body (optional)
Additional Metadata (optional)
Omit Metadata Keys (optional)
IDocument
objects, each containing:
pageContent
: The API response data as a JSON string.metadata
: An object containing at least the url
of the API endpoint, and any additional metadata specified.Document
object with metadata.