Configuration Template Management API

/api/space/config-template-management/config-templates/{id}

The following operations are supported on this resource:

  • GET - Gets a configuration template
  • PUT - Updates or replaces a configuration template
  • PATCH - Patches a configuration template
  • DELETE - Deletes a configuration template

GET /api/space/config-template-management/config-templates/{id} (v1)


This API gets a single configuration template.

Access Control

The following capabilities are required to access this API:
"ManageTemplates"


Example Usage

GET /api/space/config-template-management/config-templates/{id}


Parameters

NameTypeURI TypeDescriptionRequired
idIntegerPathThe ID of the configuration template to retrieve. Y

Content Types

  • Produces content types:
    application/vnd.net.juniper.space.config-template-management.config-template+xml;version=1;q=0.01
    application/vnd.net.juniper.space.config-template-management.config-template+json;version=1;q=0.01


  • Sample Output XML:
    <config-template
         href="/api/space/config-template-management/config-templates/{id}" uri="/api/space/config-template-management/config-templates/{id}">
         <id>Integer</id>
         <name>String</name>
         <description>String</description>
         <state>String</state>
         <os-version>String</os-version>
         <current-version>Integer</current-version>
         <device-family>String</device-family>
         <last-updated-by>String</last-updated-by>
         <last-update-time>String</last-update-time>
         <config-template-definition
               href="/api/space/config-template-management/config-template-definitions/{id}" uri="/api/space/config-template-management/config-templates/{id}">
               <id>Integer</id>
               <name>String</name>
         </config-template-definition>
         <configuration href="/api/space/config-template-management/config-templates/{id}/configuration"/>
         <exec-deploy href="/api/space/config-template-management/config-templates/{id}/exec-deploy"/>
         <exec-undeploy href="/api/space/config-template-management/config-templates/{id}/exec-undeploy"/>
         <exec-audit href="/api/space/config-template-management/config-templates/{id}/exec-audit"/>
         <device-associations href="/api/space/config-template-management/config-templates/{id}/device-associations"/>
    </config-template>


  • Sample Output JSON:
    {
       "config-template" : {
         "@href" : "/api/space/config-template-management/config-templates/{id}" ,
         "@uri" : "/api/space/config-template-management/config-templates/{id}" ,
         "id" : "Integer" ,
         "name" : "String" ,
         "description" : "String" ,
         "state" : "String" ,
         "os-version" : "String" ,
         "current-version" : "Integer" ,
         "device-family" : "String" ,
         "last-updated-by" : "String" ,
         "last-update-time" : "String" ,
         "config-template-definition" : {
           "@href" :
           "/api/space/config-template-management/config-template-definitions/{id}" ,
           "@uri" : "/api/space/config-template-management/config-templates/{id}" ,
           "id" : "Integer" ,
           "name" : "String"
         } ,
         "configuration" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/configuration"
         } ,
         "exec-deploy" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/exec-deploy"
         } ,
         "exec-undeploy" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/exec-undeploy"
         } ,
         "exec-audit" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/exec-audit"
         } ,
         "device-associations" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/device-associations"
         }
       }
    }



PUT /api/space/config-template-management/config-templates/{id} (v1)


This API updates or replaces a configuration template.

Access Control

The following capabilities are required to access this API:
"ModifyTemplate"


Example Usage

PUT /api/space/config-template-management/config-templates/{id}


Parameters

NameTypeURI TypeDescriptionRequired
idIntegerPathThe ID of the configuration template to update or replace. Y

Content Types

  • Consumes content types:
    application/vnd.net.juniper.space.config-template-management.config-template+xml;version=1;charset=UTF-8
    application/vnd.net.juniper.space.config-template-management.config-template+json;version=1;charset=UTF-8


  • Produces content types:
    application/vnd.net.juniper.space.config-template-management.config-template+xml;version=1;q=0.01
    application/vnd.net.juniper.space.config-template-management.config-template+json;version=1;q=0.01


  • Sample Input XML:
    <config-template>
         <name>String</name>
         <description>String</description>
    </config-template>


  • Sample Output XML:
    <config-template
         href="/api/space/config-template-management/config-templates/{id}" uri="/api/space/config-template-management/config-templates/{id}">
         <id>Integer</id>
         <name>String</name>
         <description>String</description>
         <state>String</state>
         <os-version>String</os-version>
         <current-version>Integer</current-version>
         <device-family>String</device-family>
         <last-updated-by>String</last-updated-by>
         <last-update-time>String</last-update-time>
         <config-template-definition
               href="/api/space/config-template-management/config-template-definitions/{id}" uri="/api/space/config-template-management/config-templates/{id}">
               <id>Integer</id>
               <name>String</name>
         </config-template-definition>
    </config-template>


  • Sample Input JSON:
    {
       "config-template" : {
         "name" : "String" ,
         "description" : "String"
       }
    }


  • Sample Output JSON:
    {
       "config-template" : {
         "@href" : "/api/space/config-template-management/config-templates/{id}" ,
         "@uri" : "/api/space/config-template-management/config-templates/{id}" ,
         "id" : "Integer" ,
         "name" : "String" ,
         "description" : "String" ,
         "state" : "String" ,
         "os-version" : "String" ,
         "current-version" : "Integer" ,
         "device-family" : "String" ,
         "last-updated-by" : "String" ,
         "last-update-time" : "String" ,
         "config-template-definition" : {
           "@href" :
           "/api/space/config-template-management/config-template-definitions/{id}" ,
           "@uri" : "/api/space/config-template-management/config-templates/{id}" ,
           "id" : "Integer" ,
           "name" : "String"
         }
       }
    }



PATCH /api/space/config-template-management/config-templates/{id} (v1)


This API patch a single configuration template.

Access Control

The following capabilities are required to access this API:
"AddDeployedDevices"


Example Usage

PATCH /api/space/config-template-management/config-templates/{id}


Parameters

NameTypeURI TypeDescriptionRequired
idIntegerPathThe ID of the configuration template to patch. Y

Content Types

  • Consumes content types:
    application/vnd.net.juniper.space.config-template-management.config-template_patch+xml;version=1;charset=UTF-8


  • Produces content types:
    application/vnd.net.juniper.space.config-template-management.config-template+xml;version=1;q=0.01


  • Sample Patch XML:
    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <diff>
       <!--What you see below are just a samples of patch operations that may be
         performed on this DTO. -->
       <!--For more information about the format of the patch document please see http://http://www.rfc-editor.org/rfc/rfc5261.txt -->
       <replace sel="config-template/name">
         <name>String</name>
       </replace>
       <replace sel="config-template/description">
         <description>String</description>
       </replace>
       <replace sel="config-template/state">
         <state>String</state>
       </replace>
       <replace sel="config-template/os-version">
         <os-version>String</os-version>
       </replace>
       <replace sel="config-template/current-version">
         <current-version>Integer</current-version>
       </replace>
       <replace sel="config-template/device-family">
         <device-family>String</device-family>
       </replace>
       <replace sel="config-template/last-updated-by">
         <last-updated-by>String</last-updated-by>
       </replace>
       <replace sel="config-template/last-update-time">
         <last-update-time>String</last-update-time>
       </replace>
       <replace sel="config-template/config-template-definition">
         <config-template-definition
           href="/api/space/config-template-management/config-template-definitions/{id}" />
       </replace>
       <replace sel="config-template/configuration">
         <configuration
           href="/api/space/config-template-management/config-templates/{id}/configuration">
           <id>Integer</id>
         </configuration>
       </replace>
       <!-- or -->
       <add sel="config-template/name">
         <name>String</name>
       </add>
       <add sel="config-template/description">
         <description>String</description>
       </add>
       <add sel="config-template/state">
         <state>String</state>
       </add>
       <add sel="config-template/os-version">
         <os-version>String</os-version>
       </add>
       <add sel="config-template/current-version">
         <current-version>Integer</current-version>
       </add>
       <add sel="config-template/device-family">
         <device-family>String</device-family>
       </add>
       <add sel="config-template/last-updated-by">
         <last-updated-by>String</last-updated-by>
       </add>
       <add sel="config-template/last-update-time">
         <last-update-time>String</last-update-time>
       </add>
       <add sel="config-template/config-template-definition">
         <config-template-definition
           href="/api/space/config-template-management/config-template-definitions/{id}" />
       </add>
       <add sel="config-template/configuration">
         <configuration
           href="/api/space/config-template-management/config-templates/{id}/configuration">
           <id>Integer</id>
         </configuration>
       </add>
       <!-- or -->
       <remove sel="config-template/state" />
       <remove sel="config-template/os-version" />
       <remove sel="config-template/current-version" />
       <remove sel="config-template/device-family" />
       <remove sel="config-template/last-updated-by" />
       <remove sel="config-template/last-update-time" />
       <remove sel="config-template/configuration" />
    </diff>


  • Sample Output XML:
    <config-template
       href="/api/space/config-template-management/config-templates/{id}" uri="/api/space/config-template-management/config-templates/{id}">
       <id>Integer</id>
       <name>String</name>
       <description>String</description>
       <state>String</state>
       <os-version>String</os-version>
       <current-version>Integer</current-version>
       <device-family>String</device-family>
       <last-updated-by>String</last-updated-by>
       <last-update-time>String</last-update-time>
       <config-template-definition
         href="/api/space/config-template-management/config-template-definitions/{id}"
         uri="/api/space/config-template-management/config-templates/{id}">
         <id>Integer</id>
         <name>String</name>
       </config-template-definition>
       <configuration
         href="/api/space/config-template-management/config-templates/{id}/configuration"
         uri="/api/space/config-template-management/config-templates/{id}">
         <id>Integer</id>
       </configuration>
       <exec-audit
         href="/api/space/config-template-management/config-templates/{id}/exec-audit" />
       <exec-deploy
         href="/api/space/config-template-management/config-templates/{id}/exec-deploy" />
       <exec-undeploy
         href="/api/space/config-template-management/config-templates/{id}/exec-undeploy" />
       <device-associations
         href="/api/space/config-template-management/config-templates/{id}/device-associations" />
    </config-template>


  • Sample Output JSON:
    {
       "config-template" : {
         "@href" : "/api/space/config-template-management/config-templates/{id}" ,
         "@uri" : "/api/space/config-template-management/config-templates/{id}" ,
         "id" : "Integer" ,
         "name" : "String" ,
         "description" : "String" ,
         "state" : "String" ,
         "os-version" : "String" ,
         "current-version" : "Integer" ,
         "device-family" : "String" ,
         "last-updated-by" : "String" ,
         "last-update-time" : "String" ,
         "config-template-definition" : {
           "@href" :
           "/api/space/config-template-management/config-template-definitions/{id}" ,
           "@uri" : "/api/space/config-template-management/config-templates/{id}" ,
           "id" : "Integer" ,
           "name" : "String"
         } ,
         "configuration" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/configuration"
           ,
           "@uri" : "/api/space/config-template-management/config-templates/{id}" ,
           "id" : "Integer"
         } ,
         "exec-audit" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/exec-audit"
         } ,
         "exec-deploy" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/exec-deploy"
         } ,
         "exec-undeploy" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/exec-undeploy"
         } ,
         "device-associations" : {
           "@href" :
           "/api/space/config-template-management/config-templates/{id}/device-associations"
         }
       }
    }



DELETE /api/space/config-template-management/config-templates/{id} (v1)


This API deletes a specified configuration template.

Access Control

The following capabilities are required to access this API:
"DeleteTemplate"


Example Usage

DELETE /api/space/config-template-management/config-templates/{id}


Parameters

NameTypeURI TypeDescriptionRequired
idIntegerPathThe ID of the configuration template to delete. Y