Generate an API Key

Generate an API key to easily connect deepset AI Platform to your solution. You'll need it to use API endpoints or when working in an SDK.

About This Task

When creating an API key, you can set its permissions by choosing a role and selecting the workspaces it can access.

You can also choose the type of API key: personal or service.

  • Personal keys are linked to the user who created them. Use this type for testing or personal projects.
  • Service keys are not linked to a specific user. Instead of a username, the search history will show the key name as the actor. Use this type for production applications and systems that connect to the deepset AI Platform.

Prerequisites

Learn about available roles and their permissions to choose the right one for your key. Check Managing Access.

Generate an API Key

In deepset AI Platform

  1. Click your profile icon in the top right corner and select API Keys.

    The settings menu expanded with the connections option higlighted
  2. One the API Keys page, click Create API Key.

  3. Configure the key:

    1. Choose if it's a personal key or a service key.
      Tip: Choose the Service type for production use cases and systems that connect to deepset.
    2. Give it a name. This is optional, if you don't type any name, the key ID is used.
    3. Set the expiration date.
    4. Assign a role to the key.
    5. Choose the workspaces this key can access. If you don't choose any, it will have access to all workspaces in the organization.
  4. Click Create API Key.

  5. Important: Copy and save your key; after you add it to deepset AI Platform, it remains masked.

  6. Click Done.

Using REST API

Use the Create Token API endpoint to create your API keys.