Skip to content

Nullification

Allows you to request the cancellation of a transaction made through payku.

Base URL: https://app.payku.cl/ (Default server) · https://des.payku.cl/ (Sandbox server)
POST/api/nullification

This method allows you to create a reversal of a transaction.

Request body

ParameterTypeDescription
id string

Identifier of the transaction which you want to cancel.

maximum 40 characters
Example: trxpr2a45s1dytg1
amount int

Transaction amount.

maximum 14 digits
Example: 25000
subject string

description of the cancellation request.

maximum 200 characters
Example: transaction annulment
Ventana de terminal
curl -X POST \
https://BASE-URL/api/nullification \
-H 'Accept: application/json, text/plain, */*' \
-H 'Authorization: Bearer PUBLIC-TOKEN' \
-H 'Sign: f96ddc14a73a4dd6e009db2514108a3f44832795cd5ac50e6a80fd0b0ae92112' \
-H 'Content-Type: application/json' \
-H 'Host: BASE-URL' \
-d '{
'id': 'trxpr2a45s1dytg1',
'amount': 25000,
'subject': 'nullable request'
}'

Responses

200
{
"status": "success",
"nullify": {
"id": "trxpr2a45s1dytg1",
"amount": 25000,
"currency": "CLP",
"type": "total",
"status_nullify": "complete",
"payment": {
"gateway": "webpay",
"payment_type": "VC"
},
"created_at": "2017-05-17T19:12:57.189Z",
"updated_at": "2017-05-17T19:12:57.189Z"
},
"gateway_response": {
"status": "No availability in the wallet",
"message": "The cancellation will be executed after the amount requested is deducted from your next settlement",
"nptify": "No availability in the wallet"
}
}
Response fields
ParameterTypeDescription
status string

Registration status

Example: success
nullify object
id string

Identifier of the transaction which you want to cancel.

Example: trxpr2a45s1dytg1
amount number

Transaction amount

Example: 25000
currency string

Currency

Example: CLP
type string

NotificationTypes of registration:

  • total ( Money available, annulment was executed successfully )
  • partial ( The total of the funds is not available, it is pending )
Example: total
status_nullify string

Annulement status:

  • pending ( Registered pending old--> (register) )
  • awaiting_funds ( In process (Missing of funds) (partial) )
  • waiting_bank_details ( Approved (Waiting for customer bank details) Only Debit and other means of payment (waiting_bank_details) )
  • complete ( Approved (Bank details entered) Only Debit and other means of payment (complete) )
  • complete ( (Money collected) (complete) )
  • reverse_deleted ( Request deleted by system (request_deleted) )
  • reverse_completed ( Annulment made (request_made) )
  • reverse_deleted ( Disabled (request_deleted) )
Example: complete
payment object
gateway string

Payment method

Example: webpay
payment_type string

Payment type

Example: VC
created_at string

Cancellation request creation date

Example: 2017-05-17T19:12:57.189Z
updated_at string

Cancellation request update date

Example: 2017-05-17T19:12:57.189Z
gateway_response object

Response to the cancellation request

status string

Status of registration of the request for annulment

Example: No availability in the wallet
message string

Application process message

Example: The cancellation will be executed after the amount requested is deducted from your next settlement
nptify string

Notification on the status of the cancellation request

Example: No availability in the wallet
GET/api/nullification/{identifier}

This method allows you to obtain nullification requests made to payku by means of an identifier:

To perform the query it is necessary to add the following at the end of the endpoint /{identifier} for example: api/nullification/trxpr2a45s1dytg1.

curl -X GET \
https://BASE-URL/api/nullification/{identifier} \
-H 'Accept: application/json, text/plain, */*' \
-H 'Authorization: Bearer PUBLIC-TOKEN' \
-H 'Content-Type: application/json' \
-H 'Host: BASE-URL' \

Responses

200
{
"nullify": {
"id": "trxpr2a45s1dytg1",
"amount": 25000,
"currency": "CLP",
"type": "total",
"status_nullify": "complete",
"payment": {
"gateway": "webpay",
"payment_type": "VC"
},
"created_at": "2017-05-17T19:12:57.189Z",
"updated_at": "2017-05-17T19:12:57.189Z"
}
}
Response fields
ParameterTypeDescription
nullify object

Return data from the creation of a cancellation request

id string

Identifier of the transfer for which cancellation is to be requested.

Example: trxpr2a45s1dytg1
amount number

Transaction amount

Example: 25000
currency string

Currency

Example: CLP
type string

NotificationTypes of registration:

  • total
  • partial
Example: total
status_nullify string

Annulement status:

  • pending ( Registered pending old--> (register) )
  • awaiting_funds ( In process (Missing of funds) (partial) )
  • waiting_bank_details ( Approved (Waiting for customer bank details) Only Debit and other means of payment (waiting_bank_details) )
  • complete ( Approved (Bank details entered) Only Debit and other means of payment (complete) )
  • complete ( (Money collected) (complete) )
  • reverse_deleted ( Request deleted by system (request_deleted) )
  • reverse_completed ( Annulment made (request_made) )
  • reverse_deleted ( Disabled (request_deleted) )
Example: complete
payment object
gateway string

Payment method

Example: webpay
payment_type string

Payment type

Example: VC
created_at string

Cancellation request creation date

Example: 2017-05-17T19:12:57.189Z
updated_at string

Cancellation request update date

Example: 2017-05-17T19:12:57.189Z
POSTcallback

From the payku application, you can generate the notification url from the configuration section.


Example of callback response:
  {
      "id": "morexxzxxx",
      "id_transaction": "morexxzxxx",
      "ordencompra": "367734544",
      "fecha": "24-08-2023 12:29:35",
      "monto": 7000,
      "status": "complete"
  }