Retailer Batch
Author:
Fluent Commerce
Changed on:
28 Nov 2024
Overview
A Retailer Batch is used to create new Retailers within a Fluent Account. This can be used when a new retail operation is being onboarded to an existing Fluent Account or during the initial setup of the Fluent Account to create the required Retailers.
Key points
- Create new Retailers using the Job API
- Sample Retailer batch payload
- Retailer batch details
Retailer Creation
In order to create new Retailers in an account, you can submit a Retailer batch using the
`/job/{jobId}/batch`
`entities`
Retailer Batch Model
The following describes the fields which can be submitted as part of a retailer batch record.
Key | Type | Mandatory? | Possible Values | Constraints | Description |
retailerId | String | ✅ | This is the reference Id for the retailer you are creating.
| ||
retailerName | String | ✅ | Character length must not exceed 45 | This is a name used to identify the retailer | |
region | String | ❌ | Character length must not exceed 255 | The region where the retailer operates | |
tradingName | String | ❌ | Character length must not exceed 255 | Trading name of the retailer (can be the same as retailerName) | |
customerSupportPhone | String | ❌ | Character length must not exceed 255 | A phone number for customer support | |
customerSupportEmail | String | ❌ | Character length must not exceed 255 | An email for customer support | |
website | String | ❌ | Character length must not exceed 255 | The website of the retailer |
Example Request Payload
1{
2 "action": "CREATE",
3 "entityType": "RETAILER",
4 "entities": [
5 {
6 "retailerId": "b2c",
7 "retailerName": "b2c",
8 "region": "AUS",
9 "tradingName": "Fluent Commerce",
10 "customerSupportPhone": "1234",
11 "customerSupportEmail": "hello@fluentcommerce.com",
12 "website": "http://www.fluentcommerce.com"
13 }
14 ]
15}
Language: json
Name: Sample Retailer Batch Request Payload
Description:
Sample Retailer Batch Request Payload
Retailer Batch Details
Once a Retailer batch has been processed the details can be retrieved via the
`/job/{jobId}/batch/{batchId}`
Example Response Payload
1{
2 "batchId": "1",
3 "entityType": "RETAILER",
4 "status": "COMPLETE",
5 "start": 1,
6 "count": 10,
7 "total": 1,
8 "results": [
9 {
10 "entityId": "1",
11 "entityRef": "b2c",
12 "entityName": "b2c",
13 "apiKey": "ABCDEF",
14 "username": "b2c_admin",
15 "password": "ABCDEF",
16 "responseCode": 200,
17 "message": "Retailer created successfully"
18 }
19 ],
20 "createdOn": "2022-10-13T23:29:40.746+00:00"
21}
Language: json
Name: Sample Retailer Batch Response Payload
Description:
Sample Retailer Batch Response Payload