# SurchargeResult

A model the API reference uses in a request or a response. The operation pages link every field typed as this model here.

The surcharge decision recorded on a transaction: whether a surcharge was applied, the reason
when it was not, the amounts and rates used, and the outcome of each evaluation stage.

## Fields
- `surcharged` (boolean): Whether this transaction was surcharged.
- `ineligibilityReason` (string): Stable string reason code (e.g. `nameof(SurchargeIneligibilityReason.DebitCard)`) for why  the transaction was not surcharged; `null` when `surcharged` is true. (nullable)
- `baseAmount` (number(double)): The transaction base amount the surcharge rate was applied against, in the transaction currency. (nullable)
- `baseComponents` (string): Which amount components formed `baseAmount`: `Base` (the base amount alone,  the default) or `Base+Shipping` (the merchant elected a shipping-inclusive surcharge base).  `null` on a decision recorded before the component was captured, which was  always the base amount alone. (nullable)
- `surchargeAmount` (number(double)): The computed surcharge amount, in the transaction currency; null when not surcharged. (nullable)
- `appliedRate` (number(double)): The rate actually applied, as a decimal fraction (0.03 = 3%): the lesser of `merchantRate`  and the caps below. (nullable)
- `merchantRate` (number(double)): The merchant-configured surcharge rate at evaluation time, as a decimal fraction (0.03 = 3%). (nullable)
- `networkCap` (number(double)): The card network's rate cap at evaluation time, as a decimal fraction, if applicable. (nullable)
- `stateCap` (number(double)): The governing state's rate cap at evaluation time, as a decimal fraction, if applicable. (nullable)
- `costOfAcceptanceCap` (number(double)): The merchant's cost-of-acceptance rate cap at evaluation time, as a decimal fraction, if applicable. (nullable)
- `winningCapSource` (string): Which of `merchantRate`/`networkCap`/`stateCap`/`costOfAcceptanceCap` produced `appliedRate`. (nullable)
- `cardFundingSource` (string): The card's funding source at evaluation time (e.g. "Credit", "Debit", "Prepaid"). (nullable)
- `cardBrand` (string): The card brand at evaluation time (e.g. "Visa", "Mastercard"). (nullable)
- `billingStateCode` (string): The cardholder billing address state code at evaluation time. (nullable)
- `merchantStateCode` (string): The merchant's state code at evaluation time. (nullable)
- `governingStateCode` (string): The state whose surcharge rules actually governed this evaluation. (nullable)
- `channel` (string): The originating channel (e.g. "VirtualTerminal", "HostedPaymentPage", "Api"). (nullable)
- `configurationId` (string(uuid)): The surcharge configuration evaluated against. (nullable)
- `configurationVersion` (integer(int32)): The version of the surcharge configuration evaluated against, for audit reproducibility. (nullable)
- `requiresDisclosure` (boolean): Whether the caller must present a surcharge disclosure to the cardholder.
- `evaluatedAt` (string(date-time)): UTC timestamp of when the evaluation was performed.
- `auditTrail` (array<[SurchargeStageOutcome](https://devportal.demo.winkpg.io/docs/api/models/SurchargeStageOutcome.md)>): Full per-stage audit trail from the eligibility pipeline, in execution order. (nullable)
  Fields of each item:
  - `contributorName` (string): Name of the contributor that produced this outcome. (nullable)
  - `order` (integer(int32)): The contributor's execution order in the pipeline.
  - `passed` (boolean): Whether this contributor passed (did not veto) the surcharge.
  - `reason` (string): Human-readable description of the contributor's verdict. (nullable)
  - `reasonCode` (string): Stable string reason code (e.g. `nameof(SurchargeIneligibilityReason.DebitCard)`) when this  contributor vetoed; `null` when `passed` is true. (nullable)

## See also

- [All documentation](https://devportal.demo.winkpg.io/llms.txt): the machine-readable index of every public page on this site.
