spin docs
AI and data

AI keys

Add your own AI key for each provider, choose a model for each step, and know what each run costs.

AI steps run on your own API key. You add keys on the Settings page, in the AI keys card. You can add one key for each provider.

Providers and models

ProviderIn strategiesSuggested models (first: the default)
OpenAIopenaigpt-5.4-mini, gpt-5.4-nano, gpt-5.5
Anthropicanthropicclaude-haiku-4-5, claude-sonnet-5, claude-opus-5-5
Googlegooglegemini-3.5-flash-lite, gemini-3.5-flash, gemini-pro-latest
xAI (Grok)xaigrok-4.3, grok-latest
OpenRouteropenrouteropenai/gpt-5.4-mini, anthropic/claude-haiku-4-5, google/gemini-3.5-flash

The In strategies column is the name a step uses in its provider field. The models are suggestions: a step can name any model that the provider offers to your key. The first model in each row is the default. A step that names no model uses it.

Add a key

Get a key from the provider

On Settings, find the provider in AI keys. Click Add key, then Where to get a key to open the provider's key page. Make a key there.

Paste and test it

Paste the key into API key. Click Test and save. Spin makes one small test call with the key, to the provider's default model. This call is on your account.

Check the result

If the provider accepts the key, Spin seals it and saves it. The row shows Saved and "key ending" with the last 4 characters of the key. If the provider refuses the key, Spin does not save it and shows the provider's reason.

A key that the provider accepts passes the test, even if the provider does not offer the default model to that key.

Replace or remove a key

  • To change a key, click Replace on its row, paste the new key, and click Test and save.
  • To delete a key, click Remove. Steps that use that provider then give no signal, so the bot does not act on them.

Choose the key and model for a step

In the workflow editor, each AI step has an AI provider field and a Model field.

SettingWhat the step uses
AI provider: My newest keyYour most recently added or replaced key, with its provider's default model.
AI provider: a providerYour key for that provider.
Model emptyThe provider's default model.
Model filled inThat model. A model needs a provider.

In JSON, these are the step's provider and model fields:

{
  "id": "research",
  "provider": "anthropic",
  "model": "claude-haiku-4-5",
  "prompt": "Summarise what is known about the token {{token.address}}.",
  "output": { "summary": "text" }
}

A step that draws an image needs an OpenAI, xAI or Google key. If it names no provider, it uses your newest key that can draw images. See image steps.

If a step names a provider that you have no key for, the strategy still saves, and the editor shows a warning. That step gives no signal until you add the key. This lets a strategy work for a later holder who has that key.

What it costs, and who pays

You pay your provider for every call that runs on your key. Spin does not pay for AI calls, and it does not resell them.

A run costs more when:

  • the strategy has more steps (up to 3 in a run);
  • the prompt is longer, or it includes earlier answers;
  • a step reads MCP tools: each tool's description goes into the prompt, and each tool call sends data back to the model;
  • the model is larger or slower;
  • the step uses Grok's search of X or the web, which xAI bills on your key.

Small, fast models usually suit AI steps, because a step can run on many tokens. You control how many runs happen with the trigger, a cheap rule before the AI, and the AI runs an hour at most limit. See AI steps.

Your key is also used when you build a strategy with AI.

When a key fails

If the provider refuses your key, limits it, or has no credit left, the step gives no signal and the bot does not act. The Spinner's page then shows the problem under Needs your attention, for example "Your OpenAI key was refused" or "Your OpenAI key is limited". Fix the key in Settings, then mark the notice as read.

How Spin keeps your key

  • Spin seals (encrypts) each key before it stores it. A sealed key is bound to your account and its provider.
  • Only Spin's servers open the key, for one call at a time.
  • The app never shows the key again. It shows only the last 4 characters.
  • Your keys belong to you, not to a Spinner. When you sell a Spinner, its bot stops using your keys at once.

On this page