Passer au contenu principal

Managing your API keys in Mark AI

Écrit par Kilian
Mis à jour aujourd’hui

The API Keys page allows you to create and manage your access keys for the Mark AI API.

This page is accessible from the left navigation menu, under the Developers label. It is only visible if the Developers feature is enabled for your workspace. If you cannot see it, contact your administrator or Mark AI support.

For the full technical API documentation, visit the Mark AI API reference.

Creating an API key

Creating an API key takes just a few steps from the API Keys page.

  1. Click the Create API Key button located in the top right corner of the page.

  2. In the dialog that appears, select the workspace the key will belong to. Each key is tied to a single workspace. It will only grant access to the resources within that workspace.

  3. Enter a name for your key in the "Key name" field. This name is only used to help you identify the key later. Choose a descriptive name, such as "Production", "Staging", or "Zapier Integration".

  4. Click Create to confirm.

Your API key is now displayed on screen. Copy it immediately using the dedicated copy button.

⚠️ Important: the full key is only shown once, at the time of creation. Mark AI will not be able to display it again afterwards. Store it in a secure location, such as a password manager. If you lose your key, you will need to revoke it and create a new one.

Revoking an API key

Revoking a key means permanently deactivating it. Any integration or script using that key will immediately stop working.

  1. Locate the key you want to revoke in the table.

  2. Click the actions menu (three-dot icon) on the right side of the corresponding row.

  3. Select Revoke.

  4. Confirm your choice in the confirmation dialog that appears.

⚠️ Revocation is immediate and irreversible. There is no way to undo this action or reactivate a revoked key. If you need access again, you will have to create an entirely new API key and update your integrations accordingly.

Monitoring your usage

At the top of the API Keys page, a summary card shows your knowledge base imports consumption. This counter indicates the number of documents imported via the API compared to the limit included in your plan. For example, "0 out of 2,000" means you have not yet used any imports during the current period.

A bar chart displays your import history over the last 30 days. This chart helps you visualize usage spikes and anticipate your needs.

There is an important distinction to keep in mind. The import limit applies to your entire company, meaning all workspaces combined. However, the chart only shows imports made within the current workspace. To get a complete view of your company's consumption, check the data in each workspace separately.

Security best practices

Keeping your API keys secure is essential to protect your data and your workspaces. Here are the recommendations to follow.

Never share an API key in a chat conversation, an email, or a Slack channel. Never embed it directly in your project's source code, and especially not in a code repository such as GitHub or GitLab. Use environment variables or a secrets manager instead.

Remember to rotate your keys periodically. To do this, create a new key, update your integration with the new key, then revoke the old one. Regular rotation limits the risk in case of a leak.

If you suspect a key has been exposed or compromised, revoke it immediately and create a new one without delay.

Frequently asked questions

I lost my API key. How can I retrieve it?

It is not possible to recover an API key after creation. The full key is only displayed once. If you have lost it, go to the API Keys page, revoke the key in question, then create a new one. Do not forget to update your integrations with the new key.

My integration suddenly stopped working. What should I do?

Check the status of your key in the table on the API Keys page. If the status reads "Revoked", the key has been deactivated and can no longer be used. Create a new key and configure it in your integration to restore the connection.

Does the usage chart show data from all my workspaces?

No. The chart only displays imports made in the workspace you are currently viewing. However, the import limit in your plan applies to your entire company, across all workspaces combined.

I cannot see the Developers page in my navigation menu. Why?

The Developers page is only visible if this feature is enabled for your workspace. Contact your administrator or Mark AI support to request its activation.

Managing your API keys is a key step in making the most of the Mark AI API. By following the best practices described in this article, you ensure secure and controlled access to your workspace.

To go further and explore the available endpoints, visit the full API documentation.

Avez-vous trouvé la réponse à votre question ?