Paytia API exception handling

Paytia API exception handling

The Paytia API services generate status update webhook posts to allow the process and status updates to be tracked.

Outside of the standard API posts there is also exception handling required for telephony. Paytia will send update webhooks for status changes as the process processes. Most can be ignored. However (see)

Confirming the payment amount was correct

When the customer presses 1 to confirm the amount was correct, the webhook sent is

payment_stage=amount_verify&reference_id=reference_id_is_number_106&amount_verify=accepted

If the customer presses 2 to say amount was wrong, the webhook sent is

success=0&reference_id=reference_id_is_number_113

Customer call leg drops:

success=0&reference_id=ref_new34_f1Ta11234521211&callhangup=customer

This denotes a customer hanging up the call leg

Agent call leg drops:

success=0&reference_id=ref_new34_f1Ta11234521211121&callhangup=merchant

This denotes an agent hanging up the call leg

 

Customer presses *

success=0&reference_id=ref_new34_f1Ta112345212118&custabort=1

 The customer has reset the payment session and is speaking to the agent again


Agent presses *

success=0&reference_id=ref_new34_f1Ta112345212118&agentabort=1

The agent has reset the payment session and is speaking to the customer again

 

Note: In these scenarios you can consider the payment request into Paytia as failed and needs to be started again so you have a new uniqueID for the session.


Agent/User licences and assigned payment types

If you send a post in to Paytia with a specified 'agentid' value and that user doesn't have the correct payment type rights assigned for the value passed in 'transaction_flag' the Paytia will return a warning in the 'statusDescription' field

{

    "httpStatus": false,

    "reference_id": "reference_id_is_number_144",

    "status": {

        "statusCode": 400,

        "statusDescription": "The agent you are using doesn't have the right to use transaction type 3."

    }

}


If you load the iframe from here then the agent will not be able to procced with the payment. 
User rights are controlled in the Paytia administration portal Administer users > Users menu.


By clicking the Edit setting button, you can see the rights assigned to the 




The View column allows you to tick the accepted payment types the user can utilise.
    • Related Articles

    • User role rights

      This article will guide the merchant on creating user role rights and how to apply them to user that they create A mechanism that will be useful when creating users is the creation of User role rights. The Paytia platform uses security rights to ...
    • Webhooks sent from Paytia to API users for the payment capture IVR flow

      Paytia IVR webhook flow The initial post into Paytia will return a URL for the Paytia iframe. If you do not want to use the iframe you can ignore that response post ‘url’ value. Note: Paytia will maintain the reference_id value throughout the payment ...
    • API details

      What can I see in the API details view? API details shows you all the internal API exchange between Paytia telephony and API services. This is used for troubleshooting and transparency of the data passed internally on the Paytia service. The API ...
    • What does this error code from Opayo mean?

      I had an error code processing payments on Opayo and I want to understand what went wrong If the payment gateway from Opayo/Sagepay is returned you can go to https://www.opayo.co.uk/support/error-codes to check what the error code means. In most ...
    • How do I add an API key on Paytia?

      Generate a API key for your Paytia account The Paytia service requires API keys to be generated if your business or developers are integrating new services to Paytia merchant accounts. The API key specifies the merchant account on the Paytia platform ...