Registry / llm-agents / openapi-llm

openapi-llm

JSON →
library0.4.3pypypiunverified

Convert and invoke OpenAPI specifications as LLM tool/function definitions. Current version 0.4.3. Active development.

pip install openapi-llm
INSTALL
IMPORT
SIG · OPENAPI-LLM
O
openapi-llm
llm-agentspythonv0.4.3
Install
4.9s avg
Import
Disk
32MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v0.4.3 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.000s · 32MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 4.9s · import 0.000s · 35MB
32MB installed
● package 32MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

OpenAPIToolSpec
from openapi_llm import OpenAPIToolSpec
from openapi_llm import OpenAPIToolSpec

Load an OpenAPI spec from a URL, convert to LLM tool definitions.

import os from openapi_llm import OpenAPIToolSpec from openapi_llm import Config config = Config(api_key=os.environ.get('OPENAI_API_KEY', 'test-key')) spec = OpenAPIToolSpec.from_url('https://api.example.com/openapi.json', config=config) tools = spec.to_tools() print(tools)
openapi-llm --version
Debug
Known issues
deprecatedOpenAPIToolSpec.from_spec() method signature changed in v0.4.0; old positional args may break.
fix
Use keyword arguments: OpenAPIToolSpec.from_spec(spec, config=config).
affects: >=0.4.0
breakingIn v0.4.0, the config parameter became mandatory for authentication.
fix
Always provide a Config object with api_key or other required credentials.
affects: >=0.4.0
gotchaOpenAPI security schemes (e.g., API Key, OAuth) are not automatically handled; you must pass a Config with the correct api_key.
fix
Set the api_key in Config for the relevant security scheme as specified in the OpenAPI spec.
affects: all
Upgrade
Version history
0.4.3latest on PyPI · released Apr 7, 2025
Audit
Dependencies

No dependency data recorded yet.

Agent activity
26 hits · last 30 days
node
24
Amazon
1
OpenAI (training)
1
Resources
openapi-llm — pip install openapi-llm · libregistry