{"type":"api","title":"Update Template","meta":{"id":"/apps/pubhub/media/crosswork-network-controller-7-1/f445c17e25a1120e8fbde4bd413083d0fd88b2b3/963b8613-6bdd-3b27-ae70-defd3dac9131","info":{"title":"Device Configuration Templates API","description":"Device Configuration Templates API","version":"1.0.0","contact":{"name":"Crosswork Team, Cisco","email":"support@cisco.com"},"license":{"name":"Cisco Software License Agreement","url":"http://www.cisco.com/public/sw-license-agreement.html"}},"x-parser-conf":{"overview":{"markdownPath":"reference/EMF/Device Configuration/device-config-templates-api-overview.md"}},"openapi":"3.1.0","servers":[{"url":"https://{server-ip}:30603/crosswork/config/v1","description":"Generated server url"}]},"spec":{"tags":["Template API"],"operationId":"updateTemplate","requestBody":{"description":"Create template JSON","content":{"application/json":{"schema":{"type":"object","description":"Template data as payload","properties":{"port_type":{"description":"Port Type List","type":"array","items":{"type":"string"}},"payload_case":{"description":"Payload Case","type":"string","enum":["CONFIGLET","TEMPLATE_NAME","FLOW_ID","PAYLOAD_NOT_SET"]},"transport_value":{"description":"Transport Value","type":"integer","format":"int32"},"failure_policy_value":{"description":"Failure Policy Value","type":"integer","format":"int32"},"last_deployed_status_value":{"description":"Last Deployed Status Value","type":"integer","format":"int32"},"category_value":{"description":"Category Value","type":"integer","format":"int32"},"device_type":{"description":"Device Type List","type":"array","properties":{"empty":{"description":"Empty","type":"boolean"}},"items":{"type":"string"}},"tag_list":{"description":"Tag List","type":"array","properties":{"empty":{"description":"Empty","type":"boolean"}},"items":{"type":"string"}},"access_list":{"description":"Access List","type":"array","properties":{"empty":{"description":"Empty","type":"boolean"}},"items":{"type":"string"}},"is_read":{"description":"Boolean value: Is Read","type":"boolean"},"flow_id":{"description":"Flow Id","type":"string"},"type_value":{"description":"Type Value","type":"integer","format":"int32"},"notes":{"description":"Notes","type":"string"},"last_deployed_status":{"description":"Last Deployed Status","type":"string","enum":["NOT_STARTED","FAILED","PARTIAL","IN_PROGRESS","SUCCESS","NOT_DEPLOYED","SYSTEM_FAILURE","UNRECOGNIZED"]},"author":{"description":"Author","type":"string"},"template_name":{"description":"Template Name","type":"object","properties":{"template_name":{"description":"Template name List","type":"array","items":{"type":"string"}}},"$$ref":"#/components/schemas/TemplateNameList"},"configlet":{"description":"Configlet","type":"string"},"variables":{"description":"Variables List","type":"array","items":{"description":"Template Variable","type":"object","properties":{"is_mandatory":{"description":"Is Mandatory","type":"boolean"},"options":{"description":"Options List","type":"array","items":{"type":"string"}},"name":{"description":"Name","type":"string"},"type":{"description":"Type","type":"string"},"default_value":{"description":"Default Value","type":"string"},"display_name":{"description":"Display Name","type":"string"},"version":{"description":"Version","type":"number","format":"float"},"description":{"description":"Description","type":"string"}},"$$ref":"#/components/schemas/TemplateVariable"}},"failure_policy":{"description":"Failure Policy","type":"string","enum":["CONTINUE_ON_FAILURE","STOP_ON_FAILURE","UNRECOGNIZED"]},"transport":{"description":"Transport","type":"string","enum":["CLI","GNMI","NETCONF","UNRECOGNIZED"]},"category":{"description":"Category","type":"string","enum":["DEVICE","INTERFACE","MODULE","UNRECOGNIZED"]},"name":{"description":"Name","type":"string"},"type":{"description":"Type","type":"string","enum":["SYSTEM","USER_DEFINED_SIMPLE","USER_DEFINED_COMPOSITE","MANAGEABILITY","EVENT_DRIVEN","UNRECOGNIZED"]},"path":{"description":"Path","type":"string"},"version":{"description":"Version","type":"number","format":"float"},"description":{"description":"Description","type":"string"}},"$$ref":"#/components/schemas/Template"},"example":{"name":"test","version":1,"notes":"Initial version","description":"test","is_read":false,"device_type":[],"category":"DEVICE","transport":"CLI","tagList":[],"accessList":["admin"],"configlet":"banner motd % test banner change%","variables":[],"type":"USER_DEFINED_SIMPLE","created_at":"2025-02-23T09:13:44.903159Z","port_type":[],"author":"admin","path":"","failurePolicy":"CONTINUE_ON_FAILURE","last_deployed_status":"NOT_STARTED"}}},"required":true},"responses":{"200":{"description":"OK","content":{"*/*":{"schema":{"type":"string"},"example":" "}}},"403":{"description":"Forbidden. The server recognizes the authentication credentials, but the client is not authorized to perform this request."}},"method":"put","path":"/templates"}}