- [JSON representation](https://developers.google.com/pay/redirect-payment-token-v1/google-redirect-payment-token-api/GeneratePaymentTokenRedirectResponse#SCHEMA_REPRESENTATION)

Response object for the Complete Redirect flow.

Here's an example of a clear text JSON request:


    {
      "redirectRequestId": "cmVxdWVzdDE",
      "result": {
        "success": {}
      }
    }

The `GeneratePaymentTokenRedirectResponse` is encrypted and signed using PGP or JWE+JWS. Further, this value is web-safe base64 encoded. This encoding is referred to below as `Base64UrlEncode`. In other words, the clear text JSON version of the `GeneratePaymentTokenRedirectResponse` must be passed through the following functions:

    Base64UrlEncode(
      PGPSignAndEncrypt(
    {
      "redirectRequestId": "cmVxdWVzdDE",
      "result": {
        "success": {}
      }
    }
      )
    )

or

    Base64UrlEncode(
      JWSignAndEncrypt(
    {
      "redirectRequestId": "cmVxdWVzdDE",
      "result": {
        "success": {}
      }
    }
      )
    )

| JSON representation |
|---|
| ``` { "redirectRequestId": string, // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "result": { object (https://developers.google.com/pay/redirect-payment-token-v1/payment-integrator-redirect-payment-token-api/getGeneratePaymentTokenRedirectStatus#GeneratePaymentTokenRedirectResult) }, "errorResponse": { object (`https://developers.google.com/pay/redirect-payment-token-v1/google-redirect-payment-token-api/GeneratePaymentTokenRedirectErrorResponse`) } // End of mutually exclusive fields. } ``` |

| Fields ||
|---|---|
| `redirectRequestId` | `string` **REQUIRED**: Unique identifier of the initiating redirect request. This is a string that has a max length of 100 characters, and contains only the characters "a-z", "A-Z", "0-9", ":", "-", and "_". |
| **REQUIRED**: The result of the redirect payment. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: ||
| `result` | `object (https://developers.google.com/pay/redirect-payment-token-v1/payment-integrator-redirect-payment-token-api/getGeneratePaymentTokenRedirectStatus#GeneratePaymentTokenRedirectResult)` Result of this redirect payment if it was successful, declined, or pending. |
| `errorResponse` | ``object (`https://developers.google.com/pay/redirect-payment-token-v1/google-redirect-payment-token-api/GeneratePaymentTokenRedirectErrorResponse`)`` Details if the redirect failed because of an error. Redirect payments that receive this reply are kept open, and the integrator can later send a `redirectPaymentCompleteNotification` if the payment was successful or declined. |
| End of mutually exclusive fields. ||