---
title: "Merge credit note metadata"
method: PATCH
path: "/credit_notes/{lago_id}/metadata"
tags: ["credit_notes"]
---

# Merge credit note metadata

`PATCH /credit_notes/{lago_id}/metadata`

This endpoint merges the provided metadata with existing metadata on the credit note.
Existing keys not in the request are preserved. New keys are added, existing keys are updated.

## Path parameters

- `lago_id` string, uuid, required

## Request body

- CreditNoteMetadataResponse
  - `metadata` MetadataObject, nullable, required — Custom metadata stored as key-value pairs. Keys are strings (max 100 characters), values can be strings (max 255 characters) or null.

## Response `200`

Credit note metadata merged

- CreditNoteMetadataResponse
  - `metadata` MetadataObject, nullable, required — Custom metadata stored as key-value pairs. Keys are strings (max 100 characters), values can be strings (max 255 characters) or null.

## Other responses

- `401` — Unauthorized error
- `404` — Not Found error
- `422` — Unprocessable entity error

---

[API](https://skmtc.net/getlago/apis/lago-api-documentation.md) · [All operations](https://skmtc.net/getlago/apis/lago-api-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/getlago/lago-api-documentation/versions/6e969ef3bb45/schema)
