> ## Documentation Index
> Fetch the complete documentation index at: https://nango.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# How to register your own Melhor Envio OAuth app

> Create a Melhor Envio app and connect its credentials to Nango

This guide shows you how to create a Melhor Envio app to get your OAuth credentials (client ID & secret). Production and sandbox are separate environments: create an app in each one you use, and a Nango integration for each.

**1. Create a Melhor Envio account**

Sign up for [Melhor Envio](https://melhorenvio.com.br) (production) or the [sandbox](https://app-sandbox.melhorenvio.com.br) for testing.

**2. Create an app**

1. In the Melhor Envio panel, open **Integrações > Área Dev.** ([production](https://app.melhorenvio.com.br/integracoes/area-dev), [sandbox](https://app-sandbox.melhorenvio.com.br/integracoes/area-dev)).
2. Click **Cadastrar aplicativo** and fill in the app details.
3. Set the callback URL to `https://api.nango.dev/oauth/callback` (or your own [custom callback URL](https://nango.dev/docs/guides/auth/auth-guide.md#custom-oauth-callback-url-optional)). It must match exactly, or Melhor Envio answers `Client invalid`.
4. Save, then copy the **Client ID** and **Client Secret**.

**3. Add the credentials in Nango**

In your Melhor Envio integration in Nango, paste the client ID and secret, and add the [scopes](https://docs.melhorenvio.com.br/reference/fluxo-de-autoriza%C3%A7%C3%A3o) your integration needs, for example `users-read`, `shipping-calculate` and `shipping-tracking`.

**4. Next**

Follow the [*Quickstart*](https://nango.dev/docs/getting-started/quickstart.md).

For more details, see [Melhor Envio's authorization flow](https://docs.melhorenvio.com.br/reference/fluxo-de-autoriza%C3%A7%C3%A3o).

***


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.