setPosForageConfig

open override fun setPosForageConfig(posForageConfig: PosForageConfig)

⚠️ The setPosForageConfig method is only valid for in-store POS Terminal transactions.

Sets the necessary PosForageConfig configuration properties for a ForageElement. setPosForageConfig must be called before any other methods can be executed on the Element.

// Example: Call setPosForageConfig on a ForagePINEditText Element
val posForagePinEditText = root?.findViewById<ForagePINEditText>(R.id.foragePinEditText)
posForagePinEditText.setPosForageConfig(
PosForageConfig(
sessionToken = "<session_token>",
merchantId = "mid/<merchant_id>"
)
)

Parameters

posForageConfig

A PosForageConfig instance that specifies a merchantId and sessionToken.

See also