Skip to content

Documentation

Grok API documentation

Use https://api.grokified.cyou/v1 as your OpenAI-compatible base URL, authenticate with a gk_live_ or gk_test_ access key, and call a current model from the live catalog. Grokified is an independent prepaid Grok API gateway — not xAI, not the official Grok console, and not Groq.

Pick a model id from the models guide or the live model catalog. Deeper guides cover streaming, tools, vision, image generation, video generation, and more.

New here? Create a key, set the base URL, send the smallest chat completion below — or install the CLI to wire agents in one command.

01

Grok API quickstart

Create an access key on the dashboard keys page, point your client at Grokified, and send a chat completion. The samples below use grok-4.7; any current text model works the same way.

First request checks

  • Base URL is https://api.grokified.cyou/v1 (host and path, not the marketing site).
  • Key prefix matches the environment: gk_live_ for production, gk_test_ for test — details in the authentication guide.
  • Every call includes Authorization: Bearer with your access key; there is no separate account or organization header.
  • Model id is a current slug from the models guide (samples here use grok-4.7).
  • If the response is not 200, match the status code in the errors and retries guide — retry only 429 and 5xx; fix 401, 402, and 403 in your config or account first.

If the first call fails: 401 → wrong or revoked key / missing Bearer · 402 → balance or billing on the account · 403 → environment or permission mismatch · 404/400 on model → use a current model id from the models guide · 429/5xx → retry per the errors guide. Fix config before retrying auth or payment errors. Full walkthrough: quickstart guide.

curl https://api.grokified.cyou/v1/chat/completions \
  -H "Authorization: Bearer $GROKIFIED_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "grok-4.7",
    "messages": [{"role": "user", "content": "Hello"}]
  }'

For the full signup-to-first-call walkthrough, open the quickstart guide. When you need token-by-token output, continue with streaming (server-sent events on the same host and key).

02

Authentication and Grok API keys

Grokified access keys authenticate every call to https://api.grokified.cyou/v1. Create a key from the dashboard keys page; the plaintext is shown once, so store it in a secret manager or environment variable immediately.

Production keys are prefixed gk_live_; test keys use gk_test_. Revoke compromised keys from the same dashboard view. The authentication guide covers Bearer headers, rotation, and what we never log.

Key lifecycle and first call

  1. Create an API key in the dashboard keys page (or through the existing sign-in flow).
  2. Copy it once and store it in an environment variable or secret manager.
  3. Send it as the documented Bearer credential on every request. Never expose it in browser code, committed files, screenshots, or logs.
  4. Rotate or revoke from the same dashboard when needed — create a replacement key first, switch your app, then revoke the old key.
  5. Confirm the base URL is https://api.grokified.cyou/v1, use a gk_* key, pick a current model from the models guide, and send the smallest chat completion from the quickstart below.
03

OpenAI-compatible Grok API setup

OpenAI-compatible quickstart

Point an OpenAI SDK client at https://api.grokified.cyou/v1, read your gk_live_ or gk_test_ key from an environment variable, and call chat completions with a current catalog model (grok-4.7 in the sample below).

curl https://api.grokified.cyou/v1/chat/completions \
  -H "Authorization: Bearer $GROKIFIED_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "grok-4.7",
    "messages": [{"role": "user", "content": "Hello"}]
  }'

Continue with the authentication, models, errors, and streaming guides rather than duplicating long setup docs here. Prepaid usage and live offers are on Grok API pricing; terminal install is on the Grokified CLI.

Switching from another provider is usually a one-line host change — see the migration guide.

04

Models and request guides

Model ids, streaming, tools, vision, image, video, and reference pages — each guide is written for api.grokified.cyou/v1 with a gk_ access key. Start with Models, then open the guide that matches what you are building. For product overviews, see image generation and video generation API.

From the blog

How to Get a Grok API KeyGet a Grok API key in about two minutes: sign up, open Access keys, create a key, and send a first request in curl, Python or Node. No card to sign up, and $5 free credit that unlocks with your first payment.→Grok API with the OpenAI SDKThe OpenAI SDK talks to Grok with a base URL swap. What changed in 2026: grok-3 and grok-code-fast-1 are retired, Chat Completions is now the legacy path, and three OpenAI parameters return errors on reasoning models.→Grok API Function CallingAgents don't make one API call, they make a dozen. Here's how function calling works on the Grok API, and why a 50% cheaper token price compounds fast once your app is looping through tool calls.→Grok API for Coding AgentsEvery one of these agents takes an OpenAI-compatible base URL, which means pointing them at Grokified is a two-field change. The hard part is stopping an autonomous loop before it spends money you did not agree to. Here is the config for each agent, the exact HTTP Grokified returns when the money runs out, and the 200K context cliff that doubles a bill in one paragraph.→Grok API Data ResidencyxAI added a US regional endpoint for the Grok API on 14 September 2026. It costs 10% more, serves two text models, and covers less than most people assume. Here is exactly what it guarantees, what it does not, and who actually needs it.→OpenRouter Alternative for GrokOpenRouter bills Grok at list price plus a 5.5% top-up fee. Grokified powers your IDE and agents with Grok models at 50% below list. Here is the fee math, side by side.→
05

Grok API pricing

Grokified is prepaid API access: you fund a balance or plan, and each request draws down credits from usage metadata. Mutable token, image, and video rates live on the public pricing page, not in this overview.

For how discounts, top-ups, subscriptions, and per-call metering work, read Pricing & credits in the docs. Need help choosing a track? The help center covers billing FAQs.

06

Build with Grokified

Grokified powers the agents and editors you already run. For curated setup paths, use the dedicated surfaces below — each documents base URL, key, and model fields for that tool.

  • Agents — configure Cursor, Claude Code, Cline, Continue, and other coding agents against Grokified.
  • Cheap Grok API for Cursor — Cursor BYOK deep-dive: base URL, key, and half-price prepaid usage.
  • CLI — one command that wires common agents to your Grokified key and host.
  • Playground — browser UI for chat, image, and video without leaving the dashboard session.

Prefer a terminal install? Use the Grokified CLI to store your key and point supported agents at api.grokified.cyou/v1. API host, key lifecycle, and first request stay on this page.

Editors with a custom OpenAI-compatible provider slot only need the host, key, and a model id — see IDE integration below for VS Code, Cursor, and other clients.

08

Data handling

Grokified keeps a copy of each request and its response, including generated images and video, in private storage for 30 days so you can review it from the request details on your Usage page. It is then deleted automatically. We do not use that content to train any model.

We keep account data, billing records, and usage metadata (model, tokens, status, timestamps) so we can charge the request. Generated images and video may be mirrored to our object storage so the URL stays valid after the original link expires.

Full detail is in the Privacy Policy.

07

IDE integration (BYOK)

Any editor or coding agent that accepts a custom provider works with Grokified. Point it at the base URL below and paste your gk_live_ access key. Usage bills against your Grokified prepaid balance — see pricing and Pricing & credits for how metering works.

Base URLhttps://api.grokified.cyou/v1
Access keygk_live_… (your Grokified key)
Modelgrok-4.7

Use grok-4.7 where the editor sends the id you type verbatim. Brand aliases such as grokified-4.6 still resolve to the full model id.

VS CODE (GITHUB COPILOT CHAT)

Copilot Chat reads a chatLanguageModels.json array of custom providers. Open Chat, run Manage Models, add a custom provider, and paste the entry below (or drop it into chatLanguageModels.json). Then pick Grokified in the model picker.

CHATLANGUAGEMODELS.JSON
[
  {
    "name": "GROKIFIED",
    "vendor": "customendpoint",
    "apiKey": "${input:chat.lm.secret.grokified}",
    "apiType": "chat-completions",
    "models": [
      {
        "id": "grok-4.7",
        "name": "grok-4.7",
        "url": "https://api.grokified.cyou/v1",
        "apiType": "chat-completions",
        "toolCalling": true,
        "vision": true,
        "maxInputTokens": 500000,
        "maxOutputTokens": 16000
      }
    ]
  }
]

CURSOR

Settings → Models → add a custom provider, set the fields below, and add a model named grok-4.7. For a step-by-step Cursor path at half-price prepaid usage, see Cheap Grok API for Cursor.

ProviderGrokified
Base URLhttps://api.grokified.cyou/v1
Access keygk_live_...
Modelgrok-4.7

OTHER EDITORS AND AGENTS

ContinueAdd a custom model with your Grokified base URL, access key, and model: grok-4.7 in config.yaml.
Cline / Roo CodeChoose the custom provider slot, then set Base URL, Access Key, and Model ID grok-4.7.
ZedSet the custom model base URL in settings.json; enter your access key in the agent panel.
AiderSet OPENAI_API_BASE and OPENAI_API_KEY, then run with --model openai/grok-4.7.
Anything elseAny editor with a custom provider field: set the base URL, access key, and model.
09

FAQ

Short answers for setup, keys, compatibility, and pricing ownership.

How do I get a Grokified API key?

Create one in the Grokified dashboard keys page after sign-in, store it as a secret, and use it as the documented Bearer key. Start with /docs/quickstart — do not put a real key in client code or logs.

What base URL does the Grokified API use?

https://api.grokified.cyou/v1. Point your OpenAI-compatible client at that host, send your access key as a Bearer token, and use a current model id such as grok-4.6.

Are Grokified keys compatible with OpenAI SDK clients?

Use the documented OpenAI-compatible client configuration with base URL https://api.grokified.cyou/v1 and your gk_* key. Follow the OpenAI-compatible quickstart on /docs for the supported request shape and a current catalog model.

What do the gk_live_ and gk_test_ key prefixes mean?

gk_live_ keys bill against your live Grokified balance for production traffic. gk_test_ keys target the test environment. Create and revoke either from the dashboard at any time.

How do I rotate or revoke a Grokified API key?

Create a new key on the dashboard keys page, update your app to use it, then revoke the old key from the same view. Revoked keys return 401 immediately with no grace period. See /docs/authentication for Bearer headers, the one-time plaintext reveal, and safe storage.

Is Grokified the official xAI API or console?

No. Grokified is an independent prepaid API product. It is not xAI, not the official Grok console, and not affiliated with xAI. You use Grokified credentials and billing. Prompt caching is automatic, so repeat calls use more than 80% fewer tokens than direct API calls.

Is Grokified the same as Groq?

No. Groq is a different company and API. Grokified is an independent prepaid gateway for Grok models with base URL https://api.grokified.cyou/v1 and gk_live_ / gk_test_ keys. If you landed on a Groq keys page, that is not Grokified.

Where can I find Grok API pricing and current rates?

Use grokified.cyou/pricing for plans and prepaid top-ups, and /docs/pricing for how credits and per-request costs are calculated. Rates change; those pages stay current.

Where do I start if I want my first request to work?

Follow the Grok API quickstart on this page: create a key, set base URL https://api.grokified.cyou/v1, send a chat completion, then open the streaming guide if you need server-sent events.

Why did my first Grokified API request fail?

Use the First request checks in the quickstart section on /docs: confirm base URL https://api.grokified.cyou/v1, a gk_live_ or gk_test_ key in the Authorization header, and a current model id from /docs/models. For status codes and when to retry, see /docs/errors; for keys and rotation, /docs/authentication.

Do I need to rewrite my integration?

Usually not. Keep the client you already use and change only the base URL and access key.

What happens to retired models?

Requests to retired model slugs are automatically routed to their current replacements, so older integrations keep working.

Does Grokified store my prompts?

For 30 days. Each request and its response is kept in private storage so you can review it from the request details on your Usage page, then deleted automatically. It is never used to train any model.