Builder

Builder for creating AdParam instances.

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
fun addCustomParam(key: String, value: String): <Error class: unknown class>

Adds a single custom parameter. Contact NAM admin before using this.

Link copied to clipboard
fun addKeyword(keyword: String): <Error class: unknown class>

Adds a single keyword for ad targeting. Contact NAM admin before using this.

Link copied to clipboard
fun addPrebidParam(key: String, value: String): <Error class: unknown class>

Adds a single prebid parameter for header bidding.

Link copied to clipboard
fun addRewardCustomParam(key: String, value: String): <Error class: unknown class>

Adds a single custom parameter for rewarded ad callback. Contact NAM admin before using this.

Link copied to clipboard
fun build(): AdParam

Builds and returns an AdParam instance with the configured parameters.

Link copied to clipboard
fun setAdUnitId(adUnitId: String): <Error class: unknown class>

Sets the ad unit ID. This is mandatory for ad requests.

Link copied to clipboard
fun setApsParam(gfpApsAdParam: GfpApsAdParam): <Error class: unknown class>

Sets the Amazon Publisher Services (APS) ad parameter.

Link copied to clipboard
fun setContentInfo(contentInfo: GfpContentInfo): <Error class: unknown class>

Sets content information for contextual ad targeting.

Link copied to clipboard
fun setCurrentPageUrl(currentPageUrl: String): <Error class: unknown class>

Sets the current page URL where the ad will be displayed.

Link copied to clipboard
fun setCustomParam(customParam: Map<out String?, String?>): <Error class: unknown class>

Sets custom parameters for targeting. Contact NAM admin before using this.

Link copied to clipboard
fun setKeywords(keywords: Set<String?>): <Error class: unknown class>

Sets keywords for ad targeting. Contact NAM admin before using this.

Link copied to clipboard
fun setPrebidParam(prebidParam: Map<out String?, String?>): <Error class: unknown class>

Sets prebid parameters for header bidding.

Link copied to clipboard
fun setRefererPageUrl(refererPage: String): <Error class: unknown class>

Sets the referer page URL that led to the current page.

Link copied to clipboard
fun setRewardCustomParam(rewardCustomParam: Map<out String?, String?>): <Error class: unknown class>

Sets custom parameters for rewarded ad callback. Contact NAM admin before using this.

Link copied to clipboard
fun setUserToken(userToken: String): <Error class: unknown class>

Sets the user token for rewarded ad callback verification.

Link copied to clipboard
fun setVcl(vcl: Long): <Error class: unknown class>

Sets the video content length in milliseconds. This is the length of the main video content, not the ad itself.

Link copied to clipboard
fun setVri(vri: String): <Error class: unknown class>

Sets the video request ID for tracking individual video ad requests.

Link copied to clipboard
fun setVrr(vrr: Int): <Error class: unknown class>

Sets whether a reminder ad is needed for this video request.

Link copied to clipboard
fun setVsd(vsd: Long): <Error class: unknown class>

Sets the video start delay in milliseconds before the ad begins playback.

Link copied to clipboard
fun setVsi(vsi: String): <Error class: unknown class>

Sets the video schedule ID for grouping related video ad requests. Contact NAM admin before using this.