Returns the list of Basic and Premium accounts for a given external id with sub-accounts and sites. Note: for efficiency this API method can only return up to 500 records at a time. Use the skip and take parameters to return more records.

Request Information

Headers

NameDescriptionTypeAdditional information
Authentication

Authentication token

string

Required

URI Parameters

NameDescriptionTypeAdditional information
externalid

Id for this account in your system. This parameter can be empty, and in this case the method returns all accounts (use /accounts/ format if this parameter is empty).

string

Optional

Max length: 250

skip

Skip count.

integer

Optional

Default value is 0

take

Take count.

integer

Optional

Default value is 500

Range: inclusive between 1 and 500

Body Parameters

None.

Response Information

Resource Description

NameDescriptionTypeAdditional information
Data

PageListOfAccount

None.

Success

boolean

None.

Messages

Collection of ErrorMessage

None.

Response Formats

application/json

Sample:
{
  "Data": {
    "Items": [
      {
        "Id": "073f4072-9870-438d-818b-c7e56eff2601",
        "ExternalId": "externalid",
        "Type": "Basic",
        "AccountPlanId": 1,
        "Status": "Active",
        "ParentAccountId": "0f0f72c9-c216-41aa-841e-e096fc741f6f",
        "FirstName": "First name",
        "LastName": "Last name",
        "Email": "someemail@gmail.com",
        "IframeStatsToken": "YWY1ZjUzNWMtNmI2Mi00ZWNmLWIxNmUtMGFkYmFiNjVjOTZh0",
        "IsLoyaltyProgramAccoun": false
      },
      {
        "Id": "fa516117-9d6a-4eb0-b5c1-0ca80db618c4",
        "ExternalId": "externalid",
        "Type": "Premium",
        "AccountPlanId": 2,
        "Status": "Active",
        "FirstName": "First name",
        "LastName": "Last name",
        "Email": "someemail@gmail.com",
        "IframeStatsToken": "YWY1ZjUzNWMtNmI2Mi00ZWNmLWIxNmUtMGFkYmFiNjVjOTZh0",
        "IsLoyaltyProgramAccoun": false,
        "SubAccounts": [
          {
            "Id": "123f4072-9870-438d-818b-c7e56eff2601",
            "Type": "Basic",
            "AccountPlanId": 1,
            "Status": "Active",
            "ParentAccountId": "fa516117-9d6a-4eb0-b5c1-0ca80db618c4",
            "FirstName": "",
            "LastName": "",
            "IframeStatsToken": "YWY1ZjUzNWMtNmI2Mi00ZWNmLWIxNmUtMGFkYmFiNjVjOTZh0",
            "IsLoyaltyProgramAccoun": false,
            "Sites": [
              {
                "Id": 31385,
                "AccountId": "123f4072-9870-438d-818b-c7e56eff2601",
                "SiteDomainName": "somedomain",
                "SiteFullDomainName": "somedomain.inapp.mobi",
                "ExternalDomainNames": [],
                "Created": "2014-04-01T12:13:19.903"
              },
              {
                "Id": 31387,
                "AccountId": "123f4072-9870-438d-818b-c7e56eff2601",
                "SiteDomainName": "somedomain2",
                "SiteFullDomainName": "somedomain2.inapp.mobi",
                "ExternalDomainNames": [],
                "Created": "2014-04-01T12:13:19.903"
              }
            ]
          },
          {
            "Id": "124f4072-9870-438d-818b-c7e56eff2601",
            "Type": "Basic",
            "AccountPlanId": 1,
            "Status": "Active",
            "ParentAccountId": "fa516117-9d6a-4eb0-b5c1-0ca80db618c4",
            "FirstName": "",
            "LastName": "",
            "IframeStatsToken": "YWY1ZjUzNWMtNmI2Mi00ZWNmLWIxNmUtMGFkYmFiNjVjOTZh0",
            "IsLoyaltyProgramAccoun": false,
            "Sites": []
          }
        ]
      }
    ],
    "AllCount": 2
  },
  "Success": true,
  "Messages": []
}