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
      • Management
        • Overview
          • Addresses
          • Authentication
          • Channels
          • Company
            • Companies
              • GETList Companies
              • POSTCreate Company
              • GETGet Company Details
              • PUTUpdate Company
              • DELDelete Company
              • POSTConvert BigCommerce Customer Group into Company
              • POSTBulk Create Companies
              • PUTUpdate Companies (batch)
              • PUTUpdate Company Catalog
              • PUTUpdate Company Status
              • GETList Company Extra Field Configs
              • GETList Company Attachments
              • POSTAdd Company Attachment
              • DELDelete Company Attachment
          • Invoice Management
          • Orders
          • Payment
          • Quotes
          • Sales Staff
          • Shopping List
          • Super Admin
          • Users
  • GraphQL
    • Overview
  • MCP
    • Overview
Dev Portal
LogoLogo
RESTB2BManagementCompanyCompanies

Create Company

POST
https://api-b2b.bigcommerce.com/api/v3/io/companies
POST
/api/v3/io/companies
$curl -X POST https://api-b2b.bigcommerce.com/api/v3/io/companies \
> -H "X-Auth-Token: <apiKey>" \
> -H "Content-Type: application/json" \
> -d '{
> "companyName": "TechCorp Solutions",
> "companyEmail": "contact@techcorp.com",
> "adminFirstName": "Alice",
> "adminLastName": "Johnson",
> "adminEmail": "alice.johnson@techcorp.com",
> "extraFields": [
> {
> "fieldName": "Tax ID",
> "fieldValue": "98-7654321"
> }
> ],
> "adminPhoneNumber": "555-123-4567",
> "originChannelId": 1,
> "channelIds": [
> 1,
> 10001234
> ],
> "catalogId": 123456,
> "acceptCreationEmail": true,
> "companyPhone": "555-987-6543",
> "addressLine1": "456 Innovation Drive",
> "addressLine2": "Suite 200",
> "city": "San Francisco",
> "state": "California",
> "country": "United States",
> "zipCode": "94107",
> "uuid": "a1b2c3d4-e5f6-7890-ab12-cd34ef56gh78"
>}'
1{
2 "code": 200,
3 "data": {
4 "companyId": 78910,
5 "customerId": 45678,
6 "customerGroupId": 123
7 },
8 "meta": {
9 "message": "SUCCESS"
10 }
11}
Creates a new Company account. This endpoint also creates a Company user account for the administrator of the business. If you have configured required information fields in your store’s Extra Fields settings for Company accounts or Company users, you must include the field’s name and value in the `extraFields` array of the request body. For more information on extra fields, see [B2B Edition Settings](https://support.bigcommerce.com/s/article/B2B-Edition-Settings) in the Help Center. After you have created a new Company account, you can configure all of its features and settings by using the [Update a Company](#update-a-company) endpoint. ### Independent vs Dependent Companies Behavior When [Independent Company behavior](https://support.bigcommerce.com/s/article/Companies-and-Customer-Groups) is enabled on your store, the system will not automatically create a dedicated customer group for each new Company account. Instead, you can assign a customer group to a Company account as needed using the `customerGroupId` field. If the `customerGroupId` field is not included in the request body, the Company account will be assigned to your configured default customer group. If you have not configured a default customer group or set the value of `customerGroupId` to `0`, the Company account will not be associated with any customer group, and its users will use your storefront’s default catalog visibility and pricing. If your store is using legacy Dependent Company behavior, a new customer group will be automatically created and associated with each new Company account. In this case, you will not use the `customerGroupId` field.
Was this page helpful?
Previous

List Companies

Next

Get Company Details

Built with

Creates a new Company account. This endpoint also creates a Company user account for the administrator of the business.

If you have configured required information fields in your store’s Extra Fields settings for Company accounts or Company users, you must include the field’s name and value in the extraFields array of the request body. For more information on extra fields, see B2B Edition Settings in the Help Center.

After you have created a new Company account, you can configure all of its features and settings by using the Update a Company endpoint.

Independent vs Dependent Companies Behavior

When Independent Company behavior is enabled on your store, the system will not automatically create a dedicated customer group for each new Company account. Instead, you can assign a customer group to a Company account as needed using the customerGroupId field. If the customerGroupId field is not included in the request body, the Company account will be assigned to your configured default customer group.

If you have not configured a default customer group or set the value of customerGroupId to 0, the Company account will not be associated with any customer group, and its users will use your storefront’s default catalog visibility and pricing.

If your store is using legacy Dependent Company behavior, a new customer group will be automatically created and associated with each new Company account. In this case, you will not use the customerGroupId field.

Authentication

X-Auth-Tokenstring
| Header | Argument | Description | |:-------|:---------|:------------| | `X-Auth-Token` | `access_token` | For more about API accounts that generate `access_token`s, see our [Guide to API Accounts](/developer/docs/overview/api-fundamentals/api-accounts). | For example requests and more information about authenticating BigCommerce APIs, see [Authentication and Example Requests](/developer/docs/overview/api-fundamentals/api-accounts#x-auth-token-header-example-requests). For more about BigCommerce OAuth scopes, see our [Guide to API Accounts](/developer/docs/overview/api-fundamentals/api-accounts#oauth-scopes). For a list of API status codes, see [API Status Codes](/developer/api-reference/rest/overview#rest-http-status-codes).
X-Store-Hashstring
| Header | Argument | Description | |:-------|:---------|:------------| | `X-Store-Hash` | `store_hash` | The unique store hash associated with a BigCommerce store that has B2B Edition enabled. |

Request

User Extra Field Values
companyNamestringRequired>=1 character
companyEmailstringRequired>=1 character
adminFirstNamestringRequired1-100 characters
The first name of the Company account administrator.
adminLastNamestringRequired1-100 characters
The last name of the Company account administrator.
adminEmailstringRequiredformat: "email"1-100 characters

The email address of the Company account administrator. If an existing BigCommerce customer account uses this email address, it is automatically linked to the administrator’s Company user account.

extraFieldslist of objectsOptional
userExtraFieldslist of objectsOptional
customerGroupIdintegerOptional
The ID of the BigCommerce customer group assigned to the Company account. This field can be static or configurable depending on whether or not your store uses Independent Companies behavior. See [Independent Companies Behavior](/developer/api-reference/rest/b2b/management/company/companies#independent-vs-dependent-companies-behavior) for more information.
adminPhoneNumberstringOptional1-100 characters
The phone number of the Company account administrator.
originChannelIdintegerOptional

The storefront channel ID designated as the origin for the Company administrator. Use 1 for your store’s default storefront channel.

channelIdslist of integersOptional

The storefront channel IDs in which buyers can access their Company’s Buyer Portal. Use 1 for your store’s default storefront channel.

catalogIdintegerOptional
The ID of the price list assigned to the Company account. This field is read-only for stores using [Independent Companies Behavior](/developer/api-reference/rest/b2b/management/company/companies#independent-vs-dependent-companies-behavior). If your store uses legacy Dependent Companies behavior **and** it does not have Multi-Storefront enabled, this field is **required** for creating new Company accounts. If your store has Multi-Storefront enabled, use the `priceListAssign` array instead.
acceptCreationEmailbooleanOptionalDefaults to false

Indicates whether or not the administrator receives a welcome email when the Company account is created.

true: Sends the welcome email to the admin user

false: Does not send the email

Response

Created
codeinteger
dataobject
metaobject

Errors

400
Bad Request Error
422
Unprocessable Entity Error
HeaderArgumentDescription
X-Auth-Tokenaccess_tokenFor more about API accounts that generate access_tokens, see our Guide to API Accounts.

For example requests and more information about authenticating BigCommerce APIs, see Authentication and Example Requests.

For more about BigCommerce OAuth scopes, see our Guide to API Accounts.

For a list of API status codes, see API Status Codes.

HeaderArgumentDescription
X-Store-Hashstore_hashThe unique store hash associated with a BigCommerce store that has B2B Edition enabled.

The ID of the BigCommerce customer group assigned to the Company account. This field can be static or configurable depending on whether or not your store uses Independent Companies behavior. See Independent Companies Behavior for more information.

The ID of the price list assigned to the Company account. This field is read-only for stores using Independent Companies Behavior.

If your store uses legacy Dependent Companies behavior and it does not have Multi-Storefront enabled, this field is required for creating new Company accounts. If your store has Multi-Storefront enabled, use the priceListAssign array instead.