1. SDKs & Tools
  2. SDKs
  3. .NET SDK
  4. Keys

Keys

The DeepgramClient class provides access to manage API keys via the Keys property. Each request is project based and will require a Deepgram project id.

List Project API Keys

You can retrieve all keys for a given project using the ListKeysAsync method.

var keys = await deepgram.Keys.ListKeysAsync("DEEPGRAM_PROJECT_ID");

Get Specific API Key

You can retrieve a specific API key for a given project using the GetKeyAsync method. You will need the API keys unique id.

var response = await deepgram.Keys.GetKeyAsync("DEEPGRAM_PROJECT_ID", "KEY_ID");

Create API Key

Create a new API key for a project using the CreateKeyAsync method with a name for the key.

var response = await deepgram.Keys.CreateKeyAsync("DEEPGRAM_PROJECT_ID", "NAME_FOR_KEY", new string[] {"member"});

Delete API Key

Delete an existing API key using the DeleteKeyAsync method with project id and key id to delete.

var response = await deepgram.Keys.DeleteKeyAsync("DEEPGRAM_PROJECT_ID", "KEY_ID");

FEEDBACK