# Models

## The Link object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```

## The Links object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"Links":{"type":"object","properties":{"link":{"type":"array","items":{"$ref":"#/components/schemas/Link"}}},"description":"Contains related resource links associated with the customer. Each link includes an id, href, and rel (customer, customer-token, payment-plan, token, transaction).","xml":{"name":"links"}},"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```

## The payload object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"payload":{"type":"object","properties":{"customers":{"$ref":"#/components/schemas/customers"},"payloadType":{"type":"string","description":"Type of payload returned in the response.","xml":{"name":"type","attribute":true}}},"description":"Payload","xml":{"name":"payload"}},"customers":{"type":"object","properties":{"customer":{"type":"array","items":{"$ref":"#/components/schemas/customer"}}},"xml":{"name":"customers"}},"customer":{"required":["first-name","last-name"],"type":"object","properties":{"email":{"type":"string","description":"Email address associated with the customer."},"phone":{"type":"string","description":"Primary phone number of the customer."},"comments":{"type":"string","description":"Additional comments associated with the customer profile."},"metadata":{"type":"object","additionalProperties":{"type":"string","description":"Key-value pairs used to store additional information related to the customer."},"description":"Key-value pairs used to store additional information related to the customer."},"customer-key":{"type":"string","description":"A unique identifier defined to reference the customer in external systems."},"first-name":{"type":"string","description":"Customer's first name."},"last-name":{"type":"string","description":"Customer's last name."},"billing-address":{"$ref":"#/components/schemas/Address"},"shipping-address":{"$ref":"#/components/schemas/Address"},"links":{"$ref":"#/components/schemas/Links"}},"description":"Represents a recurring billing customer profile.","xml":{"name":"customer"}},"Address":{"type":"object","properties":{"company":{"type":"string","description":"Company name associated with the billing address."},"street":{"type":"string","description":"Primary street address for the billing."},"street2":{"type":"string","description":"Secondary street address information, if available."},"city":{"type":"string","description":"City associated with the billing address."},"state":{"type":"string","description":"State or province of the billing address."},"zip":{"type":"string","description":"ZIP or postal code of the billing address."},"country":{"type":"string","description":"Country of the billing address."},"phone":{"type":"string","description":"Phone number associated with the billing address."},"first-name":{"type":"string","description":"First name of the billing contact."},"last-name":{"type":"string","description":"Last name of the billing contact."}},"description":"Contains the customer's billing address details.","xml":{"name":"clearent-address"}},"Links":{"type":"object","properties":{"link":{"type":"array","items":{"$ref":"#/components/schemas/Link"}}},"description":"Contains related resource links associated with the customer. Each link includes an id, href, and rel (customer, customer-token, payment-plan, token, transaction).","xml":{"name":"links"}},"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```

## The payment-plan object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"payment-plan":{"required":["customer-key","end-date","frequency","payment-amount","start-date","token-id"],"type":"object","properties":{"frequency":{"type":"string","description":"Frequency at which the payment plan runs.","enum":["MONTHLY","WEEKLY","YEARLY"]},"metadata":{"type":"object","additionalProperties":{"type":"string","description":"Key-value metadata applied to the plan."},"description":"Key-value metadata applied to the plan."},"plan-key":{"type":"string","description":"Unique identifier of the pricing or payment plan."},"plan-name":{"type":"string","description":"Display name of the payment plan."},"customer-key":{"type":"string","description":"Unique identifier of the customer for whom the payment plan is created."},"customer-name":{"type":"string","description":"Name of the customer associated with the payment plan."},"email-address":{"type":"string","description":"The customer's email address."},"email-receipt":{"type":"string","description":"Indicates whether an email receipt is sent when a payment is processed. If true, a valid email-address must exist on the customer or be provided in the payment plan request."},"token-id":{"type":"string","description":"Identifier of the payment token used for the card or ACH to process payments for the plan."},"frequency-day":{"type":"string","description":"Day on which the payment is processed. For monthly and yearly plans this is the day of the month; for weekly plans, day of week (1-7)."},"payment-amount":{"type":"string","description":"Amount charged to the card for each payment cycle of the plan."},"ach-payment-type":{"type":"string","description":"Specifies the ACH payment type used for the plan."},"start-date":{"type":"string","description":"Specifies the date on which the payment plan becomes effective. If the specified date does not align with the frequency-day, the first payment occurs on the next frequency occurrence."},"end-date":{"type":"string","description":"Date on which the payment plan ends. Maximum of 10 years per plan."},"status":{"type":"string","description":"Current status of the payment plan.","enum":["ACTIVE","CANCELLED","SUSPENDED"]},"status-date":{"type":"string","description":"Date on which the current plan status was updated."},"frequency-month":{"type":"string","description":"Specifies the month of the year when the payment plan is executed. For example, 1 - January, 2 - February, and so on through 12 - December."},"frequency-week":{"type":"string","description":"Specifies the week number within the selected month when the payment plan is executed. Required when frequency is set to WEEKLY."},"links":{"$ref":"#/components/schemas/Links"}},"description":"Represents a recurring payment plan definition.","xml":{"name":"payment-plan"}},"Links":{"type":"object","properties":{"link":{"type":"array","items":{"$ref":"#/components/schemas/Link"}}},"description":"Contains related resource links associated with the customer. Each link includes an id, href, and rel (customer, customer-token, payment-plan, token, transaction).","xml":{"name":"links"}},"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```

## The ErrorPayload object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"ErrorPayload":{"type":"object","properties":{"error-message":{"type":"string","description":"Describes the reason for the error."},"result-code":{"type":"string","description":"Numeric code that identifies the type of error returned by the request."},"time-stamp":{"type":"string","description":"Date and time when the error occurred, ISO 8601 format (UTC)."}},"xml":{"name":"error"}}}}}
```

## The ErrorPayloadResponsePayload object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"ErrorPayloadResponsePayload":{"type":"object","properties":{"error":{"$ref":"#/components/schemas/ErrorPayload"},"payloadType":{"type":"string","description":"Type of payload returned in the response.","xml":{"name":"type","attribute":true}}},"description":"Payload","xml":{"name":"payload"}},"ErrorPayload":{"type":"object","properties":{"error-message":{"type":"string","description":"Describes the reason for the error."},"result-code":{"type":"string","description":"Numeric code that identifies the type of error returned by the request."},"time-stamp":{"type":"string","description":"Date and time when the error occurred, ISO 8601 format (UTC)."}},"xml":{"name":"error"}}}}}
```

## The payment-plans object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"payment-plans":{"required":["customer-key","end-date","frequency","payment-amount","start-date","token-id"],"type":"object","properties":{"frequency":{"type":"string","description":"Frequency at which the payment plan runs.","enum":["MONTHLY","WEEKLY","YEARLY"]},"metadata":{"type":"object","additionalProperties":{"type":"string","description":"Key-value metadata applied to the plan."},"description":"Key-value metadata applied to the plan."},"plan-key":{"type":"string","description":"Unique identifier of the pricing or payment plan."},"plan-name":{"type":"string","description":"Display name of the payment plan."},"customer-key":{"type":"string","description":"Unique identifier of the customer for whom the payment plan is created."},"customer-name":{"type":"string","description":"Name of the customer associated with the payment plan."},"email-address":{"type":"string","description":"The customer's email address."},"email-receipt":{"type":"string","description":"Indicates whether an email receipt is sent when a payment is processed. If true, a valid email-address must exist on the customer or be provided in the payment plan request."},"token-id":{"type":"string","description":"Identifier of the payment token used for the card or ACH to process payments for the plan."},"frequency-day":{"type":"string","description":"Day on which the payment is processed. For monthly and yearly plans this is the day of the month; for weekly plans, day of week (1-7)."},"payment-amount":{"type":"string","description":"Amount charged to the card for each payment cycle of the plan."},"ach-payment-type":{"type":"string","description":"Specifies the ACH payment type used for the plan."},"start-date":{"type":"string","description":"Specifies the date on which the payment plan becomes effective. If the specified date does not align with the frequency-day, the first payment occurs on the next frequency occurrence."},"end-date":{"type":"string","description":"Date on which the payment plan ends. Maximum of 10 years per plan."},"status":{"type":"string","description":"Current status of the payment plan.","enum":["ACTIVE","CANCELLED","SUSPENDED"]},"status-date":{"type":"string","description":"Date on which the current plan status was updated."},"frequency-month":{"type":"string","description":"Specifies the month of the year when the payment plan is executed. For example, 1 - January, 2 - February, and so on through 12 - December."},"frequency-week":{"type":"string","description":"Specifies the week number within the selected month when the payment plan is executed. Required when frequency is set to WEEKLY."},"links":{"$ref":"#/components/schemas/Links"}},"description":"Represents a recurring payment plan definition.","xml":{"name":"payment-plan"}},"Links":{"type":"object","properties":{"link":{"type":"array","items":{"$ref":"#/components/schemas/Link"}}},"description":"Contains related resource links associated with the customer. Each link includes an id, href, and rel (customer, customer-token, payment-plan, token, transaction).","xml":{"name":"links"}},"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```

## The ClearentCustomerTokensResponsePayload object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"ClearentCustomerTokensResponsePayload":{"type":"object","properties":{"customer-tokens":{"$ref":"#/components/schemas/tokens"},"payloadType":{"type":"string","description":"Type of payload returned in the response.","xml":{"name":"type","attribute":true}}},"description":"payload","xml":{"name":"payload"}},"tokens":{"type":"object","properties":{"token":{"type":"array","items":{"$ref":"#/components/schemas/customer-token"}}},"description":"tokens","xml":{"name":"tokens"}},"customer-token":{"required":["card-type","customer-key","exp-date","last-four-digits","token-id"],"type":"object","properties":{"customer-key":{"type":"string","description":"Unique identifier of the customer to associate with the token."},"token-id":{"type":"string","description":"Unique identifier of the existing payment token that represents the card number."},"exp-date":{"type":"string","description":"Expire date of the card (MMYY)."},"card-type":{"type":"string","description":"Type of payment card associated with the token.","enum":["AMEX","Discover","JCB","MasterCard","VISA"]},"last-four-digits":{"type":"string","description":"Last four digits of the card number associated with the token."},"description":{"type":"string","description":"Description of the customer's card to help identify the payment method."},"default":{"type":"boolean","description":"Indicates whether this card is the default payment method for the customer."},"avs-address":{"type":"string","description":"Street address used for Address Verification Service (AVS) validation for the payment card."},"avs-zip":{"type":"string","description":"ZIP or postal code used for Address Verification Service (AVS) validation."}},"description":"Represents a stored payment token for a customer.","xml":{"name":"customer-token"}}}}}
```

## The customer-token object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"customer-token":{"required":["card-type","customer-key","exp-date","last-four-digits","token-id"],"type":"object","properties":{"customer-key":{"type":"string","description":"Unique identifier of the customer to associate with the token."},"token-id":{"type":"string","description":"Unique identifier of the existing payment token that represents the card number."},"exp-date":{"type":"string","description":"Expire date of the card (MMYY)."},"card-type":{"type":"string","description":"Type of payment card associated with the token.","enum":["AMEX","Discover","JCB","MasterCard","VISA"]},"last-four-digits":{"type":"string","description":"Last four digits of the card number associated with the token."},"description":{"type":"string","description":"Description of the customer's card to help identify the payment method."},"default":{"type":"boolean","description":"Indicates whether this card is the default payment method for the customer."},"avs-address":{"type":"string","description":"Street address used for Address Verification Service (AVS) validation for the payment card."},"avs-zip":{"type":"string","description":"ZIP or postal code used for Address Verification Service (AVS) validation."}},"description":"Represents a stored payment token for a customer.","xml":{"name":"customer-token"}}}}}
```

## The tokens object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"tokens":{"type":"object","properties":{"token":{"type":"array","items":{"$ref":"#/components/schemas/customer-token"}}},"description":"tokens","xml":{"name":"tokens"}},"customer-token":{"required":["card-type","customer-key","exp-date","last-four-digits","token-id"],"type":"object","properties":{"customer-key":{"type":"string","description":"Unique identifier of the customer to associate with the token."},"token-id":{"type":"string","description":"Unique identifier of the existing payment token that represents the card number."},"exp-date":{"type":"string","description":"Expire date of the card (MMYY)."},"card-type":{"type":"string","description":"Type of payment card associated with the token.","enum":["AMEX","Discover","JCB","MasterCard","VISA"]},"last-four-digits":{"type":"string","description":"Last four digits of the card number associated with the token."},"description":{"type":"string","description":"Description of the customer's card to help identify the payment method."},"default":{"type":"boolean","description":"Indicates whether this card is the default payment method for the customer."},"avs-address":{"type":"string","description":"Street address used for Address Verification Service (AVS) validation for the payment card."},"avs-zip":{"type":"string","description":"ZIP or postal code used for Address Verification Service (AVS) validation."}},"description":"Represents a stored payment token for a customer.","xml":{"name":"customer-token"}}}}}
```

## The Address object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"Address":{"type":"object","properties":{"company":{"type":"string","description":"Company name associated with the billing address."},"street":{"type":"string","description":"Primary street address for the billing."},"street2":{"type":"string","description":"Secondary street address information, if available."},"city":{"type":"string","description":"City associated with the billing address."},"state":{"type":"string","description":"State or province of the billing address."},"zip":{"type":"string","description":"ZIP or postal code of the billing address."},"country":{"type":"string","description":"Country of the billing address."},"phone":{"type":"string","description":"Phone number associated with the billing address."},"first-name":{"type":"string","description":"First name of the billing contact."},"last-name":{"type":"string","description":"Last name of the billing contact."}},"description":"Contains the customer's billing address details.","xml":{"name":"clearent-address"}}}}}
```

## The customer object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"customer":{"required":["first-name","last-name"],"type":"object","properties":{"email":{"type":"string","description":"Email address associated with the customer."},"phone":{"type":"string","description":"Primary phone number of the customer."},"comments":{"type":"string","description":"Additional comments associated with the customer profile."},"metadata":{"type":"object","additionalProperties":{"type":"string","description":"Key-value pairs used to store additional information related to the customer."},"description":"Key-value pairs used to store additional information related to the customer."},"customer-key":{"type":"string","description":"A unique identifier defined to reference the customer in external systems."},"first-name":{"type":"string","description":"Customer's first name."},"last-name":{"type":"string","description":"Customer's last name."},"billing-address":{"$ref":"#/components/schemas/Address"},"shipping-address":{"$ref":"#/components/schemas/Address"},"links":{"$ref":"#/components/schemas/Links"}},"description":"Represents a recurring billing customer profile.","xml":{"name":"customer"}},"Address":{"type":"object","properties":{"company":{"type":"string","description":"Company name associated with the billing address."},"street":{"type":"string","description":"Primary street address for the billing."},"street2":{"type":"string","description":"Secondary street address information, if available."},"city":{"type":"string","description":"City associated with the billing address."},"state":{"type":"string","description":"State or province of the billing address."},"zip":{"type":"string","description":"ZIP or postal code of the billing address."},"country":{"type":"string","description":"Country of the billing address."},"phone":{"type":"string","description":"Phone number associated with the billing address."},"first-name":{"type":"string","description":"First name of the billing contact."},"last-name":{"type":"string","description":"Last name of the billing contact."}},"description":"Contains the customer's billing address details.","xml":{"name":"clearent-address"}},"Links":{"type":"object","properties":{"link":{"type":"array","items":{"$ref":"#/components/schemas/Link"}}},"description":"Contains related resource links associated with the customer. Each link includes an id, href, and rel (customer, customer-token, payment-plan, token, transaction).","xml":{"name":"links"}},"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```

## The customers object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"customers":{"type":"object","properties":{"customer":{"type":"array","items":{"$ref":"#/components/schemas/customer"}}},"xml":{"name":"customers"}},"customer":{"required":["first-name","last-name"],"type":"object","properties":{"email":{"type":"string","description":"Email address associated with the customer."},"phone":{"type":"string","description":"Primary phone number of the customer."},"comments":{"type":"string","description":"Additional comments associated with the customer profile."},"metadata":{"type":"object","additionalProperties":{"type":"string","description":"Key-value pairs used to store additional information related to the customer."},"description":"Key-value pairs used to store additional information related to the customer."},"customer-key":{"type":"string","description":"A unique identifier defined to reference the customer in external systems."},"first-name":{"type":"string","description":"Customer's first name."},"last-name":{"type":"string","description":"Customer's last name."},"billing-address":{"$ref":"#/components/schemas/Address"},"shipping-address":{"$ref":"#/components/schemas/Address"},"links":{"$ref":"#/components/schemas/Links"}},"description":"Represents a recurring billing customer profile.","xml":{"name":"customer"}},"Address":{"type":"object","properties":{"company":{"type":"string","description":"Company name associated with the billing address."},"street":{"type":"string","description":"Primary street address for the billing."},"street2":{"type":"string","description":"Secondary street address information, if available."},"city":{"type":"string","description":"City associated with the billing address."},"state":{"type":"string","description":"State or province of the billing address."},"zip":{"type":"string","description":"ZIP or postal code of the billing address."},"country":{"type":"string","description":"Country of the billing address."},"phone":{"type":"string","description":"Phone number associated with the billing address."},"first-name":{"type":"string","description":"First name of the billing contact."},"last-name":{"type":"string","description":"Last name of the billing contact."}},"description":"Contains the customer's billing address details.","xml":{"name":"clearent-address"}},"Links":{"type":"object","properties":{"link":{"type":"array","items":{"$ref":"#/components/schemas/Link"}}},"description":"Contains related resource links associated with the customer. Each link includes an id, href, and rel (customer, customer-token, payment-plan, token, transaction).","xml":{"name":"links"}},"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```

## The ForecastResponsePayload object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"ForecastResponsePayload":{"type":"object","properties":{"forecast":{"$ref":"#/components/schemas/forecast"},"payloadType":{"type":"string","description":"Type of payload returned in the response.","xml":{"name":"type","attribute":true}}},"description":"payload","xml":{"name":"payload"}},"forecast":{"type":"object","properties":{"dates":{"type":"array","description":"List of scheduled payment dates included in the forecast.","items":{"type":"string","description":"List of scheduled payment dates included in the forecast."}}},"description":"forecast","xml":{"name":"forecast"}}}}}
```

## The forecast object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"forecast":{"type":"object","properties":{"dates":{"type":"array","description":"List of scheduled payment dates included in the forecast.","items":{"type":"string","description":"List of scheduled payment dates included in the forecast."}}},"description":"forecast","xml":{"name":"forecast"}}}}}
```

## The Sort object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"Sort":{"type":"object","properties":{"field":{"type":"object","additionalProperties":{"type":"string","description":"Specifies the field name used to sort the result set."},"description":"Specifies the field name used to sort the result set."}},"description":"Sorting details applied to the result set."}}}}
```

## The SearchGetPaymentTransaction object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"SearchGetPaymentTransaction":{"type":"object","properties":{"viewId":{"type":"integer","description":"Identifier for the transaction view.","format":"int32"},"paymentId":{"type":"integer","description":"Unique identifier of the payment.","format":"int32"},"transactionId":{"type":"integer","description":"Identifier of the transaction.","format":"int32"},"achTransactionId":{"type":"string","description":"Identifier of the ACH transaction."},"paymentStatus":{"type":"string","description":"Current status of the payment.","enum":["STARTED","APPROVED","DECLINED","ERROR"]},"scheduledDateTime":{"type":"string","description":"Date when the payment was scheduled.","format":"date-time"},"fired":{"type":"string","description":"Date when the payment was initiated.","format":"date-time"},"completed":{"type":"string","description":"Date when the payment completed.","format":"date-time"},"exchangeId":{"type":"string","description":"Identifier used to trace the transaction exchange."},"result":{"type":"string","description":"Result message returned by the processor."},"planName":{"type":"string","description":"Name of the pricing or billing plan."},"merchantId":{"type":"string","description":"The merchant's unique identification number."},"customerKey":{"type":"string","description":"System generated customer key."},"amount":{"type":"number","description":"Transaction amount."},"authorizationCode":{"type":"string","description":"Authorization code returned by the processor."},"avsResult":{"type":"string","description":"Address Verification Service (AVS) result code."},"avsStreet":{"type":"string","description":"AVS street address."},"avsZip":{"type":"string","description":"AVS ZIP code."},"batchStringID":{"type":"string","description":"Processor batch identifier."},"billingIsShipping":{"type":"integer","description":"Indicates whether the billing address matches the shipping address.","format":"int32"},"cardHolder":{"type":"string","description":"Name of the card holder."},"cardType":{"type":"string","description":"Type of the card."},"clientIp":{"type":"string","description":"IP address from which the transaction originated."},"comments":{"type":"string","description":"Additional comments associated with the transaction."},"created":{"type":"string","description":"Date when the transaction record was created.","format":"date-time"},"cscResult":{"type":"string","description":"CSC verification result."},"gatewayCustomerId":{"type":"string","description":"Identifier of the customer as stored in the payment gateway."},"description":{"type":"string","description":"Description associated with the transaction."},"emailAddress":{"type":"string","description":"Customer's email address."},"entryMethod":{"type":"integer","description":"Method used to enter the payment information.","format":"int64"},"errorCode":{"type":"string","description":"Error code returned when the transaction fails."},"expired":{"type":"integer","description":"Indicates whether the payment or authorization has expired.","format":"int32"},"expiryDate":{"type":"string","description":"Expiration date of the card."},"firstName":{"type":"string","description":"Customer's first name."},"invoice":{"type":"string","description":"Invoice number associated with the payment."},"lastFour":{"type":"string","description":"Last four digits of the card number."},"lastName":{"type":"string","description":"Customer's last name."},"locationCity":{"type":"string","description":"City where the transaction occurred."},"locationCountry":{"type":"string","description":"Country where the transaction occurred."},"locationMeta":{"type":"string","description":"Additional location metadata."},"locationState":{"type":"string","description":"State where the transaction occurred."},"orderId":{"type":"string","description":"Merchant-defined order identifier"},"purchaseOrder":{"type":"string","description":"Purchase order number associated with the payment."},"reason":{"type":"string","description":"Reason provided for the transaction result"},"refundTotal":{"type":"string","description":"Total amount refunded for the transaction."},"response":{"type":"string","description":"Processor response message."},"resultCode":{"type":"string","description":"Processor result code for the transaction."},"status":{"type":"string","description":"Overall transaction status."},"switchId":{"type":"number","description":"Identifier of the processing switch."},"transactionType":{"type":"string","description":"Type of transaction performed."},"voidCount":{"type":"integer","description":"Number of times the transaction was voided.","format":"int64"},"batchId":{"type":"number","description":"Identifier of the batch that includes the transaction."},"originatorId":{"type":"number","description":"Identifier of the transaction originator."},"refTranId":{"type":"number","description":"Reference ID of the related transaction."},"terminalId":{"type":"number","description":"Identifier of the terminal used for processing."},"tipAmount":{"type":"number","description":"Tip amount applied to the transaction."},"originalAmount":{"type":"number","description":"Original transaction amount before adjustments."},"tipAdjusted":{"type":"integer","description":"Indicates whether the tip was adjusted.","format":"int64"},"tipAdjustmentAmount":{"type":"number","description":"Amount used to adjust the tip."},"customerTokenID":{"type":"string","description":"Tokenized identifier for the customer payment method."},"customerID":{"type":"string","description":"Unique identifier of the customer."},"paymentTransactionKey":{"type":"string","description":"Unique key for the payment transaction."},"paymentTransactionId":{"type":"integer","description":"Unique identifier of the payment transaction record.","format":"int32"},"planDetailKey":{"type":"string","description":"Identifier of the plan detail configuration."},"planKey":{"type":"string","description":"Unique identifier of the plan."},"paymentType":{"type":"string","description":"Type of payment method used."}},"description":"payload"}}}}
```

## The SearchGetPaymentTransactionPayload object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"SearchGetPaymentTransactionPayload":{"type":"object","properties":{"searchGetPaymentTransactions":{"type":"array","items":{"$ref":"#/components/schemas/SearchGetPaymentTransaction"}},"page":{"$ref":"#/components/schemas/page"}}},"SearchGetPaymentTransaction":{"type":"object","properties":{"viewId":{"type":"integer","description":"Identifier for the transaction view.","format":"int32"},"paymentId":{"type":"integer","description":"Unique identifier of the payment.","format":"int32"},"transactionId":{"type":"integer","description":"Identifier of the transaction.","format":"int32"},"achTransactionId":{"type":"string","description":"Identifier of the ACH transaction."},"paymentStatus":{"type":"string","description":"Current status of the payment.","enum":["STARTED","APPROVED","DECLINED","ERROR"]},"scheduledDateTime":{"type":"string","description":"Date when the payment was scheduled.","format":"date-time"},"fired":{"type":"string","description":"Date when the payment was initiated.","format":"date-time"},"completed":{"type":"string","description":"Date when the payment completed.","format":"date-time"},"exchangeId":{"type":"string","description":"Identifier used to trace the transaction exchange."},"result":{"type":"string","description":"Result message returned by the processor."},"planName":{"type":"string","description":"Name of the pricing or billing plan."},"merchantId":{"type":"string","description":"The merchant's unique identification number."},"customerKey":{"type":"string","description":"System generated customer key."},"amount":{"type":"number","description":"Transaction amount."},"authorizationCode":{"type":"string","description":"Authorization code returned by the processor."},"avsResult":{"type":"string","description":"Address Verification Service (AVS) result code."},"avsStreet":{"type":"string","description":"AVS street address."},"avsZip":{"type":"string","description":"AVS ZIP code."},"batchStringID":{"type":"string","description":"Processor batch identifier."},"billingIsShipping":{"type":"integer","description":"Indicates whether the billing address matches the shipping address.","format":"int32"},"cardHolder":{"type":"string","description":"Name of the card holder."},"cardType":{"type":"string","description":"Type of the card."},"clientIp":{"type":"string","description":"IP address from which the transaction originated."},"comments":{"type":"string","description":"Additional comments associated with the transaction."},"created":{"type":"string","description":"Date when the transaction record was created.","format":"date-time"},"cscResult":{"type":"string","description":"CSC verification result."},"gatewayCustomerId":{"type":"string","description":"Identifier of the customer as stored in the payment gateway."},"description":{"type":"string","description":"Description associated with the transaction."},"emailAddress":{"type":"string","description":"Customer's email address."},"entryMethod":{"type":"integer","description":"Method used to enter the payment information.","format":"int64"},"errorCode":{"type":"string","description":"Error code returned when the transaction fails."},"expired":{"type":"integer","description":"Indicates whether the payment or authorization has expired.","format":"int32"},"expiryDate":{"type":"string","description":"Expiration date of the card."},"firstName":{"type":"string","description":"Customer's first name."},"invoice":{"type":"string","description":"Invoice number associated with the payment."},"lastFour":{"type":"string","description":"Last four digits of the card number."},"lastName":{"type":"string","description":"Customer's last name."},"locationCity":{"type":"string","description":"City where the transaction occurred."},"locationCountry":{"type":"string","description":"Country where the transaction occurred."},"locationMeta":{"type":"string","description":"Additional location metadata."},"locationState":{"type":"string","description":"State where the transaction occurred."},"orderId":{"type":"string","description":"Merchant-defined order identifier"},"purchaseOrder":{"type":"string","description":"Purchase order number associated with the payment."},"reason":{"type":"string","description":"Reason provided for the transaction result"},"refundTotal":{"type":"string","description":"Total amount refunded for the transaction."},"response":{"type":"string","description":"Processor response message."},"resultCode":{"type":"string","description":"Processor result code for the transaction."},"status":{"type":"string","description":"Overall transaction status."},"switchId":{"type":"number","description":"Identifier of the processing switch."},"transactionType":{"type":"string","description":"Type of transaction performed."},"voidCount":{"type":"integer","description":"Number of times the transaction was voided.","format":"int64"},"batchId":{"type":"number","description":"Identifier of the batch that includes the transaction."},"originatorId":{"type":"number","description":"Identifier of the transaction originator."},"refTranId":{"type":"number","description":"Reference ID of the related transaction."},"terminalId":{"type":"number","description":"Identifier of the terminal used for processing."},"tipAmount":{"type":"number","description":"Tip amount applied to the transaction."},"originalAmount":{"type":"number","description":"Original transaction amount before adjustments."},"tipAdjusted":{"type":"integer","description":"Indicates whether the tip was adjusted.","format":"int64"},"tipAdjustmentAmount":{"type":"number","description":"Amount used to adjust the tip."},"customerTokenID":{"type":"string","description":"Tokenized identifier for the customer payment method."},"customerID":{"type":"string","description":"Unique identifier of the customer."},"paymentTransactionKey":{"type":"string","description":"Unique key for the payment transaction."},"paymentTransactionId":{"type":"integer","description":"Unique identifier of the payment transaction record.","format":"int32"},"planDetailKey":{"type":"string","description":"Identifier of the plan detail configuration."},"planKey":{"type":"string","description":"Unique identifier of the plan."},"paymentType":{"type":"string","description":"Type of payment method used."}},"description":"payload"},"page":{"type":"object","properties":{"number":{"type":"integer","description":"Current page number in the result set.","format":"int32"},"size":{"type":"integer","description":"Number of records returned per page.","format":"int32"},"sort":{"$ref":"#/components/schemas/Sort"},"first":{"type":"boolean","description":"Indicates whether this is the first page."},"last":{"type":"boolean","description":"Indicates whether this is the last page."},"total-pages":{"type":"integer","description":"Total number of available pages.","format":"int32"},"number-of-elements":{"type":"integer","description":"Number of records returned in the current page.","format":"int32"},"total-elements":{"type":"integer","description":"Total number of records matching the search criteria.","format":"int64"}},"description":"Contains pagination details for the returned payment results.","xml":{"name":"page"}},"Sort":{"type":"object","properties":{"field":{"type":"object","additionalProperties":{"type":"string","description":"Specifies the field name used to sort the result set."},"description":"Specifies the field name used to sort the result set."}},"description":"Sorting details applied to the result set."}}}}
```

## The page object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"page":{"type":"object","properties":{"number":{"type":"integer","description":"Current page number in the result set.","format":"int32"},"size":{"type":"integer","description":"Number of records returned per page.","format":"int32"},"sort":{"$ref":"#/components/schemas/Sort"},"first":{"type":"boolean","description":"Indicates whether this is the first page."},"last":{"type":"boolean","description":"Indicates whether this is the last page."},"total-pages":{"type":"integer","description":"Total number of available pages.","format":"int32"},"number-of-elements":{"type":"integer","description":"Number of records returned in the current page.","format":"int32"},"total-elements":{"type":"integer","description":"Total number of records matching the search criteria.","format":"int64"}},"description":"Contains pagination details for the returned payment results.","xml":{"name":"page"}},"Sort":{"type":"object","properties":{"field":{"type":"object","additionalProperties":{"type":"string","description":"Specifies the field name used to sort the result set."},"description":"Specifies the field name used to sort the result set."}},"description":"Sorting details applied to the result set."}}}}
```

## The ExpectedRun object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"ExpectedRun":{"type":"object","properties":{"amount":{"type":"number","description":"Amount expected to be processed in this run."},"plan-detail-key":{"type":"string","description":"Identifier for Plan"},"fire-time":{"type":"string","description":"Scheduled time for the expected run.","format":"date-time"}},"description":"expected-run","xml":{"name":"expected-run"}}}}}
```

## The ExpectedRuns object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"ExpectedRuns":{"type":"object","properties":{"expectedRun":{"type":"array","xml":{"name":"expected-run"},"items":{"$ref":"#/components/schemas/ExpectedRun"}}},"description":"expected-runs","xml":{"name":"expected-runs"}},"ExpectedRun":{"type":"object","properties":{"amount":{"type":"number","description":"Amount expected to be processed in this run."},"plan-detail-key":{"type":"string","description":"Identifier for Plan"},"fire-time":{"type":"string","description":"Scheduled time for the expected run.","format":"date-time"}},"description":"expected-run","xml":{"name":"expected-run"}}}}}
```

## The ExpectedRunsResponsePayload object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"ExpectedRunsResponsePayload":{"type":"object","properties":{"expected-runs":{"$ref":"#/components/schemas/ExpectedRuns"},"payloadType":{"type":"string","description":"Type of payload returned in the response.","xml":{"name":"type","attribute":true}}},"description":"payload","xml":{"name":"payload"}},"ExpectedRuns":{"type":"object","properties":{"expectedRun":{"type":"array","xml":{"name":"expected-run"},"items":{"$ref":"#/components/schemas/ExpectedRun"}}},"description":"expected-runs","xml":{"name":"expected-runs"}},"ExpectedRun":{"type":"object","properties":{"amount":{"type":"number","description":"Amount expected to be processed in this run."},"plan-detail-key":{"type":"string","description":"Identifier for Plan"},"fire-time":{"type":"string","description":"Scheduled time for the expected run.","format":"date-time"}},"description":"expected-run","xml":{"name":"expected-run"}}}}}
```

## The PaymentPlansDto object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"PaymentPlansDto":{"type":"object","properties":{"payment-plan":{"type":"array","items":{"$ref":"#/components/schemas/payment-plan"}}},"description":"payment-plans","xml":{"name":"payment-plans-dto"}},"payment-plan":{"required":["customer-key","end-date","frequency","payment-amount","start-date","token-id"],"type":"object","properties":{"frequency":{"type":"string","description":"Frequency at which the payment plan runs.","enum":["MONTHLY","WEEKLY","YEARLY"]},"metadata":{"type":"object","additionalProperties":{"type":"string","description":"Key-value metadata applied to the plan."},"description":"Key-value metadata applied to the plan."},"plan-key":{"type":"string","description":"Unique identifier of the pricing or payment plan."},"plan-name":{"type":"string","description":"Display name of the payment plan."},"customer-key":{"type":"string","description":"Unique identifier of the customer for whom the payment plan is created."},"customer-name":{"type":"string","description":"Name of the customer associated with the payment plan."},"email-address":{"type":"string","description":"The customer's email address."},"email-receipt":{"type":"string","description":"Indicates whether an email receipt is sent when a payment is processed. If true, a valid email-address must exist on the customer or be provided in the payment plan request."},"token-id":{"type":"string","description":"Identifier of the payment token used for the card or ACH to process payments for the plan."},"frequency-day":{"type":"string","description":"Day on which the payment is processed. For monthly and yearly plans this is the day of the month; for weekly plans, day of week (1-7)."},"payment-amount":{"type":"string","description":"Amount charged to the card for each payment cycle of the plan."},"ach-payment-type":{"type":"string","description":"Specifies the ACH payment type used for the plan."},"start-date":{"type":"string","description":"Specifies the date on which the payment plan becomes effective. If the specified date does not align with the frequency-day, the first payment occurs on the next frequency occurrence."},"end-date":{"type":"string","description":"Date on which the payment plan ends. Maximum of 10 years per plan."},"status":{"type":"string","description":"Current status of the payment plan.","enum":["ACTIVE","CANCELLED","SUSPENDED"]},"status-date":{"type":"string","description":"Date on which the current plan status was updated."},"frequency-month":{"type":"string","description":"Specifies the month of the year when the payment plan is executed. For example, 1 - January, 2 - February, and so on through 12 - December."},"frequency-week":{"type":"string","description":"Specifies the week number within the selected month when the payment plan is executed. Required when frequency is set to WEEKLY."},"links":{"$ref":"#/components/schemas/Links"}},"description":"Represents a recurring payment plan definition.","xml":{"name":"payment-plan"}},"Links":{"type":"object","properties":{"link":{"type":"array","items":{"$ref":"#/components/schemas/Link"}}},"description":"Contains related resource links associated with the customer. Each link includes an id, href, and rel (customer, customer-token, payment-plan, token, transaction).","xml":{"name":"links"}},"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```

## The PaymentPlansDtoResponsePayload object

```json
{"openapi":"3.0.1","info":{"title":"Recurring Payments API","version":"2.0"},"components":{"schemas":{"PaymentPlansDtoResponsePayload":{"type":"object","properties":{"payment-plans":{"$ref":"#/components/schemas/PaymentPlansDto"},"payloadType":{"type":"string","description":"Type of payload returned in the response.","xml":{"name":"type","attribute":true}}},"description":"payload","xml":{"name":"payload"}},"PaymentPlansDto":{"type":"object","properties":{"payment-plan":{"type":"array","items":{"$ref":"#/components/schemas/payment-plan"}}},"description":"payment-plans","xml":{"name":"payment-plans-dto"}},"payment-plan":{"required":["customer-key","end-date","frequency","payment-amount","start-date","token-id"],"type":"object","properties":{"frequency":{"type":"string","description":"Frequency at which the payment plan runs.","enum":["MONTHLY","WEEKLY","YEARLY"]},"metadata":{"type":"object","additionalProperties":{"type":"string","description":"Key-value metadata applied to the plan."},"description":"Key-value metadata applied to the plan."},"plan-key":{"type":"string","description":"Unique identifier of the pricing or payment plan."},"plan-name":{"type":"string","description":"Display name of the payment plan."},"customer-key":{"type":"string","description":"Unique identifier of the customer for whom the payment plan is created."},"customer-name":{"type":"string","description":"Name of the customer associated with the payment plan."},"email-address":{"type":"string","description":"The customer's email address."},"email-receipt":{"type":"string","description":"Indicates whether an email receipt is sent when a payment is processed. If true, a valid email-address must exist on the customer or be provided in the payment plan request."},"token-id":{"type":"string","description":"Identifier of the payment token used for the card or ACH to process payments for the plan."},"frequency-day":{"type":"string","description":"Day on which the payment is processed. For monthly and yearly plans this is the day of the month; for weekly plans, day of week (1-7)."},"payment-amount":{"type":"string","description":"Amount charged to the card for each payment cycle of the plan."},"ach-payment-type":{"type":"string","description":"Specifies the ACH payment type used for the plan."},"start-date":{"type":"string","description":"Specifies the date on which the payment plan becomes effective. If the specified date does not align with the frequency-day, the first payment occurs on the next frequency occurrence."},"end-date":{"type":"string","description":"Date on which the payment plan ends. Maximum of 10 years per plan."},"status":{"type":"string","description":"Current status of the payment plan.","enum":["ACTIVE","CANCELLED","SUSPENDED"]},"status-date":{"type":"string","description":"Date on which the current plan status was updated."},"frequency-month":{"type":"string","description":"Specifies the month of the year when the payment plan is executed. For example, 1 - January, 2 - February, and so on through 12 - December."},"frequency-week":{"type":"string","description":"Specifies the week number within the selected month when the payment plan is executed. Required when frequency is set to WEEKLY."},"links":{"$ref":"#/components/schemas/Links"}},"description":"Represents a recurring payment plan definition.","xml":{"name":"payment-plan"}},"Links":{"type":"object","properties":{"link":{"type":"array","items":{"$ref":"#/components/schemas/Link"}}},"description":"Contains related resource links associated with the customer. Each link includes an id, href, and rel (customer, customer-token, payment-plan, token, transaction).","xml":{"name":"links"}},"Link":{"type":"object","properties":{"rel":{"type":"string","description":"Relationship type describing the linked resource. Possible values: customer customer-token payment-plan token transaction.","enum":["transaction,token,customer,payment-plan,customer-token"]},"href":{"type":"string","description":"URI of the related resource."},"id":{"type":"string","description":"Identifier of the linked resource."}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.xplorpay.com/api-reference/api/payments/recurring-payments-service/models.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
