Chat xAI (Grok)
Chat xAI (Grok)
Section titled “Chat xAI (Grok)”Use xAI Grok chat models.
What it does
Section titled “What it does”Provides access to xAI’s Grok chat models for AI agent nodes. xAI exposes an OpenAI-compatible API, so this node runs the OpenAI client against xAI’s base URL.
When to use it
Section titled “When to use it”Connect this to AI agents when you want to use xAI’s Grok models, such as grok-2-latest, for text generation or conversation.
Inputs and settings
Section titled “Inputs and settings”| Setting | Notes |
|---|---|
| Model | The xAI model to use, e.g. grok-2-latest. Placeholder: grok-2-latest. |
| Authentication | Credential used to authenticate: “Use your xAI API key as a Bearer token.” |
| Options → Temperature | The temperature to use for the model. |
| Options → Max Retries | The maximum number of retries to use for the model. Defaults to 2. |
Outputs
Section titled “Outputs”Returns a chat model dependency that can be connected to AI agent nodes.
Dependencies and credentials
Section titled “Dependencies and credentials”- Requires an Authentication credential holding your xAI API key, sent as a Bearer token.
- The node throws an error if Model is empty.
Example workflow
Section titled “Example workflow”Connect Chat xAI (Grok) to an AI agent or dependency input that accepts this dependency type, set the Model to a Grok model such as grok-2-latest, attach your xAI API key credential, then run the agent with data from previous nodes.
Troubleshooting
Section titled “Troubleshooting”- Ensure Model is filled in — the node rejects an empty value.
- If it calls an external service, verify credentials, permissions, and rate limits.
- No dedicated source test was found next to this node; verify behavior manually when changing this page.