Skip to main content

Payment models

Payment models manage credit card information, billing agreements, and payment method configurations within Chargeworx.

CreditCard / CreditCardNumber

Stores credit card payment method information with PCI-compliant data handling.

CreditCard

PropertyTypeDescription
IdGuidUnique card identifier
PersonIdGuidAssociated person reference
Last4StringLast 4 digits of card number
ExpirationMonthIntCard expiration month
ExpirationYearIntCard expiration year
CardTypeStringCard brand (Visa, Mastercard, etc.)
IsActiveBooleanCard active status

CreditCardNumber

Stores tokenized or encrypted card numbers separately from card metadata.
PropertyTypeDescription
IdGuidUnique identifier
CreditCardIdGuidAssociated credit card reference
EncryptedNumberStringEncrypted card number
TokenStringProcessor token reference

Relationships

  • CreditCard belongs to a Person
  • CreditCardNumber belongs to a CreditCard

CompanyProjectCreditCardPaymentInfo

Links credit cards to specific company projects for payment processing.

Key properties

PropertyTypeDescription
IdGuidUnique identifier
CompanyIdGuidAssociated company
ProjectIdGuidAssociated project
CreditCardIdGuidAssociated credit card
IsDefaultBooleanDefault payment method flag

Relationships

  • Belongs to a Company
  • Belongs to a Project
  • References a CreditCard

CompanyProjectBillingAgreement

Manages recurring billing agreements and subscription configurations.

Key properties

PropertyTypeDescription
IdGuidUnique identifier
CompanyIdGuidAssociated company
ProjectIdGuidAssociated project
AgreementIdStringExternal agreement reference
StatusStringAgreement status
StartDateDateTimeAgreement start date
EndDateDateTime?Agreement end date

Relationships

  • Belongs to a Company
  • Belongs to a Project

Person / Address / PersonAddress

Customer and billing address information models.

Person

Represents a customer or cardholder.
PropertyTypeDescription
IdGuidUnique person identifier
FirstNameStringFirst name
LastNameStringLast name
EmailStringEmail address
PhoneStringPhone number

Address

Physical address information.
PropertyTypeDescription
IdGuidUnique address identifier
Street1StringStreet address line 1
Street2StringStreet address line 2
CityStringCity
StateStringState/province
PostalCodeStringPostal/ZIP code
CountryStringCountry code

PersonAddress

Links persons to addresses.
PropertyTypeDescription
PersonIdGuidAssociated person
AddressIdGuidAssociated address
AddressTypeStringAddress type (Billing, Shipping)

Relationships

  • Person has many Addresses through PersonAddress
  • Address has many Persons through PersonAddress

Usage patterns

Storing payment methods

Credit card data is stored with encryption and tokenization. Sensitive card numbers are separated from metadata and never stored in plain text.

Managing billing agreements

Recurring billing agreements link payment methods to projects and track subscription lifecycle.

Address validation

Addresses are validated during payment processing and used for AVS (Address Verification Service) checks.