---
title: "POST /api/v1/tenants/bulk-create"
method: POST
path: "/api/v1/tenants/bulk-create"
tags: ["Tenants"]
---

# POST /api/v1/tenants/bulk-create

`POST /api/v1/tenants/bulk-create`

## Request

- Base URL: `https://api.immy.bot` (the document declares no server; this is the origin it was published from)
- URL: `https://api.immy.bot/api/v1/tenants/bulk-create`
- Auth: none declared

## Request body

- BulkCreateTenantRequestBody
  - `ownerTenantId` integer
  - `tenants` BulkCreateTenantRequestBodyListItem[], nullable
    - `name` string, nullable
    - `principalId` string, nullable
    - `partnerPrincipalId` string, nullable
    - `limitToDomains` string[], nullable
    - `slug` string, nullable

## Response `200`

OK

- GetTenantResponse[]
  - `id` integer
  - `name` string, nullable, required
  - `slug` string, nullable
  - `parentTenantId` integer, nullable
  - `ownerTenantId` integer, nullable
  - `active` boolean
  - `azureTenantLink` AzureTenantLinkResponse
    - `immyTenantId` integer
    - `azTenantId` string, nullable
    - `azureTenant` AzureTenantResponse
      - `principalId` string, nullable
      - `consentDetails` AzureTenantConsentDetails
        - `consentedWith` 'Backend' | 'Custom': The string or integer value may be used. Backend = 0, Custom = 1
        - `consentDateUtc` string, date-time, nullable
      - `azureTenantType` 'Partner' | 'Customer' | 'Standalone': The string or integer value may be used. Partner = 1, Customer = 2, Standalone = 3
      - `partnerPrincipalId` string, nullable
      - `infoSyncedFromAzure` AzureTenantInfo
        - `tenantName` string, nullable, required
        - `defaultDomainName` string, nullable
        - `domainNames` string[], nullable
      - `lastGetUsersSyncResult` AzureSyncResult
        - `attemptDateUtc` string, date-time
        - `attemptFailedErrorId` string, uuid, nullable
      - `lastGetTenantInfoSyncResult` AzureSyncResult
        - `attemptDateUtc` string, date-time
        - `attemptFailedErrorId` string, uuid, nullable
    - `shouldLimitDomains` boolean
    - `limitToDomains` AzureTenantLinkDomainFilter[], nullable
      - `immyTenantId` integer, required
      - `azTenantId` string, nullable, required
      - `domainName` string, nullable, required
  - `isMsp` boolean
  - `updatedBy` integer, nullable
  - `updatedDateUTC` string, date-time
  - `createdBy` integer, nullable
  - `createdDateUTC` string, date-time
  - `tenantTagIds` integer[], nullable
  - `tenantTagNames` string[], nullable
  - `markedForDeletionAtUtc` string, date-time, nullable

---

[API](https://skmtc.dev/immy/apis/immy-bot-api-2.md) · [All operations](https://skmtc.dev/immy/apis/immy-bot-api-2/llms.txt) · [OpenAPI document](https://skmtc.dev/immy/apis/immy-bot-api-2/revisions/75b50268fa51?raw)
