Magento - Get Customers
Description
Section titled “Description”This module allows querying customers from your Magento 2 store with filters by email, name, group, and dates.
Configuration
Section titled “Configuration”| Field | Type | Required | Description |
|---|---|---|---|
credentials_id | string | Yes | Credentials ID |
customer_id | string | No | Specific customer ID |
email | string | No | Filter by exact email |
firstname | string | No | Search by first name |
lastname | string | No | Search by last name |
group_id | number | No | Customer group ID |
website_id | number | No | Website ID |
created_at_from | string | No | Registered since |
created_at_to | string | No | Registered until |
sort_field | string | No | Sort field |
sort_direction | string | No | ASC or DESC |
page_size | number | No | Customers per page |
current_page | number | No | Current page |
Credentials
Section titled “Credentials”| Field | Description |
|---|---|
store_url | Magento store base URL (e.g.: https://mystore.com) |
access_token | Integration access token with customer read permissions |
Default Customer Groups
Section titled “Default Customer Groups”| ID | Name |
|---|---|
| 0 | NOT LOGGED IN |
| 1 | General |
| 2 | Wholesale |
| 3 | Retailer |
Output
Section titled “Output”{ "success": true, "customers": [ { "id": 123, "email": "cliente@ejemplo.com", "firstname": "Juan", "lastname": "Garcia", "group_id": 1, "website_id": 1, "created_at": "2024-01-15 10:30:00", "addresses": [] } ], "total": 500, "page_size": 20, "current_page": 1, "message": "20 customers retrieved"}Usage Example
Section titled “Usage Example”Search by email
Section titled “Search by email”{ "credentials_id": "magento_tienda", "email": "cliente@ejemplo.com"}Customers from a group
Section titled “Customers from a group”{ "credentials_id": "magento_tienda", "group_id": 2, "page_size": 100}New customers this month
Section titled “New customers this month”{ "credentials_id": "magento_tienda", "created_at_from": "2024-01-01 00:00:00", "created_at_to": "2024-01-31 23:59:59"}- Email search is exact
- Addresses are included in the response
- Customer groups are customizable in Magento
Related Nodes
Section titled “Related Nodes”- MagentoCreateCustomer - Create new customers
- MagentoUpdateCustomer - Update existing customers
- MagentoGetOrders - Get customer orders