Prerequisites
- The capability is enabled for your project by Reap. Talk to your account manager to request it; Reap reviews your PCI DSS compliance status before enabling. Calls from projects without it receive
403 PAN_REVEAL_NOT_ENABLED. - You hold the RSA private key:
- Production: you generate the key pair (RSA, 2048 bits or larger) and send only the public key to your implementation manager, who registers it against your program. The private key never leaves your systems and Reap never holds a copy.
- Sandbox: a single, publicly documented key pair is shared by all sandbox programs (see Sandbox keys). It provides no confidentiality, sandbox cards are test cards.
Request
See Reveal PAN for the full endpoint reference.Response
encryption is one of:
The scheme is a property of the public key registered for your program, so it stays fixed until that key is replaced. Read it from every response rather than hardcoding it, so a key rotation cannot break your decryption.
Decrypting
encryptedData yields a JSON document:
Decryption
Base64-decodeencryptedData, then decrypt with your RSA private key using OAEP padding and the hash named by encryption: SHA-256 for RSA_OAEP_SHA256, SHA-1 for RSA_OAEP_SHA1.
- OpenSSL
- Node.js
Errors
Sandbox keys
All sandbox programs share one RSA key pair. Use this private key to decrypt sandbox responses:Security obligations
- Decrypt only on PCI DSS compliant backend systems.
- Never log, persist, or cache the decrypted PAN, CVV, or expiry date.
- Never expose the private key or decrypted details to client-side code.
- Every retrieval is audited by Reap.