init(json: Data) throws
Parses JSON text.
Data
The value as JSON text, with sorted keys.
profile as a JSONValue:
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Any JSON value, for Rollup results without a fixed shape.
public enum JSONValue: Codable, Hashable, Sendable {
case null
case bool(Bool)
case number(Double)
case string(String)
case array([JSONValue])
case object([String: JSONValue])
}
profile as a JSONValue:
let schema: JSONValue = .object([
"type": .string("object"),
"properties": .object([
"home_city": .object(["type": .string("string")])
])
])
let profile = try await Rollup.shared.profile(schema: schema)
