Skip to main content
GitHub Docs
Version:
Free, Pro, & Team
Search GitHub Docs
REST API
/
Codespaces
All products
REST API
API Version:
2022-11-28 (latest)
Quickstart
Overview
Guides
REST API reference
Actions
Activity
Apps
Billing
Branches
Checks
Codes of conduct
Code Scanning
Codespaces
Codespaces
Organizations
Organization secrets
Machines
Repository secrets
User secrets
Collaborators
Commits
Copilot
Dependabot
Dependency Graph
Deploy keys
Deployments
Emojis
Gists
Git database
Gitignore
Interactions
Issues
Licenses
Markdown
Meta
Metrics
Migrations
Organizations
Packages
Pages
Projects (classic)
Pulls
Rate limit
Reactions
Releases
Repositories
Search
Secret scanning
Security advisories
Teams
Users
Repository webhooks
The REST API is now versioned.
For more information, see "
About API versioning
."
REST API
/
Codespaces
Codespaces
Use the REST API to manage GitHub Codespaces.
Codespaces
List codespaces in a repository for the authenticated user
Create a codespace in a repository
List devcontainer configurations in a repository for the authenticated user
Get default attributes for a codespace
Create a codespace from a pull request
List codespaces for the authenticated user
Create a codespace for the authenticated user
Get a codespace for the authenticated user
Update a codespace for the authenticated user
Delete a codespace for the authenticated user
Export a codespace for the authenticated user
Get details about a codespace export
Create a repository from an unpublished codespace
Start a codespace for the authenticated user
Stop a codespace for the authenticated user
Machines
List available machine types for a repository
List machine types for a codespace
Organization secrets
List organization secrets
Get an organization public key
Get an organization secret
Create or update an organization secret
Delete an organization secret
List selected repositories for an organization secret
Set selected repositories for an organization secret
Add selected repository to an organization secret
Remove selected repository from an organization secret
Organizations
List codespaces for the organization
Manage access control for organization codespaces
Add users to Codespaces access for an organization
Remove users from Codespaces access for an organization
List codespaces for a user in organization
Delete a codespace from the organization
Stop a codespace for an organization user
Repository secrets
List repository secrets
Get a repository public key
Get a repository secret
Create or update a repository secret
Delete a repository secret
Secrets
List secrets for the authenticated user
Get public key for the authenticated user
Get a secret for the authenticated user
Create or update a secret for the authenticated user
Delete a secret for the authenticated user
List selected repositories for a user secret
Set selected repositories for a user secret
Add a selected repository to a user secret
Remove a selected repository from a user secret