Target filter
Search Kotlin docs
  • Platforms
  • Tealium Prism Kotlin
core/com.tealium.prism.core.api.settings/Mappings/path

path

open fun path(root: String): JsonObjectPath

Utility method to start creating JsonObjectPaths. This method is shorthand for JsonPath.root

For example, using the following DataObject (as Json)

{
"obj": {
"list": [{
"key": "some value"
}]
}
}
Content copied to clipboard

To reference the key "key" the root parameters would be:

path("obj")
.key("list")
.index(0)
.key("key")

// or for Kotlin users only
path("obj")["list"][0]["key"]
Content copied to clipboard

Parameters

root

The root key required to reach a variable contained in nested DataObjects or DataLists

Generated by Dokka
(c) Tealium 2026