braintree · Capability

Braintree Payments API — Payment Methods

Braintree Payments API — Payment Methods. 4 operations. Lead operation: Create a payment method. Self-contained Naftiko capability covering one Braintree business surface.

Run with Naftiko BraintreePayment Methods

What You Can Do

POST
Createpaymentmethod — Create a payment method
/v1/payment-methods
GET
Getpaymentmethod — Get a payment method
/v1/payment-methods/any/{paymentmethodtoken}
PUT
Updatepaymentmethod — Update a payment method
/v1/payment-methods/any/{paymentmethodtoken}
DELETE
Deletepaymentmethod — Delete a payment method
/v1/payment-methods/any/{paymentmethodtoken}

MCP Tools

create-payment-method

Create a payment method

get-payment-method

Get a payment method

read-only idempotent
update-payment-method

Update a payment method

idempotent
delete-payment-method

Delete a payment method

idempotent

Capability Spec

payments-payment-methods.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Braintree Payments API — Payment Methods
  description: 'Braintree Payments API — Payment Methods. 4 operations. Lead operation: Create a payment method. Self-contained
    Naftiko capability covering one Braintree business surface.'
  tags:
  - Braintree
  - Payment Methods
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    BRAINTREE_API_KEY: BRAINTREE_API_KEY
capability:
  consumes:
  - type: http
    namespace: payments-payment-methods
    baseUri: https://api.braintreegateway.com/merchants/{merchantId}
    description: Braintree Payments API — Payment Methods business capability. Self-contained, no shared references.
    resources:
    - name: payment_methods
      path: /payment_methods
      operations:
      - name: createpaymentmethod
        method: POST
        description: Create a payment method
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: payment_methods-any-paymentMethodToken
      path: /payment_methods/any/{paymentMethodToken}
      operations:
      - name: getpaymentmethod
        method: GET
        description: Get a payment method
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: updatepaymentmethod
        method: PUT
        description: Update a payment method
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: deletepaymentmethod
        method: DELETE
        description: Delete a payment method
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    authentication:
      type: basic
      username: '{{env.BRAINTREE_USER}}'
      password: '{{env.BRAINTREE_PASS}}'
  exposes:
  - type: rest
    namespace: payments-payment-methods-rest
    port: 8080
    description: REST adapter for Braintree Payments API — Payment Methods. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/payment-methods
      name: payment-methods
      description: REST surface for payment_methods.
      operations:
      - method: POST
        name: createpaymentmethod
        description: Create a payment method
        call: payments-payment-methods.createpaymentmethod
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/payment-methods/any/{paymentmethodtoken}
      name: payment-methods-any-paymentmethodtoken
      description: REST surface for payment_methods-any-paymentMethodToken.
      operations:
      - method: GET
        name: getpaymentmethod
        description: Get a payment method
        call: payments-payment-methods.getpaymentmethod
        outputParameters:
        - type: object
          mapping: $.
      - method: PUT
        name: updatepaymentmethod
        description: Update a payment method
        call: payments-payment-methods.updatepaymentmethod
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deletepaymentmethod
        description: Delete a payment method
        call: payments-payment-methods.deletepaymentmethod
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: payments-payment-methods-mcp
    port: 9090
    transport: http
    description: MCP adapter for Braintree Payments API — Payment Methods. One tool per consumed operation, routed inline
      through this capability's consumes block.
    tools:
    - name: create-payment-method
      description: Create a payment method
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: payments-payment-methods.createpaymentmethod
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: get-payment-method
      description: Get a payment method
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: payments-payment-methods.getpaymentmethod
      outputParameters:
      - type: object
        mapping: $.
    - name: update-payment-method
      description: Update a payment method
      hints:
        readOnly: false
        destructive: false
        idempotent: true
      call: payments-payment-methods.updatepaymentmethod
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-payment-method
      description: Delete a payment method
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: payments-payment-methods.deletepaymentmethod
      outputParameters:
      - type: object
        mapping: $.