For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Dev Portal
DocsAPI ReferenceLearnCommunityChangelog
DocsAPI ReferenceLearnCommunityChangelog
    • About Our APIs
  • REST
    • Overview
      • Overview
      • Storefront
          • Authentication
          • Catalog
          • Company
          • Orders
          • Request for Quote
          • Sales Rep
              • GETGet Super Admin's Assigned Companies
              • GETGet Super Admin's Current Masquerading Company
              • PUTBegin Super Admin Masquerade
              • PUTEnd Super Admin Masquerade
          • Shopping List
          • Store Settings
      • Management
  • GraphQL
    • Overview
  • MCP
    • Overview
Dev Portal
LogoLogo
RESTB2BStorefrontSales RepSuper Admin

Get Super Admin's Assigned Companies

GET
https://api-b2b.bigcommerce.com/api/v2/sales-reps/:superAdminId/companies
GET
/api/v2/sales-reps/:superAdminId/companies
$curl -G https://api-b2b.bigcommerce.com/api/v2/sales-reps/1/companies \
> -H "Authorization: Bearer <token>" \
> --data-urlencode "q=Great Buys" \
> -d companyId=654321
1{
2 "code": 200,
3 "message": "SUCCESS",
4 "data": {
5 "list": [
6 {
7 "companyName": "Great Buys, Inc.",
8 "companyId": "123456",
9 "extraFields": [
10 {
11 "fieldName": "Company Tax Code",
12 "fieldValue": "Tax Code G"
13 }
14 ],
15 "bcGroupName": "Great Buys Customers",
16 "companyAdminName": "Marie Curie",
17 "companyEmail": "admin@example.com"
18 }
19 ]
20 },
21 "pagination": {
22 "totalCount": 279,
23 "perCount": 33,
24 "offset": 0,
25 "limit": 10
26 }
27}
Returns the list of Companies that the Super Admin is assigned to. Equivalent Storefront GraphQL API Query: `superAdminCompanies`. For more information, see the [GraphQL Playground](https://api-b2b.bigcommerce.com/graphql/playground).
Was this page helpful?
Previous

Super Admin

Next

Get Super Admin's Current Masquerading Company

Built with

Returns the list of Companies that the Super Admin is assigned to.

Equivalent Storefront GraphQL API Query: superAdminCompanies. For more information, see the GraphQL Playground.

Authentication

AuthorizationBearer
### Authentication header | Header | Argument | Description | |:-------|:---------|:------------| |`Authorization`|`Bearer {{B2B_JWT_TOKEN}}`| You can obtain this token using the steps described in the [REST Storefront API](/developer/docs/b2b-edition/getting-started/authentication#rest-storefront-api) section[...]

Path parameters

superAdminIdintegerRequired

The unique numeric ID assigned to the Super Admin by B2B Edition. This ID does not match the BigCommerce customer account ID. To find the ID of a given Super Admin account, use the Server-to-Server Super Admin API.

Query parameters

offsetintegerOptionalDefaults to 0
Number of results to skip before displaying the current page.
limitintegerOptionalDefaults to 10

Maximum number of results to display per page. Values over 250 will return only 250 results.

orderByenumOptional

Determines the Company field by which results will be sorted. If this is omitted, results are sorted by companyId.

Allowed values:
sortByenumOptionalDefaults to DESC

Determines the sort order (ascending or descending) of the results.

Allowed values:
qstringOptional

Search string for filtering results. If this parameter is provided, results will include entries with a partial match in companyName or companyAdminEmail.

companyIdstringOptional
Search string for filtering results by `companyId`. Only returns data with an exact match in `companyId`. This ID does **not** match the ID shown in B2B Edition. To get a specific Company's ID, use the [Server-to-Server Company API](/developer/api-reference/rest/b2b/management/company/companies).

Response

OK
codeintegerDefaults to 200
The HTTP Status code of the response.
messagestringDefaults to SUCCESS
Response message.
dataobject
paginationobject

Errors

403
Forbidden Error

Authentication header

HeaderArgumentDescription
AuthorizationBearer {{B2B_JWT_TOKEN}}You can obtain this token using the steps described in the REST Storefront API section[…]

Search string for filtering results by companyId. Only returns data with an exact match in companyId. This ID does not match the ID shown in B2B Edition. To get a specific Company’s ID, use the Server-to-Server Company API.