Skip to content

Platform · 3 November 2026

GitHub Codespaces API for Dev environments

The Codespaces endpoints of GitHub's REST API are served under /compat/github, so Octokit and other GitHub clients manage Dev environments by changing only their base URL and token (Authorization: token <key> or Bearer <key>). Supported: create in a repository (POST /repos/{owner}/{repo}/codespaces), list, list in a repository, get, update the display name, start, stop, delete, and machine types for a repository or a codespace. Lists are paginated with page and per_page (30 by default, at most 100), return the full count in total_count, and return a Link header to the next and last pages. The machine types basicLinux32gb, standardLinux32gb (the default), premiumLinux and largePremiumLinux create an environment with 2, 4, 8 or 16 vCPUs and 8, 16, 32 or 64 GiB of memory, billed by measured use. Stop pauses the environment with its memory kept. A field Dev environments does not support yet, such as devcontainer_path, returns 400 with its name.

Same day.

Cut your cloud billby 75%.

No card to start. Billed by the second after.

Start free, no card