> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chargeblast.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Digital Receipts & Deflections

> Learn how to implement Digital Receipts, Compelling Evidence 3.0 (CE3.0), and First Party Trust (FPT) to prevent chargebacks before they happen.

## Overview

Digital Receipts and Deflections work together to prevent chargebacks **before** they're filed. Unlike alerts (which intercept disputes in progress), these services stop disputes from starting.

### Digital Receipts

When cardholders check their bank statement and don't recognize a charge, they see enriched transaction details — merchant name, logo, purchase description, and contact information. This reduces "What is this charge?" confusion that leads to friendly fraud.

### Deflections

Deflections automatically block chargebacks using Visa's pre-dispute programs:

<CardGroup cols={2}>
  <Card title="Compelling Evidence 3.0 (CE3.0)" icon="file-certificate">
    When a cardholder disputes a transaction, Visa checks if the same device, IP address, or email was used for previous undisputed purchases. If compelling evidence exists, the chargeback is blocked automatically.
  </Card>

  <Card title="First Party Trust (FPT)" icon="user-check">
    Similar to CE3.0, but also uses billing/shipping address matching for even stronger fraud prevention.
  </Card>
</CardGroup>

<Info>
  Digital Receipts and Deflections share the same implementation process. The difference is which qualifying fields you provide — if certain fields are present, transactions become eligible for CE3.0/FPT deflection.
</Info>

***

## Qualifying Fields for Deflection

To enable deflections, you must provide certain data fields with your transactions:

| Field                       | CE3.0 | FPT | Description                       |
| --------------------------- | ----- | --- | --------------------------------- |
| Merchant Contact Phone      | ✓     | ✓   | Customer service phone number     |
| IP Address                  | ✓     | ✓   | Customer's IP at time of purchase |
| Customer Email              | ✓     | ✓   | Email address used for the order  |
| Billing or Shipping Address | —     | ✓   | Full address for FPT matching     |

<Note>
  The more fields you provide, the higher your deflection rate. FPT requires all fields including address; CE3.0 requires phone, IP, and email.
</Note>

***

## Choose Your Integration Path

<Tabs>
  <Tab title="Push Data (Recommended)">
    ### How It Works

    1. **Send enriched transaction data** via one of two methods:
       * [Supported payment processor](https://www.chargeblast.com/integrations) with receipt data
       * [Upload Orders](/api-reference/sync-data/upload-orders) endpoint with the `receipt` object
       * [Tracker Snippet](/guides/tracker-snippet) for IP capture on web

    2. **Chargeblast handles all lookups** — when Visa queries for transaction data or compelling evidence, we respond automatically using your uploaded data.

    3. **Monitor deflection logs** via the [Deflection Logs](/api-reference/deflections/logs) endpoint to see blocked chargebacks.

    ### Implementation Steps

    <Steps>
      <Step title="Connect Transaction Data with Receipt Info">
        Upload transactions via the [Upload Orders](/api-reference/sync-data/upload-orders) endpoint, including the `receipt` object with qualifying fields:

        ```json theme={null}
        {
          "orders": [{
            "id": "order_123",
            "amount": 1999,
            "currency": "usd",
            "transactionDate": "2024-01-15T10:30:00Z",
            "bin": "424242",
            "last4": "4242",
            "ip": "192.168.1.1",
            "receipt": {
              "customerEmail": "customer@example.com",
              "customerPhone": "+1234567890",
              "billingAddress": {
                "line1": "123 Main St",
                "city": "San Francisco",
                "state": "CA",
                "postalCode": "94102",
                "country": "US"
              },
              "description": "Premium Subscription - Annual",
              "merchantName": "Acme Inc",
              "merchantUrl": "https://acme.com"
            }
          }]
        }
        ```
      </Step>

      <Step title="(Optional) Add Tracker Snippet">
        For automatic IP capture on web transactions, add the [Tracker Snippet](/guides/tracker-snippet) to your checkout page:

        ```html theme={null}
        <script defer 
          src="https://cdn.cgb.la/v1/scripts.js" 
          data-account="YOUR_ACCOUNT_ID" 
          id="chargeblast-script">
        </script>
        ```

        Then identify the user:

        ```javascript theme={null}
        Chargeblast.identify("customer@example.com")
        ```
      </Step>

      <Step title="Monitor Deflections">
        Use the [Deflection Logs](/api-reference/deflections/logs) endpoint to track blocked chargebacks.
      </Step>
    </Steps>

    <Info>
      With push data integration, Chargeblast automatically responds to Visa queries — no real-time endpoint required.
    </Info>
  </Tab>

  <Tab title="Pull Data">
    ### How It Works

    1. **Chargeblast POSTs lookup requests** to your HTTPS endpoint when a digital receipt / deflection lookup runs (event type `digital_receipt.lookup`).

    2. **You match the transaction** from the JSON search criteria and return **HTTP 200** with a receipt body, or **HTTP 404** if not found.

    3. **You must respond within 1.5 seconds** — a hard SLA for deflection and receipt flows.

    For request headers, HMAC verification, wire-format rules, and required response fields, see the full guide: **[Digital receipt lookup pull guide](/guides/digital-receipt-lookup)**.

    ### Implementation Steps

    <Steps>
      <Step title="Implement the HTTPS POST handler">
        Build your endpoint per the [digital receipt lookup guide](/guides/digital-receipt-lookup): verify `X-Digital-Receipt-Lookup-Key` and/or `X-Digital-Receipt-Signature`, read the **raw body** for HMAC, and match primarily on **`cardBin`**, **`cardLast4`**, **`currency`**, **`arn`**, **`authCode`**, **`transactionDate`**, and **`descriptor`** (all guaranteed on the wire).
      </Step>

      <Step title="Configure URL and secrets in Chargeblast">
        In Developer settings, set **Digital receipt lookup URL** (host and path without `https://`), enable the toggle, and store your **lookup key** and **lookup signature key**. Use **Send test webhook** to validate your integration.
      </Step>

      <Step title="Return a minimal receipt (200) or not found (404)">
        On success, return JSON with top-level **`order`**, **`merchantProfile`**, and **`accountProfile`** (amounts as **strings** in this response). Include fields needed for [deflection eligibility](#qualifying-fields-for-deflection)—for example `order.transactionDetails.deviceIpAddress` and rich customer contact data for compelling evidence.

        ```json theme={null}
        {
          "order": {
            "merchantOrderId": "ord_123",
            "orderDateTime": "2026-01-15T10:07:20Z",
            "total": "15.00",
            "subtotal": "15.00",
            "currencyCode": "USD",
            "orderPhone": "+13612221788",
            "orderItems": [
              {
                "id": "line_1",
                "quantity": "1",
                "productName": "Subscription",
                "productPrice": "15.00"
              }
            ],
            "transactionDetails": {
              "deviceIpAddress": "203.0.113.10"
            }
          },
          "merchantProfile": {
            "name": "Example Co",
            "merchantReceiptContact": {
              "emailForReceipt": "support@example.com",
              "phoneForReceipt": "+18005550100",
              "websiteForReceipt": "https://example.com"
            }
          },
          "accountProfile": {
            "name": { "givenName": "Jane", "familyName": "Doe" },
            "email": "jane@example.com",
            "accountBillingAddress": {
              "city": "Austin",
              "country": "US",
              "postalCode": "78701"
            }
          }
        }
        ```
      </Step>
    </Steps>

    <Warning>
      **1.5 Second SLA** — If your endpoint doesn't respond in time, the lookup fails and the transaction won't be eligible for deflection or digital receipt display. Ensure your matching logic is optimized for speed.
    </Warning>
  </Tab>
</Tabs>

***

## Handling Deflected Transactions

When a transaction is deflected, Visa has already blocked the chargeback using compelling evidence. **You should not refund deflected transactions** — the cardholder's dispute has been resolved in your favor.

### Poll Deflection Logs

Regularly poll the [Deflection Logs](/api-reference/deflections/logs) endpoint to get a list of deflected transactions:

```bash theme={null}
GET /api/v3/deflections/logs
```

This returns transactions where chargebacks were successfully blocked via CE3.0 or FPT.

### Guard Against Refunds

Before processing any refund (whether from an alert, customer request, or internal process), check if the transaction has been deflected:

1. **Store deflected transaction IDs** — Maintain a local cache of deflected order IDs from the deflection logs
2. **Check before refunding** — Before issuing any refund, verify the transaction ID is not in your deflected list
3. **Skip refunds for deflected transactions** — If a transaction was deflected, the dispute is already resolved; issuing a refund would be unnecessary

<Warning>
  Refunding a deflected transaction means you lose the sale unnecessarily. The deflection already prevented the chargeback — there's no reason to refund.
</Warning>

***

## API Reference

| Endpoint                                                | Description                             |
| ------------------------------------------------------- | --------------------------------------- |
| [Upload Orders](/api-reference/sync-data/upload-orders) | Push transaction data with receipt info |
| [Track](/api-reference/sync-data/track)                 | Push IP/session data                    |
| [Deflection Logs](/api-reference/deflections/logs)      | View blocked chargebacks                |
| [Get Orders](/api-reference/sync-data/get-orders)       | Retrieve uploaded orders                |

***

## Related

* [Digital receipt lookup pull guide](/guides/digital-receipt-lookup) — Full pull-method spec: POST body, headers, HMAC, minimal receipt JSON
* [Tracker Snippet Guide](/guides/tracker-snippet) — Automatic IP capture for web transactions
* [Implementation Overview](/guides/implementation-overview) — Compare all services and integration paths
* [Alerts Implementation](/guides/alerts-implementation) — Handle disputes that weren't deflected
