---
title: "List machine types for a codespace"
method: GET
path: "/user/codespaces/{codespace_name}/machines"
tags: ["codespaces"]
---

# List machine types for a codespace

`GET /user/codespaces/{codespace_name}/machines`

List the machine types a codespace can transition to use.

OAuth app tokens and personal access tokens (classic) need the `codespace` scope to use this endpoint.

## Path parameters

- `codespace_name` string, required

## Response `200`

Response

- object
  - `total_count` integer, required
  - `machines` CodespaceMachine[], required
    - `name` string, required — The name of the machine.
    - `display_name` string, required — The display name of the machine includes cores, memory, and storage.
    - `operating_system` string, required — The operating system of the machine.
    - `storage_in_bytes` integer, required — How much storage is available to the codespace.
    - `memory_in_bytes` integer, required — How much memory is available to the codespace.
    - `cpus` integer, required — How many cores are available to the codespace.
    - `prebuild_availability` 'none' | 'ready' | 'in_progress', nullable, required — Whether a prebuild is currently available when creating a codespace for this machine and repository. If a branch was not specified as a ref, the default branch will be assumed. Value will be "null" if prebuilds are not supported or prebuild availability could not be determined. Value will be "none" if no prebuild is available. Latest values "ready" and "in_progress" indicate the prebuild availability status.

## Other responses

- `304` — Not modified
- `401` — Requires authentication
- `403` — Forbidden
- `404` — Resource not found
- `500` — Internal Error

---

[API](https://skmtc.net/github/apis/github-v3-rest-api-2.md) · [All operations](https://skmtc.net/github/apis/github-v3-rest-api-2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/github/github-v3-rest-api-2/versions/8ae6d0c8716e/schema)
