To chat with an AI model through a tool such as ChatJPT, you first need to get an API key. Think of it as a password that connects your requests to your account with an AI provider. The good news is that it takes only a few minutes. This article is part of the guide to using ChatJPT.
An API key is a long sequence of characters, often beginning with a prefix such as sk-. It allows software to call a provider’s AI models on your behalf. Requests are therefore billed to your account based on usage: you pay for what you consume.
Important: treat an API key like a password. Anyone who gets hold of it may be able to use your credits.
With most providers, getting an API key follows a similar process:
Copy it immediately: many providers display the full key only once.
The API_KEYS_GUIDE.txt file supplied with ChatJPT lists these addresses in French, English, and Spanish.
Once you’ve copied the key, open ChatJPT and click the key panel at the top left. Find the provider under its country and paste the key into its field. The provider’s badge then changes to ✓.
The key is encrypted in your browser’s storage and sent only to the matching provider. On a shared computer, the erase button removes all saved keys at once.
Pricing depends on the model and usage volume. An ordinary conversation typically costs a fraction of a cent. Models that reason for longer, image generation, and especially video generally cost more.
To stay in control, ChatJPT displays the tokens used for each response and a total for the conversation. Most developer consoles also let you set a monthly spending limit; that is a sensible step from the start.
In every case, ChatJPT displays the provider’s exact error message in parentheses, which makes it easier to identify the problem.
With one key, you’re ready to go. A particularly useful first experiment is to get keys from two providers and compare two AI models using the same question.