<commit_before>---
description: Details generating and using an Auth0 Management APIv2 token.
section: apis
toc: true
---

# The Auth0 Management APIv2 Token

## Overview

In order to call the endpoints of [Auth0 Management API v2](/api/management/v2), you need a token, what we refer to as Auth0 Management APIv2 Token. This token is a [JWT](/jwt), contains specific granted permissions (known as __scopes__), and is signed with a client API key and secret for the entire tenant.

There are two ways to get a Management APIv2 Token:
- [get one manually using the Dashboard](#get-a-token-manually), or
- [automate the process](#automate-the-process) (build a simple command line tool that generates tokens).

In this article we will see how you can do either.

## Get a token manually

<div class="alert alert-warning">
  <strong>Heads up!</strong> Before you decide to follow the manual process, you should know that the Management APIv2 token has a validity of <strong>24 hours</strong>. After that the token will expire and you will have to get a new one. If this doesn't work for you, you can <a href="#automate-the-process">automate the process</a>.
</div>

Let's see how you can get a token manually. Note, that the first two steps of the process need to be executed _only_ the first time. This might be true also for the third step, if the endpoints you need to access do not change. In that case you can skip to the [Get the Token](#4-get-the-token) section.

### 1. Create a Client

First, you need to create a Non Interactive Client. We recommend creating one exclusively for authorizing access to the Management API, instead of reusing another one you might have. If you already have done that, you can skip this paragraph.<commit_msg>Add alert for new doc<commit_after>---
description: Details generating and using an Auth0 Management APIv2 token.
section: apis
toc: true
---

# The Auth0 Management APIv2 Token

<div class="alert alert-info">
  We recently changed the way you get Management APIv2 tokens. To read what we changed, why we did that, and how you can work around these changes refer to <a href="/api/management/v2/tokens-flows">Changes in Auth0 Management APIv2 Tokens</a>.
</div>

## Overview

In order to call the endpoints of [Auth0 Management API v2](/api/management/v2), you need a token, what we refer to as Auth0 Management APIv2 Token. This token is a [JWT](/jwt), contains specific granted permissions (known as __scopes__), and is signed with a client API key and secret for the entire tenant.

There are two ways to get a Management APIv2 Token:
- [get one manually using the Dashboard](#get-a-token-manually), or
- [automate the process](#automate-the-process) (build a simple command line tool that generates tokens).

In this article we will see how you can do either.

## Get a token manually

<div class="alert alert-warning">
  <strong>Heads up!</strong> Before you decide to follow the manual process, you should know that the Management APIv2 token has a validity of <strong>24 hours</strong>. After that the token will expire and you will have to get a new one. If this doesn't work for you, you can <a href="#automate-the-process">automate the process</a>.
</div>

Let's see how you can get a token manually. Note, that the first two steps of the process need to be executed _only_ the first time. This might be true also for the third step, if the endpoints you need to access do not change. In that case you can skip to the [Get the Token](#4-get-the-token) section.

### 1. Create a Client

First, you need to create a Non Interactive Client. We recommend creating one exclusively for authorizing access to the Management API, instead of reusing another one you might have. If you already have done that, you can skip this paragraph.
{'fraction_non_alphanumeric': 0.0719006079830822, 'fraction_numerical': 0.008987575997885276, 'mean_word_length': 4.240997229916897, 'pattern_counts': {'":': 0, '<': 23, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5611678', 'n_tokens_mistral': 1020, 'n_tokens_neox': 989, 'n_words': 585}