Skip to content

Grok

Grok is a family of AI models and an API from SpaceXAI (formerly xAI) for building chat assistants that can call tools, and optionally use live search to include current information from the web and X.

Developers access Grok through a REST Responses API, the recommended interface, which supports prompting and function calling to integrate external tools. A legacy chat-completions endpoint is still available. For coding work, xAI also offers a Code API and Grok Build, an extensible coding agent that runs in your terminal, reads the repository it’s started in, edits files, runs shell commands, and searches the web. Its harness is open source under the Apache 2.0 license. For up-to-date information, Grok can call xAI’s server-side search tools (web_search and x_search) that retrieve current data from the web, news, and X. You enable them by including the tools in a request, and Grok invokes them as needed. These agentic tools replaced the original Live Search API, the per-request search_parameters mechanism, which xAI retired in early 2026. Requests to it now return HTTP 410 Gone. xAI has also released the Grok-1 base model weights and architecture under the Apache 2.0 license for local experimentation outside the hosted API.

Official website: grok.com

How to Use the OpenRouter API to Access Multiple AI Models via Python

Tutorial

How to Use the OpenRouter API to Access Multiple AI Models via Python

Access models from popular AI providers in Python through OpenRouter's unified API with smart routing, fallbacks, and cost controls.

intermediate ai api

For additional information on related topics, take a look at the following resources:


By Leodanis Pozo Ramos • Updated Aug. 9, 2026 • Reviewed by Martin Breuss