Voucher provision for digital channels
Operations and Messages
The table below lists the single messaging transactions that make up digital voucher provisions and the API calls you will need to implement for your digital channel.
| Transaction Leg | Operation | API Calls |
|---|---|---|
| Provision voucher | provisionVoucher |
|
| Retry voucher provision | retryProvisionVoucher |
|
| Reverse voucher | reverseVoucher |
|
| Lookup products | lookupProducts |
|
Stellr does not support advice messages (reversals or confirmations), therefore if implemented Electrum will consume any advice messages sent to the Electrum Switch.
Netcare and Stellr do not support retries, therefore Electrum will respond with a hard decline when a retry is sent to the Electrum Switch.
Message Flows
The voucher provision phase of a digital voucher purchase initiates the transaction and returns a digital voucher from the service provider. In the case of single messaging Electrum manages confirmation messages and reversals on behalf of the originating system.
The sections below describe successful voucher provision transactions and error scenarios.
Successful Voucher Provision
- The originating system sends a
POSTcall to the/vouchersAPI endpoint (provisionVoucheroperation). - The API responds with a
ProvisionResponsemessage payload containing the details of the voucher. - The transaction is complete.

Error or Timeout at Service Provider
- The originating system sends a
POSTcall to the/vouchersAPI endpoint (provisionVoucheroperation). - A hard decline or other error is encountered at the service provider.
- Electrum responds to the originating system with an HTTP status of
404and anErrorDetailmessage payload. - In the case of a hard decline, no further messaging is required from the originating system.

Timeout or Other Error at Electrum
- The originating system sends a
POSTcall to the/vouchersAPI endpoint (provisionVoucheroperation). - Electrum forwards the
ProvisionRequestmessage to the service provider. - A timeout (no response received) or other error is encountered at Electrum before receiving a successful
ProvisionResponsefrom the service provider. - Electrum sends an
ErrorDetailmessage payload to the originating system and immediately sends a reversal message to the service provider.

Timeout Downstream: Successful Retry
- The originating system sends a
POSTcall to the/vouchersAPI endpoint (provisionVoucheroperation). - Electrum forwards the
provisionRequestmessage to the service provider. - The service provider returns a
provisionResponsemessage payload containing the details of the voucher to Electrum. Electrum forwards this response to the originating system. - A timeout occurs at the originating system.
- The originating system initiates a
retryProvisionVoucherto resubmit the transaction. - Electrum searches for the original transaction outcome and responds with a
provisionResponsemessage payload containing the details of the voucher to the originating system. - The originating system successfully receives a response with the voucher details.

Timeout Downstream: Unsuccessful Retry
- The originating system sends a
POSTcall to the/vouchersAPI endpoint (provisionVoucheroperation). - Electrum forwards the
provisionRequestmessage to the service provider. - The service provider returns a
provisionResponsemessage payload containing the details of the voucher to Electrum. Electrum forwards this response to the originating system. - A timeout occurs at the originating system.
- The originating system initiates a
retryProvisionVoucherto resubmit the transaction. - Electrum searches for the original transaction outcome and responds with an
ErrorDetailmessage payload to the originating system.

If the originating system continues to time out before receiving a response from Electrum, it will send a BasicReversal message via a store-and-forward queue to Electrum, who will forward the message to the service provider as below:
Error Downstream: Timeout Persists
- The originating system sends a
POSTcall to the/vouchersAPI endpoint (provisionVoucheroperation). - Electrum forwards the
provisionRequestmessage to the service provider. - The service provider returns a
provisionResponsemessage payload containing the details of the voucher to Electrum. Electrum forwards this response to the originating system. - A timeout occurs at the originating system.
- The originating system initiates a
retryProvisionVoucherto resubmit the transaction. - The originating system continues to time out before receiving a response from Electrum.
- The originating system sends a
BasicReversalmessage via a store-and-forward queue to Electrum. - Electrum forwards the
BasicReversalmessage to the service provider and the service provider reverses the transaction. - Electrum forwards the response to the originating system.

You should not attempt transaction lookups until after the initial processing period concludes (after Electrum has received and processed the transaction outcome).