View Source GitHub.Codespaces (GitHub REST API Client v0.0.9)
Provides API endpoints related to codespaces
Link to this section Summary
Functions
Add a selected repository to a user secret
Add selected repository to an organization secret
List machine types for a codespace
Create a codespace for the authenticated user
Create or update an organization secret
Create or update a repository secret
Create or update a secret for the authenticated user
Create a codespace from a pull request
Create a codespace in a repository
Removes users from Codespaces billing for an organization
Delete a codespace for the authenticated user
Delete a codespace from the organization
Delete an organization secret
Delete a repository secret
Delete a secret for the authenticated user
Export a codespace for the authenticated user
List codespaces for a user in organization
Get details about a codespace export
Get a codespace for the authenticated user
Get an organization public key
Get an organization secret
Get public key for the authenticated user
Get a repository public key
Get a repository secret
Get a secret for the authenticated user
List devcontainer configurations in a repository for the authenticated user
List codespaces for the authenticated user
List codespaces for the organization
List codespaces in a repository for the authenticated user
List organization secrets
List repository secrets
List selected repositories for a user secret
List secrets for the authenticated user
List selected repositories for an organization secret
Get default attributes for a codespace
Create a repository from an unpublished codespace
Remove a selected repository from a user secret
Remove selected repository from an organization secret
List available machine types for a repository
Manage access control for organization codespaces
Add users to Codespaces billing for an organization
Set selected repositories for a user secret
Set selected repositories for an organization secret
Start a codespace for the authenticated user
Stop a codespace for the authenticated user
Stop a codespace for an organization user
Update a codespace for the authenticated user
Link to this section Functions
add_repository_for_secret_for_authenticated_user(secret_name, repository_id, opts \\ [])
View Source@spec add_repository_for_secret_for_authenticated_user( String.t(), integer(), keyword() ) :: :ok | {:error, GitHub.Error.t()}
Add a selected repository to a user secret
resources
Resources
add_selected_repo_to_org_secret(org, secret_name, repository_id, opts \\ [])
View Source@spec add_selected_repo_to_org_secret(String.t(), String.t(), integer(), keyword()) :: :ok | {:error, GitHub.Error.t()}
Add selected repository to an organization secret
resources
Resources
codespace_machines_for_authenticated_user(codespace_name, opts \\ [])
View Source@spec codespace_machines_for_authenticated_user( String.t(), keyword() ) :: {:ok, map()} | {:error, GitHub.Error.t()}
List machine types for a codespace
resources
Resources
@spec create_for_authenticated_user( map(), keyword() ) :: {:ok, GitHub.Codespace.t()} | {:error, GitHub.Error.t()}
Create a codespace for the authenticated user
resources
Resources
@spec create_or_update_org_secret(String.t(), String.t(), map(), keyword()) :: {:ok, GitHub.EmptyObject.t()} | {:error, GitHub.Error.t()}
Create or update an organization secret
resources
Resources
create_or_update_repo_secret(owner, repo, secret_name, body, opts \\ [])
View Source@spec create_or_update_repo_secret( String.t(), String.t(), String.t(), map(), keyword() ) :: {:ok, GitHub.EmptyObject.t()} | {:error, GitHub.Error.t()}
Create or update a repository secret
resources
Resources
create_or_update_secret_for_authenticated_user(secret_name, body, opts \\ [])
View Source@spec create_or_update_secret_for_authenticated_user(String.t(), map(), keyword()) :: {:ok, GitHub.EmptyObject.t()} | {:error, GitHub.Error.t()}
Create or update a secret for the authenticated user
resources
Resources
create_with_pr_for_authenticated_user(owner, repo, pull_number, body, opts \\ [])
View Source@spec create_with_pr_for_authenticated_user( String.t(), String.t(), integer(), map() | nil, keyword() ) :: {:ok, GitHub.Codespace.t()} | {:error, GitHub.Error.t()}
Create a codespace from a pull request
resources
Resources
create_with_repo_for_authenticated_user(owner, repo, body, opts \\ [])
View Source@spec create_with_repo_for_authenticated_user( String.t(), String.t(), map() | nil, keyword() ) :: {:ok, GitHub.Codespace.t()} | {:error, GitHub.Error.t()}
Create a codespace in a repository
resources
Resources
@spec delete_codespaces_billing_users(String.t(), map(), keyword()) :: :ok | {:error, GitHub.Error.t()}
Removes users from Codespaces billing for an organization
resources
Resources
@spec delete_for_authenticated_user( String.t(), keyword() ) :: {:ok, map()} | {:error, GitHub.Error.t()}
Delete a codespace for the authenticated user
resources
Resources
delete_from_organization(org, username, codespace_name, opts \\ [])
View Source@spec delete_from_organization(String.t(), String.t(), String.t(), keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
Delete a codespace from the organization
resources
Resources
@spec delete_org_secret(String.t(), String.t(), keyword()) :: :ok | {:error, GitHub.Error.t()}
Delete an organization secret
resources
Resources
@spec delete_repo_secret(String.t(), String.t(), String.t(), keyword()) :: :ok | {:error, GitHub.Error.t()}
Delete a repository secret
resources
Resources
@spec delete_secret_for_authenticated_user( String.t(), keyword() ) :: :ok | {:error, GitHub.Error.t()}
Delete a secret for the authenticated user
resources
Resources
@spec export_for_authenticated_user( String.t(), keyword() ) :: {:ok, GitHub.Codespace.ExportDetails.t()} | {:error, GitHub.Error.t()}
Export a codespace for the authenticated user
resources
Resources
@spec get_codespaces_for_user_in_org(String.t(), String.t(), keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
List codespaces for a user in organization
options
Options
per_page
(integer): The number of results per page (max 100).page
(integer): Page number of the results to fetch.
resources
Resources
get_export_details_for_authenticated_user(codespace_name, export_id, opts \\ [])
View Source@spec get_export_details_for_authenticated_user(String.t(), String.t(), keyword()) :: {:ok, GitHub.Codespace.ExportDetails.t()} | {:error, GitHub.Error.t()}
Get details about a codespace export
resources
Resources
@spec get_for_authenticated_user( String.t(), keyword() ) :: {:ok, GitHub.Codespace.t()} | {:error, GitHub.Error.t()}
Get a codespace for the authenticated user
resources
Resources
@spec get_org_public_key( String.t(), keyword() ) :: {:ok, GitHub.Codespace.PublicKey.t()} | {:error, GitHub.Error.t()}
Get an organization public key
resources
Resources
@spec get_org_secret(String.t(), String.t(), keyword()) :: {:ok, GitHub.Codespace.OrgSecret.t()} | {:error, GitHub.Error.t()}
Get an organization secret
resources
Resources
@spec get_public_key_for_authenticated_user(keyword()) :: {:ok, GitHub.Codespace.UserPublicKey.t()} | {:error, GitHub.Error.t()}
Get public key for the authenticated user
resources
Resources
@spec get_repo_public_key(String.t(), String.t(), keyword()) :: {:ok, GitHub.Codespace.PublicKey.t()} | {:error, GitHub.Error.t()}
Get a repository public key
resources
Resources
@spec get_repo_secret(String.t(), String.t(), String.t(), keyword()) :: {:ok, GitHub.RepoCodespacesSecret.t()} | {:error, GitHub.Error.t()}
Get a repository secret
resources
Resources
@spec get_secret_for_authenticated_user( String.t(), keyword() ) :: {:ok, GitHub.Codespace.Secret.t()} | {:error, GitHub.Error.t()}
Get a secret for the authenticated user
resources
Resources
list_devcontainers_in_repository_for_authenticated_user(owner, repo, opts \\ [])
View Source@spec list_devcontainers_in_repository_for_authenticated_user( String.t(), String.t(), keyword() ) :: {:ok, map()} | {:error, GitHub.Error.t()}
List devcontainer configurations in a repository for the authenticated user
options
Options
per_page
(integer): The number of results per page (max 100).page
(integer): Page number of the results to fetch.
resources
Resources
@spec list_for_authenticated_user(keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
List codespaces for the authenticated user
options
Options
per_page
(integer): The number of results per page (max 100).page
(integer): Page number of the results to fetch.repository_id
(integer): ID of the Repository to filter on
resources
Resources
@spec list_in_organization( String.t(), keyword() ) :: {:ok, map()} | {:error, GitHub.Error.t()}
List codespaces for the organization
options
Options
per_page
(integer): The number of results per page (max 100).page
(integer): Page number of the results to fetch.
resources
Resources
list_in_repository_for_authenticated_user(owner, repo, opts \\ [])
View Source@spec list_in_repository_for_authenticated_user(String.t(), String.t(), keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
List codespaces in a repository for the authenticated user
options
Options
per_page
(integer): The number of results per page (max 100).page
(integer): Page number of the results to fetch.
resources
Resources
@spec list_org_secrets( String.t(), keyword() ) :: {:ok, map()} | {:error, GitHub.Error.t()}
List organization secrets
options
Options
per_page
(integer): The number of results per page (max 100).page
(integer): Page number of the results to fetch.
resources
Resources
@spec list_repo_secrets(String.t(), String.t(), keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
List repository secrets
options
Options
per_page
(integer): The number of results per page (max 100).page
(integer): Page number of the results to fetch.
resources
Resources
list_repositories_for_secret_for_authenticated_user(secret_name, opts \\ [])
View Source@spec list_repositories_for_secret_for_authenticated_user( String.t(), keyword() ) :: {:ok, map()} | {:error, GitHub.Error.t()}
List selected repositories for a user secret
resources
Resources
@spec list_secrets_for_authenticated_user(keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
List secrets for the authenticated user
options
Options
per_page
(integer): The number of results per page (max 100).page
(integer): Page number of the results to fetch.
resources
Resources
@spec list_selected_repos_for_org_secret(String.t(), String.t(), keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
List selected repositories for an organization secret
options
Options
page
(integer): Page number of the results to fetch.per_page
(integer): The number of results per page (max 100).
resources
Resources
pre_flight_with_repo_for_authenticated_user(owner, repo, opts \\ [])
View Source@spec pre_flight_with_repo_for_authenticated_user(String.t(), String.t(), keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
Get default attributes for a codespace
options
Options
ref
(String.t()): The branch or commit to check for a default devcontainer path. If not specified, the default branch will be checked.client_ip
(String.t()): An alternative IP for default location auto-detection, such as when proxying a request.
resources
Resources
@spec publish_for_authenticated_user(String.t(), map(), keyword()) :: {:ok, GitHub.Codespace.WithFullRepository.t()} | {:error, GitHub.Error.t()}
Create a repository from an unpublished codespace
resources
Resources
remove_repository_for_secret_for_authenticated_user(secret_name, repository_id, opts \\ [])
View Source@spec remove_repository_for_secret_for_authenticated_user( String.t(), integer(), keyword() ) :: :ok | {:error, GitHub.Error.t()}
Remove a selected repository from a user secret
resources
Resources
remove_selected_repo_from_org_secret(org, secret_name, repository_id, opts \\ [])
View Source@spec remove_selected_repo_from_org_secret( String.t(), String.t(), integer(), keyword() ) :: :ok | {:error, GitHub.Error.t()}
Remove selected repository from an organization secret
resources
Resources
@spec repo_machines_for_authenticated_user(String.t(), String.t(), keyword()) :: {:ok, map()} | {:error, GitHub.Error.t()}
List available machine types for a repository
options
Options
location
(String.t()): The location to check for available machines. Assigned by IP if not provided.client_ip
(String.t()): IP for location auto-detection when proxying a request
resources
Resources
@spec set_codespaces_billing(String.t(), map(), keyword()) :: :ok | {:error, GitHub.Error.t()}
Manage access control for organization codespaces
resources
Resources
@spec set_codespaces_billing_users(String.t(), map(), keyword()) :: :ok | {:error, GitHub.Error.t()}
Add users to Codespaces billing for an organization
resources
Resources
set_repositories_for_secret_for_authenticated_user(secret_name, body, opts \\ [])
View Source@spec set_repositories_for_secret_for_authenticated_user(String.t(), map(), keyword()) :: :ok | {:error, GitHub.Error.t()}
Set selected repositories for a user secret
resources
Resources
set_selected_repos_for_org_secret(org, secret_name, body, opts \\ [])
View Source@spec set_selected_repos_for_org_secret(String.t(), String.t(), map(), keyword()) :: :ok | {:error, GitHub.Error.t()}
Set selected repositories for an organization secret
resources
Resources
@spec start_for_authenticated_user( String.t(), keyword() ) :: {:ok, GitHub.Codespace.t()} | {:error, GitHub.Error.t()}
Start a codespace for the authenticated user
resources
Resources
@spec stop_for_authenticated_user( String.t(), keyword() ) :: {:ok, GitHub.Codespace.t()} | {:error, GitHub.Error.t()}
Stop a codespace for the authenticated user
resources
Resources
@spec stop_in_organization(String.t(), String.t(), String.t(), keyword()) :: {:ok, GitHub.Codespace.t()} | {:error, GitHub.Error.t()}
Stop a codespace for an organization user
resources
Resources
@spec update_for_authenticated_user(String.t(), map(), keyword()) :: {:ok, GitHub.Codespace.t()} | {:error, GitHub.Error.t()}
Update a codespace for the authenticated user