Create ticket

Creates a new ticket with status `open` for the logged user.

post
Creates a new with ticket with status 'open' for the logged user

https://wallet.vndc.io/run/tickets
The logged user will be the ticket's owner and then the receiver of the payment generated after processing the ticket only if was previously approved by the payer.
Request
Response
Request
Headers
Access-Client-Token
required
string
Authentication token to track down who is emptying our stocks.
Body Parameters
amount
required
string
The transaction amount
description
optional
string
The (optional) transaction description
expiresAfter.amount
required
integer
The amount of time units
expiresAfter.field
required
string
Determines a time field, such as seconds, hours or months Possible values are: + days: Day(s) + hours: Hour(s) + millis: Millisecond(s) + months: Month(s) + seconds: Second(s) + weeks: Week(s) + years: Year(s)
orderId
optional
string
An optional order identifier given by the ticket's creator. If given then that identifier will be used at ticket processing to ensure the ticket is for that order. This attribute is usefull in case the client doesn't want to reflect the generated ticket number in its database after creating the ticket,
successWebhook
optional
string
The url to be invoked by the server after successfully approving a ticket. If an orderId is given then it will be added as a query parameter to this url when redirect as well as the ticket number too.
Response
201: Created
The created ticket
{
"id": "string",
"display": "string",
"transactionNumber": "string",
"ticketNumber": "string",
"date": "2020-05-30T09:40:09.570Z",
"amount": "string",
"fromKind": "system",
"fromUser": {
"id": "string",
"display": "string",
"shortDisplay": "string",
"image": {
"id": "string",
"name": "string",
"contentType": "string",
"length": 0,
"url": "string",
"width": 0,
"height": 0
}
},
"toKind": "system",
"toUser": {
"id": "string",
"display": "string",
"shortDisplay": "string",
"image": {
"id": "string",
"name": "string",
"contentType": "string",
"length": 0,
"url": "string",
"width": 0,
"height": 0
}
},
"type": {
"id": "string",
"name": "string",
"internalName": "string",
"from": {
"id": "string",
"name": "string",
"internalName": "string"
},
"to": {
"id": "string",
"name": "string",
"internalName": "string"
}
},
"currency": {
"id": "string",
"name": "string",
"internalName": "string",
"symbol": "string",
"prefix": "string",
"suffix": "string",
"transactionNumberPattern": "string",
"decimalDigits": 0
},
"description": "string",
"kind": "chargeback",
"authorizationStatus": "authorized"
}
401: Unauthorized
Unauthorized access. Missing or invalid crendentials supplied for such operation
{
"missingSecondaryPassword": {
"id": "string",
"name": "string",
"internalName": "string",
"global": true,
"mode": "generated"
},
"secondaryDeviceAllowed": true,
"code": "blockedAccessClient",
"userStatus": "active",
"passwordStatus": "active"
}
403: Forbidden
Permission denied for such operation
{
"passwordType": {
"id": "string",
"name": "string",
"internalName": "string"
},
"maxDeviceActivationReached": true,
"code": "devicePinRemoved",
"invalidDeviceConfirmation": "invalidConfirmation"
}
404: Not Found
An expected data was not found
{
"entityType": "string",
"key": "string"
}
422: Unprocessable Entity
Input error. Either a validation error or the maximum allowed items was exceeded
{
"generalErrors": [
"string"
],
"properties": [
"string"
],
"propertyErrors": {
"additionalProp1": [
"string"
],
"additionalProp2": [
"string"
],
"additionalProp3": [
"string"
]
},
"customFields": [
"string"
],
"customFieldErrors": {
"additionalProp1": [
"string"
],
"additionalProp2": [
"string"
],
"additionalProp3": [
"string"
]
},
"maxItems": 0,
"maxFileSize": 0,
"value": "string",
"name": "string",
"errors": {},
"indexedErrors": {
"additionalProp1": [
null
],
"additionalProp2": [
null
],
"additionalProp3": [
null
]
},
"code": "aggregated"
}
500: Internal Server Error
Unexpected error
{
"exceptionType": "string",
"exceptionMessage": "string",
"kind": "buyVoucher"
}