# Patch Payment Method

patch ` https://app.mk.io/api/v1/organization/paymentMethods/:paymentmethod_id`

Partially update a payment method using JSON Patch (RFC 6902). Requires `Content-Type: application/json-patch+json`.

The following field can be updated via `replace` operations:

- `/metadata/displayName` — a human-friendly display name (max 256 characters, or `""` to clear).

RBAC Capability Required: `core.subscription.update`

## Authentication

Authorization Bearer

Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Path parameters

paymentmethod_id string Required format: uuid

## Request

This endpoint expects a list of objects.

## Response

200 The updated payment method.

metadata object [PaymentMethodMetadata](https://docs.mediakind.com/api-reference/management-api/schemas/paymentmethodmetadata) Optional

Metadata.

Show 6 properties Hide 6 properties

- created string Optional format: date-time
- createdBy string Optional format: uuid
- createdByEmail string Optional
- displayName string Optional
- id string Required format: uuid
- organizationId string or null Required format: uuid

related object [PaymentMethodRelated](https://docs.mediakind.com/api-reference/management-api/schemas/paymentmethodrelated) Optional

Related data.

Show 1 property Hide 1 property

- projects list of strings Required

spec object Required

Specification.

Show 3 variants Hide 3 variants

Discriminated by `type`. Select one variant:

### azure object [PaymentMethodAzureSpec](https://docs.mediakind.com/api-reference/management-api/schemas/paymentmethodazurespec)

- allowedOrganizations list of strings or null Optional
- autoPurchaseBeamLicenses boolean Required
- azureOfferId string or null Optional
- azurePlanName string or null Optional
- azurePrivateOfferId string Optional format: uuid
- endDate string or null Required format: date
- notes string Optional <=256 characters
- productPublicationName string Required
- startDate string or null Required format: date
- type string Required

### aws object [PaymentMethodAWSSpec](https://docs.mediakind.com/api-reference/management-api/schemas/paymentmethodawsspec)

- allowedOrganizations list of strings or null Optional
- autoPurchaseBeamLicenses boolean Required
- awsAccountId string Optional
- awsCustomerId string or null Optional
- awsOfferId string Optional
- endDate string or null Required format: date
- notes string Optional <=256 characters
- productPublicationName string Required
- startDate string or null Required format: date
- type string Required

### direct object [PaymentMethodDirectSpec](https://docs.mediakind.com/api-reference/management-api/schemas/paymentmethoddirectspec)

- allowedOrganizations list of strings or null Optional
- autoPurchaseBeamLicenses boolean Required
- endDate string or null Required format: date
- notes string Optional <=256 characters
- productPublicationName string Required
- redeemedBy string or null Optional
- salesOrderNumber string Optional
- startDate string or null Required format: date
- status string Optional
- type string Required

status object [PaymentMethodStatus](https://docs.mediakind.com/api-reference/management-api/schemas/paymentmethodstatus) Optional

Status.

Show 2 properties Hide 2 properties

- isActive boolean Required
- termsAndConditionsAccepted boolean Required

## Errors

### 400 Bad Request

error object [ErrorDetail](https://docs.mediakind.com/api-reference/management-api/schemas/errordetail) Required

Pertinent information about the error

Show 3 properties Hide 3 properties

- code string Required
- detail string Required
- extraDetail map from strings to any Optional
- ref string Required
- status integer Required

### 401 Unauthorized

### 403 Forbidden

### 404 Not Found

### 429 Too Many Requests

### 500 Internal Server Error

All error responses follow a similar structure as the 400 Bad Request.
