# (NEW!) Update Metadata Template Partially update an existing metadata template. Only fields included in the request body will be updated — omitted fields remain unchanged. Updatable Fields: name, groupIds, attributesDefaultValue, accessTemplates, templateOverride Fields that cannot be updated: templateId, customerId, createdBy, createdEpoch, createdDate, templateType, templateDenormalized, dependencies Key Business Rules: - Request body must contain at least one updatable field - Unknown or immutable fields are rejected with 400 - name must be unique per customer (case-insensitive) — duplicate returns 409 - groupIds must reference existing groups; system group is auto-appended last - Duplicate effective attributes across groups return 400 - accessTemplates must reference existing access templates; can be cleared with [] - attributesDefaultValue keys must exist in the effective template - templateDenormalized is regenerated on every successful update The user submitting the request must have the Metadata Management admin privilege. Endpoint: PATCH /metadata/template/{id} Version: 1.5 Security: ApiKeyAuth, BasicAuth ## Header parameters: - `Authorization` (string, required) Bearer token from authentication. - `X-API-Key` (string) Customer-specific API key (optional). - `Content-Type` (string, required) Enum: "application/json" ## Path parameters: - `id` (string, required) The unique ID of the metadata template to update. Example: "8cd2c221-6a91-4dc6-9379-d55dca9d5313" ## Request fields (application/json): - `name` (string) Display name of the metadata template. Example: "Updated Product Template" - `groupIds` (array) Attribute groups included in the template. Replaces existing list. Example: ["52ce0235-02cc-46f6-8bdb-05238c76bf83","5d1f1f87-5f64-4e03-8a2b-2c7e77f85bcb"] - `attributesDefaultValue` (array) Default metadata values for fields in the template. Example: [{"searchField":"title","value":"Test Assets"}] - `attributesDefaultValue.searchField` (string) - `attributesDefaultValue.value` (any) The default value. - `accessTemplates` (array) Access template IDs. Pass [] to clear. Example: [] - `templateOverride` (object) Template-level required/optional attribute overrides. - `templateOverride.required` (array) searchFields to make required at the template level. Example: ["title"] - `templateOverride.optional` (array) searchFields to make optional at the template level. Example: ["country"] ## Response 200 fields (application/json): - `templateId` (string) - `name` (string) - `customerId` (string) - `createdBy` (string) - `createdEpoch` (integer) - `createdDate` (string) - `lastUpdatedBy` (string) - `lastUpdatedEpoch` (integer) - `lastUpdatedDate` (string) - `groupIds` (array) - `templateType` (array) - `attributesDefaultValue` (array) - `attributesDefaultValue.searchField` (string) - `attributesDefaultValue.value` (any) Default value for the attribute. - `accessTemplates` (array) - `templateOverride` (object) - `templateOverride.required` (array) - `templateOverride.optional` (array) - `templateDenormalized` (object) System-generated denormalized template structure. ## Response 400 fields (application/json): - `message` (string) - `detail` (string) ## Response 401 fields (application/json): - `message` (string) - `detail` (string) ## Response 403 fields (application/json): - `message` (string) - `detail` (string) ## Response 404 fields (application/json): - `message` (string) - `detail` (string) ## Response 409 fields (application/json): - `message` (string) - `detail` (string)