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
              • POSTCreate Company
              • GETGet Company Extra Fields
              • GETGet Company by User ID
              • GETList Company Users
              • GETValidate Frontend User Email
          • Orders
          • Request for Quote
          • Sales Rep
          • Shopping List
          • Store Settings
      • Management
  • GraphQL
    • Overview
  • MCP
    • Overview
Dev Portal
LogoLogo
RESTB2BStorefrontCompanyCompanies

Create Company

POST
https://api-b2b.bigcommerce.com/api/v2/frontend/companies
POST
/api/v2/frontend/companies
$curl -X POST https://api-b2b.bigcommerce.com/api/v2/frontend/companies \
> -H "Authorization: Bearer <token>" \
> -H "Content-Type: application/json" \
> -d '{
> "companyFirstName": "Robert",
> "companyLastName": "Robertson",
> "companyName": "Great Buys",
> "companyPhoneNumber": "1234567890",
> "customerEmail": "admin@example.com",
> "customerId": "string",
> "storeHash": "abc123"
>}'
1{
2 "code": 200,
3 "message": "string",
4 "data": {
5 "companyId": 123456
6 }
7}
Submit a Business Account application on the storefront to create a Company account in the Pending status. This is an anonymous operation which does not require a [storefront authToken](/developer/api-reference/rest/b2b/storefront/authentication) for a particular customer. Equivalent Storefront GraphQL API Mutation: `companyCreate`. For more information, see the [GraphQL Playground](https://api-b2b.bigcommerce.com/graphql/playground). > The `registerCompany` mutation in the BigCommerce Storefront GraphQL API also allows you to create a new Company account as a storefront customer. See [Company Account Registration](/developer/docs/b2b-edition/storefront/graphql-storefront-api/overview) to learn more. 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. ### Pending Company Accounts If your store uses [Independent Companies behavior](https://support.bigcommerce.com/s/article/Companies-and-Customer-Groups), buyers with a pending Company account cannot log in to the B2C version of the Buyer Portal or view previous orders until you have approved or rejected their Company application. Depending on your Company management setting configurations, they may also be restricted from viewing products and placing orders. When you approve an application, the buyer can log in to the B2B version of the Buyer Portal and view previous orders. Rejecting an application restores their access to the B2C version of the Buyer Portal. For stores using legacy Dependent Companies behavior, buyers with a pending Company account can still log in to the Buyer Portal and view their orders before you have processed their application. See [Companies (Help Center)](https://support.bigcommerce.com/s/article/B2B-Edition-User-Guide-Company-and-Customer-Functions) to learn more about the settings and buyer experience for pending Company accounts.
Was this page helpful?
Previous

Get Company Default Addresses

Next

Get Company Extra Fields

Built with

Submit a Business Account application on the storefront to create a Company account in the Pending status. This is an anonymous operation which does not require a storefront authToken for a particular customer.

Equivalent Storefront GraphQL API Mutation: companyCreate. For more information, see the GraphQL Playground.

The registerCompany mutation in the BigCommerce Storefront GraphQL API also allows you to create a new Company account as a storefront customer. See Company Account Registration to learn more.

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.

Pending Company Accounts

If your store uses Independent Companies behavior, buyers with a pending Company account cannot log in to the B2C version of the Buyer Portal or view previous orders until you have approved or rejected their Company application. Depending on your Company management setting configurations, they may also be restricted from viewing products and placing orders.

When you approve an application, the buyer can log in to the B2B version of the Buyer Portal and view previous orders. Rejecting an application restores their access to the B2C version of the Buyer Portal.

For stores using legacy Dependent Companies behavior, buyers with a pending Company account can still log in to the Buyer Portal and view their orders before you have processed their application.

See Companies (Help Center) to learn more about the settings and buyer experience for pending Company accounts.

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[...]

Request

This endpoint expects an object.
companyFirstNamestringRequired
The first name of the Company account administrator.
companyLastNamestringRequired
The last name of the Company account administrator.
companyNamestringRequired
The name of the Company associated with the order's buyer.
companyPhoneNumberstringRequired
The primary phone number for the Company account.
customerEmailstringRequiredformat: "email"

The email address of the BigCommerce customer account for the Company account administrator. Must match the email on the customer account identified by customerId.

customerIdstringRequired
The ID of the BigCommerce customer account for the Company account administrator.
storeHashstringRequired
The unique store hash for the BigCommerce store.
addressLine1stringOptional
The first line of the address
addressLine2stringOptional
The second line of the address
citystringOptional
City of the address.
companyEmailstringOptionalformat: "email"
The primary email address of the company.
countrystringOptional
Country of the address.
extraFieldslist of objectsOptional
Contains extra field information associated with the order.
statestringOptional
State of the address.
zipCodestringOptional
Zip or Postal Code of the address.

Response

OK
codedoubleDefaults to 200
messagestring
dataobject
Response data.

Errors

400
Bad Request Error

Authentication header

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