Template Specs - List By Resource Group

Lists all the Template Specs within the specified resource group.

GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/?api-version=2021-05-01
GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Resources/templateSpecs/?$expand=versions&api-version=2021-05-01

URI Parameters

Name In Required Type Description
resourceGroupName
path True

string

The name of the resource group. The name is case insensitive.

Regex pattern: ^[-\w\._\(\)]+$

subscriptionId
path True

string

Subscription Id which forms part of the URI for every service call.

api-version
query True

string

Client Api version.

$expand
query

TemplateSpecExpandKind

Allows for expansion of additional Template Spec details in the response. Optional.

Responses

Name Type Description
200 OK

TemplateSpecsListResult

OK - Returns an array of Template Specs.

Other Status Codes

TemplateSpecsError

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

TemplateSpecsListByResourceGroup

Sample Request

GET https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/templateSpecRG/providers/Microsoft.Resources/templateSpecs/?$expand=versions&api-version=2021-05-01

Sample Response

{
  "value": [
    {
      "id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/templateSpecRG/providers/Microsoft.Resources/templateSpecs/simpleTemplateSpec",
      "type": "Microsoft.Resources/templateSpecs",
      "name": "simpleTemplateSpec",
      "location": "eastus",
      "systemData": {
        "createdBy": "string",
        "createdByType": "Application",
        "createdAt": "2020-02-01T01:01:01.1075056Z",
        "lastModifiedBy": "string",
        "lastModifiedByType": "Application",
        "lastModifiedAt": "2020-02-02T02:03:01.1974346Z"
      },
      "properties": {
        "description": "A very simple Template Spec"
      }
    },
    {
      "id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/templateSpecRG/providers/Microsoft.Resources/templateSpecs/anotherSimpleTemplateSpec",
      "type": "Microsoft.Resources/templateSpecs",
      "name": "anotherSimpleTemplateSpec",
      "location": "westus",
      "systemData": {
        "createdBy": "string",
        "createdByType": "Application",
        "createdAt": "2020-02-02T01:01:01.1075056Z",
        "lastModifiedBy": "string",
        "lastModifiedByType": "Application",
        "lastModifiedAt": "2020-02-03T02:03:01.1974346Z"
      },
      "properties": {
        "description": "Another very simple Template Spec"
      }
    }
  ]
}

Definitions

Name Description
createdByType

The type of identity that created the resource.

ErrorAdditionalInfo

The resource management error additional info.

ErrorResponse

Error Response

systemData

Metadata pertaining to creation and last modification of the resource.

TemplateSpec

Template Spec object.

TemplateSpecExpandKind

Allows for expansion of additional Template Spec details in the response. Optional.

TemplateSpecsError

Template Specs error response.

TemplateSpecsListResult

List of Template Specs.

TemplateSpecVersionInfo

High-level information about a Template Spec version.

createdByType

The type of identity that created the resource.

Name Type Description
Application

string

Key

string

ManagedIdentity

string

User

string

ErrorAdditionalInfo

The resource management error additional info.

Name Type Description
info

object

The additional info.

type

string

The additional info type.

ErrorResponse

Error Response

Name Type Description
additionalInfo

ErrorAdditionalInfo[]

The error additional info.

code

string

The error code.

details

ErrorResponse[]

The error details.

message

string

The error message.

target

string

The error target.

systemData

Metadata pertaining to creation and last modification of the resource.

Name Type Description
createdAt

string

The timestamp of resource creation (UTC).

createdBy

string

The identity that created the resource.

createdByType

createdByType

The type of identity that created the resource.

lastModifiedAt

string

The timestamp of resource last modification (UTC)

lastModifiedBy

string

The identity that last modified the resource.

lastModifiedByType

createdByType

The type of identity that last modified the resource.

TemplateSpec

Template Spec object.

Name Type Description
id

string

String Id used to locate any resource on Azure.

location

string

The location of the Template Spec. It cannot be changed after Template Spec creation. It must be one of the supported Azure locations.

name

string

Name of this resource.

properties.description

string

Template Spec description.

properties.displayName

string

Template Spec display name.

properties.metadata

object

The Template Spec metadata. Metadata is an open-ended object and is typically a collection of key-value pairs.

properties.versions

<string,  TemplateSpecVersionInfo>

High-level information about the versions within this Template Spec. The keys are the version names. Only populated if the $expand query parameter is set to 'versions'.

systemData

systemData

Azure Resource Manager metadata containing createdBy and modifiedBy information.

tags

object

Resource tags.

type

string

Type of this resource.

TemplateSpecExpandKind

Allows for expansion of additional Template Spec details in the response. Optional.

Name Type Description
versions

string

Includes version information with the Template Spec.

TemplateSpecsError

Template Specs error response.

Name Type Description
error

ErrorResponse

Error Response
Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.)

TemplateSpecsListResult

List of Template Specs.

Name Type Description
nextLink

string

The URL to use for getting the next set of results.

value

TemplateSpec[]

An array of Template Specs.

TemplateSpecVersionInfo

High-level information about a Template Spec version.

Name Type Description
description

string

Template Spec version description.

timeCreated

string

The timestamp of when the version was created.

timeModified

string

The timestamp of when the version was last modified.