Skip to main content
xAI provides direct, usage-billed API access to Grok models. This connection is separate from xAI Grok Subscription, which uses included SuperGrok or eligible X Premium+ plan capacity.

Get an API key

Create an API key in the xAI Console and enable billing for the account or team that should pay for Roomote usage.

Configuration

Add xAI in Settings > Models and paste the key, or configure:
Roomote exposes Grok models with the xai/ prefix. Enable the supported model and assign it to the coding or another role. If both xAI API and a Grok subscription are connected, Roomote prefers the subscription for xai/ models.

Cost behavior

API-key requests are billed by xAI according to model usage. Roomote records tokens and estimates cost from model metadata; the xAI Console and API pricing are authoritative. When a subscription is also connected, requests may consume the subscription allowance instead of API credits because it takes precedence.

Verify setup

  1. save XAI_API_KEY
  2. confirm xAI models appear in Settings > Models
  3. enable an xai/... model and assign it to a role
  4. run a small task and confirm usage in the xAI Console

Common issues

  • The API key is not used. Disconnect the Grok subscription if you want xai/ requests to use separately billed API capacity.
  • Authentication or credit errors occur. Check key status, team selection, billing, and spend limits in the xAI Console.
  • A model is unavailable. Refresh model metadata and confirm the API account can access the selected Grok model.