Skip to content

Receipts

SumUp API reference and code samples.

The Receipts model obtains receipt-like details for specific transactions.

The Receipt object

Receipt details for a transaction.

  • transaction_dataReceipt Transaction

    Transaction information.

     Show attributes
     Close
    Receipt Transaction
    • transaction_codestring

      Transaction code.

    • transaction_idTransaction ID

      Unique ID of the transaction.

    • merchant_codestring

      Merchant code.

    • amountstring

      Transaction amount.

    • vat_amountstring

      Transaction VAT amount.

    • tip_amountstring

      Tip amount (included in transaction amount).

    • currencystring

      Transaction currency.

    • timestampstringformat: date-time

      Time created at.

    • statusstring

      Transaction processing status.

    • payment_typestring

      Transaction type.

    • entry_modestring

      Transaction entry mode.

    • verification_methodstring

      Cardholder verification method.

    • card_readerReceipt Reader

      Card reader details displayed on the receipt.

       Show attributes
       Close
      Receipt Reader
      • codestring

        Reader serial number.

      • typestring

        Reader type.

    • cardReceipt Card

      Payment card details displayed on the receipt.

       Show attributes
       Close
      Receipt Card
      • last_4_digitsstring

        Card last 4 digits.

      • typestring

        Card Scheme.

    • installments_countinteger

      Number of installments.

    • process_asstring
      Options: CREDITDEBIT

      Debit/Credit.

      Example: "CREDIT"
    • products[]object

      Products

       Show attributes
       Close
      Attributes
      • namestring

        Product name

        Example: "Coffee"
      • descriptionstring

        Product description

      • pricestringformat: double

        Product price

        Example: "150.0"
      • vat_ratestringformat: double

        VAT rate

        Example: "0.0"
      • single_vat_amountstringformat: double

        VAT amount for a single product

        Example: "0.0"
      • price_with_vatstringformat: double

        Product price including VAT

        Example: "150.0"
      • vat_amountstringformat: double

        VAT amount

        Example: "0.0"
      • quantityinteger

        Product quantity

        Example: 1
      • total_pricestringformat: double

        Quantity x product price

        Example: "150.0"
      • total_with_vatstringformat: double

        Total price including VAT

        Example: "150.0"
    • vat_rates[]object

      Vat rates.

       Show attributes
       Close
      Attributes
      • grossnumber

        Gross

      • netnumber

        Net

      • ratenumber

        Rate

      • vatnumber

        Vat

    • events[]ReceiptEvent

      Events

       Show attributes
       Close
      Receipt Event
      • idEvent ID

        Unique ID of the transaction event.

      • transaction_idTransaction ID

        Unique ID of the transaction.

      • typeEvent Type
        Options: PAYOUTCHARGE_BACKREFUNDPAYOUT_DEDUCTION

        Type of the transaction event.

      • statusEvent Status
        Options: FAILEDPAID_OUTPENDINGRECONCILEDREFUNDEDSCHEDULEDSUCCESSFUL

        Status of the transaction event.

        Not every value is used for every event type.

        • PENDING: The event has been created but is not final yet. Used for events that are still being processed and whose final outcome is not known yet.
        • SCHEDULED: The event is planned for a future payout cycle but has not been executed yet. This applies to payout events before money is actually sent out.
        • RECONCILED: The underlying payment has been matched with settlement data and is ready to continue through payout processing, but the funds have not been paid out yet. This applies to payout events.
        • PAID_OUT: The payout event has been completed and the funds were included in a merchant payout.
        • REFUNDED: A refund event has been accepted and recorded in the refund flow. This is the status returned for refund events once the transaction amount is being or has been returned to the payer.
        • SUCCESSFUL: The event completed successfully. Use this as the generic terminal success status for event types that do not expose a more specific business outcome such as PAID_OUT or REFUNDED.
        • FAILED: The event could not be completed. Typical examples are a payout that could not be executed or an event that was rejected during processing.
      • amountstringformat: double

        Amount of the event.

      • timestampstringformat: date-time

        Date and time of the transaction event.

      • receipt_nostring

        Receipt number associated with the event.

    • receipt_nostring

      Receipt number

    Example: {"transaction_code":"TEENSK4W2K","transaction_id":"410fc44a-5956-44e1-b5cc-19c6f8d727a4","merchant_code":"MH4H92C7","amount":"10.10","vat_amount":"6.00","tip_amount":"3.00","currency":"EUR","timestamp":"2020-02-29T10:56:56.876Z","status":"SUCCESSFUL","payment_type":"ECOM","entry_mode":"CUSTOMER_ENTRY","installments_count":1,"process_as":"CREDIT"}
  • merchant_dataReceipt Merchant Data

    Receipt merchant data

     Show attributes
     Close
    Receipt Merchant Data
    • merchant_profileobject

      Merchant profile details displayed on the receipt.

       Show attributes
       Close
      Attributes
      • merchant_codestring
        Example: "MH4H92C7"
      • business_namestring
      • company_registration_numberstring
      • vat_idstring
      • websitestring
      • emailstring
      • languagestring
      • addressobject
         Show attributes
         Close
        Attributes
        • address_line1string
        • address_line2string
        • citystring
        • countrystring
        • country_en_namestring
        • country_native_namestring
        • region_namestring
        • post_codestring
        • landlinestring
    • localestring

      Locale used for rendering localized receipt fields.

  • emv_dataobject

    EMV-specific metadata returned for card-present payments.

    Example: {}
  • acquirer_dataobject

    Acquirer-specific metadata related to the card authorization.

     Show attributes
     Close
    Attributes
    • tidstring
    • authorization_codestring
    • return_codestring
    • local_timestring
    Example: {"authorization_code":"053201","return_code":"00"}
The Receipt object
{
"transaction_data": {
"transaction_code": "TEENSK4W2K",
"transaction_id": "410fc44a-5956-44e1-b5cc-19c6f8d727a4",
"merchant_code": "MH4H92C7",
"amount": "10.10",
"vat_amount": "6.00",
"tip_amount": "3.00",
"currency": "EUR",
"timestamp": "2020-02-29T10:56:56.876Z",
"status": "SUCCESSFUL",
"payment_type": "ECOM",
"entry_mode": "CUSTOMER_ENTRY",
"installments_count": 1,
"process_as": "CREDIT"
},
"merchant_data": {
"merchant_profile": {
"merchant_code": "MH4H92C7",
"business_name": null,
"company_registration_number": null,
"vat_id": null,
"website": null,
"email": null,
"language": null,
"address": {
"address_line1": null,
"address_line2": null,
"city": null,
"country": null,
"country_en_name": null,
"country_native_name": null,
"region_name": null,
"post_code": null,
"landline": null
}
},
"locale": null
},
"emv_data": {},
"acquirer_data": {
"authorization_code": "053201",
"return_code": "00"
}
}
Receipts

Retrieve receipt details

GET/v1.1/receipts/{transaction_id}

Retrieves receipt specific data for a transaction.

Path Parameters

  • transaction_idstringrequired

    SumUp unique transaction ID or transaction code, e.g. TS7HDYLSKD.

Query Parameters

  • midstringrequired

    Merchant code.

  • tx_event_idinteger

    The ID of the transaction event (refund).

Response

Returns receipt details for the requested transaction. See Receipt object.

  • transaction_dataReceipt Transaction

    Transaction information.

     Show attributes
     Close
    Receipt Transaction
    • transaction_codestring

      Transaction code.

    • transaction_idTransaction ID

      Unique ID of the transaction.

    • merchant_codestring

      Merchant code.

    • amountstring

      Transaction amount.

    • vat_amountstring

      Transaction VAT amount.

    • tip_amountstring

      Tip amount (included in transaction amount).

    • currencystring

      Transaction currency.

    • timestampstringformat: date-time

      Time created at.

    • statusstring

      Transaction processing status.

    • payment_typestring

      Transaction type.

    • entry_modestring

      Transaction entry mode.

    • verification_methodstring

      Cardholder verification method.

    • card_readerReceipt Reader

      Card reader details displayed on the receipt.

       Show attributes
       Close
      Receipt Reader
      • codestring

        Reader serial number.

      • typestring

        Reader type.

    • cardReceipt Card

      Payment card details displayed on the receipt.

       Show attributes
       Close
      Receipt Card
      • last_4_digitsstring

        Card last 4 digits.

      • typestring

        Card Scheme.

    • installments_countinteger

      Number of installments.

    • process_asstring
      Options: CREDITDEBIT

      Debit/Credit.

      Example: "CREDIT"
    • products[]object

      Products

       Show attributes
       Close
      Attributes
      • namestring

        Product name

        Example: "Coffee"
      • descriptionstring

        Product description

      • pricestringformat: double

        Product price

        Example: "150.0"
      • vat_ratestringformat: double

        VAT rate

        Example: "0.0"
      • single_vat_amountstringformat: double

        VAT amount for a single product

        Example: "0.0"
      • price_with_vatstringformat: double

        Product price including VAT

        Example: "150.0"
      • vat_amountstringformat: double

        VAT amount

        Example: "0.0"
      • quantityinteger

        Product quantity

        Example: 1
      • total_pricestringformat: double

        Quantity x product price

        Example: "150.0"
      • total_with_vatstringformat: double

        Total price including VAT

        Example: "150.0"
    • vat_rates[]object

      Vat rates.

       Show attributes
       Close
      Attributes
      • grossnumber

        Gross

      • netnumber

        Net

      • ratenumber

        Rate

      • vatnumber

        Vat

    • events[]ReceiptEvent

      Events

       Show attributes
       Close
      Receipt Event
      • idEvent ID

        Unique ID of the transaction event.

      • transaction_idTransaction ID

        Unique ID of the transaction.

      • typeEvent Type
        Options: PAYOUTCHARGE_BACKREFUNDPAYOUT_DEDUCTION

        Type of the transaction event.

      • statusEvent Status
        Options: FAILEDPAID_OUTPENDINGRECONCILEDREFUNDEDSCHEDULEDSUCCESSFUL

        Status of the transaction event.

        Not every value is used for every event type.

        • PENDING: The event has been created but is not final yet. Used for events that are still being processed and whose final outcome is not known yet.
        • SCHEDULED: The event is planned for a future payout cycle but has not been executed yet. This applies to payout events before money is actually sent out.
        • RECONCILED: The underlying payment has been matched with settlement data and is ready to continue through payout processing, but the funds have not been paid out yet. This applies to payout events.
        • PAID_OUT: The payout event has been completed and the funds were included in a merchant payout.
        • REFUNDED: A refund event has been accepted and recorded in the refund flow. This is the status returned for refund events once the transaction amount is being or has been returned to the payer.
        • SUCCESSFUL: The event completed successfully. Use this as the generic terminal success status for event types that do not expose a more specific business outcome such as PAID_OUT or REFUNDED.
        • FAILED: The event could not be completed. Typical examples are a payout that could not be executed or an event that was rejected during processing.
      • amountstringformat: double

        Amount of the event.

      • timestampstringformat: date-time

        Date and time of the transaction event.

      • receipt_nostring

        Receipt number associated with the event.

    • receipt_nostring

      Receipt number

    Example: {"transaction_code":"TEENSK4W2K","transaction_id":"410fc44a-5956-44e1-b5cc-19c6f8d727a4","merchant_code":"MH4H92C7","amount":"10.10","vat_amount":"6.00","tip_amount":"3.00","currency":"EUR","timestamp":"2020-02-29T10:56:56.876Z","status":"SUCCESSFUL","payment_type":"ECOM","entry_mode":"CUSTOMER_ENTRY","installments_count":1,"process_as":"CREDIT"}
  • merchant_dataReceipt Merchant Data

    Receipt merchant data

     Show attributes
     Close
    Receipt Merchant Data
    • merchant_profileobject

      Merchant profile details displayed on the receipt.

       Show attributes
       Close
      Attributes
      • merchant_codestring
        Example: "MH4H92C7"
      • business_namestring
      • company_registration_numberstring
      • vat_idstring
      • websitestring
      • emailstring
      • languagestring
      • addressobject
         Show attributes
         Close
        Attributes
        • address_line1string
        • address_line2string
        • citystring
        • countrystring
        • country_en_namestring
        • country_native_namestring
        • region_namestring
        • post_codestring
        • landlinestring
    • localestring

      Locale used for rendering localized receipt fields.

  • emv_dataobject

    EMV-specific metadata returned for card-present payments.

    Example: {}
  • acquirer_dataobject

    Acquirer-specific metadata related to the card authorization.

     Show attributes
     Close
    Attributes
    • tidstring
    • authorization_codestring
    • return_codestring
    • local_timestring
    Example: {"authorization_code":"053201","return_code":"00"}
GET/v1.1/receipts/{transaction_id}
curl https://api.sumup.com/v1.1/receipts/{transaction_id} \
-X GET \
-H "Authorization: Bearer $SUMUP_API_KEY"
import SumUp from '@sumup/sdk';
const client = new SumUp();
const result = await client.receipts.get("transaction_id", "mid");
using SumUp;
var client = new SumUpClient();
var result = await client.Receipts.GetAsync(
"transaction_id",
"mid"
);
import com.sumup.sdk.SumUpClient;
SumUpClient client = SumUpClient.builder().build();
var result = client.receipts().getReceipt(
"transaction_id",
"mid"
);
from sumup import Sumup
client = Sumup()
result = client.receipts.get("transaction_id", "mid")
$sumup = new \SumUp\SumUp();
$result = $sumup->receipts->get('transaction_id', 'mid');
client := sumup.NewClient()
result, err := client.Receipts.Get(context.Background(), "transaction_id", "mid")
use sumup::Client;
let client = Client::default();
let result = client.receipts().get("transaction_id", sumup::GetReceiptParams{
mid: Some("mid".to_string()),
tx_event_id: Some("tx_event_id".to_string()),
}).await;
Response
{
"transaction_data": {
"transaction_code": "TEENSK4W2K",
"transaction_id": "410fc44a-5956-44e1-b5cc-19c6f8d727a4",
"merchant_code": "MH4H92C7",
"amount": "10.10",
"vat_amount": "6.00",
"tip_amount": "3.00",
"currency": "EUR",
"timestamp": "2020-02-29T10:56:56.876Z",
"status": "SUCCESSFUL",
"payment_type": "ECOM",
"entry_mode": "CUSTOMER_ENTRY",
"installments_count": 1,
"process_as": "CREDIT"
},
"merchant_data": {
"merchant_profile": {
"merchant_code": "MH4H92C7"
}
},
"acquirer_data": {
"authorization_code": "053201"
}
}

Content-Type: application/json

The request is invalid for the submitted parameters.

  • messagestring

    Short description of the error.

    Example: "Resource not found"
  • error_codestring

    Platform code for the error.

    Example: "NOT_FOUND"
Error 400
{
"message": "is not a valid merchant code",
"error_code": "INVALID"
}