LogoLogo
  • Transaction API
    • Overview
    • Authentication
    • Payment Methods
    • Integrations
      • POS (In-Store)
      • E-commerce
    • Payment Flows
      • Create a transaction
        • Examples for POS (In-Store)
          • Basic Payment Request
          • Payment request with products
          • Payment request with callback
          • Payment request with POS Data
          • SMS Payment Request
          • Email Payment Request
          • Payment request with invoice
          • Payment request with receipt generated by SensePass
          • Payment request with receipt generated by the POS
        • Examples for e-commerce
          • Basic Payment Request
          • iFrame Example
          • Payment request with products
          • Payment request with callback
          • Payment request with website custom data
          • SMS Payment Request
          • Email Payment Request
          • Payment request with invoice
          • Payment request with receipt generated by SensePass
          • Payment request with receipt generated by the e-commerce platform
      • Transaction status
      • Authorization
      • Tokenization
      • Subscription
        • Fetch a subscription
        • Update a subscription
        • Subscription callbacks
      • Cancel a pending transaction
      • Refund a transaction
      • Pay by Credit Card
      • Credit by Credit Card
      • Payment Commit
      • Update a Transaction
    • Other Flows
      • Tags Pairing
      • Receipts
      • Customer Input
      • Token Migration
      • Create Dynamic QR
    • Terminal Agent
      • Installation
      • Pairing
      • Usage
        • Synchronous Payment
        • Real-time product information update
        • Get Last Transaction Status
        • Get Device ID
    • Settlement
    • API Notifications
      • Socket.IO Websockets
      • Callback/Webhook
      • Post Message
    • Flow Charts
      • Payment Flow
      • Transaction Status Flow
    • SDK & iFrames
      • JavaScript UI SDK
        • API
        • Commit Transaction
        • Custom SDK Style
        • Simulator
        • Manual Capture (deprecated)
      • E-commerce iFrame
      • POS iFrame
      • Credit Card iFrame
    • Models
      • Receipts Model
      • Metadata Model
      • SDK Theme Config Model
      • SDK Credit Card Field Model
      • Invoice Model
      • Product Model
      • Payment Details Model
      • Receipt Notifications Model
      • Payment Commit Model
      • Confirmation Model
      • Settlement Model
      • Subscription Model
      • Transaction Page Model
      • Transaction Model
      • Customer Input Model
      • Settlement Report Model
      • Customer Shipping/Billing Details Model
      • Additional Data Model
    • SOAP and XML
      • SOAP
      • XML
    • Testing
    • Postman
  • Partner API
    • Models
      • Onboarding Model
      • Onboarding Configuration Pages
      • Onboarding Status Model
    • SDK & iFrames
      • Onboarding iFrame
    • Flows
      • Create onboarding
      • Get Onboarding Configuration Page
      • Onboarding status
Powered by GitBook
On this page

Was this helpful?

Export as PDF
  1. Transaction API
  2. Models

SDK Credit Card Field Model

customize credit card texts

This model represents all the required data for customizing the text for the SDK's credit card form field.

{
  "cardNumber": {
    "label": "Card Number",
    "placeholder": "Credit Card",
    "hint": "Digits",
    "defaultHint": "Full Card Number",
    "errors": {
      "required": "Card Number is Mandatory",
      "cardTypeLength": {
        "minLengthStart": "Must be Over",
        "minLengthEnd": "Digits",
        "maxLengthStart": "Must be Under",
        "maxLengthEnd": "Digits",
        "lengthsStart": "Must be:",
        "lengthsSplit": "or",
        "lengthsEnd": "Digits"
      }
    }
  },
  "expiration": {
    "label": "Expiration",
    "placeholder": "Month / Year",
    "hint": "MM/YY",
    "errors": {
      "required": "Expiration Date is Mandatory",
      "cardExpiration": {
        "invalidDateFormat": "Date Invalid, Should Be MM/YY",
        "monthRange": "Month Should Be Between 1 - 12",
        "yearExpiration": "The Year You've Set Expired",
        "monthExpiration": "The Month You've Set Expired This Year"
      }
    }
  },
  "securityCode": {
    "label": "CVV",
    "placeholder": "CVV/CVC",
    "hint": {
      "amex": "digits, front of the card",
      "default": "digits, back of the card"
    },
    "defaultHint": "Security Code",
    "errors": {
      "required": "CVC is Mandatory",
      "securityCodeLength": {
        "lengthShouldBe": "must be",
        "digits": "digits"
      }
    }
  },
  "socialID": {
    "label": "Document ID",
    "placeholder": "Document ID",
    "hint": "Document ID",
    "errors": {
      "required": "Document ID is Mandatory",
      "minlength": "5 Digits Minimum",
      "maxlength": "20 Digits Maximum"
    }
  },
  "zipCode": {
    "label": "Zip Code",
    "placeholder": "Zip Code",
    "hint": "address associated to your card",
    "errors": {
      "required": "Zip Code is Mandatory",
      "minlength": "0 Digits Minimum",
      "maxlength": "9 Digits Maximum"
    }
  },
  "email": {
    "label": "Email",
    "placeholder": "John@domain.com",
    "hint": "Email",
    "errors": {
      "required": "Email is Mandatory",
      "minlength": "5 Characters Minimum",
      "maxlength": "50 Characters Maximum"
    }
  },
  "mobilePhone": {
    "label": "Mobile Phone",
    "placeholder": "000-000-0000",
    "hint": "Mobile Phone",
    "errors": {
      "required": "Mobile Phone is Mandatory",
      "minlength": "6 Digits Minimum",
      "maxlength": "15 Digits Maximum"
    }
  },
  "installments": "Installments",
  "fullName": {
    "label": "Full Name",
    "placeholder": "Full Name",
    "hint": "First & Last names",
    "errors": {
      "required": "Full Name is Mandatory",
      "pattern": "Full Name must ONLY be letters",
      "minlength": "4 Characters Minimum",
      "maxlength": "50 Characters Maximum"
    }
  },
  "saveCard": {
    "label": "Save this card"
  }
}

Description of the parameters required for various payment options configurations.

field
type
description

label

string

label of the field

placeholder

string

placeholder while the field is empty

hint

string | object

hint for the field's use

defaultHint

string

hint to default before user interaction

errors

object

mapping the display-keys of various errors

errors.required

string

required field error message

errors.minlength

string

minimum character length error message

errors.maxlength

string

maximum character length error message

Field specific parameters.

field
type
description

securityCode.hint.amex

string

hint for Amex's 4 digits once the credit card field detects an amex-type-card

securityCode.hint.default

string

hint for every card's 3 digits, that is not detected as Amex

cardNumber.errors.cardTypeLength

object

specific object keys to build an error message to clarify the credit card's length:

expiration.errors.cardExpiration

object

securityCode.errors.securityCodeLength

object

Last updated 1 year ago

Was this helpful?

"minLengthStart": "Must be Over",
"minLengthEnd": "Digits",
"maxLengthStart": "Must be Under",
"maxLengthEnd": "Digits",
"lengthsStart": "Must be:",
"lengthsSplit": "or",
"lengthsEnd": "Digits"
"invalidDateFormat": "Date Invalid, Should Be MM/YY",
"monthRange": "Month Should Be Between 1 - 12",
"yearExpiration": "The Year You've Set Expired",
"monthExpiration": "The Month You've Set Expired This Year"
"lengthShouldBe": "must be",
"digits": "digits"