API reference

updatePaymentMethod

Required permission: RestaurantReportWrite

graphql
updatePaymentMethod(
  restaurantId: ID!
  paymentMethodId: ID!
  patch: PaymentMethodPatch!
): PaymentMethod

Arguments

Name Type Description
restaurantId ID!
paymentMethodId ID!
patch PaymentMethodPatch!

Returns

PaymentMethod

Example

graphql
mutation UpdatePaymentMethod($restaurantId: ID!, $paymentMethodId: ID!, $patch: PaymentMethodPatch!) {
  updatePaymentMethod(restaurantId: $restaurantId, paymentMethodId: $paymentMethodId, patch: $patch) {
    id
    iconUrl
    isLegacy
    name
    paymentProvider
    receiptPaymentMethodLabel
  }
}
bash
curl https://api.thelocoapp.com/graphql \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $LOCO_API_KEY" \
  -d '{"query": "mutation { updatePaymentMethod(...) { __typename } }"}'