Response and validation models
These models capture payment processor responses and validation results for security checks like AVS and CVV.AvsResponse
Stores Address Verification Service (AVS) check results from payment processors.Key properties
| Property | Type | Description |
|---|---|---|
| Id | Guid | Unique identifier |
| TransactionId | Guid | Associated transaction reference |
| ResponseCode | String | AVS response code |
| StreetMatch | Boolean | Street address match result |
| PostalCodeMatch | Boolean | Postal code match result |
| ResponseMessage | String | Human-readable response |
Relationships
- Belongs to a Transaction
Common AVS response codes
| Code | Description | Street | Postal |
|---|---|---|---|
| Y | Full match | Match | Match |
| A | Partial match | Match | No match |
| Z | Partial match | No match | Match |
| N | No match | No match | No match |
| U | Unavailable | - | - |
| R | Retry | - | - |
CvvResponse
Stores Card Verification Value (CVV) check results from payment processors.Key properties
| Property | Type | Description |
|---|---|---|
| Id | Guid | Unique identifier |
| TransactionId | Guid | Associated transaction reference |
| ResponseCode | String | CVV response code |
| IsMatch | Boolean | CVV match result |
| ResponseMessage | String | Human-readable response |
Relationships
- Belongs to a Transaction
Common CVV response codes
| Code | Description | Match |
|---|---|---|
| M | Match | Yes |
| N | No match | No |
| P | Not processed | - |
| S | Should be present | - |
| U | Unavailable | - |
Usage patterns
AVS validation
AVS checks compare the billing address provided by the customer against the address on file with the card issuer. This helps prevent fraudulent transactions.CVV validation
CVV checks verify that the customer has physical possession of the card by validating the security code on the back of the card.Risk management
AVS and CVV responses are used to:- Decline high-risk transactions automatically
- Flag transactions for manual review
- Calculate fraud scores
- Meet processor requirements
Configuration
Projects can configure AVS and CVV handling rules:- Required vs. optional checks
- Auto-decline on mismatch
- Manual review thresholds
- Bypass for specific transaction types
Best practices
- Always collect and validate CVV for card-not-present transactions
- Use AVS checks for additional fraud protection
- Configure appropriate decline rules based on risk tolerance
- Log all validation responses for dispute resolution
- Monitor validation failure rates for fraud patterns
Security considerations
- CVV values are never stored after validation
- AVS responses are logged for audit purposes
- Failed validation attempts are tracked for fraud detection
- Validation results are included in transaction reports
