> For the complete documentation index, see [llms.txt](https://docs.globalalerting.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.globalalerting.com/web-api/tenants.md).

# Tenants

## GET /V2/{tenantVarCode}

> Returns information about the specified tenant

```json
{"openapi":"3.0.4","info":{"title":"GAP REST API Documentation V2","version":"v2"},"tags":[{"name":"Tenants"}],"paths":{"/V2/{tenantVarCode}":{"get":{"tags":["Tenants"],"summary":"Returns information about the specified tenant","operationId":"GetTenant","parameters":[{"name":"tenantVarCode","in":"path","description":"Tenant Var Code","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json;IEEE754Compatible=false":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json;IEEE754Compatible=true":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/xml":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/plain":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/octet-stream":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/xml":{"schema":{"$ref":"#/components/schemas/Tenant"}}}}}}}},"components":{"schemas":{"Tenant":{"required":["Description"],"type":"object","properties":{"TenantCode":{"type":"string","description":"Tenant Var Code","nullable":true},"Description":{"minLength":1,"type":"string","description":"Name used to describe the tenant (max 250 characters)"},"AdminContacts":{"type":"string","description":"A semicolon separated list of email addresses","nullable":true},"SalesContacts":{"type":"string","description":"A semicolon separated list of email addresses","nullable":true},"DeviceTypes":{"type":"string","description":"A comma separated list of device types that this tenant can provision and manage","nullable":true},"CultureName":{"type":"string","description":"The culture used by this tenant. This is normally used in a portal for date formatting","nullable":true},"DefaultUiLanguage":{"type":"string","description":"The default UI language for new users. Empty value would set user preferences to use browser language settings","nullable":true},"TimeZoneId":{"type":"string","description":"The default time zone to be used by this tenant. This is normally used to format dates and times for UI purposes. All dates are stored as UTC","nullable":true},"Properties":{"type":"object","additionalProperties":{"type":"string","nullable":true},"description":"A dictionary with additional tenant properties","nullable":true},"ParentTenantCode":{"type":"string","description":"A 4 digit number that uniquely identifies the parent of this tenant, returned only when the user has access to the parent tenant","nullable":true},"Timestamp":{"type":"string","description":"Timestamp (UTC) indicating version of record being returned","format":"date-time","nullable":true},"ETag":{"type":"string","description":"ETag representing record version","nullable":true}},"additionalProperties":false}}}}
```

## POST /V2/{tenantVarCode}

> Creates a new tenant

```json
{"openapi":"3.0.4","info":{"title":"GAP REST API Documentation V2","version":"v2"},"tags":[{"name":"Tenants"}],"paths":{"/V2/{tenantVarCode}":{"post":{"tags":["Tenants"],"summary":"Creates a new tenant","parameters":[{"name":"tenantVarCode","in":"path","description":"Parent Tenant Var Code","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"Tenant that should be created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json;IEEE754Compatible=false":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json;IEEE754Compatible=true":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/xml":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/plain":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/xml":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/*+xml":{"schema":{"$ref":"#/components/schemas/Tenant"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json;IEEE754Compatible=false":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json;IEEE754Compatible=true":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/xml":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/plain":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/octet-stream":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/xml":{"schema":{"$ref":"#/components/schemas/Tenant"}}}}}}}},"components":{"schemas":{"Tenant":{"required":["Description"],"type":"object","properties":{"TenantCode":{"type":"string","description":"Tenant Var Code","nullable":true},"Description":{"minLength":1,"type":"string","description":"Name used to describe the tenant (max 250 characters)"},"AdminContacts":{"type":"string","description":"A semicolon separated list of email addresses","nullable":true},"SalesContacts":{"type":"string","description":"A semicolon separated list of email addresses","nullable":true},"DeviceTypes":{"type":"string","description":"A comma separated list of device types that this tenant can provision and manage","nullable":true},"CultureName":{"type":"string","description":"The culture used by this tenant. This is normally used in a portal for date formatting","nullable":true},"DefaultUiLanguage":{"type":"string","description":"The default UI language for new users. Empty value would set user preferences to use browser language settings","nullable":true},"TimeZoneId":{"type":"string","description":"The default time zone to be used by this tenant. This is normally used to format dates and times for UI purposes. All dates are stored as UTC","nullable":true},"Properties":{"type":"object","additionalProperties":{"type":"string","nullable":true},"description":"A dictionary with additional tenant properties","nullable":true},"ParentTenantCode":{"type":"string","description":"A 4 digit number that uniquely identifies the parent of this tenant, returned only when the user has access to the parent tenant","nullable":true},"Timestamp":{"type":"string","description":"Timestamp (UTC) indicating version of record being returned","format":"date-time","nullable":true},"ETag":{"type":"string","description":"ETag representing record version","nullable":true}},"additionalProperties":false}}}}
```

## PUT /V2/{tenantVarCode}

> Updates an existing tenant

```json
{"openapi":"3.0.4","info":{"title":"GAP REST API Documentation V2","version":"v2"},"tags":[{"name":"Tenants"}],"paths":{"/V2/{tenantVarCode}":{"put":{"tags":["Tenants"],"summary":"Updates an existing tenant","parameters":[{"name":"tenantVarCode","in":"path","description":"Tenant Var Code","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"Updated Tenant","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json;IEEE754Compatible=false":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json;IEEE754Compatible=true":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/xml":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/plain":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/Tenant"}},"text/xml":{"schema":{"$ref":"#/components/schemas/Tenant"}},"application/*+xml":{"schema":{"$ref":"#/components/schemas/Tenant"}}}},"responses":{"200":{"description":"OK"}}}}},"components":{"schemas":{"Tenant":{"required":["Description"],"type":"object","properties":{"TenantCode":{"type":"string","description":"Tenant Var Code","nullable":true},"Description":{"minLength":1,"type":"string","description":"Name used to describe the tenant (max 250 characters)"},"AdminContacts":{"type":"string","description":"A semicolon separated list of email addresses","nullable":true},"SalesContacts":{"type":"string","description":"A semicolon separated list of email addresses","nullable":true},"DeviceTypes":{"type":"string","description":"A comma separated list of device types that this tenant can provision and manage","nullable":true},"CultureName":{"type":"string","description":"The culture used by this tenant. This is normally used in a portal for date formatting","nullable":true},"DefaultUiLanguage":{"type":"string","description":"The default UI language for new users. Empty value would set user preferences to use browser language settings","nullable":true},"TimeZoneId":{"type":"string","description":"The default time zone to be used by this tenant. This is normally used to format dates and times for UI purposes. All dates are stored as UTC","nullable":true},"Properties":{"type":"object","additionalProperties":{"type":"string","nullable":true},"description":"A dictionary with additional tenant properties","nullable":true},"ParentTenantCode":{"type":"string","description":"A 4 digit number that uniquely identifies the parent of this tenant, returned only when the user has access to the parent tenant","nullable":true},"Timestamp":{"type":"string","description":"Timestamp (UTC) indicating version of record being returned","format":"date-time","nullable":true},"ETag":{"type":"string","description":"ETag representing record version","nullable":true}},"additionalProperties":false}}}}
```

## DELETE /V2/{tenantVarCode}

> Deletes a tenant

```json
{"openapi":"3.0.4","info":{"title":"GAP REST API Documentation V2","version":"v2"},"tags":[{"name":"Tenants"}],"paths":{"/V2/{tenantVarCode}":{"delete":{"tags":["Tenants"],"summary":"Deletes a tenant","parameters":[{"name":"tenantVarCode","in":"path","description":"Tenant Var Code","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK"}}}}}}
```

## GET /V2/{tenantVarCode}/tenants

> Returns subtenants for specified tenant

```json
{"openapi":"3.0.4","info":{"title":"GAP REST API Documentation V2","version":"v2"},"tags":[{"name":"Tenants"}],"paths":{"/V2/{tenantVarCode}/tenants":{"get":{"tags":["Tenants"],"summary":"Returns subtenants for specified tenant","parameters":[{"name":"tenantVarCode","in":"path","description":"Tenant Var Code","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}},"application/json;IEEE754Compatible=false":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}},"application/json;IEEE754Compatible=true":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}},"application/xml":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}},"text/plain":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}},"application/octet-stream":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}},"text/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}},"text/xml":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}},"text/csv":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}}}}}}}}},"components":{"schemas":{"Tenant":{"required":["Description"],"type":"object","properties":{"TenantCode":{"type":"string","description":"Tenant Var Code","nullable":true},"Description":{"minLength":1,"type":"string","description":"Name used to describe the tenant (max 250 characters)"},"AdminContacts":{"type":"string","description":"A semicolon separated list of email addresses","nullable":true},"SalesContacts":{"type":"string","description":"A semicolon separated list of email addresses","nullable":true},"DeviceTypes":{"type":"string","description":"A comma separated list of device types that this tenant can provision and manage","nullable":true},"CultureName":{"type":"string","description":"The culture used by this tenant. This is normally used in a portal for date formatting","nullable":true},"DefaultUiLanguage":{"type":"string","description":"The default UI language for new users. Empty value would set user preferences to use browser language settings","nullable":true},"TimeZoneId":{"type":"string","description":"The default time zone to be used by this tenant. This is normally used to format dates and times for UI purposes. All dates are stored as UTC","nullable":true},"Properties":{"type":"object","additionalProperties":{"type":"string","nullable":true},"description":"A dictionary with additional tenant properties","nullable":true},"ParentTenantCode":{"type":"string","description":"A 4 digit number that uniquely identifies the parent of this tenant, returned only when the user has access to the parent tenant","nullable":true},"Timestamp":{"type":"string","description":"Timestamp (UTC) indicating version of record being returned","format":"date-time","nullable":true},"ETag":{"type":"string","description":"ETag representing record version","nullable":true}},"additionalProperties":false}}}}
```
