Commands and Events Contracts
Here you can find the contracts that every service expects to handle.
There are 2 categories of Commands: Regular and Compensation.
Regular: A command that requests some response from a service.
Compensation: A command that signals to a service to rollback a previous change.
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"accountFromId" : " 38495" ,
"accountToId" : " 12309" ,
"amount" : 100.00
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"accountFromId" : " 38495" ,
"accountToId" : " 12309" ,
"amount" : 100.00
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2"
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"error" : {
"message" : " The amount can not be negative."
}
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"error" : {
"message" : " The from account was not found on the system."
}
}
OtherReasonValidationFailedEvent
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"error" : {
"message" : " A generic error has happened. Please try again."
}
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2"
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"error" : {
"message" : " A generic error has happened. Please try again."
}
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"accountFromId" : " 38495" ,
"accountToId" : " 12309" ,
"amount" : 100.00
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"accountFromId" : " 38495" ,
"accountToId" : " 12309" ,
"amount" : 100.00
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2"
}
OtherReasonTransferFailedEvent
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"error" : {
"message" : " A generic error has happened. Please try again."
}
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2"
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"error" : {
"message" : " A generic error has happened. Please try again."
}
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"accountFromId" : " 38495" ,
"accountToId" : " 12309" ,
"amount" : 100.00
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"accountFromId" : " 38495" ,
"accountToId" : " 12309" ,
"amount" : 100.00
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"receiptId" : " 2de835db-8286-459f-a1bc-809b551a12a6" ,
"receiptSignature" : " 8951f6ab43086a04ca04b2ea6978a110f59335c6d48462640afdad0ad201b41b"
}
OtherReasonReceiptFailedEvent
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"error" : {
"message" : " A generic error has happened. Please try again."
}
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2"
}
{
"transactionId" : " afc63a8b-5ba6-46cb-97fe-4e0d7740cac2" ,
"error" : {
"message" : " A generic error has happened. Please try again."
}
}