Creates a new reversal transaction
PUT/transactions/:transactionId/reversals/:reversalTransactionId
Creates a new reversal transaction
Request
Path Parameters
The id of the transaction which should be returned.
The id of the reversal transaction which should be returned.
- application/json
Body
required
- MOD1
- MOD2
- MOD1
- MOD2
Possible values: <= 100 characters
A short text describing the purpose of the transaction
triggeredBy
object
required
The entry point via which the customer was registered or her/his data was updated
For DistributorB2B the following details are mandatory: distributorId, shopId, posDevice (id, type), operatorId
For MerchantB2B the following details are mandatory: merchantId
For PosApp the following details are mandatory: distributorId, shopId, posDevice (id, type, appInstallationId), operatorId
For Admin the following details are mandatory: operatorId
For System there are no mandatory fields
Possible values: [DistributorB2B
, MerchantB2B
, PosApp
, Admin
, System
]
The distributor at which the transaction got created/modified, in case the type is DistributorB2B
shopId
object
The distributor's shop at which the transaction got created/modified
anyOf
Arbitrary string if type is DistributorB2B
string
Id reference in uuid format if type is PosApp
string
posDevice
object
The device at which the transaction was triggered
Possible values: <= 50 characters
The unique id of the device
Possible values: [Till
, Terminal
, Mobile
]
The type of the device
The unique id of the app installation on the device
operatorId
object
The cashier/operator who performed the transaction
anyOf
Arbitrary string if type is DistributorB2B
string
Id reference in uuid format if type is Admin or PosApp
string
The customer who performed the transaction, in case the type is SelfServicePortal
The merchant who performed the transaction, in case the type is SelfServicePortal
Possible values: non-empty
and <= 50 characters
, Value must match regular expression ^[\d\p{L}]([\d\p{L}\-\. ]{0,48}[\d\p{L}])$
A reference to a transaction in an external system e.g. bank transfer.
Responses
- 201
- 400
- 409
- 422
- 500
Successful response
Response Headers
Location
string
The relative URI of the transaction.
ETag
string
The current version identifier of the transaction.
- application/json
- Schema
- Example (from schema)
Schema
The id of the transaction
Possible values: [PassthroughDeposit
, PassthroughWithdrawal
, CustomerToMerchantTransfer
, CustomerToMerchantPassthrough
, MerchantToCustomerTransfer
, MerchantToCustomerPassthrough
]
The type of the transaction, defining which other transaction properties are mandatory, e.g. PassthroughDeposit requires customerId, merchantId, documents, card
Possible values: <= 10000
The amount of the transaction
The currency code as ISO 4217 3-digit code (https://en.wikipedia.org/wiki/ISO_4217).
The unique id of the customer participating in the transaction. Available if type is Passthrough
Possible values: non-empty
and <= 100 characters
, Value must match regular expression ^[\p{L}0-9'\.\-\\!\$\%\&\/\\\(\)\[\]\{\}\=\?\+\*\#\;\,\:_\"]{1,100}$
A short text describing the purpose of the transaction
The id of another existing transaction referenced by the current one. Available if type is *Reversal or *Refund
Possible values: [Declined
, Completed
, Cancelled
]
The current(last) state of the transaction.
Possible values: [BeingProcessed
, Succeeded
, Failed
]
The overall status/outcome of the transaction.
The server-generated timestamp of the initial creation of the transaction record, in ISO 8601 format of YYYY-MM-DDThh:mm:ssZ in UTC time
The unique id of the distributor the account balance of whom will be affected. Available if type is DistributorPayment*
Possible values: non-empty
and <= 50 characters
, Value must match regular expression ^[\d\p{L}]([\d\p{L}\-\. ]{0,48}[\d\p{L}])$
A reference to a transaction in an external system e.g. bank transfer.
{
"id": "40c7fe9f-3bf9-464a-8d3a-937db20f5dae",
"type": "PassthroughDeposit",
"amount": 100,
"currency": "EUR",
"customerId": "111abc22-33de-4444-5555-111111111111",
"description": "Load into gaming account",
"referenceTransactionId": "56c7c679-3019-4a56-94c7-b043bacf0dda",
"state": "Declined",
"status": "BeingProcessed",
"createdOn": "2019-01-31T11:50:59Z",
"distributorId": "222abc22-33de-4444-5555-222222222222",
"externalReference": "234abc22-33de-4444-5555-222222222222"
}
Validation failed
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
Possible values: [Validation
, EntityVersionMismatch
, InvalidTransition
, DuplicateEntity
, CustomerNotFound
, MerchantNotFound
, MerchantNotActive
, InvalidTriggeredBy
, GeneralErrorOccurred
, TransactionIntentNotFound
, SubscriptionNotFound
]
The type of error
A short text describing the error
A link to the online documentation describing the error in detail
Identifies the conversation within which the error got generated
details
object
Contains additional details of the error
validationErrorReasons
object[]
A collection of Validation error details
name of filed that failed validation
error message
{
"code": "Validation",
"message": "string",
"moreInfo": "https://developer.example.com/ExampleService/v1.0/errors/validation",
"correlationId": "ce8056cd-ae4d-4f2d-87de-7562c92f92cc",
"details": {
"validationErrorReasons": [
{
"fieldName": "customerId",
"errorMessage": "Value must not be empty"
}
]
}
}
Transaction was updated in the meantime, get and retry
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
Possible values: [Validation
, EntityVersionMismatch
, InvalidTransition
, DuplicateEntity
, CustomerNotFound
, MerchantNotFound
, MerchantNotActive
, InvalidTriggeredBy
, GeneralErrorOccurred
, TransactionIntentNotFound
, SubscriptionNotFound
]
The type of error
A short text describing the error
A link to the online documentation describing the error in detail
Identifies the conversation within which the error got generated
details
object
Contains additional details of the error
validationErrorReasons
object[]
A collection of Validation error details
name of filed that failed validation
error message
{
"code": "Validation",
"message": "string",
"moreInfo": "https://developer.example.com/ExampleService/v1.0/errors/validation",
"correlationId": "ce8056cd-ae4d-4f2d-87de-7562c92f92cc",
"details": {
"validationErrorReasons": [
{
"fieldName": "customerId",
"errorMessage": "Value must not be empty"
}
]
}
}
Transaction could not be processed
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
Possible values: [Validation
, EntityVersionMismatch
, InvalidTransition
, DuplicateEntity
, CustomerNotFound
, MerchantNotFound
, MerchantNotActive
, InvalidTriggeredBy
, GeneralErrorOccurred
, TransactionIntentNotFound
, SubscriptionNotFound
]
The type of error
A short text describing the error
A link to the online documentation describing the error in detail
Identifies the conversation within which the error got generated
details
object
Contains additional details of the error
validationErrorReasons
object[]
A collection of Validation error details
name of filed that failed validation
error message
{
"code": "Validation",
"message": "string",
"moreInfo": "https://developer.example.com/ExampleService/v1.0/errors/validation",
"correlationId": "ce8056cd-ae4d-4f2d-87de-7562c92f92cc",
"details": {
"validationErrorReasons": [
{
"fieldName": "customerId",
"errorMessage": "Value must not be empty"
}
]
}
}
Unexpected technical error
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
Possible values: [Validation
, EntityVersionMismatch
, InvalidTransition
, DuplicateEntity
, CustomerNotFound
, MerchantNotFound
, MerchantNotActive
, InvalidTriggeredBy
, GeneralErrorOccurred
, TransactionIntentNotFound
, SubscriptionNotFound
]
The type of error
A short text describing the error
A link to the online documentation describing the error in detail
Identifies the conversation within which the error got generated
details
object
Contains additional details of the error
validationErrorReasons
object[]
A collection of Validation error details
name of filed that failed validation
error message
{
"code": "Validation",
"message": "string",
"moreInfo": "https://developer.example.com/ExampleService/v1.0/errors/validation",
"correlationId": "ce8056cd-ae4d-4f2d-87de-7562c92f92cc",
"details": {
"validationErrorReasons": [
{
"fieldName": "customerId",
"errorMessage": "Value must not be empty"
}
]
}
}