Skip to content

Set-GitHubOidcSubjectClaim

SYNOPSIS

Set the customization template for an OIDC subject claim

SYNTAX

Set the customization template for an OIDC subject claim for an organization (Default)

Set-GitHubOidcSubjectClaim -Owner <string> -IncludeClaimKeys <string[]> [-Context <Object>]
 [-WhatIf] [-Confirm] [<CommonParameters>]

Set the customization template for an OIDC subject claim for a repository

Set-GitHubOidcSubjectClaim -Owner <string> -Repository <string> -IncludeClaimKeys <string[]>
 [-UseDefault] [-Context <Object>] [-WhatIf] [-Confirm] [<CommonParameters>]

ALIASES

This cmdlet has the following aliases, {{Insert list of aliases}}

DESCRIPTION

Creates or updates the customization template for an OpenID Connect (OIDC) subject claim for an organization or repository.

For repositories, when UseDefault is true, the IncludeClaimKeys are ignored by the API.

EXAMPLES

EXAMPLE 1

Set-GitHubOidcSubjectClaim -Owner 'PSModule' -IncludeClaimKeys @('repo', 'context')

Sets the OIDC subject claim customization template for the 'PSModule' organization.

EXAMPLE 2

Set-GitHubOidcSubjectClaim -Owner 'PSModule' -Repository 'GitHub' -IncludeClaimKeys @('repo', 'context')

Sets the OIDC subject claim customization template for the 'GitHub' repository with custom claim keys.

EXAMPLE 3

Set-GitHubOidcSubjectClaim -Owner 'PSModule' -Repository 'GitHub' -UseDefault -IncludeClaimKeys @('repo')

Resets the OIDC subject claim customization for the 'GitHub' repository to use the default template.

PARAMETERS

-Confirm

Prompts you for confirmation before running the cmdlet.

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases:
- cf
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Context

The context to run the command in. Used to get the details for the API call. Can be either a string or a GitHubContext object.

Type: System.Object
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-IncludeClaimKeys

Array of unique strings. Each claim key can only contain alphanumeric characters and underscores.

Type: System.String[]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Owner

The account owner of the repository or the organization name. The name is not case sensitive.

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases:
- User
- Organization
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: true
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Repository

The name of the repository without the .git extension. The name is not case sensitive.

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: Set the customization template for an OIDC subject claim for a repository
  Position: Named
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: true
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-UseDefault

Whether to use the default subject claim template for the repository. When true, the IncludeClaimKeys are ignored by the API.

Type: System.Management.Automation.SwitchParameter
DefaultValue: False
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: Set the customization template for an OIDC subject claim for a repository
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-WhatIf

Runs the command in a mode that only reports what would happen without performing the actions.

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases:
- wi
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

System.String

{{ Fill in the Description }}

OUTPUTS

System.Void

{{ Fill in the Description }}

NOTES

Set the customization template for an OIDC subject claim for an organization Set the customization template for an OIDC subject claim for a repository