Use the API with Syntic Code
Syntic Code, the coding assistant for your terminal, normally doesn’t need an API key: you sign in with your browser and it keeps itself signed in. Use an API key only where a browser sign-in isn’t possible, such as a build server.
Normal sign-in: no key needed
Run syntic login (or type /login inside a session), sign in on syntic.ai and approve the request. Syntic Code then holds short-lived sign-in tokens and renews them in the background. It doesn’t create a long-lived API key for you.
Syntic Code needs a paid plan. On Free you’ll see “Your account is a free one. Please upgrade to use Syntic Code.” Installation and sign-in help: Install Syntic Code.
See and revoke signed-in terminals
Every browser sign-in creates a session you can review in the main Syntic app:
- Open Settings → API Access.
- Scroll to Connected CLIs. Each entry shows its label (usually “Syntic Code CLI”) and where it was first used.
- Choose Revoke on any session you don’t recognise or no longer use. You’ll see “Session revoked.”
If there are none, the panel reads “No active sessions.” A revoked terminal must sign in again.
Using an API key with Syntic Code
On machines without a browser, you can give Syntic Code a private sk_live_ key from the Console through the SYNTIC_API_KEY environment variable. When that variable is set, it is used before any saved sign-in.
A stray key in your shell overrides your normal sign-in. If Syntic Code is billing the wrong organization or says your key is invalid, unset the variable and run syntic auth status to check which credential is in use.
Usage made with a key is billed to the key’s organization, the same as any API call, and shows on the Console’s Billing Details page.
Keys that start with sk_syntic_
You may see keys with this prefix. They are created for Syntic Code and work with the API in the same way. They count toward your organization’s limit of 100 active keys.