Share via


Monitors - Create

Create a monitor resource.

PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}?api-version=2025-06-11

URI Parameters

Name In Required Type Description
monitorName
path True

string

minLength: 2
maxLength: 32
pattern: ^[a-zA-Z0-9_][a-zA-Z0-9_-]+$

Monitor resource name

resourceGroupName
path True

string

minLength: 1
maxLength: 90

The name of the resource group. 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.

Request Body

Name Required Type Description
location True

string

The geo-location where the resource lives

identity

IdentityProperties

properties

MonitorProperties

Properties specific to the monitor resource.

sku

ResourceSku

tags

object

Resource tags.

Responses

Name Type Description
200 OK

DatadogMonitorResource

Resource 'DatadogMonitorResource' update operation succeeded

201 Created

DatadogMonitorResource

Resource 'DatadogMonitorResource' create operation succeeded

Headers

  • Azure-AsyncOperation: string
  • Retry-After: integer
Other Status Codes

ErrorResponse

An unexpected error response.

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

Monitors_Create

Sample request

PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Datadog/monitors/myMonitor?api-version=2025-06-11

{
  "location": "West US",
  "properties": {
    "datadogOrganizationProperties": {
      "name": "myOrg",
      "cspm": false,
      "enterpriseAppId": "00000000-0000-0000-0000-000000000000",
      "id": "myOrg123",
      "linkingAuthCode": "someAuthCode",
      "linkingClientId": "00000000-0000-0000-0000-000000000000",
      "resourceCollection": false
    },
    "monitoringStatus": "Enabled",
    "userInfo": {
      "name": "Alice",
      "emailAddress": "alice@microsoft.com",
      "phoneNumber": "123-456-7890"
    }
  },
  "sku": {
    "name": "free_Monthly"
  },
  "tags": {
    "Environment": "Dev"
  }
}

Sample response

{
  "name": "myMonitor",
  "type": "Microsoft.Datadog/monitors",
  "id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/monitors/myMonitor",
  "location": "West US",
  "properties": {
    "datadogOrganizationProperties": {
      "name": "myOrg",
      "enterpriseAppId": null,
      "id": "myOrg123",
      "linkingAuthCode": null,
      "linkingClientId": null
    },
    "liftrResourceCategory": "MonitorLogs",
    "liftrResourcePreference": 1,
    "monitoringStatus": "Enabled",
    "provisioningState": "Succeeded"
  },
  "sku": {
    "name": "free_Monthly"
  },
  "tags": {
    "Environment": "Dev"
  }
}
{
  "name": "myMonitor",
  "type": "Microsoft.Datadog/monitors",
  "id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/monitors/myMonitor",
  "location": "West US",
  "properties": {
    "datadogOrganizationProperties": {
      "name": "myOrg",
      "id": "myOrg123"
    },
    "liftrResourceCategory": "MonitorLogs",
    "liftrResourcePreference": 1,
    "monitoringStatus": "Enabled",
    "provisioningState": "Accepted"
  },
  "sku": {
    "name": "free_Monthly"
  },
  "tags": {
    "Environment": "Dev"
  }
}

Definitions

Name Description
createdByType

The type of identity that created the resource.

DatadogMonitorResource

Concrete tracked resource types can be created by aliasing this type using a specific property type.

DatadogOrganizationProperties

Specify the Datadog organization name. In the case of linking to existing organizations, Id, ApiKey, and Applicationkey is required as well.

ErrorAdditionalInfo

The resource management error additional info.

ErrorDetail

The error detail.

ErrorResponse

Error response

IdentityProperties
LiftrResourceCategories
ManagedIdentityTypes

Specifies the identity type of the Datadog Monitor. At this time the only allowed value is 'SystemAssigned'.

MarketplaceSubscriptionStatus

Flag specifying the Marketplace Subscription Status of the resource. If payment is not made in time, the resource will go in Suspended state.

MonitoringStatus

Flag specifying if the resource monitoring is enabled or disabled.

MonitorProperties

Properties specific to the monitor resource.

ProvisioningState
ResourceSku
systemData

Metadata pertaining to creation and last modification of the resource.

UserInfo

Includes name, email and optionally, phone number. User Information can't be null.

createdByType

The type of identity that created the resource.

Value Description
User
Application
ManagedIdentity
Key

DatadogMonitorResource

Concrete tracked resource types can be created by aliasing this type using a specific property type.

Name Type Description
id

string

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

identity

IdentityProperties

location

string

The geo-location where the resource lives

name

string

The name of the resource

properties

MonitorProperties

Properties specific to the monitor resource.

sku

ResourceSku

systemData

systemData

Azure Resource Manager metadata containing createdBy and modifiedBy information.

tags

object

Resource tags.

type

string

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

DatadogOrganizationProperties

Specify the Datadog organization name. In the case of linking to existing organizations, Id, ApiKey, and Applicationkey is required as well.

Name Type Description
apiKey

string (password)

Api key associated to the Datadog organization.

applicationKey

string (password)

Application key associated to the Datadog organization.

cspm

boolean

The configuration which describes the state of cloud security posture management. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks.

enterpriseAppId

string

The Id of the Enterprise App used for Single sign on.

id

string

Id of the Datadog organization.

linkingAuthCode

string (password)

The auth code used to linking to an existing Datadog organization.

linkingClientId

string (password)

The client_id from an existing in exchange for an auth token to link organization.

name

string

Name of the Datadog organization.

redirectUri

string

The redirect URI for linking.

resourceCollection

boolean

The configuration which describes the state of resource collection. This collects configuration information for all resources in a subscription.

ErrorAdditionalInfo

The resource management error additional info.

Name Type Description
info

object

The additional info.

type

string

The additional info type.

ErrorDetail

The error detail.

Name Type Description
additionalInfo

ErrorAdditionalInfo[]

The error additional info.

code

string

The error code.

details

ErrorDetail[]

The error details.

message

string

The error message.

target

string

The error target.

ErrorResponse

Error response

Name Type Description
error

ErrorDetail

The error object.

IdentityProperties

Name Type Description
principalId

string

The identity ID.

tenantId

string

The tenant ID of resource.

type

ManagedIdentityTypes

Specifies the identity type of the Datadog Monitor. At this time the only allowed value is 'SystemAssigned'.

LiftrResourceCategories

Value Description
Unknown
MonitorLogs

ManagedIdentityTypes

Specifies the identity type of the Datadog Monitor. At this time the only allowed value is 'SystemAssigned'.

Value Description
SystemAssigned
UserAssigned

MarketplaceSubscriptionStatus

Flag specifying the Marketplace Subscription Status of the resource. If payment is not made in time, the resource will go in Suspended state.

Value Description
Provisioning
Active
Suspended
Unsubscribed

MonitoringStatus

Flag specifying if the resource monitoring is enabled or disabled.

Value Description
Enabled
Disabled

MonitorProperties

Properties specific to the monitor resource.

Name Type Default value Description
datadogOrganizationProperties

DatadogOrganizationProperties

Specify the Datadog organization name. In the case of linking to existing organizations, Id, ApiKey, and Applicationkey is required as well.

liftrResourceCategory

LiftrResourceCategories

liftrResourcePreference

integer (int32)

The priority of the resource.

marketplaceSubscriptionStatus

MarketplaceSubscriptionStatus

Flag specifying the Marketplace Subscription Status of the resource. If payment is not made in time, the resource will go in Suspended state.

monitoringStatus

MonitoringStatus

Enabled

Flag specifying if the resource monitoring is enabled or disabled.

provisioningState

ProvisioningState

userInfo

UserInfo

Includes name, email and optionally, phone number. User Information can't be null.

ProvisioningState

Value Description
Accepted
Creating
Updating
Deleting
Succeeded
Failed
Canceled
Deleted
NotSpecified

ResourceSku

Name Type Description
name

string

Name of the SKU in {PlanId} format. For Terraform, the only allowed value is 'Linked'.

systemData

Metadata pertaining to creation and last modification of the resource.

Name Type Description
createdAt

string (date-time)

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 (date-time)

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.

UserInfo

Includes name, email and optionally, phone number. User Information can't be null.

Name Type Description
emailAddress

string

pattern: ^[A-Za-z0-9._%+-]+@(?:[A-Za-z0-9-]+\.)+[A-Za-z]{2,}$

Email of the user used by Datadog for contacting them if needed

name

string

maxLength: 50

Name of the user

phoneNumber

string

maxLength: 40

Phone number of the user used by Datadog for contacting them if needed