Summary
          Translate XPaths to FAML
          Description
          Translate XPath expressions to FAML
          Route
          POST /smart_template/xpaths/to/faml
          Roles
          
            admin
          
          Parameters
          
            DetailsExampleSchema
          
          
            
              
                | Name | Type | Required | Description | 
            
            
              
    | xpaths | object | yes | Array of objects that contain xpath expressions and values | 
            
          
          
            Copied to Clipboard
            
            {
  "xpaths": [
    {
      "xpath": "/ncs:devices/ncs:device[ncs:ncs:name='os']/ncs:config/ios:hostname itential.com",
      "value": "HMBYjPpYQN",
      "ruleId": "0374529a-221a-ff2b-cb69-a86ef47488c5"
    },
    {
      "xpath": "/ncs:devices/ncs:device[ncs:ncs:name='os']/ncs:config/ios:hostname itential.com",
      "value": "CXuLfxywY",
      "ruleId": "0ac49523-ed85-d43d-1b8a-e00682162681"
    },
    {
      "xpath": "/ncs:devices/ncs:device[ncs:ncs:name='os']/ncs:name",
      "value": "SgZp",
      "ruleId": "7ed84e6c-ccc4-9e32-f26f-92b404a12b18"
    },
    {
      "xpath": "/ncs:devices/ncs:device[ncs:ncs:name='os']/ncs:config/ios:hostname itential.com",
      "value": "JUOSyEtcaW",
      "ruleId": "da225d29-6f06-4c9c-6439-f959fdb00efd"
    },
    {
      "xpath": "/ncs:devices/ncs:device[ncs:ncs:name='os']/ncs:name",
      "value": "tPdq",
      "ruleId": "23223d41-5b0c-61f1-5b7c-6d6e88ab6ecd"
    }
  ]
}
           
          
            Copied to Clipboard
            
            {
  "type": "object",
  "properties": {
    "xpaths": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "xpath": {
            "type": "string",
            "enum": [
              "/ncs:devices/ncs:device[ncs:ncs:name='os']/ncs:config/ios:hostname itential.com",
              "/ncs:devices/ncs:device[ncs:ncs:name='os']/ncs:name"
            ]
          },
          "value": {
            "type": "string",
            "pattern": "[A-Za-z]+"
          },
          "ruleId": {
            "type": "string",
            "pattern": "^[0-9a-f]{8}(-[0-9a-f]{4}){3}-[0-9a-f]{12}$"
          }
        },
        "required": [
          "xpath",
          "value",
          "ruleId"
        ]
      }
    }
  },
  "required": [
    "xpaths"
  ],
  "additionalProperties": false
}
           
          Return
          
            DetailsExampleSchema
          
          
            
              
                | Name | Type | Description | 
            
            
              
                | config | object | Pronghorn Config object | 
            
          
          
            Copied to Clipboard
            
            "\"ios:hostname\": { \"_attr\": {\"type\": \"leaf\",\"ns\": \"http://tail-f.com/ns/ncs\", \"prefix\": \"ios\", \"xpath\": \"/ncs:devices/ncs:device[ncs:name='os']/ncs:config/ios:hostname\", \"condition\": \"must\", \"severity\": \"error\" }, \"_value\": \"itential.com\" }"
           
          
            Copied to Clipboard
            
            {
  "type": "string",
  "enum": [
    "\"ios:hostname\": { \"_attr\": {\"type\": \"leaf\",\"ns\": \"http://tail-f.com/ns/ncs\", \"prefix\": \"ios\", \"xpath\": \"/ncs:devices/ncs:device[ncs:name='os']/ncs:config/ios:hostname\", \"condition\": \"must\", \"severity\": \"error\" }, \"_value\": \"itential.com\" }"
  ]
}