# Grok API 公测版发布

- 来源：xAI：News（网页）
- 发布时间：2024-11-04 08:00
- AIHOT 标记：精选
- AIHOT 链接：https://aihot.virxact.com/items/cmnwsvjeh005usltetv1i8jim
- 原文链接：https://x.ai/news/api

## 精选理由

xAI开放Grok API公测，每月送$25额度且兼容OpenAI接口，开发者可立即体验

## AI 摘要

xAI 启动 Grok API 公测，发布新模型 grok-beta，支持 128k 上下文、函数调用及系统提示，视觉版本下周上线。开发者每月可获 $25 免费额度至年底，已购预付额度可叠加。API 兼容 OpenAI 与 Anthropic 格式，修改 base_url 即可迁移。

## 正文

API Public Beta | xAI

Back to news

Nov 4, 2024

API Public Beta

Starting today, developers can build on our Grok foundation models using our newly released API. We will run a public beta program until the end of 2024 during which everyone will get $25 of free API credits per month.

Models Free credits API

We are happy to announce the immediate availability of our API, which gives developers programmatic access to our Grok series of foundation models. To get started, head to console.x.ai and sign up to create an account. We are excited to see what developers build using Grok.**

Models

We are kicking off our public beta with a preview of a new Grok model that is currently in the final stages of development. The model – released under the provisional name grok-beta – has a context length of 128,000 tokens and also supports function calling and system prompts. We will release more information about the model shortly.

In addition to the text-only version of the model grok-beta, we will also release a multi-modal version that can ingest images. The vision model will be available next week.

Free credits

We will run a public beta program throughout the end of the year. Everyone will get $25 of free API credits per month to test the API and get started using Grok.

Anyone who has purchased prepaid credits so far will get the equivalent amount of free monthly credits for every month until the end of the year. For example, if you purchased $50 of prepaid credits already, you will now have $25 + $50 of additional free credits in November and December.

API

To learn more about our API, check out our documentation at docs.x.ai. Our REST API is fully compatible with the ones offered by OpenAI and Anthropic. This simplifies migration. For example, if you’re currently using the OpenAI Python SDK, you can start using Grok by simply changing the base_url to https://api.x.ai/v1 and using your xAI API key that you created on console.x.ai.

Copy dark SVG

Copy light SVG
