Skip to main content
Pay By Bank

Use consent-related services

In this tutorial, you will learn how to use the Account Information API to perform various account operations. By the end of this tutorial, you will be able to:

  • Renew a consent request that has not been completed
  • Revoke previously granted consent
Note

The consent related services are only supported in the U.S.

For manually entered accounts, resend the consent request when customers don't complete account validation within the timeout period. The following example shows the minimum required fields for the United States.

Sample request - To renew consent in the U.S.
curl --request POST \
  --url https://api-mock.payments.jpmorgan.com/paybybank/v2/consents/0488ecb133c34b6ab5e57a61680c463f/renew \
  --header 'Accept: application/json' \
  --header 'Client-Id: ' \
  --header 'Content-Type: application/json' \
  --header 'Idempotency-Key: ' \
  --header 'Request-Id: ' \
  --data '{
  "locale": "en-ES",
  "redirectUrl": "https://abc.merchant.com/callback"
}'
Sample response - To renew a consent in the U.S.
{
  "consentLinkId": "ed392d86-83f3-4611-ac51-3a00442c8fc5",
  "consentId": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
  "referenceId": "120c99c4b05347d096ccd77f758f7315",
  "consentLink": "https://globalconnect.jpmorgan.com?consentLinkId=ed392d86-83f3-4611-ac51-3a00442c8fc5&redirect_uri=https://test.merchant.com/callback&locale=en_US",
  "updatedAt": "2025-05-29T14:06:01Z",
  "consentLinkExpiringAt": "2025-05-29T14:16:45Z"
}

For connected accounts, you can revoke customer consent that was previously granted. The following example shows the minimum required fields for the U.S.

Sample request - To revoke a consent in the U.S.
curl --request DELETE \
  --url https://api-mock.payments.jpmorgan.com/paybybank/v2/consents/0488ecb133c34b6ab5e57a61680c463f \
  --header 'Accept: application/json' \
  --header 'Client-Id: ' \
  --header 'Idempotency-Key: ' \
  --header 'Request-Id: '
Sample response - To revoke a consent in the U.S.
204 (Consent Revoked Successfully)