# Update category

## Updates a category.

> Updates category properties. Only provided fields will be modified.

```json
{"openapi":"3.0.1","info":{"title":"Marketplace API","version":"5.0.5202-gabed2ddc"},"servers":[{"url":"https://api.platform.softwareone.com"}],"paths":{"/public/v1/notifications/categories/{id}":{"put":{"tags":["Categories"],"summary":"Updates a category.","description":"Updates category properties. Only provided fields will be modified.","parameters":[{"name":"id","in":"path","description":"The category ID.","required":true,"schema":{"type":"string"}}],"requestBody":{"description":"The update request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateCategory"}},"text/json":{"schema":{"$ref":"#/components/schemas/UpdateCategory"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/UpdateCategory"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"UpdateCategory":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string"}},"additionalProperties":false},"Category":{"type":"object","properties":{"id":{"type":"string"},"audit":{"allOf":[{"$ref":"#/components/schemas/NotificationCategoryAudit"}],"description":"Represents audit information for a Mpt.Notifications.Models.Categories.Category."},"$meta":{"allOf":[{"$ref":"#/components/schemas/PlatformMetadata"}],"nullable":true},"name":{"type":"string"},"revision":{"type":"integer","format":"int32"},"description":{"type":"string","description":"Gets or sets the description of the category."},"optOutAllowed":{"type":"boolean","description":"Gets or sets a value indicating whether recipients can opt out of notifications in this category."},"status":{"type":"string","description":"Gets or sets the current status of the category."},"note":{"type":"string","description":"Gets or sets an optional note about the category.","nullable":true},"deleteAllowed":{"type":"boolean","description":"Gets or sets a value indicating whether this category can be deleted."},"statistics":{"allOf":[{"$ref":"#/components/schemas/MessageStatistics"}],"description":"Gets or sets the message statistics for this category."},"lastUsed":{"type":"string","description":"Gets or sets the timestamp of when this category was last used to send a notification.","format":"date-time","nullable":true},"enabledByDefault":{"type":"boolean","description":"Gets or sets a value indicating whether this category is enabled by default for new recipients."}},"additionalProperties":false,"description":"Represents a notification category that can be used to organize and filter notifications."},"NotificationCategoryAudit":{"type":"object","properties":{"created":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"nullable":true},"updated":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"nullable":true},"published":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"description":"Gets or sets the event information for when the category was published.","nullable":true},"unpublished":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"description":"Gets or sets the event information for when the category was unpublished.","nullable":true},"deleted":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"description":"Gets or sets the event information for when the category was deleted.","nullable":true}},"additionalProperties":false,"description":"Represents audit information for a Mpt.Notifications.Models.Categories.Category."},"PlatformObjectEvent":{"type":"object","properties":{"at":{"type":"string","format":"date-time","nullable":true},"by":{"type":"object","allOf":[{"$ref":"#/components/schemas/PlatformIdentityRef"}]}},"additionalProperties":false},"PlatformIdentityRef":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"icon":{"type":"string","nullable":true},"revision":{"type":"integer","format":"int32"}},"additionalProperties":false},"PlatformMetadata":{"type":"object","properties":{"omitted":{"type":"array","items":{"type":"string"}}},"additionalProperties":false},"MessageStatistics":{"type":"object","properties":{"month":{"type":"integer","description":"Gets or sets the number of messages sent in the current month.","format":"int32"},"today":{"type":"integer","description":"Gets or sets the number of messages sent today.","format":"int32"},"week":{"type":"integer","description":"Gets or sets the number of messages sent in the current week.","format":"int32"}},"additionalProperties":false,"description":"Represents message statistics aggregated over different time periods."},"ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}}}
```
