Skip to content
Grok by xAI

How to use Grok by xAI

Artificial intelligenceCost: 1 credit + 2 per runTechnical reference

What it is for

AI chatbot by xAI that answers questions, generates text, extracts data, and provides real-time insights.

Grok by xAI has no triggers: use it as an action in flows started by other apps, a schedule or a webhook.

Set up the connection

Authentication type: API key or token

  1. 1Sign in to Grok by xAI and look for the API or integrations section in its settings.
  2. 2Create an API key or token with the permissions you need and copy it.
  3. 3In flooows, add a Grok by xAI step, click "Connect" and paste it.
  4. 4Save the connection: it is stored encrypted and is never shown in plain text.

Credentials are stored encrypted in your isolated database, in Spain, and are never shown in plain text.

How to use it in a flow

  • Ask Grok: fill in Model, Messages; use the data selector to map values from earlier steps.
  • Extract Data From Text: fill in Model, Text to Extract From, Fields to Extract; use the data selector to map values from earlier steps.
  • Categorize Text: fill in Model, Text to Categorize, Categories; use the data selector to map values from earlier steps.

Tips

  • •Test each step before publishing to see the exact output structure.
  • •Enable retries on steps that call external services.

Actions (5)

Operations available as flow steps. Expand each one to see its fields.

Ask Grok18 fields
FieldTypeRequired
ModelList (from your account)Yes
MessagesList of valuesYes
Quick Prompt (Alternative)Long textNo
System InstructionsLong textNo
Image URL (Optional)TextNo
TemperatureNumberNo
Max Completion TokensNumberNo
Response FormatFixed listNo
JSON SchemaLong textNo
Enable Real-Time SearchYes / NoNo
Search ModeFixed listNo
Max Search ResultsNumberNo
Search SourcesMulti-selectNo
Tools/FunctionsList of valuesNo
Tool ChoiceFixed listNo
Parallel Tool CallsYes / NoNo
Reasoning EffortFixed listNo
Memory KeyTextNo
Extract Data From Text10 fields
FieldTypeRequired
ModelList (from your account)Yes
Text to Extract FromLong textYes
Extraction InstructionsLong textNo
Fields to ExtractList of valuesYes
Enable Context SearchYes / NoNo
Strict ExtractionYes / NoNo
TemperatureNumberNo
Max Completion TokensNumberNo
Reasoning EffortFixed listNo
Include Confidence ScoresYes / NoNo
Categorize Text10 fields
FieldTypeRequired
ModelList (from your account)Yes
Text to CategorizeLong textYes
CategoriesList of valuesYes
Allow Multiple CategoriesYes / NoNo
Include Confidence ScoresYes / NoNo
Custom InstructionsLong textNo
Enable Context SearchYes / NoNo
TemperatureNumberNo
Max Completion TokensNumberNo
Reasoning EffortFixed listNo
Generate Image4 fields
FieldTypeRequired
Image PromptLong textYes
Image ModelList (from your account)Yes
Number of ImagesNumberNo
Response FormatFixed listNo
Custom API Call10 fields
FieldTypeRequired
urlDynamic fieldsYes
MethodFixed listYes
HeadersKey / value pairsNo
Query ParametersKey / value pairsNo
Body TypeList (from your account)No
BodyDynamic fieldsNo
Response is BinaryYes / NoNo
Return Error as OutputYes / NoNo
TimeoutNumberNo
Follow redirectsYes / NoNo

Common errors

Authentication error

The connection expired or the key was revoked: reconnect it from Connections.

Field not found or empty

Re-test the previous step and remap the field in the data selector.

Field types

"List (from your account)" loads options from your connected account; "Dynamic fields" appear depending on earlier choices; in any field you can insert data from previous steps with the data selector (e.g. {{trigger.email}}). More about data between steps