{ "opencollection": "1.0.0", "info": { "name": "github-repos-api Environments API", "version": "1.1.4" }, "items": [ { "info": { "name": "Environments", "type": "folder" }, "items": [ { "info": { "name": "GitHub List Environments", "type": "http" }, "http": { "method": "GET", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "per_page", "value": "", "type": "query", "description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/using-pagination-in-the-rest-api).\"" }, { "name": "page", "value": "", "type": "query", "description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/using-pagination-in-the-rest-api).\"" } ] }, "docs": "Lists the environments for a repository.\n\nAnyone with read access to the repository can use this endpoint.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint with a private repository." }, { "info": { "name": "GitHub Get an Environment", "type": "http" }, "http": { "method": "GET", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ] }, "docs": "**Note:** To get information about name patterns that branches must match in order to deploy to this environment, see \"[Get deployment branch policy](/rest/deployments/branch-policies#get-a-deployment-branch-policy).\"\n\nAnyone with read access to the repository can use this endpoint.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint with a private repository." }, { "info": { "name": "GitHub Create or Update an Environment", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Create or update an environment with protection rules, such as required reviewers. For more information about environment protection rules, see \"[Environments](/actions/reference/environments#environment-protection-rules).\"\n\n**Note:** To create or update name patterns that branches must match in order to deploy to this environment, see \"[Deployment branch policies](/rest/deployments/branch-policies).\"\n\n**Note:** To create or update secrets for an environment, see \"[GitHub Actions secrets](/rest/" }, { "info": { "name": "GitHub Delete an Environment", "type": "http" }, "http": { "method": "DELETE", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ] }, "docs": "OAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub List Environment Secrets", "type": "http" }, "http": { "method": "GET", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/secrets", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." }, { "name": "per_page", "value": "", "type": "query", "description": "The number of results per page (max 100). For more information, see \"[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/using-pagination-in-the-rest-api).\"" }, { "name": "page", "value": "", "type": "query", "description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/using-pagination-in-the-rest-api).\"" } ] }, "docs": "Lists all secrets available in an environment without revealing their\nencrypted values.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Get an Environment Public Key", "type": "http" }, "http": { "method": "GET", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/secrets/public-key", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ] }, "docs": "Get the public key for an environment, which you need to encrypt environment\nsecrets. You need to encrypt a secret before you can create or update secrets.\n\nAnyone with read access to the repository can use this endpoint.\n\nIf the repository is private, OAuth tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Get an Environment Secret", "type": "http" }, "http": { "method": "GET", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/secrets/:secret_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." }, { "name": "secret_name", "value": "", "type": "path", "description": "The name of the secret." } ] }, "docs": "Gets a single environment secret without revealing its encrypted value.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.\n\nOAuth tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Create or Update an Environment Secret", "type": "http" }, "http": { "method": "PUT", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/secrets/:secret_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." }, { "name": "secret_name", "value": "", "type": "path", "description": "The name of the secret." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Creates or updates an environment secret with an encrypted value. Encrypt your secret using\n[LibSodium](https://libsodium.gitbook.io/doc/bindings_for_other_languages). For more information, see \"[Encrypting secrets for the REST API](https://docs.github.com/enterprise-server@3.9/rest/guides/encrypting-secrets-for-the-rest-api).\"\n\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.\n\nOAuth tokens and personal access tokens (classic) need the `repo` " }, { "info": { "name": "GitHub Delete an Environment Secret", "type": "http" }, "http": { "method": "DELETE", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/secrets/:secret_name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." }, { "name": "secret_name", "value": "", "type": "path", "description": "The name of the secret." } ] }, "docs": "Deletes a secret in an environment using the secret name.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read secrets.\n\nOAuth tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub List Environment Variables", "type": "http" }, "http": { "method": "GET", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/variables", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." }, { "name": "per_page", "value": "", "type": "query", "description": "The number of results per page (max 30). For more information, see \"[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/using-pagination-in-the-rest-api).\"" }, { "name": "page", "value": "", "type": "query", "description": "The page number of the results to fetch. For more information, see \"[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.9/rest/using-the-rest-api/using-pagination-in-the-rest-api).\"" } ] }, "docs": "Lists all environment variables.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Create an Environment Variable", "type": "http" }, "http": { "method": "POST", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/variables", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Create an environment variable that you can reference in a GitHub Actions workflow.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.\n\nOAuth tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Get an Environment Variable", "type": "http" }, "http": { "method": "GET", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/variables/:name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." }, { "name": "name", "value": "", "type": "path", "description": "The name of the variable." } ] }, "docs": "Gets a specific variable in an environment.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.\n\nOAuth tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Update an Environment Variable", "type": "http" }, "http": { "method": "PATCH", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/variables/:name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "name", "value": "", "type": "path", "description": "The name of the variable." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ], "body": { "type": "json", "data": "{}" } }, "docs": "Updates an environment variable that you can reference in a GitHub Actions workflow.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.\n\nOAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." }, { "info": { "name": "GitHub Delete an Environment Variable", "type": "http" }, "http": { "method": "DELETE", "url": "{protocol}://{hostname}/repos/:owner/:repo/environments/:environment_name/variables/:name", "headers": [ { "name": "Authorization", "value": "example_value" }, { "name": "X-GitHub-Api-Version", "value": "example_value" }, { "name": "Accept", "value": "example_value" } ], "params": [ { "name": "owner", "value": "", "type": "path", "description": "The account owner of the repository. The name is not case sensitive." }, { "name": "repo", "value": "", "type": "path", "description": "The name of the repository without the `.git` extension. The name is not case sensitive." }, { "name": "name", "value": "", "type": "path", "description": "The name of the variable." }, { "name": "environment_name", "value": "", "type": "path", "description": "The name of the environment. The name must be URL encoded. For example, any slashes in the name must be replaced with `%2F`." } ] }, "docs": "Deletes an environment variable using the variable name.\n\nAuthenticated users must have collaborator access to a repository to create, update, or read variables.\n\nOAuth tokens and personal access tokens (classic) need the `repo` scope to use this endpoint." } ] } ], "bundled": true }