Target filter
Search Kotlin docs
  • Platforms
  • Tealium Prism Kotlin
core/com.tealium.prism.core.api.data/JsonObjectPath

JsonObjectPath

typealias JsonObjectPath = JsonPath<JsonPath.Component.Key>

A JsonPath that can be applied to a JSON object to represent the path to a potentially nested value. Nested items can be in both JSON objects and JSON arrays.

To create a basic JsonObjectPath you can call JsonPath.root with a String.

JsonPath.root("container")

// or for Kotlin users only
JsonPath["container"]
Content copied to clipboard

To create a path like container.array[0].property you can use either JsonPath.key or JsonPath.index for each subsequent path component.

JsonPath.root("container")
.key("array")
.index(0)
.key("property")

// or for Kotlin users only
JsonPath["container"]["array"][0]["property"]
Content copied to clipboard
Generated by Dokka
(c) Tealium 2026