Server to Server Management APIs
Super Admin

Super Admin

Super Admin manage.

Get a Company SuperAdmins

GET /companies/{companyId}/super-admins

Request

Get a Company's all SuperAdmins

Authentication

  • authToken in header

Parameters

  • companyId in path - integer
    required
    Unique ID of a company object
    Example: 14
  • limit in query with default of 10 - integer
    Pagination limit
    Example: 15
  • offset in query - integer
    Pagination offset
    Example: 5
  • q in query - string
    Super admin query string. Supported fields: email, e.g., ?q=xyz@abc.com
  • isIncludeExtraFields in query - string
    Is show extra fields in the response

    Allowed: 0 | 1

example

curl --request GET \
--url 'https://api-b2b.bigcommerce.com/api/v3/io/companies/[companyId]/super-admins' \
--header 'Content-Type: application/json' \
--header 'authToken: {{token}}'

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    array[object]
    required

  • meta
    object
    required

    Used to response pagination information
    Example: {"pagination":{"limit":10,"offset":0,"totalCount":1}}

example-1

{
"code": 0,
"data": [
{
"id": 0,
"createdAt": 0,
"updateAt": 0,
"firstName": "string",
"lastName": "string",
"email": "string"
}
],
"meta": {
"message": "string",
"pagination": {
"limit": 2,
"offset": 0,
"totalCount": 0
}
}
}

Update Company & Super Admins Relationship

PUT /companies/{companyId}/super-admins

Request

Create or delete the super admin relationships of a company.

Authentication

  • authToken in header

Parameters

  • companyId in path - integer
    required
    Unique ID of a company object
    Example: 14

Body

object | application/json
  • superAdmins
    array[object]
    required

example-1

{
"superAdmins": [
{
"superAdminId": 1,
"isAssigned": true
},
{
"superAdminId": 2,
"isAssigned": true
}
]
}

Response

OK

Body

object | application/json
  • code
    number

  • data
    array[]

  • meta
    object

example-1

{
"code": 200,
"data": [],
"meta": {
"message": "success"
}
}

Update SuperAdmin & Companies Relationship

PUT /super-admins/{superAdminId}

Request

Create or delete the company relationships of a superAdmin.

Authentication

  • authToken in header

Parameters

  • superAdminId in path - integer
    required
    Unique SuperAdmin ID
    Example: 11

Body

object | application/json
  • companies
    array[object]
    required

example-1

{
"companies": [
{
"companyId": 1,
"isAssigned": true
},
{
"companyId": 2,
"isAssigned": false
}
]
}

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

example-1

{
"code": 200,
"data": {},
"meta": {
"message": "SUCCESS"
}
}

Get SuperAdmin with Company Count

GET /companies/super-admins

Request

Get SuperAdmins with Company Count (group by superAdmin)

Authentication

  • authToken in header

Parameters

  • limit in query with default of 10 - integer
    Pagination limit
    Example: 15
  • offset in query - integer
    Pagination offset
    Example: 5
  • orderBy in query with default of DESC - string
    Order by
    Example: ASC

    Allowed: DESC | ASC

  • q in query - string
    Super admin query string. Supported fields: email, e.g., ?q=xyz@abc.com
  • uuid in query - string
    Uuid of super admin
  • maxCreated in query - string
    Maximum created timestamp
  • minCreated in query - string
    Minimum created timestamp
  • maxModified in query - string
    Maximum modified timestamp
  • minModified in query - string
    Minimum modified timestamp
  • isIncludeExtraFields in query - string
    Is show extra fields in the response

    Allowed: 0 | 1

example

curl --request GET \
--url https://api-b2b.bigcommerce.com/api/v3/io/companies/super-admins \
--header 'Content-Type: application/json' \
--header 'authToken: {{token}}'

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    array[object]
    required

  • meta
    object
    required

    Used to response pagination information
    Example: {"pagination":{"limit":10,"offset":0,"totalCount":1}}

example-1

{
"code": 200,
"data": [
{
"firstName": "zzz",
"lastName": "aaa",
"email": "zzz@ssalesrep.com",
"id": 9208,
"companyCount": 7,
"uuid": "",
"createdAt": 1622421600,
"updatedAt": 1622421600
},
{
"firstName": "Walter",
"lastName": "White",
"email": "Walter.White@gmail.com",
"id": 293,
"companyCount": 3,
"uuid": "",
"createdAt": 1622421600,
"updatedAt": 1622421600
}
],
"meta": {
"message": "SUCCESS",
"pagination": {
"limit": 2,
"offset": 0,

Get Companies with SuperAdmin Count

GET /super-admins/companies

Request

Get Companies with SuperAdmin Count (group by company)

Authentication

  • authToken in header

Parameters

  • limit in query with default of 10 - integer
    Pagination limit
    Example: 15
  • offset in query - integer
    Pagination offset
    Example: 5
  • orderBy in query with default of DESC - string
    Order by
    Example: ASC

    Allowed: DESC | ASC

example

curl --request GET \
--url https://api-b2b.bigcommerce.com/api/v3/io/super-admins/companies \
--header 'Content-Type: application/json' \
--header 'authToken: {{token}}'

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    array[object]
    required

  • meta
    object
    required

    Used to response pagination information
    Example: {"pagination":{"limit":10,"offset":0,"totalCount":1}}

example-1

{
"code": 200,
"data": [
{
"addressLine1": "",
"addressLine2": "",
"catalogId": 2,
"city": "",
"companyEmail": "kobe.tian@bunldeb2b.com",
"companyId": 34,
"companyName": "KobeCropTest111",
"country": ",",
"description": "KobeCropTest111",
"superAdminCount": 2,
"state": "",
"zipCode": ""
}
],
"meta": {
"message": "SUCCESS",
"pagination": {
"limit": 3,
"offset": 1,
"totalCount": 989
}
}
}

Create Super Admin

POST /super-admins

Request

Create a super admin without a company assigned.

Authentication

  • authToken in header

Body

object | application/json
Extra Field Values
  • firstName
    string
    required

    First name of the SuperAdmin
    >= 0 characters<= 100 characters
  • lastName
    string
    required

    Last name of the SuperAdmin
    >= 0 characters<= 100 characters
  • phone
    string

    Phone number of the SuperAdmin
    >= 0 characters<= 200 characters
  • uuid
    string

    UUID of the SuperAdmin
    >= 0 characters<= 100 characters
  • channelIds
    array[integer]

    BigCommerce channel ID list. If this fields is missing, super admin can access all enabled channels.
  • originChannelId
    integer

    BigCommerce channel ID, used for BigCommerce customer origin channel ID. This field takes effect only when the store default b2b channel is not configured
  • extraFields
    array[object]

example-1

{
"firstName": "Tom",
"lastName": "Cat",
"phone": "0000000000",
"email": "Tom@gmail.com",
"uuid": ""
}

Response

OK

Body

object | application/json
  • code
    number

  • data
    object

  • meta
    object

example-1

{
"code": 0,
"data": {
"userId": 1,
"customerId": 1
},
"meta": {
"message": "success"
}
}

Get Companies of a Super Admin

GET /super-admins/{superAdminId}/companies

Request

Get companies of a super admin

Authentication

  • authToken in header

Parameters

  • superAdminId in path - string
    required
    Unique SuperAdmin ID
    Example: 11
  • offset in query - integer
    Pagination offset
  • limit in query - integer
    Pagination limit

example

curl --request GET \
--url 'https://api-b2b.bigcommerce.com/api/v3/io/super-admins/[superAdminId]/companies' \
--header 'Content-Type: application/json' \
--header 'authToken: {{token}}'

Response

OK

Body

object | application/json
  • code
    number

  • data
    array[object]
    required

  • meta
    object

example-1

{
"code": 0,
"data": [
{
"companyId": 1,
"companyName": "Tom company",
"companyEmail": "Tom@gmail.com"
},
{
"companyId": 1,
"companyName": "Jerry company",
"companyEmail": "Jerry@gmail.com"
}
],
"meta": {
"message": "success",
"pagination": {
"totalCount": 2,
"offset": 0,
"limit": 10
}
}
}

Bulk Create Super Admins

POST /super-admins/bulk

Request

Bulk create super admins

Authentication

  • authToken in header

Body

array | application/json
  • firstName
    string
    required

    First name of the super admin
    >= 1 characters
  • lastName
    string
    required

    Last name of the super admin
    >= 1 characters
  • phone
    string
    required

    Phone number of the super admin
    >= 1 characters
  • uuid
    string
    required

    UUID of the super admin
    >= 1 characters
  • channelIds
    array[integer]

    BigCommerce channel ID list
  • originChannelId
    integer

    BigCommerce channel ID, used for BigCommerce customer origin channel ID. This field takes effect only when the store default b2b channel is not configured.
  • extraFields
    array[object]

example-1

[
{
"firstName": "Tom",
"lastName": "Cat",
"phone": "1000000000",
"email": "Tom21@gmail.com",
"uuid": "21"
},
{
"firstName": "Tom",
"lastName": "Cat",
"phone": "2000000000",
"email": "Tom22@gmail.com",
"uuid": "22"
},
{
"firstName": "Tom",
"lastName": "Cat",
"phone": "3000000000",
"email": "Tom23@gmail.com",
"uuid": "23"
}
]

Response

OK

Body

object | application/json
  • code
    number
    required

  • data
    object
    required

  • meta
    object
    required

example-1

{
"code": 200,
"data": {
"superAdminIds": [
51,
52,
53
]
},
"meta": {
"message": "SUCCESS"
}
}

Get a Super Admin Info

GET /super-admins/info/{superAdminId}

Request

Get super admin info

Authentication

  • authToken in header

Parameters

  • superAdminId in path - string
    required
    Unique SuperAdmin ID

example

curl --request GET \
--url 'https://api-b2b.bigcommerce.com/api/v3/io/super-admins/info/[superAdminId]' \
--header 'Content-Type: application/json' \
--header 'authToken: {{token}}'

Response

OK

Body

object | application/json
  • code
    integer

  • data
    object

    Super Admin model
    Example: {"extraFields":[{"fieldName":"string","fieldValue":"string"}]}
  • meta
    object

example

{
"code": 0,
"data": {
"id": 0,
"createdAt": 1620872672,
"updatedAt": 1620872672,
"firstName": "Tom",
"lastName": "Cat",
"uuid": "string",
"phone": "string",
"channelList": [
{
"channelId": 0,
"channelName": "string",
"iconUrl": "string"
}
],
"extraFields": [
{
"fieldName": "string",
"fieldValue": "string"
}
]
},
"meta": {
"message": "string"
}
}

Update a Super Admin Info

PUT /super-admins/info/{superAdminId}

Request

Update super admin info

Authentication

  • authToken in header

Parameters

  • superAdminId in path - string
    required
    Unique SuperAdmin ID

Body

object | application/json
Extra Field Values
  • firstName
    string

    First name
  • lastName
    string

    Last name
  • uuid
    string

    UUID of super admin
  • phone
    string

    Phone number of super admin
  • channelIds
    array[integer]

    BigCommerce channel IDs.
  • extraFields
    array[object]

example

{
"firstName": "Tom",
"lastName": "Cat",
"uuid": "string",
"phone": "string",
"channelIds": [
0
],
"extraFields": [
{
"fieldName": "string",
"fieldValue": "string"
}
]
}

Response

OK

Body

object | application/json
  • code
    integer

  • data
    object

    Super Admin model
    Example: {"extraFields":[{"fieldName":"string","fieldValue":"string"}]}
  • meta
    object

example

{
"code": 0,
"data": {
"id": 0,
"createdAt": 1620872672,
"updatedAt": 1620872672,
"firstName": "Tom",
"lastName": "Cat",
"uuid": "string",
"phone": "string",
"channelList": [
{
"channelId": 0,
"channelName": "string",
"iconUrl": "string"
}
],
"extraFields": [
{
"fieldName": "string",
"fieldValue": "string"
}
]
},
"meta": {
"message": "string"
}
}

See something you can improve? Edit this file on GitHub

Did you find what you were looking for?