SDKsiOS

Visitor Attributes

Share anonymous visitor signals like age range so Koah can serve more relevant ads.

Set visitor attributes through the Swift API below. See Visitor Attributes for what they are, the privacy posture, the bucket list, and when to clear.

Age range

Set visitor age as an exact value, a custom range, or a predefined bucket—use whichever fits your data and privacy needs. See Age range buckets in the reference for the full list of predefined buckets.

// Pick the bucket closest to the visitor's age
Koah.shared.setAgeRange(.age25To29)

Gender

Koah.shared.setGender(.female)

Accepts .male, .female, or .unknown.

Household income

Pass the visitor's annual household income bracket (thousands of USD):

Koah.shared.setIncomeBracket(.income50kTo100k)

See Gender and income values in the reference for the full bracket list.

Clearing a stored attribute

Pass .unknown to any setter to clear the value stored on this device:

Koah.shared.setAgeRange(.unknown)
Koah.shared.setGender(.unknown)
Koah.shared.setIncomeBracket(.unknown)

Clearing is local only — it stops this device storing and re-sending the value, but does not delete a value already sent to Koah. See Visitor Attributes for when to clear and how values persist across launches.

Was this helpful?