1. Packages
  2. Azure Classic
  3. API Docs
  4. storage
  5. getQueue

We recommend using Azure Native.

Azure v6.28.0 published on Friday, Oct 3, 2025 by Pulumi

azure.storage.getQueue

Get Started
azure logo

We recommend using Azure Native.

Azure v6.28.0 published on Friday, Oct 3, 2025 by Pulumi

    Use this data source to access information about an existing Storage Queue.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as azure from "@pulumi/azure";
    
    const example = azure.storage.getQueue({
        name: "example-queue-name",
        storageAccountName: "example-storage-account-name",
    });
    
    import pulumi
    import pulumi_azure as azure
    
    example = azure.storage.get_queue(name="example-queue-name",
        storage_account_name="example-storage-account-name")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/storage"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := storage.LookupQueue(ctx, &storage.LookupQueueArgs{
    			Name:               "example-queue-name",
    			StorageAccountName: pulumi.StringRef("example-storage-account-name"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Azure = Pulumi.Azure;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Azure.Storage.GetQueue.Invoke(new()
        {
            Name = "example-queue-name",
            StorageAccountName = "example-storage-account-name",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azure.storage.StorageFunctions;
    import com.pulumi.azure.storage.inputs.GetQueueArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var example = StorageFunctions.getQueue(GetQueueArgs.builder()
                .name("example-queue-name")
                .storageAccountName("example-storage-account-name")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: azure:storage:getQueue
          arguments:
            name: example-queue-name
            storageAccountName: example-storage-account-name
    

    API Providers

    This data source uses the following Azure API Providers:

    • Microsoft.Storage - 2023-05-01

    Using getQueue

    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 getQueue(args: GetQueueArgs, opts?: InvokeOptions): Promise<GetQueueResult>
    function getQueueOutput(args: GetQueueOutputArgs, opts?: InvokeOptions): Output<GetQueueResult>
    def get_queue(metadata: Optional[Mapping[str, str]] = None,
                  name: Optional[str] = None,
                  storage_account_id: Optional[str] = None,
                  storage_account_name: Optional[str] = None,
                  opts: Optional[InvokeOptions] = None) -> GetQueueResult
    def get_queue_output(metadata: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
                  name: Optional[pulumi.Input[str]] = None,
                  storage_account_id: Optional[pulumi.Input[str]] = None,
                  storage_account_name: Optional[pulumi.Input[str]] = None,
                  opts: Optional[InvokeOptions] = None) -> Output[GetQueueResult]
    func LookupQueue(ctx *Context, args *LookupQueueArgs, opts ...InvokeOption) (*LookupQueueResult, error)
    func LookupQueueOutput(ctx *Context, args *LookupQueueOutputArgs, opts ...InvokeOption) LookupQueueResultOutput

    > Note: This function is named LookupQueue in the Go SDK.

    public static class GetQueue 
    {
        public static Task<GetQueueResult> InvokeAsync(GetQueueArgs args, InvokeOptions? opts = null)
        public static Output<GetQueueResult> Invoke(GetQueueInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetQueueResult> getQueue(GetQueueArgs args, InvokeOptions options)
    public static Output<GetQueueResult> getQueue(GetQueueArgs args, InvokeOptions options)
    
    fn::invoke:
      function: azure:storage/getQueue:getQueue
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Name string
    The name of the Queue.
    Metadata Dictionary<string, string>
    A mapping of MetaData for this Queue.
    StorageAccountId string

    The name of the Storage Account where the Queue exists. This property will become Required in version 5.0 of the Provider.

    Note: One of storage_account_name or storage_account_id must be specified. When specifying storage_account_id the resource will use the Resource Manager API, rather than the Data Plane API.

    StorageAccountName string
    The name of the Storage Account where the Queue exists. This property is deprecated in favour of storage_account_id.

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    Name string
    The name of the Queue.
    Metadata map[string]string
    A mapping of MetaData for this Queue.
    StorageAccountId string

    The name of the Storage Account where the Queue exists. This property will become Required in version 5.0 of the Provider.

    Note: One of storage_account_name or storage_account_id must be specified. When specifying storage_account_id the resource will use the Resource Manager API, rather than the Data Plane API.

    StorageAccountName string
    The name of the Storage Account where the Queue exists. This property is deprecated in favour of storage_account_id.

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    name String
    The name of the Queue.
    metadata Map<String,String>
    A mapping of MetaData for this Queue.
    storageAccountId String

    The name of the Storage Account where the Queue exists. This property will become Required in version 5.0 of the Provider.

    Note: One of storage_account_name or storage_account_id must be specified. When specifying storage_account_id the resource will use the Resource Manager API, rather than the Data Plane API.

    storageAccountName String
    The name of the Storage Account where the Queue exists. This property is deprecated in favour of storage_account_id.

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    name string
    The name of the Queue.
    metadata {[key: string]: string}
    A mapping of MetaData for this Queue.
    storageAccountId string

    The name of the Storage Account where the Queue exists. This property will become Required in version 5.0 of the Provider.

    Note: One of storage_account_name or storage_account_id must be specified. When specifying storage_account_id the resource will use the Resource Manager API, rather than the Data Plane API.

    storageAccountName string
    The name of the Storage Account where the Queue exists. This property is deprecated in favour of storage_account_id.

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    name str
    The name of the Queue.
    metadata Mapping[str, str]
    A mapping of MetaData for this Queue.
    storage_account_id str

    The name of the Storage Account where the Queue exists. This property will become Required in version 5.0 of the Provider.

    Note: One of storage_account_name or storage_account_id must be specified. When specifying storage_account_id the resource will use the Resource Manager API, rather than the Data Plane API.

    storage_account_name str
    The name of the Storage Account where the Queue exists. This property is deprecated in favour of storage_account_id.

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    name String
    The name of the Queue.
    metadata Map<String>
    A mapping of MetaData for this Queue.
    storageAccountId String

    The name of the Storage Account where the Queue exists. This property will become Required in version 5.0 of the Provider.

    Note: One of storage_account_name or storage_account_id must be specified. When specifying storage_account_id the resource will use the Resource Manager API, rather than the Data Plane API.

    storageAccountName String
    The name of the Storage Account where the Queue exists. This property is deprecated in favour of storage_account_id.

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    getQueue Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Metadata Dictionary<string, string>
    A mapping of MetaData for this Queue.
    Name string
    ResourceManagerId string
    The Resource Manager ID of this Storage Queue.

    Deprecated: the resource_manager_id property has been deprecated in favour of id and will be removed in version 5.0 of the Provider.

    Url string
    The data plane URL of the Storage Queue in the format of <storage queue endpoint>/<queue name>. E.g. https://example.queue.core.windows.net/queue1.
    StorageAccountId string
    StorageAccountName string

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    Id string
    The provider-assigned unique ID for this managed resource.
    Metadata map[string]string
    A mapping of MetaData for this Queue.
    Name string
    ResourceManagerId string
    The Resource Manager ID of this Storage Queue.

    Deprecated: the resource_manager_id property has been deprecated in favour of id and will be removed in version 5.0 of the Provider.

    Url string
    The data plane URL of the Storage Queue in the format of <storage queue endpoint>/<queue name>. E.g. https://example.queue.core.windows.net/queue1.
    StorageAccountId string
    StorageAccountName string

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    id String
    The provider-assigned unique ID for this managed resource.
    metadata Map<String,String>
    A mapping of MetaData for this Queue.
    name String
    resourceManagerId String
    The Resource Manager ID of this Storage Queue.

    Deprecated: the resource_manager_id property has been deprecated in favour of id and will be removed in version 5.0 of the Provider.

    url String
    The data plane URL of the Storage Queue in the format of <storage queue endpoint>/<queue name>. E.g. https://example.queue.core.windows.net/queue1.
    storageAccountId String
    storageAccountName String

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    id string
    The provider-assigned unique ID for this managed resource.
    metadata {[key: string]: string}
    A mapping of MetaData for this Queue.
    name string
    resourceManagerId string
    The Resource Manager ID of this Storage Queue.

    Deprecated: the resource_manager_id property has been deprecated in favour of id and will be removed in version 5.0 of the Provider.

    url string
    The data plane URL of the Storage Queue in the format of <storage queue endpoint>/<queue name>. E.g. https://example.queue.core.windows.net/queue1.
    storageAccountId string
    storageAccountName string

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    id str
    The provider-assigned unique ID for this managed resource.
    metadata Mapping[str, str]
    A mapping of MetaData for this Queue.
    name str
    resource_manager_id str
    The Resource Manager ID of this Storage Queue.

    Deprecated: the resource_manager_id property has been deprecated in favour of id and will be removed in version 5.0 of the Provider.

    url str
    The data plane URL of the Storage Queue in the format of <storage queue endpoint>/<queue name>. E.g. https://example.queue.core.windows.net/queue1.
    storage_account_id str
    storage_account_name str

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    id String
    The provider-assigned unique ID for this managed resource.
    metadata Map<String>
    A mapping of MetaData for this Queue.
    name String
    resourceManagerId String
    The Resource Manager ID of this Storage Queue.

    Deprecated: the resource_manager_id property has been deprecated in favour of id and will be removed in version 5.0 of the Provider.

    url String
    The data plane URL of the Storage Queue in the format of <storage queue endpoint>/<queue name>. E.g. https://example.queue.core.windows.net/queue1.
    storageAccountId String
    storageAccountName String

    Deprecated: the storage_account_name property has been deprecated in favour of storage_account_id and will be removed in version 5.0 of the Provider.

    Package Details

    Repository
    Azure Classic pulumi/pulumi-azure
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the azurerm Terraform Provider.
    azure logo

    We recommend using Azure Native.

    Azure v6.28.0 published on Friday, Oct 3, 2025 by Pulumi
      Meet Neo: Your AI Platform Teammate