- [HTTP request](https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#body.HTTP_TEMPLATE)
- [Request body](https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#body.request_body)
  - [JSON representation](https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#body.request_body.SCHEMA_REPRESENTATION)
- [Response body](https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#body.response_body)
- [TransactionInitiatedNotificationResponse](https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#TransactionInitiatedNotificationResponse)
  - [JSON representation](https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#TransactionInitiatedNotificationResponse.SCHEMA_REPRESENTATION)
- [TransactionInitiatedNotificationResult](https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#TransactionInitiatedNotificationResult)
  - [JSON representation](https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#TransactionInitiatedNotificationResult.SCHEMA_REPRESENTATION)

This API is used by Google to notify the integrator that a payment transaction has been initiated within the Google system. The integrator will inform Google of the transaction's final result by calling the CaptureResultNotification API.

The `requestId` within the header is the idempotency key and uniquely identifies this transaction.

If the endpoint encounters an error while processing the request, the response body from this endpoint should be of type `https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/ErrorResponse`.

An example request looks like:


    {
      "requestHeader": {
        "protocolVersion": {
          "major": 2
        },
        "requestId": "requestId123",
        "requestTimestamp": {
          "epochMillis": "1502220196077"
        },
        "paymentIntegratorAccountId": "JUSPAY_1"
      },
      "transactionUri": "upi://pay?mode=04&purpose=14&orgid=000000&tid=Gtxn4686someTransactionId&tr=Gtxn4686someTransactionId&tn=Test for Imali&pa=googletest2@okaxis&pn=Google&mc=5399&am=500.00&cu=INR"
    }

An example response looks like:


    {
      "responseHeader": {
        "responseTimestamp": {
          "epochMillis": "1581900013178"
        }
      },
      "result": {
        "acknowledged": {}
      }
    }

### HTTP request

`POST https://www.integratorhost.example.com/integrator-base-path/e-wallets-v2/transactionInitiatedNotification`

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "requestHeader": { object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/RequestHeader`) }, // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "transactionUri": string // End of mutually exclusive fields. } ``` |

| Fields ||
|---|---|
| `requestHeader` | ``object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/RequestHeader`)`` **REQUIRED**: Common header for all requests. |
| **REQUIRED**: Details regarding the form of payment being used to initiate the transaction. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: ||
| `transactionUri` | `string` This is a URI which contains the essential information about the transaction including transaction identifier, amount, and currency. This will be the same URL used to generate a QR code or redirect a user for the transaction. |
| End of mutually exclusive fields. ||

### Response body

This method supports multiple return types. For additional information about what 4XX or 5XX HTTP status code to return with an `ErrorResponse`, consult the `ErrorResponse` object and [HTTP status codes documentation](https://developers.google.com/pay/e-wallets-v2/guides/connectivity/protocol-standards#http_status_codes).

| Possible response messages ||
|---|---|
| HTTP 200 Status | ``object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#TransactionInitiatedNotificationResponse`)`` |
| HTTP 4XX / 5XX Status | ``object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/ErrorResponse`)`` |
| End of mutually exclusive fields. ||

## TransactionInitiatedNotificationResponse

Response object for the transaction initiated notification method.

| JSON representation |
|---|
| ``` { "responseHeader": { object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/ResponseHeader`) }, "result": { object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#TransactionInitiatedNotificationResult`) } } ``` |

| Fields ||
|---|---|
| `responseHeader` | ``object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/ResponseHeader`)`` **REQUIRED**: Common header for all responses. |
| `result` | ``object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/transactionInitiatedNotification#TransactionInitiatedNotificationResult`)`` **REQUIRED**: The result of the transaction initiated notification call. |

## TransactionInitiatedNotificationResult

Result codes for `transactionInitiatedNotification` method call.

| JSON representation |
|---|
| ``` { // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "acknowledged": { object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/Empty`) } // End of mutually exclusive fields. } ``` |

| Fields ||
|---|---|
| **REQUIRED**: The result must contain exactly one of these messages. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: ||
| `acknowledged` | ``object (`https://developers.google.com/pay/e-wallets-v2/payment-integrator-e-wallets-api/Empty`)`` The transaction inititation notification has been successfully processed and the integrator will do additional steps to determine if the payment transaction was successful or declined. Once the integrator knows the result of the transaction, they will inform Google of the result by calling the `captureResultNotification` API. |
| End of mutually exclusive fields. ||