Lean Technologies · Capability

Lean Payment Sources API — Payment Sources

Lean Payment Sources — list, retrieve, and delete tokenized customer payment sources.

Lean Payment Sources API — Payment Sources is a Naftiko capability published by Lean Technologies, one of 19 capabilities the APIs.io network indexes for this provider. It bundles 3 operations across the GET and DELETE methods rooted at /v1/customers/v1/{…}/payment-sources.

The capability includes 2 read-only operations and 1 state-changing operation. Lead operation: Lean List Customer Payment Sources. Can be deployed as a REST endpoint, MCP tool, or Agent Skill via Naftiko.

Tagged areas include Lean, Payment Sources, and Tokenization.

Run with Naftiko LeanPayment SourcesTokenization

What You Can Do

GET
Listcustomerpaymentsources — Lean List Customer Payment Sources
/v1/customers/v1/{customer_id}/payment-sources
GET
Getpaymentsourcebyid — Lean Get Payment Source By Id
/v1/customers/v1/{customer_id}/payment-sources/{payment_source_id}
DELETE
Deletepaymentsource — Lean Delete Payment Source
/v1/customers/v1/{customer_id}/payment-sources/{payment_source_id}

MCP Tools

lean-listcustomerpaymentsources

Lean List Customer Payment Sources

read-only idempotent
lean-getpaymentsourcebyid

Lean Get Payment Source By Id

read-only idempotent
lean-deletepaymentsource

Lean Delete Payment Source

idempotent

Capability Spec

payment-sources-payment-sources.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Lean Payment Sources API — Payment Sources
  description: 'Lean Payment Sources — list, retrieve, and delete tokenized customer payment sources.'
  tags:
  - Lean
  - Payment Sources
  - Tokenization
  created: '2026-05-25'
  modified: '2026-05-25'
binds:
- namespace: env
  keys:
    LEAN_API_TOKEN: LEAN_API_TOKEN
capability:
  consumes:
  - type: http
    namespace: payment-sources-payment-sources
    baseUri: https://api2.leantech.me
    description: Lean Payment Sources API — Payment Sources business capability backed by Lean Technologies APIs.
    resources:
    - name: customer-payment-sources
      path: /customers/v1/{customer_id}/payment-sources
      operations:
      - name: listCustomerPaymentSources
        method: GET
        description: Lean List Customer Payment Sources
        outputRawFormat: json
        inputParameters:
        - name: customer_id
          in: path
          type: string
          required: true
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: payment-source-by-id
      path: /customers/v1/{customer_id}/payment-sources/{payment_source_id}
      operations:
      - name: getPaymentSourceById
        method: GET
        description: Lean Get Payment Source By Id
        outputRawFormat: json
        inputParameters:
        - name: customer_id
          in: path
          type: string
          required: true
        - name: payment_source_id
          in: path
          type: string
          required: true
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: deletePaymentSource
        method: DELETE
        description: Lean Delete Payment Source
        outputRawFormat: json
        inputParameters:
        - name: customer_id
          in: path
          type: string
          required: true
        - name: payment_source_id
          in: path
          type: string
          required: true
        outputParameters:
        - name: result
          type: object
          value: $.
    authentication:
      type: apikey
      key: Authorization
      value: 'Bearer {{env.LEAN_API_TOKEN}}'
      placement: header
  exposes:
  - type: rest
    namespace: payment-sources-payment-sources-rest
    port: 8080
    description: REST adapter for Lean Payment Sources API — Payment Sources.
    resources:
    - path: /v1/customers/v1/{customer_id}/payment-sources
      name: customer-payment-sources
      operations:
      - method: GET
        name: listCustomerPaymentSources
        description: Lean List Customer Payment Sources
        call: payment-sources-payment-sources.listCustomerPaymentSources
        with:
          customer_id: rest.path.customer_id
    - path: /v1/customers/v1/{customer_id}/payment-sources/{payment_source_id}
      name: payment-source-by-id
      operations:
      - method: GET
        name: getPaymentSourceById
        description: Lean Get Payment Source By Id
        call: payment-sources-payment-sources.getPaymentSourceById
        with:
          customer_id: rest.path.customer_id
          payment_source_id: rest.path.payment_source_id
      - method: DELETE
        name: deletePaymentSource
        description: Lean Delete Payment Source
        call: payment-sources-payment-sources.deletePaymentSource
        with:
          customer_id: rest.path.customer_id
          payment_source_id: rest.path.payment_source_id
  - type: mcp
    namespace: payment-sources-payment-sources-mcp
    port: 9090
    transport: http
    description: MCP adapter for Lean Payment Sources API — Payment Sources.
    tools:
    - name: lean-listcustomerpaymentsources
      description: Lean List Customer Payment Sources
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: payment-sources-payment-sources.listCustomerPaymentSources
      with:
        customer_id: tools.customer_id
    - name: lean-getpaymentsourcebyid
      description: Lean Get Payment Source By Id
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: payment-sources-payment-sources.getPaymentSourceById
      with:
        customer_id: tools.customer_id
        payment_source_id: tools.payment_source_id
    - name: lean-deletepaymentsource
      description: Lean Delete Payment Source
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: payment-sources-payment-sources.deletePaymentSource
      with:
        customer_id: tools.customer_id
        payment_source_id: tools.payment_source_id