Google Cloud Classic v7.29.0 published on Wednesday, Jun 26, 2024 by Pulumi
gcp.tags.getTagKey
Explore with Pulumi AI
Get a tag key by org or project parent
and short_name
.
Example Usage
data "google_tags_tag_key" "environment_tag_key"{
parent = "organizations/12345"
short_name = "environment"
}
data "google_tags_tag_key" "environment_tag_key"{
parent = "projects/abc"
short_name = "environment"
}
Using getTagKey
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getTagKey(args: GetTagKeyArgs, opts?: InvokeOptions): Promise<GetTagKeyResult>
function getTagKeyOutput(args: GetTagKeyOutputArgs, opts?: InvokeOptions): Output<GetTagKeyResult>
def get_tag_key(parent: Optional[str] = None,
short_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetTagKeyResult
def get_tag_key_output(parent: Optional[pulumi.Input[str]] = None,
short_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetTagKeyResult]
func LookupTagKey(ctx *Context, args *LookupTagKeyArgs, opts ...InvokeOption) (*LookupTagKeyResult, error)
func LookupTagKeyOutput(ctx *Context, args *LookupTagKeyOutputArgs, opts ...InvokeOption) LookupTagKeyResultOutput
> Note: This function is named LookupTagKey
in the Go SDK.
public static class GetTagKey
{
public static Task<GetTagKeyResult> InvokeAsync(GetTagKeyArgs args, InvokeOptions? opts = null)
public static Output<GetTagKeyResult> Invoke(GetTagKeyInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetTagKeyResult> getTagKey(GetTagKeyArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: gcp:tags/getTagKey:getTagKey
arguments:
# arguments dictionary
The following arguments are supported:
- parent str
- The resource name of the parent organization or project. It can be in format
organizations/{org_id}
orprojects/{project_id_or_number}
. - short_
name str - The tag key's short_name.
getTagKey Result
The following output properties are available:
- Create
Time string - Creation time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- Description string
- Id string
- an identifier for the resource with format
tagKeys/{{name}}
- Name string
- The generated numeric id for the TagKey.
- Namespaced
Name string - Namespaced name of the TagKey which is in the format
{parentNamespace}/{shortName}
. - Parent string
- Short
Name string - Update
Time string - Update time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- Create
Time string - Creation time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- Description string
- Id string
- an identifier for the resource with format
tagKeys/{{name}}
- Name string
- The generated numeric id for the TagKey.
- Namespaced
Name string - Namespaced name of the TagKey which is in the format
{parentNamespace}/{shortName}
. - Parent string
- Short
Name string - Update
Time string - Update time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- create
Time String - Creation time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- description String
- id String
- an identifier for the resource with format
tagKeys/{{name}}
- name String
- The generated numeric id for the TagKey.
- namespaced
Name String - Namespaced name of the TagKey which is in the format
{parentNamespace}/{shortName}
. - parent String
- short
Name String - update
Time String - Update time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- create
Time string - Creation time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- description string
- id string
- an identifier for the resource with format
tagKeys/{{name}}
- name string
- The generated numeric id for the TagKey.
- namespaced
Name string - Namespaced name of the TagKey which is in the format
{parentNamespace}/{shortName}
. - parent string
- short
Name string - update
Time string - Update time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- create_
time str - Creation time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- description str
- id str
- an identifier for the resource with format
tagKeys/{{name}}
- name str
- The generated numeric id for the TagKey.
- namespaced_
name str - Namespaced name of the TagKey which is in the format
{parentNamespace}/{shortName}
. - parent str
- short_
name str - update_
time str - Update time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- create
Time String - Creation time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- description String
- id String
- an identifier for the resource with format
tagKeys/{{name}}
- name String
- The generated numeric id for the TagKey.
- namespaced
Name String - Namespaced name of the TagKey which is in the format
{parentNamespace}/{shortName}
. - parent String
- short
Name String - update
Time String - Update time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
Package Details
- Repository
- Google Cloud (GCP) Classic pulumi/pulumi-gcp
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
google-beta
Terraform Provider.