# Update template

Update a template for a product.

## PUT /public/v1/catalog/products/{productId}/templates/{id}

>

```json
{"openapi":"3.0.1","info":{"title":"Marketplace API","version":"5.0.5164-g77db55e8"},"servers":[{"url":"https://api.platform.softwareone.com"}],"paths":{"/public/v1/catalog/products/{productId}/templates/{id}":{"put":{"tags":["Templates"],"parameters":[{"name":"productId","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateUpdate"}},"text/json":{"schema":{"$ref":"#/components/schemas/TemplateUpdate"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/TemplateUpdate"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Template"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"Internal Server Error"}}}}},"components":{"schemas":{"TemplateUpdate":{"type":"object","properties":{"name":{"type":"string"},"default":{"type":"boolean","nullable":true},"content":{"type":"string"},"externalIds":{"allOf":[{"$ref":"#/components/schemas/TemplateExternalIdBag"}],"nullable":true}},"additionalProperties":false},"TemplateExternalIdBag":{"type":"object","properties":{"vendor":{"type":"string","nullable":true}},"additionalProperties":false},"Template":{"type":"object","properties":{"id":{"type":"string"},"audit":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectAudit"}]},"$meta":{"allOf":[{"$ref":"#/components/schemas/PlatformMetadata"}],"nullable":true},"name":{"type":"string"},"revision":{"type":"integer","format":"int32"},"content":{"type":"string"},"type":{"enum":["OrderProcessing","OrderQuerying","OrderCompleted","Subscription","Asset"],"type":"string"},"default":{"type":"boolean","nullable":true},"externalIds":{"allOf":[{"$ref":"#/components/schemas/TemplateExternalIdBag"}]},"product":{"type":"object","allOf":[{"$ref":"#/components/schemas/ProductRef"}]}},"additionalProperties":false},"PlatformObjectAudit":{"type":"object","properties":{"created":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"nullable":true},"updated":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"nullable":true}},"additionalProperties":false},"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},"ProductRef":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"icon":{"type":"string","nullable":true},"revision":{"type":"integer","format":"int32"},"externalIds":{"allOf":[{"$ref":"#/components/schemas/ProductExternalIdBag"}]},"status":{"type":"string"}},"additionalProperties":false},"ProductExternalIdBag":{"type":"object","properties":{"operations":{"type":"string","nullable":true},"defaultErpItem":{"type":"string","nullable":true}},"additionalProperties":false},"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":{}}}}}
```
