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

# Cancel Payment

> Cancel a Processing ProxyWallet one-time payment with zero paid amount



## OpenAPI

````yaml /openapi.yaml delete /payments/{paymentId}
openapi: 3.1.0
info:
  contact:
    email: support@boomfi.xyz
    name: API Support
  description: >-
    The BoomFi Merchants API provides a set of endpoints for merchants to manage
    their accounts, transactions, and more. Hosts differ per brand/environment;
    use the brand-specific base URL from the docs.
  title: BoomFi Merchants API
  version: '1.0'
servers:
  - url: https://mapi.boomfi.xyz/v1
    description: Production
  - url: https://mapi-test.boomfi.xyz/v1
    description: Test
security: []
tags:
  - description: Payment links
    name: Paylinks
  - description: Billing plans
    name: Plans
  - description: Subscriptions
    name: Subscriptions
  - description: Customer records
    name: Customers
  - description: Invoices
    name: Invoices
  - description: Payments
    name: Payments
  - description: Organisation events
    name: Events
  - description: Organisation profile and display settings
    name: Organisation
  - description: Webhook and request-signing secrets
    name: Secrets
  - description: Settlement accounts
    name: Accounts
  - name: External Accounts
  - description: Managed virtual accounts, balances, pay-in, and payout
    name: Virtual Accounts
  - description: Partner-managed accounts, virtual accounts, pay-in, and payout
    name: Partners
  - description: Partner maintain-balance automations
    name: Partner Balance Monitoring
  - name: Checkout Sessions
paths:
  /payments/{paymentId}:
    delete:
      tags:
        - Payments
      summary: Cancel Payment
      description: Cancel a Processing ProxyWallet one-time payment with zero paid amount
      parameters:
        - description: Unique payment identifier (pay_... or raw UUID)
          in: path
          name: paymentId
          required: true
          schema:
            type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/internal.Response-payments_PaymentResponse
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/internal.ErrorResponse'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/internal.ErrorResponse'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    internal.Response-payments_PaymentResponse:
      properties:
        data:
          allOf:
            - $ref: '#/components/schemas/payments.PaymentResponse'
          description: Response payload when the request succeeded.
        error:
          description: True when the request failed.
          type: boolean
        message:
          description: Human-readable status or error message.
          type: string
      type: object
    internal.ErrorResponse:
      properties:
        error:
          allOf:
            - $ref: '#/components/schemas/internal.ErrorStruct'
          description: Error details including HTTP-style code and message.
      type: object
    payments.PaymentResponse:
      properties:
        amount:
          description: amount
          type: string
        amount_usd:
          description: Amount denominated in USD.
          type: string
        cf_headers:
          additionalProperties:
            type: string
          description: >-
            Cloudflare or edge request headers captured with the payment, when
            present.
          type: object
        chain_id:
          description: Blockchain chain ID.
          type: integer
        created_at:
          description: created_at
          type: string
        crypto_transaction:
          allOf:
            - $ref: '#/components/schemas/models.PublicCryptoTransaction'
          description: Primary crypto transaction associated with this payment.
        crypto_transactions:
          description: used when polling crypto refund
          items:
            $ref: '#/components/schemas/payment.CryptoTransaction'
          type: array
        currency:
          description: currency
          type: string
        customer:
          allOf:
            - $ref: '#/components/schemas/customers.CustomerResponse'
          description: Customer associated with this resource.
        customer_id:
          description: customer_id
          type: string
        from_account:
          allOf:
            - $ref: '#/components/schemas/models.PublicOrgSettlementAccount'
          description: Deposit/Payout enrichment — matches webhook event shape
        id:
          description: id
          type: string
        invoice_id:
          description: invoice_id
          type: string
        metadata:
          additionalProperties: {}
          description: Arbitrary merchant-defined metadata.
          type: object
        next_action:
          description: next_action
          type: string
        org_id:
          description: org_id
          type: string
        parent_id:
          description: parent_id
          type: string
        payment_link:
          allOf:
            - $ref: '#/components/schemas/paylinks.PaymentLinkResponse'
          description: Payment link associated with this resource.
        payment_method:
          allOf:
            - $ref: '#/components/schemas/docenums.PaymentMethod'
          description: payment_method
        payout_splits:
          description: How payment proceeds were split to destination addresses.
          items:
            $ref: '#/components/schemas/models.PublicPayoutSplit'
          type: array
        properties:
          additionalProperties: {}
          description: Additional properties as a key-value map.
          type: object
        reference:
          description: reference
          type: string
        scheduled_time:
          description: scheduled_time
          type: integer
        sender_address:
          description: On-chain address that originated the payment.
          type: string
        settlement_transaction:
          allOf:
            - $ref: '#/components/schemas/models.PublicCryptoTransaction'
          description: Settlement crypto transaction, when separate from the payment.
        source:
          allOf:
            - $ref: '#/components/schemas/docenums.BillingSource'
          description: source
        status:
          allOf:
            - $ref: '#/components/schemas/docenums.PaymentStatus'
          description: status
        to_account:
          allOf:
            - $ref: '#/components/schemas/models.PublicOrgSettlementAccount'
          description: Settlement or destination account for this payment.
        updated_at:
          description: updated_at
          type: string
      type: object
    internal.ErrorStruct:
      properties:
        code:
          description: |-
            Error code
            Example: 400
          example: 400
          type: integer
        errors:
          description: List of errors
          items:
            $ref: '#/components/schemas/internal.SingleError'
          type: array
        message:
          description: |-
            Error message
            Example: Insufficient quantity
          example: Insufficient quantity
          type: string
      type: object
    models.PublicCryptoTransaction:
      properties:
        chain_id:
          description: Blockchain chain ID.
          example: 8453
          type: integer
        created_at:
          description: When the resource was created (RFC3339).
          example: '2024-06-15T14:32:40.000Z'
          type: string
        payment_id:
          description: Unique identifier of the payment linked to this resource.
          example: pay_01HXYZ
          type: string
        status:
          allOf:
            - $ref: '#/components/schemas/docenums.TransactionStatus'
          description: Status of this resource.
          example: Success
        transaction_hash:
          description: On-chain transaction hash.
          example: 0xdemoaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
          type: string
        type:
          allOf:
            - $ref: '#/components/schemas/docenums.TransactionType'
          description: Resource or value type.
          example: Payment
        updated_at:
          description: When the resource was last updated (RFC3339).
          example: '2024-06-15T14:32:45.000Z'
          type: string
      type: object
    payment.CryptoTransaction:
      properties:
        chain_id:
          description: Blockchain chain ID.
          type: integer
        created_at:
          description: When the resource was created (RFC3339).
          type: string
        entity_id:
          description: ID of the related entity.
          type: string
        fee_amount:
          description: Fee amount as a decimal string in major units.
          type: string
        fee_currency:
          description: Currency of the fee amount.
          type: string
        from:
          description: Sender address of the crypto transaction.
          type: string
        id:
          description: Unique resource identifier.
          type: integer
        payment_id:
          description: Unique identifier of the payment linked to this resource.
        raw:
          description: Raw provider/RPC transaction payload when available.
        sequence:
          description: Ordering sequence for related records.
          type: string
        source:
          allOf:
            - $ref: '#/components/schemas/docenums.PaymentMethod'
          description: Origin system or integration that created this resource.
        status:
          allOf:
            - $ref: '#/components/schemas/docenums.TransactionStatus'
          description: Status of this resource.
        transaction_hash:
          description: On-chain transaction hash.
          type: string
        transfer_logs:
          description: Log of value transfers included in this crypto transaction.
          items:
            $ref: '#/components/schemas/payment.TransferLog'
          type: array
        type:
          allOf:
            - $ref: '#/components/schemas/docenums.TransactionType'
          description: Resource or value type.
        updated_at:
          description: >-
            When the crypto transaction record was last updated (RFC3339), if
            present.
        value:
          description: Transferred value as a decimal string in major units.
          type: string
      type: object
    customers.CustomerResponse:
      properties:
        created_at:
          description: When the resource was created (RFC3339).
          type: string
        deleted_at:
          description: When the resource was soft-deleted (RFC3339), if applicable.
          type: string
        email:
          description: Email address.
          type: string
        id:
          description: Unique resource identifier.
          type: string
        metadata:
          additionalProperties: {}
          description: Arbitrary key-value metadata.
          type: object
        name:
          description: Display name.
          type: string
        org_id:
          description: Organisation ID that owns this resource.
          type: string
        phone:
          description: Phone number.
          type: string
        properties:
          additionalProperties: {}
          description: Internal properties (for example social handles).
          type: object
        reference:
          description: Merchant-defined reference string.
          type: string
        updated_at:
          description: When the resource was last updated (RFC3339).
          type: string
        wallet_address:
          description: Blockchain wallet address.
          type: string
      type: object
    models.PublicOrgSettlementAccount:
      properties:
        account_type:
          description: Account type.
          enum:
            - CryptoPayIn
            - CryptoPayOut
            - FiatPayIn
            - FiatPayOut
            - Virtual
            - ProxyWallet
            - GasMaster
            - Crypto
            - Bank
            - Card
            - MPCVault
            - GooglePay
            - ApplePay
          type: string
        address:
          description: >-
            On-chain wallet address or postal street address, depending on
            context.
          type: string
        chain_id:
          description: Blockchain chain ID.
          type: integer
        currencies:
          description: Supported currency codes for this account or chain.
          items:
            type: string
          type: array
        enabled:
          description: Whether this resource is enabled.
          type: boolean
        id:
          description: Unique resource identifier.
          type: integer
        name:
          description: Display name.
          type: string
        reference:
          description: Merchant-defined reference string.
          type: string
      type: object
    paylinks.PaymentLinkResponse:
      properties:
        after_completion:
          allOf:
            - $ref: '#/components/schemas/paylinks.AfterCompletionStruct'
          description: >-
            Checkout behaviour after payment or when the link expires. Mirrors
            metadata.after_completion.
        created_at:
          description: created_at
          type: string
        created_by:
          description: created_by
          type: string
        customer_ident_collection:
          description: customer_ident_collection
          type: boolean
        deleted_at:
          description: deleted_at
          type: string
        enabled:
          description: enabled
          type: boolean
        id:
          description: id
          type: string
        invoice_id:
          description: invoice_id
          type: string
        metadata:
          additionalProperties: {}
          description: >-
            Arbitrary merchant-defined metadata. Also includes after_completion
            when configured, and customer_fields when extra identity fields are
            collected at checkout.
          type: object
        plan:
          allOf:
            - $ref: '#/components/schemas/plan.PlanResponse'
          description: Plan associated with this resource.
        plan_id:
          description: plan_id
          type: string
        properties:
          additionalProperties: {}
          description: Additional properties as a key-value map.
          type: object
        shipping_address_collection:
          description: shipping_address_collection
          type: boolean
        source:
          allOf:
            - $ref: '#/components/schemas/docenums.BillingSource'
          description: source
        tax_ident_collection:
          description: tax_ident_collection
          type: boolean
        updated_at:
          description: updated_at
          type: string
        updated_by:
          description: updated_by
          type: string
        url:
          description: Hosted checkout URL for this payment link.
          type: string
      type: object
    docenums.PaymentMethod:
      enum:
        - Unknown
        - MerchantContract
        - ProxyWallet
        - Unblock
        - Payout
        - Card
        - GooglePay
        - ApplePay
        - Paypal
        - DirectDebit
        - Ramp
        - RampCryptoSettlement
        - Refund
        - Deposit
      type: string
      x-enum-varnames:
        - PaymentMethodUnknown
        - PaymentMethodMerchantContract
        - PaymentMethodProxyWallet
        - PaymentMethodUnblock
        - PaymentMethodPayout
        - PaymentMethodCard
        - PaymentMethodGooglePay
        - PaymentMethodApplePay
        - PaymentMethodPaypal
        - PaymentMethodDirectDebit
        - PaymentMethodRamp
        - PaymentMethodRampCryptoSettlement
        - PaymentMethodRefund
        - PaymentMethodDeposit
    models.PublicPayoutSplit:
      properties:
        address:
          description: >-
            On-chain wallet address or postal street address, depending on
            context.

            Empty for a bank payout, which has no address — see
            DestinationAccountID.
          type: string
        amount:
          description: Amount as a decimal string in major units.
          type: string
        chain_id:
          description: Blockchain chain ID.
          type: integer
        currency:
          description: Currency symbol (for example USDC or USD).
          type: string
        destination_account_id:
          description: >-
            Destination account id, when the payout was addressed to a
            registered account.
          type: integer
        reference:
          description: Merchant-defined reference string.
          type: string
      type: object
    docenums.BillingSource:
      enum:
        - Lago
        - BoomFi
        - Stripe
        - Chargebee
        - QuickBooks
      type: string
      x-enum-varnames:
        - BillingSourceLago
        - BillingSourceBoomFi
        - BillingSourceStripe
        - BillingSourceChargebee
        - BillingSourceQuickBooks
    docenums.PaymentStatus:
      enum:
        - Unknown
        - RequiresPaymentMethod
        - RequiresConfirmation
        - RequiresAction
        - Processing
        - Succeeded
        - Canceled
        - Failed
      type: string
      x-enum-varnames:
        - PaymentStatusUnknown
        - PaymentStatusRequiresPaymentMethod
        - PaymentStatusRequiresConfirmation
        - PaymentStatusRequiresAction
        - PaymentStatusProcessing
        - PaymentStatusSucceeded
        - PaymentStatusCanceled
        - PaymentStatusFailed
    internal.SingleError:
      properties:
        domain:
          description: |-
            Domain
            Example: orders
          example: orders
          type: string
        reason:
          description: |-
            Error Reason
            Example: InsufficientQuantity
          example: InsufficientQuantity
          type: string
      type: object
    docenums.TransactionStatus:
      enum:
        - Pending
        - Success
        - Failed
      type: string
      x-enum-varnames:
        - TransactionStatusPending
        - TransactionStatusSuccess
        - TransactionStatusFailed
    docenums.TransactionType:
      enum:
        - Unknown
        - Approval
        - Deposit
        - Withdraw
        - Payment
        - Refund
        - Subscribe
        - Unsubscribe
        - Internal
        - Swap
        - Redact
        - Retain
        - Verify
        - Authorize
        - Capture
        - Burn
        - Attestation
        - Mint
      type: string
      x-enum-varnames:
        - TransactionTypeUnknown
        - TransactionTypeApproval
        - TransactionTypeDeposit
        - TransactionTypeWithdraw
        - TransactionTypePayment
        - TransactionTypeRefund
        - TransactionTypeSubscribe
        - TransactionTypeUnsubscribe
        - TransactionTypeInternal
        - TransactionTypeSwap
        - TransactionTypeRedact
        - TransactionTypeRetain
        - TransactionTypeVerify
        - TransactionTypeAuthorize
        - TransactionTypeCapture
        - TransactionTypeBurn
        - TransactionTypeAttestation
        - TransactionTypeMint
    payment.TransferLog:
      properties:
        address:
          description: Token contract address for this transfer log entry, when not native.
          type: string
        recipient:
          description: Recipient address of the transfer log entry.
          type: string
        sender:
          description: Sender address of the transfer log entry.
          type: string
        value:
          description: Transferred value as a decimal string in major units.
          type: string
      type: object
    paylinks.AfterCompletionStruct:
      properties:
        custom_message:
          description: >-
            Custom message shown on the hosted success receipt after checkout
            completes.
          maxLength: 200
          type: string
        failure_redirect_url:
          description: >-
            Failure URL. Hosted and lite checkout send the customer here when
            the payment link is expired or exhausted, or when payment.status is
            Failed. Optional for both hosted and redirect types. Not used when
            the payer switches payment method (Canceled). Max 512 characters.
          example: https://merchant.example/checkout/failed
          maxLength: 512
          type: string
        redirect_url:
          description: >-
            Success URL. When type is redirect, hosted and lite checkout send
            the customer here after a successful payment (Succeeded). Required
            when type is redirect. Not used for expired links or Failed
            payments. Max 512 characters.
          example: https://merchant.example/checkout/success
          maxLength: 512
          type: string
        type:
          description: >-
            After-completion behaviour: hosted keeps the customer on the in-app
            receipt; redirect sends them to redirect_url after a successful
            payment. When omitted, redirect_url implies redirect.
          enum:
            - hosted
            - redirect
          example: redirect
          type: string
      type: object
    plan.PlanResponse:
      properties:
        available_quantity:
          description: >-
            Remaining purchasable quantity when the plan has a capped supply;
            omitted when unlimited.
          type: integer
        billing_scheme:
          allOf:
            - $ref: '#/components/schemas/docenums.BillingScheme'
          description: billing_scheme
        created_at:
          description: created_at
          type: string
        created_by:
          description: created_by
          type: string
        currency:
          description: currency
          type: string
        deleted_at:
          description: deleted_at
          type: string
        enabled:
          description: enabled
          type: boolean
        expires_at:
          description: expires_at
          type: string
        id:
          description: id
          type: string
        metadata:
          additionalProperties: {}
          description: Arbitrary key-value metadata attached to the plan.
          type: object
        name:
          description: name
          type: string
        org_id:
          description: org_id
          type: string
        payment_link:
          allOf:
            - $ref: '#/components/schemas/plan.PaymentLinkResponse'
          description: Checkout payment link associated with this plan, when one exists.
        price:
          description: price
          type: string
        properties:
          additionalProperties: {}
          description: Internal plan properties (feature flags and display settings).
          type: object
        recurring_interval:
          allOf:
            - $ref: '#/components/schemas/docenums.RecurringInterval'
          description: recurring_interval
        recurring_interval_count:
          description: recurring_interval_count
          type: integer
        recurring_usage_type:
          allOf:
            - $ref: '#/components/schemas/docenums.RecurringUsageType'
          description: recurring_usage_type
        reference:
          description: reference
          type: string
        source:
          allOf:
            - $ref: '#/components/schemas/docenums.BillingSource'
          description: source
        trial_period:
          description: trial_period
          type: string
        type:
          allOf:
            - $ref: '#/components/schemas/docenums.PlanType'
          description: type
        updated_at:
          description: updated_at
          type: string
      type: object
    docenums.BillingScheme:
      enum:
        - FlatFee
        - PerUnit
        - Graduated
        - Volume
      type: string
      x-enum-varnames:
        - BillingSchemeFlatFee
        - BillingSchemePerUnit
        - BillingSchemeGraduated
        - BillingSchemeVolume
    plan.PaymentLinkResponse:
      properties:
        after_completion:
          additionalProperties: {}
          description: >-
            Checkout behaviour after payment or when the link expires. Mirrors
            metadata.after_completion.
          type: object
        created_at:
          description: created_at
          type: string
        created_by:
          description: created_by
          type: string
        customer_ident_collection:
          description: customer_ident_collection
          type: boolean
        deleted_at:
          description: deleted_at
          type: string
        enabled:
          description: enabled
          type: boolean
        id:
          description: id
          type: string
        invoice_id:
          description: invoice_id
          type: string
        metadata:
          additionalProperties: {}
          description: Arbitrary key-value metadata attached to the payment link.
          type: object
        plan_id:
          description: plan_id
          type: string
        properties:
          additionalProperties: {}
          description: Internal payment link properties.
          type: object
        shipping_address_collection:
          description: shipping_address_collection
          type: boolean
        source:
          allOf:
            - $ref: '#/components/schemas/docenums.BillingSource'
          description: source
        tax_ident_collection:
          description: tax_ident_collection
          type: boolean
        updated_at:
          description: updated_at
          type: string
        updated_by:
          description: updated_by
          type: string
      type: object
    docenums.RecurringInterval:
      enum:
        - Unknown
        - Minute
        - Hour
        - Day
        - Week
        - Month
        - Year
      type: string
      x-enum-varnames:
        - RecurringIntervalUnknown
        - RecurringIntervalMinute
        - RecurringIntervalHour
        - RecurringIntervalDay
        - RecurringIntervalWeek
        - RecurringIntervalMonth
        - RecurringIntervalYear
    docenums.RecurringUsageType:
      enum:
        - Unknown
        - Licensed
        - Metered
      type: string
      x-enum-varnames:
        - RecurringUsageTypeUnknown
        - RecurringUsageTypeLicensed
        - RecurringUsageTypeMetered
    docenums.PlanType:
      enum:
        - Unknown
        - OneTime
        - Recurring
      type: string
      x-enum-varnames:
        - PlanTypeUnknown
        - PlanTypeOneTime
        - PlanTypeRecurring
  securitySchemes:
    ApiKeyAuth:
      in: header
      name: X-API-KEY
      type: apiKey

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.