LogoLogo
CommunitySupport PortalYouTubeStart a free trial
  • Welcome
  • Commerce Engine
  • Orchestration Engine
  • API Documentation
  • Release Notes
  • Changelog
  • Emporix API
  • OpenAPI Generator
  • Standard Practices
    • General Info
    • Mixins
    • Query Parameter
    • Translations
    • Custom ID
    • Upsert
    • B2B Token
  • API Guides and References
    • Authorization
      • OAuth Service
        • API Reference
          • Customer Token
          • Anonymous Token
          • Service Access Token
          • Models
        • Download API Specification
    • Artificial Intelligence
      • AI Service
        • AI Tutorials
        • API Reference
          • Text Generation
          • AI Completions
          • Models
        • Download API Specification
    • Configuration
      • Configuration Service
        • Language Tutorials
        • API Reference
          • Tenant configurations
          • Client configurations
          • Global configurations
          • Models
        • Download API Specification
      • Country Service
        • Country Tutorial
        • API Reference
          • Countries
          • Regions
          • Models
        • Download API Specification
      • Currency Service
        • Currency Tutorial
        • API Reference
          • Currencies
          • Currency exchange
          • Models
        • Download API Specification
      • Unit Handling Service
        • Unit Handling Tutorial
        • API Reference
          • Unit management
          • Unit conversion
          • Type management
          • Models
        • Download API Specification
      • Site Settings Service
        • Site Settings Tutorial
        • API Reference
          • Mixins
          • Site settings
          • Models
        • Download API Specification
      • Indexing Service
        • Indexing Tutorial
        • API Reference
          • Configuration
          • Public Configuration
          • Reindex
          • Models
        • Download API Specification
    • Catalogs and Categories
      • Catalog Service
        • Catalog Tutorials
        • API Reference
          • List catalogs
          • Catalog management
          • Models
        • Download API Specification
      • Category Service
        • Category Tutorials
        • API Reference
          • Category Resources
          • Category Assignment Resources
          • Assignment Resources
          • Category Tree Resources
          • Models
        • Download API Specification
    • Products, Labels and Brands
      • Product Service
        • Product Tutorial
        • API Reference
          • Products
          • Product Templates
          • Models
        • Download API Specification
      • Label Service
        • Label Tutorial
        • API Reference
          • Label
          • Media
          • Models
        • Download API Specification
      • Brand Service
        • Brand Tutorial
        • API Reference
          • Brands
          • Media
          • Models
        • Download API Specification
    • Prices and Taxes
      • Price Service
        • Price Tutorials
        • API Reference
          • Price lists
          • Price matching
          • Price models
          • Prices
          • Prices assigned to price lists
          • Models
        • Download API Specification
      • Tax Service
        • Tax Tutorials
        • API Reference
          • Taxes
          • Tax calculation
          • Models
        • Download API Specification
    • Users and Permissions
      • IAM Service
        • IAM Tutorial
        • API Reference
          • Access Controls
          • Group Assignments
          • Groups
          • Permissions
          • Resources
          • Roles
          • Access Control Templates
          • Users
          • Management Dashboard Users
          • Models
        • Download API Specification
      • Session-context Service
        • Session-context Tutorial
        • API Reference
          • Session management
          • Session context modification
          • Own session management
          • Own session context modification
          • Models
        • Download API Specification
    • Companies and Customers
      • Customer Management
        • Customer Management Tutorial
        • API Reference
          • Locations
          • Contact Assignments
          • Legal Entities
          • Models
        • Download API Specification
      • Customer Service (Customer Managed)
        • API Reference
          • Addresses
          • Account and profile
          • Authentication and authorization
          • Double opt In
          • Credentials
          • Models
        • Download API Specification
      • Customer Service (Tenant Managed)
        • API Reference
          • Account and profile
          • Addresses
          • Models
        • Download API Specification
      • Customer Segments
        • Segments Tutorial
        • API Reference
          • Segments
          • Items Assignments
          • Customers Assignments
          • Models
        • Download API Specification
      • Approval Service
        • Approval Tutorials
        • API Reference
          • Approvals
          • Approval
          • Search
          • Models
        • Download API Specification
    • Delivery and Shipping
      • Shipping Service
        • Shipping Tutorial
        • API Reference
          • Customer Group Relations
          • Delivery Windows
          • Shipping Cost
          • Shipping Zones
          • Shipping Methods
          • Shipping Groups
          • Sites
          • Delivery Times Management
          • Delivery Times Slots Management
          • Delivery Cycles
          • Models
        • Download API Specification
      • Delivery Providers Service
        • API Reference
          • Delivery Orders
          • Delivery Plan
          • Models
        • Download API Specification
    • Rewards and Promotions
      • Coupon Service
        • Coupon Tutorial
        • API Reference
          • Coupon Management
          • Coupon Validation
          • Coupon Redemption
          • Referral Coupon Management
          • Models
        • Download API Specification
      • Reward-points Service
        • Reward-points Tutorial
        • API Reference
          • Redeem Options Management
          • Reward Points Management
          • Signed In Customer Reward Points
          • Models
        • Download API Specification
    • Quotes
      • Quote Service
        • Quote Tutorial
        • API Reference
          • Quote management
          • Quote history
          • Quote pdf
          • Quote reason
          • Models
        • Download API Specification
    • Checkout
      • Cart Service
        • Cart Tutorial
        • API Reference
          • Carts
          • Cart items
          • Discounts
          • Models
        • Download API Specification
      • Payment-gateway Service
        • Payment-gateway Tutorial
        • API Reference
          • Payment
          • Payment mode
          • Payment frontend
          • Payment mode frontend
          • Transaction
          • Models
        • Download API Specification
      • Checkout Service
        • Checkout Tutorial
        • API Reference
          • Checkouts
          • Models
        • Download API Specification
      • Fee Service
        • Fee Tutorial
        • API Reference
          • Fee management
          • Item Fee management
          • Product Fees management
          • Item Fee search
          • Models
        • Download API Specification
      • Shopping List
        • API Reference
          • Shopping Lists
          • Models
        • Download API Specification
    • Orders
      • Availability Service
        • Availability Tutorial
        • API Reference
          • Locations
          • Availabilities
          • Models
        • Download API Specification
      • Order Service
        • Order Tutorial
        • API Reference
          • Orders (tenant Managed)
          • Orders (customer Managed)
          • Models
        • Download API Specification
      • Pick-pack Service
        • API Reference
          • Orders
          • Order cycles
          • Assignees
          • Recalculations
          • Events
          • Models
        • Download API Specification
      • Invoice Service
        • Invoice Tutorial
        • API Reference
          • Invoice Jobs
          • Models
        • Download API Specification
      • Returns Service
        • Returns Tutorial
        • API Reference
          • Returns
          • Models
        • Download API Specification
      • SEPA Export Service
        • API Reference
          • Files
          • Jobs
          • Models
        • Download API Specification
    • Utilities
      • Schema Service
        • Schema Tutorial
        • API Reference
          • Schema
          • Type
          • Reference
          • Custom Schema Type
          • Custom Instance
          • Models
        • Download API Specification
      • Sequential-id Service
        • Sequential-id Tutorial
        • API Reference
          • Sequential IDs management
          • Models
        • Download API Specification
    • Media
      • Media Service
        • Media Tutorial
        • API Reference
          • Assets
          • Models
        • Download API Specification
    • Webhooks
      • Webhook Service
        • Webhooks Tutorial
        • API Reference
          • Config
          • Events
          • Svix Emporix Shared Account
          • Models
        • Download API Specification
      • Events-Availability
      • Events-Cart
      • Events-Catalog
      • Events-Category
      • Events-Client Management
      • Events-Customer
      • Events-Index
      • Events-Order
      • Events-Price
      • Events-Product
      • Events-Quote
      • Events-Product
    • Integrations
      • Emporix and Make
      • Identity Providers
      • Workflow Automation
Powered by GitBook
LogoLogo

Resources

  • Emporix.com
  • Developer Policy
  • Terms of Use

Find us

  • LinkedIn

© 2025 Emporix. All Rights Reserved.

On this page
  • Customer Management
  • How to set up business customer information
  • Before you start
  • Add a location
  • Add a legal entity
  • How to add a subsidiary
  • Before you start
  • Retrieve the ID of the parent company
  • Add a subsidiary
  • How to add an employee to a company's customer group
  • Before you start
  • Retrieve the ID of the company
  • Retrieve the employee's customer ID
  • Assign the contact to the company

Was this helpful?

Export as PDF
  1. API Guides and References
  2. Companies and Customers
  3. Customer Management

Customer Management Tutorial

PreviousCustomer ManagementNextAPI Reference

Last updated 2 days ago

Was this helpful?

Customer Management

Take a look at the relationships between objects in the Customer Management Service and other resources in the Emporix Commerce Engine. Click the diagram to enlarge it:

How to set up business customer information

Setting up a business customer's information is a process made up of two steps:

Before you start

Add a location

curl -i -X POST \
  'https://api.emporix.io/customer-management/{tenant}/locations' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Main HQ",
    "type": "HEADQUARTER",
    "contactDetails": {
      "emails": [
        "jon.doe@example.com",
        "adam.smith@sample.org"
      ],
      "phones": [
        "1234567890",
        "123456789"
      ],
      "addressLine1": "W Sample St",
      "addressLine2": "3601-3799",
      "city": "South Bend",
      "state": "Indiana",
      "postcode": "46619",
      "countryCode": "US",
      "tags": [
        "shipping"
      ]
    }
  }'

The id from the response is further referred to as locationId.

Add a legal entity

curl -i -X POST \
  'https://api.emporix.io/customer-management/{tenant}/legal-entities' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Company name",
    "type": "COMPANY",
    "legalInfo": {
      "legalName": "Some company name",
      "registrationDate": "2022-03-31T13:18:02.379Z",
      "registrationAgency": "Comp reg agency",
      "registrationId": "627e06ecf0452c2d6c0b81391",
      "countryOfRegistration": "DE",
      "taxRegistrationNumber": "1234"
    },
    "accountLimit": {
      "currency": "EUR",
      "value": 1000.99
    },
    "customerGroups": [
      {
        "id": "123e06ecf0452c2d6c0b81390",
        "name": {
          "en": "En customer group name",
          "de": "De customer group name"
        }
      }
    ],
    "entitiesAddresses": [
      {
        "id": "123e123455452c2d6c0b81390"
      },
      {
        "id": "123e06ecf0acd223140b12345"
      }
    ],
    "approvalGroup": [
      {
        "id": "123e121111452c12330b81390"
      },
      {
        "id": "123e061110acd223133333345"
      }
    ]
  }'

How to add a subsidiary

Subsidiaries are companies legally owned or controlled by other companies. In the Emporix Commerce Engine, subsidiaries are structured the same way as regular companies — the only difference is that a subsidiary must have its parent company specified.

Before you start

Retrieve the ID of the parent company

curl -i -X GET \
  'https://api.emporix.io/customer-management/{tenant}/legal-entities?pageNumber=1&pageSize=16&sort=name%2Cmetadata.createdAt%3Adesc&q=name%3A~john&fields=name%2Ctype&id=string&name=string&type=COMPANY&parentId=string&legalInfo.legalName=string&legalInfo.registrationDate=string&legalInfo.taxRegistrationNumber=string&legalInfo.registrationAgency=string&legalInfo.countryOfRegistration=string&legalInfo.registrationId=string' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'X-Total-Count: false'

The id from the response is further referred to as parentId.

Add a subsidiary

curl -i -X POST \
  'https://api.emporix.io/customer-management/{tenant}/legal-entities' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Company name",
    "type": "COMPANY",
    "legalInfo": {
      "legalName": "Some company name",
      "registrationDate": "2022-03-31T13:18:02.379Z",
      "registrationAgency": "Comp reg agency",
      "registrationId": "627e06ecf0452c2d6c0b81391",
      "countryOfRegistration": "DE",
      "taxRegistrationNumber": "1234"
    },
    "accountLimit": {
      "currency": "EUR",
      "value": 1000.99
    },
    "customerGroups": [
      {
        "id": "123e06ecf0452c2d6c0b81390",
        "name": {
          "en": "En customer group name",
          "de": "De customer group name"
        }
      }
    ],
    "entitiesAddresses": [
      {
        "id": "123e123455452c2d6c0b81390"
      },
      {
        "id": "123e06ecf0acd223140b12345"
      }
    ],
    "approvalGroup": [
      {
        "id": "123e121111452c12330b81390"
      },
      {
        "id": "123e061110acd223133333345"
      }
    ]
  }'

How to add an employee to a company's customer group

You can offer personalized pricing to your business customers' employees by adding them to company customer groups. A company customer group is automatically created when that company's data is added to the system.

When added to a subsidiary’s customer group, the employee is also automatically assigned to customer groups of all the subsidiary’s parent companies.

Before you start

Make sure the following requirements are fulfilled:

  • The employee has their customer account set up.

A customer account can be created by the employee themselves or from your Emporix tenant's side. For more information, check out the following endpoints in the Emporix API Reference:

Retrieve the ID of the company

curl -i -X GET \
  'https://api.emporix.io/customer-management/{tenant}/legal-entities?pageNumber=1&pageSize=16&sort=name%2Cmetadata.createdAt%3Adesc&q=name%3A~john&fields=name%2Ctype&id=string&name=string&type=COMPANY&parentId=string&legalInfo.legalName=string&legalInfo.registrationDate=string&legalInfo.taxRegistrationNumber=string&legalInfo.registrationAgency=string&legalInfo.countryOfRegistration=string&legalInfo.registrationId=string' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'X-Total-Count: false'

The id from the response is further referred to as legalEntityId.

Retrieve the employee's customer ID

curl -i -X GET \
  'https://api.emporix.io/customer/{tenant}/customers?q=contactEmail%3A{email}&sort=string&pageNumber=1&pageSize=60&expand=string' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

The id from the response is further referred to as customerId.

Assign the contact to the company

curl -i -X POST \
  'https://api.emporix.io/customer-management/{tenant}/contact-assignments' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "legalEntity": {
      "id": "612306ecf0452c2d6c0b81392"
    },
    "customer": {
      "id": "612306ecf0452c2d6c0b81123"
    },
    "type": "BILLING",
    "primary": true
  }'

.

.

Make sure you have marked the country in which the company operates as active. You can do it by sending a request to the endpoint in the Emporix API Country Service.

A location is a physical address where a company operates, such as its headquarters, office, or warehouse. To add a new location, you need to send a request to the endpoint.

A legal entity is a representation of a company. To add a new legal entity, you need to send a request to the endpoint and provide the locationId in the request body.

Make sure you have already finished the tutorial.

To find out what a company's ID is, you need to send a request to the endpoint and use the q query parameter to find the desired company.

Subsidiaries are added similarly to their parent companies. To add a new subsidiary, send a request to the endpoint. In the request body, set the type field to SUBSIDIARY and provide the parentId.

You have already finished the tutorial.

To find out what a company's ID is, you need to send a request to the endpoint and use the q query parameter to find the desired company.

To retrieve an employee's customer ID, you need to send a request to the endpoint and use the q query parameter. For example, you can search for a customer with a specific email address with q=contactEmail:employeeEmail.

A contact represents an employee of one or more business customers. To assign a contact to a legal entity (in this case, the desired company), you need to send a request to the endpoint and provide legalEntityId and customerId in the request body.

Once desired employees are added to appropriate customer groups, you can — for example — create personalized price lists for them. For instructions, check out in the Price Service guide.

Updating a country
Creating a new location
API Reference
Creating a new legal entity
API Reference
Retrieving all legal entities
API Reference
Creating a new legal entity
API Reference
Creating a new customer (customer-managed)
Creating a new customer (tenant-managed)
Retrieving all legal entities
API Reference
Retrieving a list of customers
API Reference
Creating a new contact assignment
API Reference
Adding a location
Adding a legal entity
How to set up business customer information

To test the endpoint, open the API reference below or check the example of a curl request.

To test the endpoint, open the API reference below or check the example of a curl request.

To test the endpoint, open the API reference below or check the example of a curl request.

To test the endpoint, open the API reference below or check the example of a curl request.

To test the endpoint, open the API reference below or check the example of a curl request.

To test the endpoint, open the API reference below or check the example of a curl request.

To test the endpoint, open the API reference below or check the example of a curl request.

How to set up business customer information
How to configure a price list