Index Ai Academy
Glossary · Phase 0 · Tools

API key

Also written: API keys

A secret password-like string that identifies you to an API. Never share it or put it in code.

An API key is a long random string that identifies your account to an API, something like sk-ant-api03-Xk2.... Every request you send carries it. That way the provider knows whose request it is, what that account may do, and who to bill.

Try it now

Programs started from this terminal can now read GRADIENT_API_KEY. Close the window and it's gone.

Learn it properly

API keys and secrets · Authenticate safely and keep keys out of your code. About 25 minutes.

Start this free lesson

Other terms from the same lesson

Never trained an AI?

Teach a small one to write, right in your browser. It takes about 20 seconds and needs no account.

Teach it to write