POST {{baseURL}}/v2/transactions/{{transactionId}}/share-receipt
This endpoint shares a transaction receipt by SMS.
The following is a typical workflow:
- For authorization:
POST /v2/transactions - For sharing the receipt:
/v2/transactions/a1b2c3d4-e5f6-7890-abcd-ef1234567890/share-receipt.
The transactionId, the UUID in the path, is returned fromPOST /v2/transactions. - A successful response is 200 OK with no response body.
Notes for the workflow:
- The
hasCustomerConsentis required and must betrue. The endpoint will reject the request if the customer has not explicitly consented to receive an SMS. - The
mobileNumberdoes not have to match the one on the original transaction. A receipt can be sent to any phone number the customer provides at time of receipt.
See Also:
To list transactions, see GET /v2/transactions.
To retrieve a transaction by ID, see GET /v2/transactions/{transactionId}.
To create a new transaction, see POST /v2/transactions.
To capture a transaction, see POST /v2/transactions/{transactionId}/capture.
To reverse a transaction, see POST /v2/transactions/{transactionId}/reversal.
Specifies the recipient mobile number for the SMS receipt.
Specifies the method that shares this receipt.
Valid values are:
| Value | Description |
|---|---|
| The system sends the notification by email. | |
| None | The system does not send a notification. |
| Sms | The system sends the notification by text message. |
Example: Sms
Specifies the customer's mobile phone number.
This value is required only for SMS messages.
The field hasCustomerConsent must also be true to send an SMS messages.
A receipt can be sent to any phone number the customer provides at time of receipt.
Example: +14155552309
- Sandbox environmenthttps://sandbox.api.flute.com/v2/transactions/{transactionId}/share-receipt
- Production environmenthttps://api.flute.com/v2/transactions/{transactionId}/share-receipt
curl -i -X POST \
https://sandbox.api.flute.com/v2/transactions/e6d064c0-b2a5-4cb3-bc57-8135123ed791/share-receipt \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"mobilePhoneNumber": "+15551234567",
"hasCustomerConsent": true
}'