Skip to main content

How do I create API keys within a Workspace?

Updated this week

API keys are used to authenticate applications and scripts when they interact with Mistral AI services.

Keys created in a Workspace are scoped to that Workspace. They only grant access to its resources, and their usage is tracked separately in usage reports.

Open your Workspace settings

First, open your Workspace settings. You can do this in two ways:

From Mistral AI Studio

  1. Click on your Organization name / Workspace name in the top left corner.

  2. Select your Workspace from the dropdown menu then click the “gear” icon to open the Workspace settings.

image

Select your Workspace and open its settings

From the Workspaces list on the Admin Console

  1. Go to the main Workspaces list page (showing all your Workspaces).

  2. Find the Workspace you want to manage.

  3. Click ... to open the actions menu and select Settings or Members.

image

Open the actions menu for a Workspace and select the relevant option

Create a new API key

Open the API Keys tab then click Create new key.

image

Click the Create new key button

A modal opens with options:

  1. Name (optional): Add a label to help identify the key later (e.g., “Pipeline integration” or “Project X”).

  2. Expiration (optional): Set an expiry date. After this date, the key will stop working.

🔑 We recommend setting an expiration date and regularly rotating API keys (create a new key and delete the old one).

When ready, click Create new key.

image

Configure the API key with optional name and expiration date

Copy and store the key

A confirmation modal will display the key once, in full.

🚨 This is the only time the full key will be shown. Copy it immediately and store it securely (e.g., password manager, secrets vault). It cannot be retrieved again after closing the modal.

Click Done when finished. The key will now appear in the list, with only part of it visible for reference.

Delete an API key

If a key is compromised or no longer needed, locate it in the Active tab and click the “trash” icon twice to confirm deletion.

image

Click the “trash” icon to delete an API key

Creating API Keys from the Admin Console

In addition to creating keys directly from your Workspace settings, you can also create API keys from the Admin Console interface.

🔑 API keys created this way must still be scoped to a Workspace. Organization-level keys are not supported.

Did this answer your question?