{"type":"api","title":"Get the Mop (Playbook) Specs","meta":{"id":"/apps/pubhub/media/crosswork-network-controller-7-1/f445c17e25a1120e8fbde4bd413083d0fd88b2b3/c0404d8d-ff8e-36e9-bb59-ee336d247534","info":{"title":"Crosswork Change Automation API","version":"7.1.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"},"description":"A web server dedicated to RESTful queries into the Crosswork Change Automation application."},"x-parser-conf":{"overview":{"markdownPath":"reference/CAHI/change_automation.overview.md"}},"openapi":"3.1.0","servers":[{"url":"https://{server_ip}:30603/crosswork/nca/v1","description":"Generated server url"}]},"spec":{"summary":"Get the Mop (Playbook) Specs","operationId":"NCA_GetMopSpecs","tags":["NCA"],"parameters":[{"name":"mop_id","description":"ID of the MoP for which specs files are needed. API will return error if mop_id is not specified","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object","description":"Change Automation Mop Specs Read Response","properties":{"mop_id":{"type":"string","title":"ID of the playbook","description":"ID of the playbook"},"pb_exec_policy_specs":{"type":"object","description":"Playbook execution policy spec file content."},"pb_params_specs":{"type":"object","description":"Playbook params/vars spec file content."}},"example":{"mop_id":"router_check_accessibility","pb_exec_policy_specs":{"$schema":"http://json-schema.org/draft-06/schema#","description":"A representation of playbook execution policy parameters","type":"object","required":["execution_strategy"],"properties":{"timeout":{"default":"1h","description":"Timeout duration for MoP i.e. maximum time spent in Running/Paused states. e.g. 900s, 10m, 1.5h, etc. Valid time units are 'ns', 'us' (or 'µs'), 'ms', 's', 'm', 'h'.","type":"string"},"execution_strategy":{"default":"strategy_continuous","description":"Type of execution of playbook","type":"string","enum":["strategy_continuous","strategy_single_step","strategy_dry_run"]},"pause_on_tasks":{"description":"ID's of the tasks on which the execution should pause when in single stepping mode","type":"array","items":{"type":"integer"}},"on_failure":{"default":"on_failure_pause","description":"Action that the user wishes to take on task failure","type":"string","enum":["on_failure_pause","on_failure_complete_rollback","on_failure_abort"]}},"oneOf":[{"title":"Execution strategy single_step (Specify pause to tasks & on_failure)","type":"object","required":["pause_on_tasks","on_failure"],"properties":{"execution_strategy":{"description":"Type of execution of playbook","enum":["strategy_single_step"]}}},{"title":"Execution strategy continuous (on_failure mandatory)","type":"object","required":["on_failure"],"properties":{"execution_strategy":{"description":"Type of execution of playbook","enum":["strategy_continuous"]}}},{"title":"Execution strategy dry_run (Everything else is optional)","type":"object","properties":{"execution_strategy":{"description":"Type of execution of playbook","enum":["strategy_dry_run"]}}}]},"pb_params_specs":{"$schema":"http://json-schema.org/draft-04/schema#","definitions":{},"title":"Router Check Accessibility","properties":{"1":{"title":"Check IP connectivity","description":"Check IP connectivity to router","properties":{},"type":"object"},"2":{"title":"Check JsonRpc connectivity to managing NSO","description":"Check connectivity to the local config provider","properties":{},"type":"object"}},"type":"object"}},"$$ref":"#/components/schemas/change_automationMopSpecsReadResp"}}}},"400":{"description":"Bad Request. The request is malformed in some way and the server cannot process it.","content":{"application/json":{"schema":{"type":"object","description":"Change Automation Error 400","required":["code","severity","message"],"properties":{"code":{"type":"string","description":"HTTP return code","example":"400"},"severity":{"type":"string","description":"Error severity level","enum":["Critical","Warning","Fatal"]},"message":{"type":"string","description":"Error message","example":"top level error string"},"data":{"type":"string","description":"Details of the error","example":"detailed description of the error"}},"example":{"code":"400","severity":"Critical","message":"error message","data":"detailed description of the error"},"$$ref":"#/components/schemas/change_automationError400"}}}},"500":{"description":"Internal Server Error. The server could not fulfill the request.","content":{"application/json":{"schema":{"type":"object","description":"Change Automation Error 500","required":["code","severity","message"],"properties":{"code":{"type":"string","description":"HTTP return code","example":"500"},"severity":{"type":"string","description":"Error severity level","enum":["Critical","Warning","Fatal"]},"message":{"type":"string","description":"Error message","example":"top level error string"},"data":{"type":"string","description":"Error detailed description"}},"example":{"code":"500","severity":"Critical","message":"error message","data":"Server Error. detailed description of the error"},"$$ref":"#/components/schemas/change_automationError500"}}}}},"method":"get","path":"/mops/{mop_id}/specs"}}