The Customers API in Stax allows merchants to manage their customers efficiently, providing a centralized way to create, retrieve, update, and delete customer records. Customers are tied to a merchant's account and enable seamless transactions without requiring individual Stax accounts. Once a customer completes a transaction, their record is automatically saved under the merchant's account, facilitating future interactions.
Key Features
- Customer Management: Create, update, and delete customer records tied to a merchant's account.
- Effortless Retrieval: Retrieve all customers or search using various filters, such as name, email, or keywords.
- Streamlined Transactions: Automatically save customer records upon transaction completion for future use.
- Flexible Record Updates: Modify customer information to ensure records remain accurate and up to date.
- Soft Deletion: Remove customers from active view without permanent deletion, allowing for recovery when needed.
Common Use Cases
Building a Customer Database
Merchants can create customer records using the Create Customer endpoint, enabling quick access to customer details for future transactions.
Search and Filter Customers
The Find All Customers endpoint allows merchants to retrieve customer lists based on specific criteria such as first name, last name, or email address.
Update Customer Records
Keep customer records accurate with the Update a Customer's Information endpoint, ensuring merchants always have the most up-to-date information.
Handle Customer Deletion Gracefully
Use the Delete a Customer endpoint to soft-delete a customer, making the record inactive but still retrievable if necessary.
Customer Data Model
The Customers API requires certain data points for creating and managing records. Here's an overview of the required and optional fields:
Field | Description |
---|---|
firstname | Customer's first name (optional, but required if lastname , email , or company is not provided). |
lastname | Customer's last name (optional, but required if firstname , email , or company is not provided). |
Customer's email address (optional, but required if firstname , lastname , or company is not provided). | |
company | Company name associated with the customer (optional, same requirements as above). |
address_country | ISO 3 code for the country (optional). |
reference | Reference string for identifying the customer (optional). |
Status and Deletion
- Active vs Deleted Customers: Customers marked as deleted are hidden from active views but remain retrievable using their
customer_id
. - Soft Deletion: Use the Delete a Customer endpoint to soft-delete a customer record without permanently erasing it.
Benefits for Developers
Simplified Customer Management: A unified system for managing customer records tied to a merchant's account.
Efficiency in Integration: Search, retrieve, and update customer records effortlessly with powerful filtering and sorting options.
Improved Customer Experience: By maintaining accurate and centralized records, merchants can provide a seamless payment experience.