# reduce_openapi_spec

> **Function** in `langchain_sema4`

📖 [View in docs](https://reference.langchain.com/python/langchain-sema4/_common/reduce_openapi_spec)

Simplify OpenAPI spec to only required information for the agent

## Signature

```python
reduce_openapi_spec(
    url: str,
    spec: dict,
) -> ReducedOpenAPISpec
```

---

[View source on GitHub](https://github.com/langchain-ai/langchain-sema4/blob/14caa588ea60d411598f096d0734099bedcca0dd/libs/sema4/langchain_sema4/_common.py#L26)