This POST API allows pushing Credit Memo posted in ERP into GEP SMART for further processing.
URL Format: https://<Instance>/SmartInterfaceAPI/api/Invoice/CreditMemoStatusBatch
{
"models": [
{
"sourceSytemName": "string",
"documentNumber": "string",
"documentStatus": "string",
"comments": {
"commentText": "string",
"accessType": "string",
"commentAttachment": [
{
"fileName": "string",
"fileUri": "string"
}
]
},
"lob": "string",
"clientPartnerCode": "string",
"creditMemoDate": "2020-01-22T12:24:52.146Z",
"header": {
"from": {
"domain": "string",
"identity": "string"
},
"to": {
"domain": "string",
"identity": "string"
},
"sender": {
"domain": "string",
"identity": "string",
"sharedSecret": "string",
"userAgent": "string"
}
}
}
]
}
{
"data": {},
"statusCode": "string",
"errorDetails": [
{
"key": "string",
"errors": [
{
"errorCode": "string",
"errorDescription": "string"
}
]
}
],
"successDetails": [
{
"key": "string"
}
]
}
Success Scenario - Request
Request below describes that this contains only the mandatory attributes.
{
"models": [
{
"documentStatus": "Cancelled",
"sourceSytemName": "Client Supplier code",
"documentNumber": "CM90w",
"creditMemoDate": "2020-02-07T08:31:54.609Z",
"comments": {
"commentText": "The MEMO HAS BEEN CANCELLED"
},
"clientPartnerCode": "0080000006",
"lob": "KNA-SAP",
"header": {
"from": {
"domain": "Kellogg",
"identity": "Kellogg"
},
"to": {
"domain": "Gep-Cumulus",
"identity": "GEP"
},
"sender": {
"domain": "Kellogg",
"identity": "Kellogg",
"sharedSecret": "Kellogg123",
"userAgent": "Kellogg-Suite"
}
}
}
]
}
Success Scenario – Response
{
"data": null,
"statusCode": "200",
"errorDetails": [],
"successDetails": [
{
"key": "CM90w"
}
]
}
Error Scenario – Request
{
"models": [
{
"documentStatus": "",
"sourceSytemName": "Client Supplier code",
"documentNumber": "CM094W",
"creditMemoDate": "2020-02-07T08:31:54.609Z",
"comments": {
"commentText": "The MEMO HAS BEEN CANCELLED"
},
"clientPartnerCode": "0080000006",
"lob": "KNA-SAP",
"header": {
"from": {
"domain": "Kellogg",
"identity": "Kellogg"
},
"to": {
"domain": "Gep-Cumulus",
"identity": "GEP"
},
"sender": {
"domain": "Kellogg",
"identity": "Kellogg",
"sharedSecret": "Kellogg123",
"userAgent": "Kellogg-Suite"
}
}
}
]
}
Error Scenario – Response
{
"data": null,
"statusCode": "400",
"errorDetails": [
{
"key": "CM094W",
"errors": [
{
"errorCode": "MandatoryField",
"errorDescription": "There was an error in processing the CreditMemo Status as Type is mandatory"
}
]
}
],
"successDetails": []
}
Post Invoice Status Model |
||||
Property |
Required? |
Data type |
Description |
Validations/Exceptions |
Yes |
List of InterfaceCreditMemoStatus object |
|
Models |
||||
Property |
Required? |
Data type |
Description |
Validations/Exceptions |
SourceSytemName |
No |
String |
Name of the Source System |
|
DocumentNumber |
Yes |
String |
Number for the document |
|
DocumentStatus |
Yes |
String |
Status of the document |
|
No |
List of InterfaceComment object |
|||
Lob |
No |
String |
||
ClientPartnerCode |
Yes |
String |
|
|
CreditMemoDate |
Yes |
Date Time |
|
|
Yes |
Header object |
|
Comments |
||||
Property |
Required? |
Data type |
Description |
Validations/Exceptions |
CommentText |
No |
String |
||
AccessType |
No |
String |
||
No |
List of InterfaceCommentAttachment object |
CommentAttachment |
||||
Property |
Required? |
Data type |
Description |
Validations/Exceptions |
FileName |
No |
String |
||
FileUri |
No |
String |
Header |
||||
Property |
Required? |
Data type |
Description |
Validations/Exceptions |
Yes |
From object |
|
||
Yes |
To object |
|
||
Yes |
Sender object |
|
From |
||||
Property |
Required? |
Data type |
Description |
Validations/Exceptions |
Domain |
No |
String |
||
Identity |
Yes |
String |
|
To |
||||
Property |
Required? |
Data type |
Description |
Validations/Exceptions |
Domain |
No |
String |
||
Identity |
Yes |
String |
|
Sender |
||||
Property |
Required? |
Data type |
Description |
Validations/Exceptions |
Domain |
No |
String |
||
Identity |
Yes |
String |
|
|
SharedSecret |
Yes |
String |
|
|
UserAgent |
Yes |
String |
|