Skip to content

Updates a payment method

Request

PATCH {{baseURL}}/v2/payment-methods/{{paymentMethodId}}

This endpoint updates a payment method.

Renames the payment method.

The payment method is identified by paymentMethodId within the merchant. The operation works the same for orphan and customer-linked payment methods.

See Also:
To list payment methods, see GET /v2/payment-methods.
To retrieve a payment method by ID, see GET /v2/payment-methods/{{paymentMethodId}}.
To delete a payment method, see DELETE /v2/payment-methods/{{paymentMethodId}}.
To set a payment method as the default, see POST /v2/payment-methods/{{paymentMethodId}}/set-default.

Security
Bearer
Path
paymentMethodIdstring, (uuid)required

Specifies the payment method identifier.

Example:c857af4c-ced9-4b79-b39b-13c077711d7e
Bodyapplication/json

The payment method fields to update.

paymentNamestring or null

Specifies the name for the payment method.

This is a free-formed name that is convenient for the merchant to recognize.

Example: Peppared Street Cafe's Preferred Payment

Example:"Peppared Street Cafe's Preferred Payment"
curl -i -X PATCH \
  https://sandbox.api.flute.com/v2/payment-methods/c857af4c-ced9-4b79-b39b-13c077711d7e \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "paymentName": "My Updated Card"
  }'

Responses

OK. The payment method was successfully updated.

Response
No content