# Mounted AgentOS apps now enforce token scopes

> Agno fixed a scope check in AgentOS apps mounted inside another app, where a valid JWT or service-account token could reach management routes without the required scopes.

- Published: 2026-09-08
- Author: Ashpreet Bedi
- Categories: Changelog
- Canonical: https://www.agno.com/articles/mounted-agentos-apps-now-enforce-token-scopes
- Markdown: https://www.agno.com/articles/mounted-agentos-apps-now-enforce-token-scopes.md

Agno's AgentOS now checks token scopes against the route inside AgentOS, whatever the mount prefix, with or without a `PublicSurface`. The permission check used to look up each route's required scopes with the full request path, prefix included. Under a mount like `/runtime`, the check found no requirement. A valid JWT or service-account token with no scopes could then read management routes such as `/config`, `/sessions`, `/metrics` and `/schedules`.

```python
parent = FastAPI()
parent.mount("/runtime", agent_os.get_app())
```

AgentOS always rejected requests without a valid token, and the bug never affected AgentOS apps served at the root.

![GET /config with a valid token that has no scopes. Mounted under /runtime it returned 200 and now returns 403. Served at the root it returns 403 either way. With no token it returns 401 either way.](https://www.agno.com/images/v3-0-9-mounted-scope-check.png)

If you mount AgentOS inside another application and use JWT or service-account authorization, upgrade.

Learn more about [authorization](https://docs.agno.com/agent-os/security/overview#authorization-jwt) and [mounting AgentOS on an existing app](https://docs.agno.com/examples/agent-os/customize/basic) in the documentation.
