--- title: Company - GraphQL Admin description: >- A business entity that purchases from the shop as part of B2B commerce. Companies organize multiple locations and contacts who can place orders on behalf of the organization. [`CompanyLocation`](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyLocation) objects can have custom pricing through [`Catalog`](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/Catalog) and [`PriceList`](https://shopify.dev/docs/api/admin-graphql/latest/objects/PriceList) configurations. api_version: 2025-10 api_name: admin type: object api_type: graphql source_url: html: 'https://shopify.dev/docs/api/admin-graphql/latest/objects/Company' md: 'https://shopify.dev/docs/api/admin-graphql/latest/objects/Company.md' --- # Company object Requires `read_customers` access scope or `read_companies` access scope. Also: The API client must be installed on a Shopify Plus store. A business entity that purchases from the shop as part of B2B commerce. Companies organize multiple locations and contacts who can place orders on behalf of the organization. [`CompanyLocation`](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyLocation) objects can have custom pricing through [`Catalog`](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/Catalog) and [`PriceList`](https://shopify.dev/docs/api/admin-graphql/latest/objects/PriceList) configurations. ## Fields * contact​Roles [Company​Contact​Role​Connection!](https://shopify.dev/docs/api/admin-graphql/latest/connections/CompanyContactRoleConnection) non-null The list of roles for the company contacts. * contacts [Company​Contact​Connection!](https://shopify.dev/docs/api/admin-graphql/latest/connections/CompanyContactConnection) non-null The list of contacts in the company. * contacts​Count [Count](https://shopify.dev/docs/api/admin-graphql/latest/objects/Count) The number of contacts that belong to the company. * created​At [Date​Time!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/DateTime) non-null The date and time ([ISO 8601 format](http://en.wikipedia.org/wiki/ISO_8601)) at which the company was created in Shopify. * customer​Since [Date​Time!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/DateTime) non-null The date and time ([ISO 8601 format](http://en.wikipedia.org/wiki/ISO_8601)) at which the company became the customer. * default​Cursor [String!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/String) non-null A default [cursor](https://shopify.dev/api/usage/pagination-graphql) that returns the single next record, sorted ascending by ID. * default​Role [Company​Contact​Role](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyContactRole) The role proposed by default for a contact at the company. * draft​Orders [Draft​Order​Connection!](https://shopify.dev/docs/api/admin-graphql/latest/connections/DraftOrderConnection) non-null The list of the company's draft orders. * events [Event​Connection!](https://shopify.dev/docs/api/admin-graphql/latest/connections/EventConnection) non-null The paginated list of events associated with the host subject. * external​Id [String](https://shopify.dev/docs/api/admin-graphql/latest/scalars/String) A unique externally-supplied ID for the company. * has​Timeline​Comment [Boolean!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/Boolean) non-null Whether the merchant added a timeline comment to the company. * id [ID!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/ID) non-null A globally-unique ID. * lifetime​Duration [String!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/String) non-null The lifetime duration of the company, since it became a customer of the shop. Examples: `2 days`, `3 months`, `1 year`. * locations [Company​Location​Connection!](https://shopify.dev/docs/api/admin-graphql/latest/connections/CompanyLocationConnection) non-null The list of locations in the company. * locations​Count [Count](https://shopify.dev/docs/api/admin-graphql/latest/objects/Count) The number of locations that belong to the company. * main​Contact [Company​Contact](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyContact) The main contact for the company. * metafield [Metafield](https://shopify.dev/docs/api/admin-graphql/latest/objects/Metafield) A [custom field](https://shopify.dev/docs/apps/build/custom-data), including its `namespace` and `key`, that's associated with a Shopify resource for the purposes of adding and storing additional information. * metafields [Metafield​Connection!](https://shopify.dev/docs/api/admin-graphql/latest/connections/MetafieldConnection) non-null A list of [custom fields](https://shopify.dev/docs/apps/build/custom-data) that a merchant associates with a Shopify resource. * name [String!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/String) non-null The name of the company. * note [String](https://shopify.dev/docs/api/admin-graphql/latest/scalars/String) A note about the company. * orders [Order​Connection!](https://shopify.dev/docs/api/admin-graphql/latest/connections/OrderConnection) non-null The list of the company's orders. * orders​Count [Count](https://shopify.dev/docs/api/admin-graphql/latest/objects/Count) The total number of orders placed for this company, across all its locations. * total​Spent [Money​V2!](https://shopify.dev/docs/api/admin-graphql/latest/objects/MoneyV2) non-null The total amount spent by this company, across all its locations. * updated​At [Date​Time!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/DateTime) non-null The date and time ([ISO 8601 format](http://en.wikipedia.org/wiki/ISO_8601)) at which the company was last modified. ### Deprecated fields * contact​Count [Int!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/Int) non-nullDeprecated * metafield​Definitions [Metafield​Definition​Connection!](https://shopify.dev/docs/api/admin-graphql/latest/connections/MetafieldDefinitionConnection) non-nullDeprecated *** ## Map ### Fields and connections with this object * <->[CompanyConnection.nodes](https://shopify.dev/docs/api/admin-graphql/latest/connections/CompanyConnection#returns-nodes) * {}[CompanyContact.company](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyContact#field-CompanyContact.fields.company) * {}[CompanyContactRoleAssignment.company](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyContactRoleAssignment#field-CompanyContactRoleAssignment.fields.company) * {}[CompanyEdge.node](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyEdge#field-CompanyEdge.fields.node) * {}[CompanyLocation.company](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyLocation#field-CompanyLocation.fields.company) * {}[PurchasingCompany.company](https://shopify.dev/docs/api/admin-graphql/latest/objects/PurchasingCompany#field-PurchasingCompany.fields.company) ### Possible type in * [Metafield​Reference](https://shopify.dev/docs/api/admin-graphql/latest/unions/MetafieldReference) * [Metafield​Referencer](https://shopify.dev/docs/api/admin-graphql/latest/unions/MetafieldReferencer) *** ## Queries * [companies](https://shopify.dev/docs/api/admin-graphql/latest/queries/companies) query A paginated list of companies in the shop. [`Company`](https://shopify.dev/docs/api/admin-graphql/latest/objects/Company) objects are business entities that purchase from the merchant. Use the [`query`](https://shopify.dev/docs/api/admin-graphql/latest/queries/companies#arguments-query) argument to filter companies by attributes like name or externalId. Sort and paginate results to handle large datasets efficiently. Learn more about [Shopify API search syntax](https://shopify.dev/docs/api/usage/search-syntax). * [company](https://shopify.dev/docs/api/admin-graphql/latest/queries/company) query Returns a `Company` resource by ID. *** ## \Company Queries ### Queried by * \[companies](https://shopify.dev/docs/api/admin-graphql/latest/queries/companies) * \[company](https://shopify.dev/docs/api/admin-graphql/latest/queries/company) *** ## Mutations * [company​Assign​Main​Contact](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companyAssignMainContact) mutation Assigns the main contact for the company. * [company​Create](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companyCreate) mutation Creates a [`Company`](https://shopify.dev/docs/api/admin-graphql/latest/objects/Company) for B2B commerce. This mutation creates the company and can optionally create an initial [`CompanyContact`](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyContact) and [`CompanyLocation`](https://shopify.dev/docs/api/admin-graphql/latest/objects/CompanyLocation) in a single operation. Company contacts are people who place orders on behalf of the company. Company locations are branches or offices with their own billing and shipping addresses. *** Note Creating a company without a `name` [returns an error](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companycreate?example=creating-a-company-without-a-name-returns-an-error). *** Learn more about [creating companies for B2B](https://shopify.dev/docs/apps/build/b2b/start-building#step-1-create-a-company). * [company​Revoke​Main​Contact](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companyRevokeMainContact) mutation Revokes the main contact from the company. * [company​Update](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companyUpdate) mutation Updates a [`Company`](https://shopify.dev/docs/api/admin-graphql/latest/objects/Company) with new information. Companies represent business customers that can have multiple contacts and locations with specific pricing, payment terms, and checkout settings. The mutation accepts the company's ID and an input object containing the fields to update. You can modify the company name, add or update internal notes, set an external ID for integration with other systems, or adjust the customer relationship start date. Learn more about [building B2B features](https://shopify.dev/docs/apps/build/b2b/start-building). *** ## <\~> Company Mutations ### Mutated by * <\~>[company​Assign​Main​Contact](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companyAssignMainContact) * <\~>[company​Create](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companyCreate) * <\~>[company​Revoke​Main​Contact](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companyRevokeMainContact) * <\~>[company​Update](https://shopify.dev/docs/api/admin-graphql/latest/mutations/companyUpdate) *** ## Interfaces * * [Comment​Event​Subject](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/CommentEventSubject) interface * [Has​Events](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/HasEvents) interface * [Has​Metafield​Definitions](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/HasMetafieldDefinitions) interface * [Has​Metafields](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/HasMetafields) interface * [Navigable](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/Navigable) interface * [Node](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/Node) interface *** ## ||-Company Implements ### Implements * ||-[Comment​Event​Subject](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/CommentEventSubject) * ||-[Has​Events](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/HasEvents) * ||-[Has​Metafield​Definitions](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/HasMetafieldDefinitions) * ||-[Has​Metafields](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/HasMetafields) * ||-[Navigable](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/Navigable) * ||-[Node](https://shopify.dev/docs/api/admin-graphql/latest/interfaces/Node)