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

# Remove a brokerage firm payment method

> The payment method stops being used for billing.



## OpenAPI

````yaml /openapi.json delete /brokerage-firms/{brokerageFirmId}/payment-methods/{paymentMethodId}
openapi: 3.0.0
info:
  title: Korint API
  description: >-
    Quoting, policy issuance, billing, claims, documents and compliance for
    insurance distribution.
  version: 1.0.0
  contact: {}
servers:
  - url: https://api.korint.io
    description: Production
  - url: https://api.sandbox.korint.io
    description: Sandbox
security:
  - oauth2: []
  - bearerAuth: []
tags: []
paths:
  /brokerage-firms/{brokerageFirmId}/payment-methods/{paymentMethodId}:
    delete:
      tags:
        - brokerage-firms
      summary: Remove a brokerage firm payment method
      description: The payment method stops being used for billing.
      operationId: BrokerageFirmController_deletePaymentMethod
      parameters:
        - name: tenant
          in: header
          required: true
          description: Your tenant identifier. Requests without it are rejected.
          schema:
            type: string
        - name: brokerageFirmId
          required: true
          in: path
          description: the brokerage firm id
          schema:
            pattern: >-
              ^brokerage_firm(_test)?_[346789ABCDEFGHJKLMNPQRTUVWXYabcdefghijkmnpqrtwxyz]{21}$
            type: string
        - name: paymentMethodId
          required: true
          in: path
          schema:
            pattern: >-
              ^payment_method(_test)?_[346789ABCDEFGHJKLMNPQRTUVWXYabcdefghijkmnpqrtwxyz]{21}$
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeleteBrokerageFirmPaymentMethodOutput'
        '404':
          content:
            application/json:
              schema:
                anyOf:
                  - $ref: '#/components/schemas/BrokerageFirmNotFoundErrorDto'
                  - $ref: '#/components/schemas/PaymentMethodNotFoundErrorDto'
              examples:
                BROKERAGE_FIRM_NOT_FOUND:
                  value:
                    code: BROKERAGE_FIRM_NOT_FOUND
                    message: >-
                      No brokerage firm found for brokerage firm id
                      {brokerageFirmId}
                    details: {}
                PAYMENT_METHOD_NOT_FOUND:
                  value:
                    code: PAYMENT_METHOD_NOT_FOUND
                    message: >-
                      No payment method found for payment method id
                      {paymentMethodId}
                    details: {}
          description: ''
        '409':
          content:
            application/json:
              schema:
                anyOf:
                  - $ref: '#/components/schemas/CannotDeleteLastPaymentMethodErrorDto'
              examples:
                CANNOT_DELETE_LAST_PAYMENT_METHOD:
                  value:
                    code: CANNOT_DELETE_LAST_PAYMENT_METHOD
                    message: >-
                      Cannot delete the last recurring payment method
                      {paymentMethodId}
                    details: {}
          description: ''
components:
  schemas:
    DeleteBrokerageFirmPaymentMethodOutput:
      type: object
      properties: {}
    BrokerageFirmNotFoundErrorDto:
      type: object
      properties:
        code:
          type: string
          enum:
            - BROKERAGE_FIRM_NOT_FOUND
        message:
          type: string
          example: No brokerage firm found for brokerage firm id {brokerageFirmId}
        details:
          $ref: '#/components/schemas/BrokerageFirmNotFoundDetailsDto'
      required:
        - code
        - message
        - details
    PaymentMethodNotFoundErrorDto:
      type: object
      properties:
        code:
          type: string
          enum:
            - PAYMENT_METHOD_NOT_FOUND
        message:
          type: string
          example: No payment method found for payment method id {paymentMethodId}
        details:
          $ref: '#/components/schemas/PaymentMethodNotFoundDetailsDto'
      required:
        - code
        - message
        - details
    CannotDeleteLastPaymentMethodErrorDto:
      type: object
      properties:
        code:
          type: string
          enum:
            - CANNOT_DELETE_LAST_PAYMENT_METHOD
        message:
          type: string
          example: Cannot delete the last recurring payment method {paymentMethodId}
        details:
          $ref: '#/components/schemas/CannotDeleteLastPaymentMethodDetailsDto'
      required:
        - code
        - message
        - details
    BrokerageFirmNotFoundDetailsDto:
      type: object
      properties:
        brokerageFirmId:
          type: string
        source:
          type: string
        policyId:
          type: string
      required:
        - brokerageFirmId
    PaymentMethodNotFoundDetailsDto:
      type: object
      properties:
        paymentMethodId:
          type: string
      required:
        - paymentMethodId
    CannotDeleteLastPaymentMethodDetailsDto:
      type: object
      properties:
        paymentMethodId:
          type: string
      required:
        - paymentMethodId
  securitySchemes:
    oauth2:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://korint-tenant.auth.eu-west-3.amazoncognito.com/oauth2/token
          scopes:
            korint.io/account: Read account information
            korint.io/analytics: Access analytics endpoints
            korint.io/assets: Access asset endpoints
            korint.io/billing: Access billing endpoints
            korint.io/branches: Access branch endpoints
            korint.io/broker: Access broker endpoints
            korint.io/claims: Access claim endpoints
            korint.io/comments: Access comment endpoints
            korint.io/customers: Access customer endpoints
            korint.io/derogations: Access derogation endpoints
            korint.io/documents: Access document endpoints
            korint.io/external: Access external lookup endpoints
            korint.io/external-claims: Declare claims from an external system
            korint.io/internal-notes: Access internal note endpoints
            korint.io/invitations: Access invitation endpoints
            korint.io/payments: Access payment endpoints
            korint.io/permissions: Access permission management endpoints
            korint.io/policies: Access policy endpoints
            korint.io/quotes: Access quote endpoints
            korint.io/reportings: Access reporting endpoints
            korint.io/signature: Access signature endpoints
      description: >-
        Machine-to-machine clients use the OAuth 2.0 client credentials grant.
        Each tenant has its own authorization server: in the token URL below,
        replace `tenant` with your tenant identifier.
    bearerAuth:
      scheme: bearer
      bearerFormat: JWT
      type: http
      description: An access token obtained from your tenant authorization server.

````