PropagaPaymentComponent using the global hook too.
onSuccessTransaction will be executed with the following response format:
onErrorTransaction will be called with this value:
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
PropagaPaymentComponent using the global hook too.
import { usePropaga } from '@propaga/react-native-sdk';
const MyAwesomeCheckout = () => {
const { PropagaPaymentComponent } = usePropaga();
return ( ... );
}
<PropagaPaymentComponent
transaction={{
cornerStoreId: '1234567890',
products: [{
externalSKU: '123',
name: 'ProductName',
quantity: 1
}],
totalAmount: 2000,
wholesalerTransactionId: 'TRAN-3245',
}}
user={{
phoneNumber: '52123567890',
firstName: 'Jon',
lastNames: 'Snow',
latitude: '19.4362086',
longitude: '-99.1572047',
}}
config={{
token: '...',
}}
onSuccessTransaction={(response) => console.log(response)}
onErrorTransaction={(error) => console.log(error)}
/>
onSuccessTransaction will be executed with the following response format:
{
transactionId: 'e83bd5ca-7742-42e5-97c2-b7a0fbaa68cf',
totalAmountWithInterest: 2000,
cornerStoreId: '6f29a76a-41c4-4c9f-b13b-709b936f4eeb',
paymentDate: '2019-01-01',
}
onErrorTransaction will be called with this value:
{
errorCode: '',
errorMessage:'',
}
Was this page helpful?
