The following operation is supported on this resource:

  • GET - Get Script details and basic data by ID
GET /scripts/{script-id}/contentsVersion 1

This API finds and returns script details along with basic script data available on Junos Space.

Sample Usage

GET /scripts/{script-id}/contents

  • Parameters:
    NameTypeURI TypeDescriptionRequired
    script-idIntegerPathThe ID of the script to get from Junos Space Y
  • Sample Output XML:
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
          <scriptName>cpu-usage-60.slax</ scriptName>
          <comments>Script is imported for the first time</comments>
          <scriptContents>ns junos .....</scriptContents>
          <collection href="/api/space/script-management/scripts/1114117/results" rel="script verification results"/>

  • Sample Output JSON:
          id: 1114117
          scriptName: cpu-usage-60.slax
          type: TYPE_EVENT
          category: sample
          format: FORMAT_SLAX
          lastestRevision: 1.1
          comments: Script is imported for the first time
          scriptSize: 7520
          scriptContents: ns junos .....
          @href:/api/space/script-management/scripts/ 1114117/results
          @rel:script verification results

  • Access Control

    The following capabilities are required to access this API: ExportScriptsCap