Javascript library
setPublicKey
Sets the public key for use in other functions.
Twisto.setPublicKey(key)
Arguments | Data Type | Description |
---|---|---|
key | String | Public Api key |
precheck
Performs a preliminary check on the customer even before choosing a payment method
Twisto.precheck(data, success, error)
Arguments | Data Type | Description |
---|---|---|
data | JSON | Encrypted JSON order data |
success | function | It is executed in case of successful communication with the server |
error | function | It is executed in case of unsuccessful communication with the server |
check
Performs a customer check and confirms or rejects the payment via Twisto
Twisto.check(data, success, error)
Arguments | Data Type | Description |
---|---|---|
data | JSON | Data about order |
success | function | It is executed in case of successful communication with the server |
error | function | It is executed in case of unsuccessful communication with the server |