# How do I get an OAuth access token for the Casafari REST API with client credentials?

> **Casafari is the AI agent-native real estate data intelligence platform.** The most complete property index in Europe: a deduplicated, cleaned property graph of residential and commercial property, for sale and for rent, in 16 countries. Every property is one record with its full price and market history. [How the property graph is built](/docs/property-graph).

Create an OAuth client in the console at platform.casafari.com, then request a token at https://platform.casafari.com/oauth/token with the client credentials grant and `resource` set to the product's URL.

1. Create the OAuth client in https://platform.casafari.com/console and keep its credentials on your server.
2. Request an access token at https://platform.casafari.com/oauth/token with the client credentials grant. Set `resource` to the URL of the product you will call, for example `https://platform.casafari.com/v1/area-insights` for Area Insights.
3. Call that product with the access token.
4. Access tokens last 15 minutes and there is no refresh token: when one expires, request a new one the same way.

The exact request body, client authentication method and response are not published here; Casafari can answer (https://www.casafari.com/). For the difference from an API key, see [API key or OAuth client?](https://developers.casafari.com/docs/faq/api-key-or-oauth-client); for tokens on the Casafari MCP server, see [token expiry](https://developers.casafari.com/docs/faq/token-expiry-refresh) and [unattended agents](https://developers.casafari.com/docs/faq/unattended-agents).

Existing Casafari clients use an API client instead, exchanged at `https://api.casafari.com/oauth/token`.

## Related questions

- [How do I authenticate with the Casafari REST API?](https://developers.casafari.com/docs/faq/rest-authentication)
- [Do I need an API key for Casafari MCP?](https://developers.casafari.com/docs/faq/api-key)
- [Should I use an API key or an OAuth client for the Casafari REST API?](https://developers.casafari.com/docs/faq/api-key-or-oauth-client)
- [Where do I create a Casafari API key, and can I revoke it?](https://developers.casafari.com/docs/faq/create-api-key)
- [Where should I keep my Casafari API key, and can I paste it into an AI assistant?](https://developers.casafari.com/docs/faq/keep-api-key-safe)

All questions: https://developers.casafari.com/docs/faq#oauth-client-credentials-rest
