> ## Documentation Index
> Fetch the complete documentation index at: https://docs.jupico.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Process a card sale

> A sale combines authorization and capture in one transaction. Use it when purchases are fulfilled immediately, such as retail or e-commerce checkout. If the issuing bank approves, an approval code is returned; if it declines, the response includes the decline reason.



## OpenAPI

````yaml /openapi.json post /v1/transactions/creditcard/sale
openapi: 3.0.0
info:
  title: Jupico - OpenAPI 3.0
  description: >-
    The Jupico API lets Service Providers onboard merchants, process card and
    eCheck (ACH) payments, run hosted payment pages, manage recurring billing,
    send payouts, and query every resource. All endpoints use HTTPS with Basic
    authentication and accept and return JSON. Endpoints are grouped by
    workflow: onboard merchants first, then accept payments, then move funds and
    report.
  termsOfService: https://help.jupico.com/references-and-resources/legal
  contact:
    email: support@jupico.com
  license:
    name: Jupico License
    url: https://jupico.com
  version: 1.0.5
servers:
  - url: https://sandbox-platform.jupico.com
security:
  - basicAuth: []
tags:
  - name: Status
    description: Health check for the Jupico API.
  - name: Onboarding Invites
    description: >-
      Create and send invites that onboard merchants through the Jupico-hosted
      flow, with optional pre-filled identity, fees, and payout bank account
      data.
  - name: Provisioning
    description: >-
      Onboard merchants from your own UI. Collect onboarding data and submit it
      through the provisioning chain: applicant → application → submerchant.
  - name: Session
    description: >-
      Create browser authorization sessions for the Jupico web components, so
      card and bank account data is tokenized client-side and never touches your
      servers.
  - name: Tokenization
    description: >-
      Convert one-time tokens from the web components into permanent Jupico
      tokens, or tokenize raw card data if your systems are PCI DSS compliant.
  - name: Customer
    description: >-
      Create and manage customer records that payments, subscriptions,
      installments, and invoices link to.
  - name: Card Transactions
    description: >-
      Process credit and debit card transactions using tokenized card data:
      sale, authorization, capture, void, refund, and rollback.
  - name: eCheck Transactions
    description: >-
      Debit customer bank accounts via eCheck (ACH): sale, void, refund,
      rollback, and bank account tokenization.
  - name: Checkouts
    description: >-
      Hosted checkout sessions where customers complete payment on a
      Jupico-hosted page.
  - name: Payment Links
    description: >-
      Shareable links that open a Jupico-hosted payment page — no integration
      code needed at the point of sharing.
  - name: Invoices
    description: Create and email invoices that customers pay online.
  - name: Subscriptions
    description: >-
      Recurring billing. Plans define billing schedules and pricing models;
      subscriptions enroll customers against a stored payment token.
  - name: Installments
    description: Split a fixed total into scheduled payments with an optional deposit.
  - name: Payouts
    description: >-
      Send funds from a submerchant's available balance to a tokenized bank
      account with on-demand payout instructions.
  - name: Query
    description: >-
      Search and report across every resource: transactions, merchants,
      settlements, balances, disputes, fees, and more. All query endpoints
      accept the same filter, sort, and pagination envelope — see the Query
      Capabilities guide.
paths:
  /v1/transactions/creditcard/sale:
    post:
      tags:
        - Card Transactions
      summary: Process a card sale
      description: >-
        A sale combines authorization and capture in one transaction. Use it
        when purchases are fulfilled immediately, such as retail or e-commerce
        checkout. If the issuing bank approves, an approval code is returned; if
        it declines, the response includes the decline reason.
      operationId: ccSale
      requestBody:
        $ref: '#/components/requestBodies/ccSale'
      responses:
        '200':
          $ref: '#/components/responses/ccSale'
      security:
        - basicAuth: []
components:
  requestBodies:
    ccSale:
      description: >-
        API support various types of use. Required fields are defined by the
        most basic call. For other uses be sure to send the required information
        defined in the schema and examples.
      required: true
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ccSale'
          examples:
            saleMostBasicCall:
              $ref: '#/components/examples/ccSaleMostBasicCall'
            ccSaleCommercialLevel2:
              $ref: '#/components/examples/ccSaleCommercialLevel2'
            ccSaleCommercialLevel3:
              $ref: '#/components/examples/ccSaleCommercialLevel3'
            ccSaleFullExample:
              $ref: '#/components/examples/ccSaleFullExample'
  responses:
    ccSale:
      description: Successful sale
      content:
        application/json:
          schema:
            type: object
            properties:
              success:
                type: boolean
                description: >-
                  Whether the request was processed successfully. Declines
                  return HTTP 200 with `success: false`.
              data:
                type: object
                properties:
                  status:
                    type: string
                    description: Current status.
                  transactionId:
                    type: string
                    description: Unique identifier of the original transaction.
                  approvalNumber:
                    type: string
                    description: Approval code returned by the issuing bank.
                  operation:
                    type: string
                    description: >-
                      Transaction operation type (for example, sale,
                      authorization, refund).
                  subMerchantId:
                    type: string
                    description: Unique identifier of the submerchant.
                  amount:
                    type: number
                    description: The amount of the transaction.
                  txDate:
                    type: string
                    description: Date and time of the transaction (ISO 8601).
                  referenceNumber:
                    type: string
                    description: Processor reference number for the transaction.
                  referenceId:
                    type: string
                    description: >-
                      Your own reference for this transaction. Returned in
                      responses and query results for reconciliation.
                  taxAmount:
                    type: number
                    description: Sales tax portion of the amount.
                  taxWithHold:
                    type: boolean
                    description: >-
                      When true, the sales tax portion is withheld from the
                      merchant's settlement until released.
                  items:
                    type: array
                    items:
                      type: object
                      properties:
                        description:
                          type: string
                          example: Consulting services
                          description: Description of the line item.
                        quantity:
                          type: number
                          example: 5
                          description: Number of units.
                        amount:
                          type: number
                          example: 100
                          description: Price per unit.
                        taxRate:
                          type: number
                          description: Tax rate applied to this line item, as a percentage.
                    description: Line items included in the total amount.
                  balanceAmount:
                    type: number
                    description: >-
                      Remaining balance on the transaction after captures,
                      refunds, and voids.
                  parentId:
                    type: string
                    description: >-
                      Identifier of the parent transaction (for example, the
                      authorization behind a capture).
                  description:
                    type: string
                    description: Free-text description.
                  dynamicFee:
                    type: object
                    properties:
                      fixed:
                        type: number
                        description: Fixed portion of the dynamic fee.
                      discountRatePerc:
                        type: number
                        description: >-
                          Percentage portion of the dynamic fee, applied to the
                          transaction amount.
                    description: >-
                      Fee added to the transaction at processing time and
                      itemized separately.
                  paymentMethod:
                    type: object
                    properties:
                      type:
                        type: string
                        description: The type.
                      eCheck:
                        type: object
                        description: eCheck (ACH) acceptance settings.
                      cc:
                        type: object
                        properties:
                          card:
                            type: object
                            properties:
                              cardHolderName:
                                type: string
                                description: Name of the cardholder.
                              last4Digits:
                                type: string
                                description: Last 4 digits of the card number.
                              expirationMonth:
                                type: string
                                description: Two-digit expiration month (01-12).
                              expirationYear:
                                type: string
                                description: Two-digit expiration year.
                              logo:
                                type: string
                                description: Card brand logo identifier.
                            description: Card details.
                          provider:
                            type: string
                            description: Payment provider that issued the token.
                          cardHolderInitiated:
                            type: boolean
                            description: >-
                              True when the cardholder actively initiates the
                              payment; false for merchant-initiated transactions
                              such as recurring charges.
                          networkTransactionID:
                            type: string
                            description: >-
                              Card network transaction identifier, used for
                              merchant-initiated follow-on transactions.
                          token:
                            type: string
                            description: The token value.
                        description: Card payment method details.
                    description: Details of the payment method used.
                  billing:
                    type: object
                    properties:
                      address:
                        type: string
                        description: Street address, including number.
                      city:
                        type: string
                        description: City name.
                      zipCode:
                        type: string
                        description: ZIP or postal code.
                      state:
                        type: string
                        description: Two-letter US state code.
                      email:
                        type: string
                        description: Email address of the payer.
                      name:
                        type: string
                        description: Full name of the payer.
                      phone:
                        type: string
                        description: Phone number of the payer.
                    description: Billing contact and address details for the payer.
                  shipping:
                    type: object
                    properties:
                      address:
                        type: string
                        description: Street address, including number.
                      city:
                        type: string
                        description: City name.
                      zipCode:
                        type: string
                        description: ZIP or postal code.
                      state:
                        type: string
                        description: Two-letter US state code.
                      email:
                        type: string
                        description: Email address of the recipient.
                      name:
                        type: string
                        description: Name of the recipient.
                      phone:
                        type: string
                        description: Phone number of the recipient.
                    description: Shipping contact and address details for the order.
                  validations:
                    type: object
                    properties:
                      avs:
                        type: object
                        properties:
                          addressNumber:
                            type: string
                            description: AVS result for the street number.
                          addressPostalCode:
                            type: string
                            description: AVS result for the postal code.
                        description: Address Verification Service (AVS) results.
                      cvv:
                        type: object
                        properties:
                          cvcCheck:
                            type: string
                            description: Result of the card verification code check.
                        description: CVV check result.
                    description: Verification results returned by the issuer.
                  paymentToken:
                    type: object
                    properties:
                      type:
                        type: string
                        description: Type of token supplied.
                      token:
                        type: object
                        properties:
                          provider:
                            type: string
                            description: >-
                              Payment provider that issued the token (for
                              example, `jupico`).
                          token:
                            type: string
                            description: The token value.
                          cardHolderName:
                            type: string
                            description: Name of the cardholder.
                          expirationMonth:
                            type: string
                            description: Two-digit expiration month (01-12).
                          expirationYear:
                            type: string
                            description: Two-digit expiration year.
                          logo:
                            type: string
                            description: Card brand logo identifier.
                          cardLogo:
                            type: string
                            description: Card brand logo identifier.
                          last4Digits:
                            type: string
                            description: Last 4 digits of the card number.
                          truncatedCardNumber:
                            type: string
                            description: Masked card number.
                        description: Token payload returned by tokenization.
                    description: >-
                      The payment credential to charge: a one-time token from
                      the web component or a stored Jupico token.
                description: The response payload.
              message:
                type: string
                description: Human-readable result message.
              code:
                type: string
                description: Machine-readable result code. See the Error Codes reference.
  schemas:
    ccSale:
      type: object
      properties:
        subMerchantId:
          type: string
          description: Unique identifier of the submerchant.
        items:
          type: array
          items:
            type: object
            properties:
              description:
                type: string
                description: Description of the line item.
              quantity:
                type: number
                description: Number of units.
              amount:
                type: number
                description: Price per unit.
              taxRate:
                type: number
                description: Tax rate applied to this line item, as a percentage.
          description: Line items included in the total amount.
        amount:
          type: number
          description: The amount to charge.
        paymentToken:
          type: object
          properties:
            type:
              type: string
              description: Type of token supplied.
            token:
              type: object
              description: Token payload returned by tokenization.
          description: >-
            The payment credential to charge: a one-time token from the web
            component or a stored Jupico token.
        cardHolderInitiated:
          type: boolean
          description: >-
            True when the cardholder actively initiates the payment; false for
            merchant-initiated transactions such as recurring charges.
        description:
          type: string
          description: Free-text description of the transaction.
        taxAmount:
          type: number
          description: |
            The total amount of sales tax must be between:
            Visa: 0.1% - 18%
            MasterCard: 0.1% - 23%
            Default: 0.1% - 50%
        taxWithHold:
          type: boolean
          description: >-
            When true, the sales tax portion is withheld from the merchant's
            settlement until released.
        dynamicFee:
          type: object
          properties:
            fixed:
              type: number
              description: Fixed portion of the dynamic fee.
            discountRatePerc:
              type: number
              description: >-
                Percentage portion of the dynamic fee, applied to the
                transaction amount.
          description: >-
            Fee added to the transaction at processing time and itemized
            separately.
        cvv:
          type: string
          description: Card verification code (CVV/CVC).
        referenceId:
          type: string
          description: >-
            Your own reference for this transaction. Returned in responses and
            query results for reconciliation.
        billing:
          type: object
          properties:
            address:
              type: string
              description: Street address, including number.
            city:
              type: string
              description: City name.
            zipCode:
              type: string
              description: ZIP or postal code.
            state:
              type: string
              description: Two-letter US state code.
            email:
              type: string
              description: Email address of the payer.
            name:
              type: string
              description: Full name of the payer.
            phone:
              type: string
              description: Phone number of the payer.
          description: Billing contact and address details for the payer.
        shipping:
          type: object
          properties:
            address:
              type: string
              description: Street address, including number.
            city:
              type: string
              description: City name.
            zipCode:
              type: string
              description: ZIP or postal code.
            state:
              type: string
              description: Two-letter US state code.
            email:
              type: string
              description: Email address of the recipient.
            name:
              type: string
              description: Name of the recipient.
            phone:
              type: string
              description: Phone number of the recipient.
          description: Shipping contact and address details for the order.
        metadata:
          $ref: '#/components/schemas/metadata'
        billingDescriptor:
          type: object
          properties:
            name:
              type: string
              maxLength: 25
              example: test
              description: >-
                The text that appears on the cardholder's statement, overriding
                the default business name.
          description: Overrides the descriptor that appears on the cardholder's statement.
      required:
        - subMerchantId
        - amount
        - cardHolderInitiated
        - paymentToken
    metadata:
      type: object
      description: >-
        metadata is an object that can host as much as 50 key-value pairs, where
        the keys can be at most 40 char length and can’t include the characters
        “[“ or “]”, and the values must be strings and cannot exceed 500 chars
        [Learn more about metadata](https://docs.jupico.com/docs/metadata#/)
      additionalProperties:
        type: string
        maxLength: 500
      x-key-max-length: 40
  examples:
    ccSaleMostBasicCall:
      summary: Only basic parameters
      value:
        subMerchantId: jpt-sim-md-1
        paymentToken:
          type: creditcard
          token:
            provider: jupico
            token: 5dd19881-b437-42b0-9c9b-7773ebb598eb
        amount: 40
        cardHolderInitiated: true
        metadata:
          test: test
    ccSaleCommercialLevel2:
      summary: Commercial level 2
      value:
        subMerchantId: jpt-sim-md-1
        cardHolderInitiated: true
        amount: 44
        paymentToken:
          type: creditcard
          token:
            provider: jupico
            token: 5dd19881-b437-42b0-9c9b-7773ebb598eb
        cvv: '123'
        description: Hamburguer
        taxAmount: 4
        billing:
          name: Joe Smith
          email: accounting@companyinc.com
          phone: '123123123'
          address: 123 Silent Hill
          city: Danbury
          state: CT
          zipCode: '12345'
        shipping:
          address: 123 Silent Hill
          city: Batavia
          state: OH
          zipCode: '50403'
        items:
          - description: Hamburguer
            quantity: 4
            amount: 10
            taxRate: 10
        metadata:
          test: test
    ccSaleCommercialLevel3:
      summary: Commercial level 3
      value:
        subMerchantId: jpt-sim-md-1
        cardHolderInitiated: true
        amount: 44
        paymentToken:
          type: creditcard
          token:
            provider: jupico
            token: 5dd19881-b437-42b0-9c9b-7773ebb598eb
        cvv: '123'
        description: Hamburguer
        taxAmount: 4
        poNumber: '123'
        billing:
          name: Joe Smith
          email: accounting@companyinc.com
          phone: '123123123'
          address: 123 Silent Hill
          city: Danbury
          state: CT
          zipCode: '12345'
        shipping:
          address: 123 Silent Hill
          city: Batavia
          state: OH
          zipCode: '50403'
        items:
          - description: Hamburguer
            quantity: 4
            amount: 10
            taxRate: 10
        metadata:
          test: test
    ccSaleFullExample:
      summary: Full example
      value:
        subMerchantId: jpt-sim-md-1
        amount: 44
        paymentToken:
          type: creditcard
          token:
            provider: jupico
            token: 5dd19881-b437-42b0-9c9b-7773ebb598eb
        description: CC Authorization
        cardHolderInitiated: true
        taxAmount: 4
        referenceId: 2b174787-bb93-40a4-8343-c7c9785c11a2
        invoiceNumber: '123'
        poNumber: '123456'
        cvv: '123'
        billing:
          address: 123 Silent Hill
          city: Danbury
          zipCode: '12345'
          state: CT
          email: mail@mail.com
          name: John Doe
          phone: '123123123'
        shipping:
          address: 123 Silent Hill
          city: Danbury
          zipCode: '12345'
          state: CT
          email: mail@mail.com
          name: John Doe
          phone: '123123123'
        items:
          - description: Hamburguer
            quantity: 4
            amount: 10
            taxRate: 10
        metadata:
          test: test
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic

````