SpyBara
Go Premium

rest-api-reference/files.md 2026-09-03 16:59 UTC to 2026-09-07 22:57 UTC

This page contains 1 addition and 0 deletions.

2026
Mon 7 22:57 Wed 16 19:01

Files API

Files REST API Overview

The Files API lets you upload, manage, and retrieve files for use with Grok models. Files can be attached to chat messages for document understanding, or added to collections for semantic search.

The base URL for all file operations is https://api.x.ai. You have to authenticate with the header Authorization: Bearer <your xAI API key>.