Grok Endpoints

Ask Grok

Ask Grok with a Twitter account cookie.

post/v3/twitter/grok/ask

Request

  • Base URL: https://api.twexapi.io
  • URL: https://api.twexapi.io/v3/twitter/grok/ask
  • Auth: HTTP bearer

Request body

promptstring required

User prompt.

conversation_idstring nullable

Continue an existing Grok conversation.

modelstring nullable

Optional model id (default grok-3-latest).

cookiestring required

The user's own authorized Twitter session credentials or auth_token (BYOC — Bring Your Own Cookie). Stateless proxy execution with zero credential retention. See Authentication Security and How to get Cookie.

proxystring nullable

Optional HTTP proxy. Example: http://username:password@ip:port

Example request

{
  "prompt": "Say hi in one sentence.",
  "conversation_id": "2076320454898278729",
  "model": "grok-3-latest",
  "cookie": "ct0=abc123... or 2c4a4e1832096aa694c739b83c83b6d96d43eba7",
  "proxy": "http://username:password@ip:port"
}

Response

Grok response result.

codeinteger required

Response code

msgstring required

Response message

Example response

{
  "code": 200,
  "msg": "success",
  "data": {
    "conversation_id": "2076320454898278729",
    "message": "Hi there!",
    "reasoning": "Thinking about your request",
    "follow_up_suggestions": [
      {
        "label": "Learn about conversational AI"
      }
    ]
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.