elevenlabs/skills · Official

setup-api-key

Guides users through setting up an ElevenLabs API key for REST API and SDK workflows.

All-time #2363 Trending #2351 First seen Jan 27, 2026
8-week activity · all time api

Installation

$ npx skills add elevenlabs/skills --skill setup-api-key

Summary

  • Guides users through setting up an ElevenLabs API key for REST API and SDK workflows.
  • Use when the user needs to configure an ElevenLabs API key or when an API or SDK request fails because a key is missing.
  • First checks whether ELEVENLABS_API_KEY is already configured and valid, and only runs full setup when needed.

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from elevenlabs/skills · top by installs.

npx skills add elevenlabs/skills

Browse all from elevenlabs/skills

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Repository health

Stars 443
License LICENSE
Default branch main
Open issues 2
Status Active

Skill metadata

Parsed from SKILL.md frontmatter.

LicenseMIT
CompatibilityRequires internet access to elevenlabs.io and api.elevenlabs.io.

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 3,813 B
  • docs SUMMARY.md 338 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 6,206 installs

SKILL.md

ElevenLabs API Key Setup

Guide the user through obtaining and configuring an ElevenLabs API key.

Workflow

Step 0: Check for an existing API key first

Before asking the user for a key, check for an existing ELEVENLABSAPIKEY:

  1. Check whether ELEVENLABSAPIKEY exists in the current environment. If it does, use that value for this initial check.
  2. Only if it is not in the environment, check .env for ELEVENLABSAPIKEY=<value>.
  3. Do not print, quote, or repeat the key. If you mention it, redact it.
  4. If an existing key is found, validate it:

``text GET https://api.elevenlabs.io/v1/user Header: xi-api-key: <existing-api-key> ``

  1. If existing key validation succeeds:

- Tell the user ElevenLabs is already configured and working - Skip the setup flow - Ask whether they want to replace/rotate the key; if not, stop

  1. If existing key validation fails:

- Tell the user the existing key appears invalid or expired - Continue to Step 1

Step 1: Request the API key

Tell the user:

To set up ElevenLabs, open the API keys page: https://elevenlabs.io/app/settings/api-keys

(Need an account? Create one at https://elevenlabs.io/app/sign-up first)

If you don't have an API key yet:
1. Click "Create key"
2. Name it (or use the default)
3. Set permission for your key. If you provide a key with "User" permission set to "Read" this skill will automatically verify if your key works
4. Click "Create key" to confirm
5. Copy the key immediately - it's only shown once!

Do not paste the key into this chat. Instead, copy/paste it into your local .env file:

```
ELEVENLABSAPIKEY=your-api-key
```

If .env already has an ELEVENLABSAPIKEY=... line, replace that line.
Tell me when you've saved it, without sharing the key.

Then wait for the user to confirm that the key is saved locally.

Step 2: Validate and configure

After the user says the key is saved:

  1. Re-check both .env and the current environment for ELEVENLABSAPIKEY, but treat .env as the source of truth for this step.
  2. If .env contains a value, validate that value even when the current environment also has a different ELEVENLABSAPIKEY.
  3. If .env does not contain the key:

- Tell the user .env does not appear to contain ELEVENLABSAPIKEY. - Show the expected line again. - If the current environment does contain a key, note that this step still requires saving the key in .env. - Remind them not to paste the key into chat.

  1. If a .env key is found, validate it:

``text GET https://api.elevenlabs.io/v1/user Header: xi-api-key: <local-api-key> ``

  1. If validation fails:

- Tell the user the local key appears invalid or expired. - Remind them of the API keys page. - Ask them to replace the .env value and tell you when it is saved.

  1. If validation succeeds, confirm:

> Done. ElevenLabs is configured and the key in .env works.

Safety Rules

  • Never ask the user to paste an API key, token, or secret into chat.
  • Never print or echo API key values from environment variables or .env.
  • Prefer .env or managed secrets over shell history for persistent local configuration.
  • For browser or client-side apps, keep ELEVENLABSAPIKEY on the server and issue short-lived tokens where applicable.