/api/space/schema-service/upload-tgz-schema-file

The following operation is supported on this resource:

  • POST - Upload .tgz schema file to the Junos Space server
POST /upload-tgz-schema-file Version 1

This API uploads a tgz schema file to the Junos Space server to be, subsequently, used for schema installation. The schema file is passed to the REST API as a multipart/form-data binary and the API returns the schema-location on the server where the file was copied to, along with the device-family and JunOS release. This schema location must then be passed to the /api/space/schema-service/install-schemas API, in order to install the schema on Space.

Sample Usage

POST /upload-tgz-schema-file


  • Sample Output XML:
    <schemas total="1" uri="/api/space/schema-service/upload-tgz-schema-file">
         <schema>
               <device-family>junos</device-family>
               <schema-location>/tmp/cmp.SchemaManager_1492700917176</schema-location>
               <release>11.4R2.19</release>
         </schema>
    </schemas>

  • Sample Output JSON:
    {
       "schemas" : {
         "@total" : "1" ,
         "@uri" : "/api/space/schema-service/upload-tgz-schema-file" ,
         "schema" : [
           {
             "device-family" : "junos" ,
             "schema-location" : "/tmp/cmp.SchemaManager_1492700917176" ,
             "release" : "11.4R2.19"
           }
         ]
       }
    }

  • Access Control

    The following capabilities are required to access this API: UpdateDMISchema