Add or remove labels for a payment.
Security
Bearer
Labels to add to or remove from the payment.
Application-defined labels for grouping and categorizing payments (e.g., campaign IDs, workflow tags, or batch identifiers). Labels are optional and mutable; they can be added or removed over the payment’s lifetime.
- Mock serverhttps://docs.ripple.com/_mock/products/payments-direct-2/v2025.11/api-docs/payments-direct-api/payments-direct-2-api/v2/payments/{paymentId}/labels
- UAT environment with simulated currencyhttps://api.test.ripple.com/v2/payments/{paymentId}/labels
- Production environmenthttps://api.ripple.com/v2/payments/{paymentId}/labels
curl -i -X PATCH \
https://docs.ripple.com/_mock/products/payments-direct-2/v2025.11/api-docs/payments-direct-api/payments-direct-2-api/v2/payments/7ea3399c-1234-5678-8d8f-d320ea406630/labels \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"labelsToAdd": [
"batchId=aaaaaaaa-1111-bbbb-abab-123412341234"
],
"labelsToRemove": [
"batchId=aaaaaaaa-1111-bbbb-abab-123412341234"
]
}'Successfully updated the payment labels.
Response
{ "labels": [ "batchId=aaaaaaaa-1111-bbbb-abab-123412341234" ] }