Transaction Details

You can use the Transactions object to send transaction information to and from the API.

Information is specified at both the transaction level and the transaction line level.

Transaction object

The Transaction object refers to the JSON structure that contains most of the information you need to send to the API.

You can include information such as the following at the Transaction object level:

  • Currency code
  • Buyer's details
  • Ship-to address

For example:

{
    "transaction": {
        "tax_timestamp": "2025-03-01T12:00:00Z",
        "description": "Transaction description",
        "currency_code": "EUR",
        "buyer_name": "Test buyer",
        "ship_to_address": {
            "country_code": "GB",
            "city": "Big city",
            "street_name": "Street name",
            "building_number": "100a",
            "address_detail": "2nd fl",
            "postal_code": "00000"
        },
        "billing_address": {
            "country_code": "GB",
            "city": "The big city",
            "street_name": "The street name",
            "building_number": "100a",
            "postal_code": "00000"
        },

A list of the available fields is in the Transaction Object Fields topic.

Transaction Lines object

Transaction line item information is specified in the Transaction Lines object. You can specify information such as the following:

  • Transaction amounts
  • Your e-commerce or order ID (custom_id field). This is a custom identifier that you can add to help you link your Vertex for e-Commerce transaction to other systems or records.
  • Product identifiers and classifications
  • Addresses

For example:

        "transaction_lines": [
            {
                "amount": 100,
                "custom_id": "",
                "ship_from_address": {
                    "country_code": "GB"
                },
                "description": "Product 1",
                "product_class": "P",
                "product_tax_code": {
                    "class": "TPP/Goods"
                }
            },

When the API receives this request, it will generate an identifier for the line called line_key:

               "tax_country_code": "GB",
                "line_key": "UwJ85ua2PYVf48bX",
                "custom_id": "",
                "tax_address_kind": "ship_to_address",
                "ship_from_address": {
                    "country_code": "GB",
                    "tax_region": "GB"
                },

A list of the available fields is provided in the Transaction Lines Object Fields topic.