POST Tenants({id})/Subscriptions

Create new subscriptions.

Note: A subscription ties a tenant to an offering, with a list of users. When attempting to create a subscription for a tenant and offering where a subscription already exists, the specified list of users is added to the existing subscription.

Request Information

Parameters

NameDescriptionAdditional information
id

The ID of the tenant the subscription is being created for.

Type: String

Request body type

CreateTenantSubscriptionModel

Request body formats

application/json, text/json

Sample:
{
  "OfferingIds": [
    "2f08f456-7ec8-4edc-866d-25037776ef4f"
  ],
  "Groups": [
    "DOMAIN\\group1",
    "DOMAIN\\group2"
  ],
  "Tags": [
    "tag"
  ],
  "CustomProperties": [
    {
      "Name": "myProperty",
      "Value": "myValue"
    }
  ]
}

Response Information

A list of created or updated subscriptions.

Response type

CollectionResultModel<SubscriptionModel>

Response body formats

application/json, text/json

Sample:
{
  "Href": "[api:Tenants({id})/Subscriptions]",
  "Count": 1,
  "TotalMatchingFilter": 1,
  "Items": [
    {
      "Href": "[api:Subscriptions(df13665a-533d-451a-a43a-d1faf29af13b)]",
      "Id": "df13665a-533d-451a-a43a-d1faf29af13b",
      "ChangeId": "9",
      "Name": "tenant1 subscription to Application",
      "Description": "my subscription",
      "Tags": [
        "tag"
      ],
      "CustomProperties": [
        {
          "Name": "myProperty",
          "Value": "myValue"
        }
      ],
      "DeleteState": "NotDeleted",
      "IsolationMode": "PrivateDeliveryGroup",
      "Icon": {
        "Href": "[api:Icons(00000000-0000-0000-0000-000000000002)]",
        "RelatedTo": "2f08f456-7ec8-4edc-866d-25037776ef4f",
        "Id": "00000000-0000-0000-0000-000000000002"
      },
      "Offering": {
        "Href": "[api:Offerings(2f08f456-7ec8-4edc-866d-25037776ef4f)]",
        "Name": "Application",
        "Id": "2f08f456-7ec8-4edc-866d-25037776ef4f"
      },
      "Tenant": {
        "Href": "[api:Tenants(91ade655-feb5-47d3-9585-a5827ad50132)]",
        "Name": "Tenant 1",
        "Id": "91ade655-feb5-47d3-9585-a5827ad50132"
      },
      "Groups": [
        {
          "Name": "DOMAIN\\group",
          "Sid": "S-1-5-21-1180699209-877415012-3182924384-1004",
          "PrimaryDeliveryGroup": {
            "Href": "[api:DeliveryGroups(c004375e-a96d-4368-96ba-c80702d7e80f)]",
            "Name": "dg1",
            "Id": "c004375e-a96d-4368-96ba-c80702d7e80f"
          }
        }
      ],
      "HealthSummary": {
        "ActiveCount": 0,
        "ErrorCount": 0,
        "WarningCount": 0,
        "InfoCount": 1,
        "Messages": [
          {
            "Text": "Attempting to reach desired capacity",
            "IsError": false,
            "IsWarning": false,
            "IsInfo": false,
            "IsActive": true,
            "Type": "Allocation"
          }
        ]
      }
    }
  ]
}