Class GithubCredentials
- java.lang.Object
-
- software.amazon.jsii.JsiiObject
-
- io.github.cdklabs.projen.github.GithubCredentials
-
- All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable
@Generated(value="jsii-pacmak/1.96.0 (build 921e240)", date="2024-03-28T21:16:43.082Z") @Stability(Experimental) public class GithubCredentials extends software.amazon.jsii.JsiiObject
(experimental) Represents a method of providing GitHub API access for projen workflows.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedGithubCredentials(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)protectedGithubCredentials(software.amazon.jsii.JsiiObjectRef objRef)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static GithubCredentialsfromApp()(experimental) Provide API access through a GitHub App.static GithubCredentialsfromApp(GithubCredentialsAppOptions options)(experimental) Provide API access through a GitHub App.static GithubCredentialsfromPersonalAccessToken()(experimental) Provide API access through a GitHub personal access token.static GithubCredentialsfromPersonalAccessToken(GithubCredentialsPersonalAccessTokenOptions options)(experimental) Provide API access through a GitHub personal access token.List<JobStep>getSetupSteps()(experimental) Setup steps to obtain GitHub credentials.StringgetTokenRef()(experimental) The value to use in a workflow when a GitHub token is expected.-
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
-
-
-
-
Method Detail
-
fromApp
@Stability(Experimental) @NotNull public static GithubCredentials fromApp(@Nullable GithubCredentialsAppOptions options)
(experimental) Provide API access through a GitHub App.The GitHub App must be installed on the GitHub repo, its App ID and a private key must be added as secrets to the repo. The name of the secrets can be specified here.
Default: - app id stored in "PROJEN_APP_ID" and private key stored in "PROJEN_APP_PRIVATE_KEY" with all permissions attached to the app
- Parameters:
options-- See Also:
- https://projen.io/github.html#github-app
-
fromApp
@Stability(Experimental) @NotNull public static GithubCredentials fromApp()
(experimental) Provide API access through a GitHub App.The GitHub App must be installed on the GitHub repo, its App ID and a private key must be added as secrets to the repo. The name of the secrets can be specified here.
Default: - app id stored in "PROJEN_APP_ID" and private key stored in "PROJEN_APP_PRIVATE_KEY" with all permissions attached to the app
- See Also:
- https://projen.io/github.html#github-app
-
fromPersonalAccessToken
@Stability(Experimental) @NotNull public static GithubCredentials fromPersonalAccessToken(@Nullable GithubCredentialsPersonalAccessTokenOptions options)
(experimental) Provide API access through a GitHub personal access token.The token must be added as a secret to the GitHub repo, and the name of the secret can be specified here.
Default: - a secret named "PROJEN_GITHUB_TOKEN"
- Parameters:
options-- See Also:
- https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token
-
fromPersonalAccessToken
@Stability(Experimental) @NotNull public static GithubCredentials fromPersonalAccessToken()
(experimental) Provide API access through a GitHub personal access token.The token must be added as a secret to the GitHub repo, and the name of the secret can be specified here.
Default: - a secret named "PROJEN_GITHUB_TOKEN"
-
getSetupSteps
@Stability(Experimental) @NotNull public List<JobStep> getSetupSteps()
(experimental) Setup steps to obtain GitHub credentials.
-
getTokenRef
@Stability(Experimental) @NotNull public String getTokenRef()
(experimental) The value to use in a workflow when a GitHub token is expected.This typically looks like "${{ some.path.to.a.value }}".
-
-