tfe_organization_token

Generates a new organization token, replacing any existing token. This token can be used to act as the organization service account.

Example Usage

Basic usage:

resource "tfe_organization_token" "test" {
  organization = "my-org-name"
}

Argument Reference

The following arguments are supported:

Example Usage

When a token has an expiry:

resource "time_rotating" "example" {
  rotation_days = 30
}

resource "tfe_organization_token" "test" {
  organization = data.tfe_organization.org.name
  expired_at = time_rotating.example.rotation_rfc3339
}

Attributes Reference

Import

Organization tokens can be imported; use <ORGANIZATION NAME> as the import ID. For example:

terraform import tfe_organization_token.test my-org-name