We recommend using Azure Native.
Viewing docs for Azure v4.42.0 (Older version)
published on Monday, Mar 9, 2026 by Pulumi
published on Monday, Mar 9, 2026 by Pulumi
We recommend using Azure Native.
Viewing docs for Azure v4.42.0 (Older version)
published on Monday, Mar 9, 2026 by Pulumi
published on Monday, Mar 9, 2026 by Pulumi
Use this data source to access information about an existing Container Registry token.
Example Usage
using Pulumi;
using Azure = Pulumi.Azure;
class MyStack : Stack
{
public MyStack()
{
var example = Output.Create(Azure.ContainerService.GetRegistryToken.InvokeAsync(new Azure.ContainerService.GetRegistryTokenArgs
{
Name = "exampletoken",
ResourceGroupName = "example-resource-group",
ContainerRegistryName = "example-registry",
}));
this.ScopeMapId = example.Apply(example => example.ScopeMapId);
}
[Output("scopeMapId")]
public Output<string> ScopeMapId { get; set; }
}
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v4/go/azure/containerservice"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := containerservice.LookupRegistryToken(ctx, &containerservice.LookupRegistryTokenArgs{
Name: "exampletoken",
ResourceGroupName: "example-resource-group",
ContainerRegistryName: "example-registry",
}, nil)
if err != nil {
return err
}
ctx.Export("scopeMapId", example.ScopeMapId)
return nil
})
}
Example coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = azure.containerservice.getRegistryToken({
name: "exampletoken",
resourceGroupName: "example-resource-group",
containerRegistryName: "example-registry",
});
export const scopeMapId = example.then(example => example.scopeMapId);
import pulumi
import pulumi_azure as azure
example = azure.containerservice.get_registry_token(name="exampletoken",
resource_group_name="example-resource-group",
container_registry_name="example-registry")
pulumi.export("scopeMapId", example.scope_map_id)
Example coming soon!
Using getRegistryToken
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 getRegistryToken(args: GetRegistryTokenArgs, opts?: InvokeOptions): Promise<GetRegistryTokenResult>
function getRegistryTokenOutput(args: GetRegistryTokenOutputArgs, opts?: InvokeOptions): Output<GetRegistryTokenResult>def get_registry_token(container_registry_name: Optional[str] = None,
name: Optional[str] = None,
resource_group_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetRegistryTokenResult
def get_registry_token_output(container_registry_name: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
resource_group_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetRegistryTokenResult]func LookupRegistryToken(ctx *Context, args *LookupRegistryTokenArgs, opts ...InvokeOption) (*LookupRegistryTokenResult, error)
func LookupRegistryTokenOutput(ctx *Context, args *LookupRegistryTokenOutputArgs, opts ...InvokeOption) LookupRegistryTokenResultOutput> Note: This function is named LookupRegistryToken in the Go SDK.
public static class GetRegistryToken
{
public static Task<GetRegistryTokenResult> InvokeAsync(GetRegistryTokenArgs args, InvokeOptions? opts = null)
public static Output<GetRegistryTokenResult> Invoke(GetRegistryTokenInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetRegistryTokenResult> getRegistryToken(GetRegistryTokenArgs args, InvokeOptions options)
public static Output<GetRegistryTokenResult> getRegistryToken(GetRegistryTokenArgs args, InvokeOptions options)
fn::invoke:
function: azure:containerservice/getRegistryToken:getRegistryToken
arguments:
# arguments dictionaryThe following arguments are supported:
- Container
Registry stringName - The Name of the Container Registry where the token exists.
- Name string
- The name of the Container Registry token.
- Resource
Group stringName - The Name of the Resource Group where this Container Registry token exists.
- Container
Registry stringName - The Name of the Container Registry where the token exists.
- Name string
- The name of the Container Registry token.
- Resource
Group stringName - The Name of the Resource Group where this Container Registry token exists.
- container
Registry StringName - The Name of the Container Registry where the token exists.
- name String
- The name of the Container Registry token.
- resource
Group StringName - The Name of the Resource Group where this Container Registry token exists.
- container
Registry stringName - The Name of the Container Registry where the token exists.
- name string
- The name of the Container Registry token.
- resource
Group stringName - The Name of the Resource Group where this Container Registry token exists.
- container_
registry_ strname - The Name of the Container Registry where the token exists.
- name str
- The name of the Container Registry token.
- resource_
group_ strname - The Name of the Resource Group where this Container Registry token exists.
- container
Registry StringName - The Name of the Container Registry where the token exists.
- name String
- The name of the Container Registry token.
- resource
Group StringName - The Name of the Resource Group where this Container Registry token exists.
getRegistryToken Result
The following output properties are available:
- Container
Registry stringName - Enabled bool
- Whether this Token is enabled.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Resource
Group stringName - Scope
Map stringId - The Scope Map ID used by the token.
- Container
Registry stringName - Enabled bool
- Whether this Token is enabled.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Resource
Group stringName - Scope
Map stringId - The Scope Map ID used by the token.
- container
Registry StringName - enabled Boolean
- Whether this Token is enabled.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- resource
Group StringName - scope
Map StringId - The Scope Map ID used by the token.
- container
Registry stringName - enabled boolean
- Whether this Token is enabled.
- id string
- The provider-assigned unique ID for this managed resource.
- name string
- resource
Group stringName - scope
Map stringId - The Scope Map ID used by the token.
- container_
registry_ strname - enabled bool
- Whether this Token is enabled.
- id str
- The provider-assigned unique ID for this managed resource.
- name str
- resource_
group_ strname - scope_
map_ strid - The Scope Map ID used by the token.
- container
Registry StringName - enabled Boolean
- Whether this Token is enabled.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- resource
Group StringName - scope
Map StringId - The Scope Map ID used by the token.
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurermTerraform Provider.
We recommend using Azure Native.
Viewing docs for Azure v4.42.0 (Older version)
published on Monday, Mar 9, 2026 by Pulumi
published on Monday, Mar 9, 2026 by Pulumi