This provider is currently in preview.
published on Thursday, May 21, 2026 by Pulumi
This provider is currently in preview.
published on Thursday, May 21, 2026 by Pulumi
Generates a new access token scoped to a specific team within an organization. Team tokens inherit the stack permissions assigned to the team, making them suitable for CI/CD pipelines that need access limited to a specific set of stacks.
The name field must be unique across the organization (including deleted tokens) and cannot exceed 40 characters. The expires field accepts a unix epoch timestamp up to two years from the present, or 0 for no expiry (default).
Important: The token value in the response is only returned once at creation time and cannot be retrieved later.
Create TeamToken Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new TeamToken(name: string, args: TeamTokenArgs, opts?: CustomResourceOptions);@overload
def TeamToken(resource_name: str,
args: TeamTokenArgs,
opts: Optional[ResourceOptions] = None)
@overload
def TeamToken(resource_name: str,
opts: Optional[ResourceOptions] = None,
description: Optional[str] = None,
expires: Optional[int] = None,
name: Optional[str] = None,
org_name: Optional[str] = None,
team_name: Optional[str] = None,
reason: Optional[str] = None)func NewTeamToken(ctx *Context, name string, args TeamTokenArgs, opts ...ResourceOption) (*TeamToken, error)public TeamToken(string name, TeamTokenArgs args, CustomResourceOptions? opts = null)
public TeamToken(String name, TeamTokenArgs args)
public TeamToken(String name, TeamTokenArgs args, CustomResourceOptions options)
type: pulumiservice:api/tokens:TeamToken
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "pulumiservice_api_tokens_teamtoken" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args TeamTokenArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args TeamTokenArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args TeamTokenArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args TeamTokenArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args TeamTokenArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var teamTokenResource = new PulumiService.Api.Tokens.TeamToken("teamTokenResource", new()
{
Description = "string",
Expires = 0,
Name = "string",
OrgName = "string",
TeamName = "string",
Reason = "string",
});
example, err := tokens.NewTeamToken(ctx, "teamTokenResource", &tokens.TeamTokenArgs{
Description: pulumi.String("string"),
Expires: pulumi.Int(0),
Name: pulumi.String("string"),
OrgName: pulumi.String("string"),
TeamName: pulumi.String("string"),
Reason: pulumi.String("string"),
})
resource "pulumiservice_api_tokens_teamtoken" "teamTokenResource" {
description = "string"
expires = 0
name = "string"
org_name = "string"
team_name = "string"
reason = "string"
}
var teamTokenResource = new TeamToken("teamTokenResource", TeamTokenArgs.builder()
.description("string")
.expires(0)
.name("string")
.orgName("string")
.teamName("string")
.reason("string")
.build());
team_token_resource = pulumiservice.api.tokens.TeamToken("teamTokenResource",
description="string",
expires=0,
name="string",
org_name="string",
team_name="string",
reason="string")
const teamTokenResource = new pulumiservice.api.tokens.TeamToken("teamTokenResource", {
description: "string",
expires: 0,
name: "string",
orgName: "string",
teamName: "string",
reason: "string",
});
type: pulumiservice:api/tokens:TeamToken
properties:
description: string
expires: 0
name: string
orgName: string
reason: string
teamName: string
TeamToken Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The TeamToken resource accepts the following input properties:
Outputs
All input properties are implicitly available as output properties. Additionally, the TeamToken resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Token
Id string - The unique identifier
- Token
Value string - The token value
- Id string
- The provider-assigned unique ID for this managed resource.
- Token
Id string - The unique identifier
- Token
Value string - The token value
- id string
- The provider-assigned unique ID for this managed resource.
- token_
id string - The unique identifier
- token_
value string - The token value
- id String
- The provider-assigned unique ID for this managed resource.
- token
Id String - The unique identifier
- token
Value String - The token value
- id string
- The provider-assigned unique ID for this managed resource.
- token
Id string - The unique identifier
- token
Value string - The token value
- id str
- The provider-assigned unique ID for this managed resource.
- token_
id str - The unique identifier
- token_
value str - The token value
- id String
- The provider-assigned unique ID for this managed resource.
- token
Id String - The unique identifier
- token
Value String - The token value
Package Details
- Repository
- pulumiservice pulumi/pulumi-pulumiservice
- License
- Apache-2.0
This provider is currently in preview.
published on Thursday, May 21, 2026 by Pulumi