Share via


Queue Services - Get Service Properties

Gets the properties of a storage account’s Queue service, including properties for Storage Analytics and CORS (Cross-Origin Resource Sharing) rules.

GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/queueServices/default?api-version=2024-01-01

URI Parameters

Name In Required Type Description
accountName
path True

string

minLength: 3
maxLength: 24
pattern: ^[a-z0-9]+$

The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only.

queueServiceName
path True

QueueServiceName

The name of the Queue Service within the specified storage account. Queue Service Name must be 'default'

resourceGroupName
path True

string

minLength: 1
maxLength: 90
pattern: ^[-\w\._\(\)]+$

The name of the resource group within the user's subscription. The name is case insensitive.

subscriptionId
path True

string

minLength: 1

The ID of the target subscription.

api-version
query True

string

minLength: 1

The API version to use for this operation.

Responses

Name Type Description
200 OK

QueueServiceProperties

OK -- returned the properties of a storage account’s Queue service.

Other Status Codes

CloudError

Error response describing why the operation failed.

Security

azure_auth

Azure Active Directory OAuth2 Flow

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Examples

QueueServicesGet

Sample request

GET https://management.azure.com/subscriptions/{subscription-id}/resourceGroups/res4410/providers/Microsoft.Storage/storageAccounts/sto8607/queueServices/default?api-version=2024-01-01

Sample response

{
  "id": "/subscriptions/{subscription-id}/resourceGroups/res4410/providers/Microsoft.Storage/storageAccounts/sto8607/queueServices/default",
  "name": "default",
  "type": "Microsoft.Storage/storageAccounts/queueServices",
  "properties": {
    "cors": {
      "corsRules": [
        {
          "allowedOrigins": [
            "http://www.contoso.com",
            "http://www.fabrikam.com"
          ],
          "allowedMethods": [
            "GET",
            "HEAD",
            "POST",
            "OPTIONS",
            "MERGE",
            "PUT"
          ],
          "maxAgeInSeconds": 100,
          "exposedHeaders": [
            "x-ms-meta-*"
          ],
          "allowedHeaders": [
            "x-ms-meta-abc",
            "x-ms-meta-data*",
            "x-ms-meta-target*"
          ]
        },
        {
          "allowedOrigins": [
            "*"
          ],
          "allowedMethods": [
            "GET"
          ],
          "maxAgeInSeconds": 2,
          "exposedHeaders": [
            "*"
          ],
          "allowedHeaders": [
            "*"
          ]
        },
        {
          "allowedOrigins": [
            "http://www.abc23.com",
            "https://www.fabrikam.com/*"
          ],
          "allowedMethods": [
            "GET",
            "PUT"
          ],
          "maxAgeInSeconds": 2000,
          "exposedHeaders": [
            "x-ms-meta-abc",
            "x-ms-meta-data*",
            "x-ms-meta-target*"
          ],
          "allowedHeaders": [
            "x-ms-meta-12345675754564*"
          ]
        }
      ]
    }
  }
}

Definitions

Name Description
AllowedMethods

Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.

CloudError

An error response from the Storage service.

CloudErrorBody

An error response from the Storage service.

CorsRule

Specifies a CORS rule for the Blob service.

CorsRules

Sets the CORS rules. You can include up to five CorsRule elements in the request.

QueueServiceName

The name of the Queue Service within the specified storage account. Queue Service Name must be 'default'

QueueServiceProperties

The properties of a storage account’s Queue service.

AllowedMethods

Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.

Value Description
DELETE
GET
HEAD
MERGE
POST
OPTIONS
PUT
PATCH
CONNECT
TRACE

CloudError

An error response from the Storage service.

Name Type Description
error

CloudErrorBody

An error response from the Storage service.

CloudErrorBody

An error response from the Storage service.

Name Type Description
code

string

An identifier for the error. Codes are invariant and are intended to be consumed programmatically.

details

CloudErrorBody[]

A list of additional details about the error.

message

string

A message describing the error, intended to be suitable for display in a user interface.

target

string

The target of the particular error. For example, the name of the property in error.

CorsRule

Specifies a CORS rule for the Blob service.

Name Type Description
allowedHeaders

string[]

Required if CorsRule element is present. A list of headers allowed to be part of the cross-origin request.

allowedMethods

AllowedMethods[]

Required if CorsRule element is present. A list of HTTP methods that are allowed to be executed by the origin.

allowedOrigins

string[]

Required if CorsRule element is present. A list of origin domains that will be allowed via CORS, or "*" to allow all domains

exposedHeaders

string[]

Required if CorsRule element is present. A list of response headers to expose to CORS clients.

maxAgeInSeconds

integer

Required if CorsRule element is present. The number of seconds that the client/browser should cache a preflight response.

CorsRules

Sets the CORS rules. You can include up to five CorsRule elements in the request.

Name Type Description
corsRules

CorsRule[]

The List of CORS rules. You can include up to five CorsRule elements in the request.

QueueServiceName

The name of the Queue Service within the specified storage account. Queue Service Name must be 'default'

Value Description
default

QueueServiceProperties

The properties of a storage account’s Queue service.

Name Type Description
id

string

Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}

name

string

The name of the resource

properties.cors

CorsRules

Specifies CORS rules for the Queue service. You can include up to five CorsRule elements in the request. If no CorsRule elements are included in the request body, all CORS rules will be deleted, and CORS will be disabled for the Queue service.

type

string

The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"