List all the customer tenants of an MSP

URI - GET

To use this endpoint, send a GET request to retrieve all tenants associated with a given MSP: /msp/tenants

Request

The request includes HTTP headers (obtained in the authentication/authorization process and used to sign the request) with request string parameters.

Request Headers

Header

Type

Required

Format

Description/Sample

x-av-req-id

String

Yes

UUID – generated and supplied on the request

d290f1ee-6c54-4b01-90e6-d701748f0851

x-av-token

String

Yes

Token obtained in the authentication sequence

tkn8546ffffggd9d8934593

x-av-app-id

String

Yes

Application ID provided by Avanan

myapp29

x-av-date

String

Yes

Date-time in GMT

'2016-08-29T09:12:33.001Z'

x-av-sig

String

Yes

Calculated signature

tkn8jmveolrrtertr9d8934593

Request Body

All applicable request parameters are posted on the request body JSON:

Copy
{
    "requestData":
        {
          "scrollId": "string"
        } 
}

Request Body Parameters

The JSON parameters:

Parameter

Type

Required

Format

Description/Sample

scrollId

String

No

 

ID used to scroll large sets of results.

Request sample (CURL) format

This request sample shows URI base in USA region. For URI base in other regions, see MSP Types.

Copy
curl -X GET -H "Accept: application/json" \
    -H "x-av-req-id: d290f1ee-6c54-4b01-90e6-d701748f0851" \
    -H "x-av-token: tkn8546ffffggd9d8934593" \
    -H "x-av-app-id: myapp29" \
    -H "x-av-date: 2016-08-29T09:12:33.001Z" \
    -H "x-av-sig: tkn8jmveolrrtertr9d8934593" \
    https://smart-api-production-1-us.avanan.net/v1.0/msp/tenants

Response

The response obtained from the service includes an HTTP response code and JSON formatted structure. The structure consists of a responseEnvelope structure and a responseData object that holds an array of tenants.

You can find tenant details within each tenant. This includes the domain, deployment mode, user counts, and billing package.

Response Structure

A valid response obtained from the service (JSON format):

Copy
{
  "responseEnvelope": {
    "requestId": "string",
    "responseCode": 0,
    "responseText": "string",
    "additionalText": "string",
    "recordsNumber": 1,
    "totalRecordsNumber": 1,
    "scrollId": "string"
  },
  "responseData":[
    {
      "id": 0,
      "domain": "string",
      "deploymentMode": "string",
      "pocDateStart": "string",
      "pocDateExpiration": "string",
      "users": 0,
      "status": {
        "statusCode": "string",
        "description": "string"
      }
      "package": {
        "id": 0,
        "codeName": "string",
        "displayName": "string"
      },
      "addons": [
        {
          "id": 0,
          "name": "string"
        }
      ],
      "maxLicensedUsers": 0
    }
  ]
}

Response Parameters

The response parameters:

Parameter

Type

Description

responseEnvelope

Object

A container of metadata properties

 

requestId

String

Request ID (from the request header x-av-req-id value)

 

responseCode

Integer

0 = Success

Other values = Failure

 

responseText

String

The text value of the response

 

additionalText

String

Additional information

 

recordsNumber

Integer

Number of records in the response

 

totalRecordsNumber

Integer

Total number of records

 

scrollId

String

A unique ID used to scroll through data

responseData

Object

Array of tenants

responseData/

TenantList

id

Integer

Unique ID of the tenant

 

domain

String

Avanan customer portal domain

 

deploymentMode

String

Tenant mode paid or PoC

 

pocDateStart

String

Start of PoC for a tenant

 

pocDateExpiration

String

End of PoC for a tenant

 

users

Integer

Total user count for a tenant

 

status

Object

Object with tenant status

 

package

Object

Billing package object

 

addons

Object

Array of Add-ons

 

maxLicensedUsers

Integer

Maximum number of users for the portal

Response Sample

A valid response from the service:

Copy
{
  "responseEnvelope": {
    "requestId": "cc7796ac-6235-4a06-b7e9-6abc557976f6",
    "responseCode": 0,
    "responseText": "Success",
    "additionalText": "",
    "recordsNumber": 1,
    "totalRecordsNumber": 1,
    "scrollId": "34234345454353343"
  },
  "responseData": {
    [
        {
        'id': 3318,
              'domain': 'abctenant.avanan.net',
              'deploymentMode': 'paid',
              'pocDateStart': '2021-10-25',
              'pocDateExpiration':  '2021-11-09',
              'users': 25,
           'status': {'statusCode': 'success', 'description': 'Active'},
           'package': None,
           'addons': [],
           'maxLicensedUsers': None
        }
     ]
}