Extended Data - Ingress
If your GAINS instance has extended data attributes enabled, you will be able to supply additional key-value pairs as part of your inbound payload.
For example, consider the below POST request to load new customers in to GAINS:
[
{
"CustomerCode": "string",
"Name": "string",
"ShipToCode": "string",
"ShipFromIdealLocationCode": "string",
"Address1": "string",
"Address2": "string",
"City": "string",
"State": "string",
"Country": "string",
"PostalCode": "string",
"Latitude": 0,
"Longitude": 0,
"StartDate": "2024-06-20",
"EndDate": "2024-06-20",
"NearestLocation": "string",
"ExtendedData": {
"Attribute": "Value",
"AnotherAttribute": "Value"
}
}
]
The components of extended data include:
- A wrapper object called
ExtendedData
which can contain 1..n attributes - Attribute names can be defined by you but these need to be communicated to your GAINS representative (for mapping purposes)
- String values for said attributes are provided from your systems. These will be stored as strings
Supported Endpoints
Ingress of extended data is supported for the following endpoints:
- POST
/locations
- POST
/skus-locations
- POST
/supply-transactions
- POST
/supply-transactions-splits
- POST
/demand-transactions
Error Scenarios
When your GAINS environment is configured to expect extended data for a specific endpoint, then you must include the ExtendedData
object and agreed upon attributes as part of the payload. Failing to do so will result in:
HTTP 422 Unprocessable Content
{
Reason: "ExtendedData is expected as part of the payload..."
}
If, for a given record, a specific extended attribute is not available, include the attribute with an empty string value.
Later, during processing of inbound payloads, any extended data attributes that contribute to failed processing will return a response consistent with the documentation on Rejected Records
Updated about 2 months ago