Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support
Skip to main content
The Vega APS Client API is a bridge between React Native for Vega apps and the native code implementation for the Amazon Publisher Services(APS). The API provides the getDeviceParams() method to fetch the required parameters for your bid request. You send these parameters to APS via C2S (Client-to-Server) or S2S (Server-to-Server) integration to complete the request.
This user guide explains APS client library installation and API usage.

Remarks

APS offers publishers two distinct integration paths on the KeplerTV platform. These integrations allow publishers to submit bid request to fill their ad break inventory. S2S Integration: Publishers retrieve APS key value pairs using an S2S back-end call that returns the bid information to pass to the publisher ad server. You can only call the server only from your server. APS doesn’t support client-side calls. The call parameters are: C2S Integration: Publishers use a C2S call that returns the bid information to pass to the publisher ad server as of custom key values. You can only call the server from your app, APS supports server-side calls with this endpoint. The call parameters are: For more information, see the S2S integration guide.

Get Started

Prerequisites

Before you begin, make sure you have installed the Vega SDK and created your own React Native for Vega app. Additionally, you need to have followed either the C2S or S2S integration guide to complete the cloud side onboarding and you should understand how payload creation works.

Setup

  1. Add the following library dependency to the dependencies section of your package.json file.
  1. Add the following component and privilege in your manifest.toml.

Usage

Step 1: Import the required components

To use the APS API, import the required components from @amazon-devices/kepler-aps-client.

Step 2: Get the device paramaters

ApsClientLibraryAPI.getDeviceParams() is asynchronous and returns a Promise thay you can wait on using an await or then() construct. On success, the payload of the Promise is a mapping of ApsDeviceParametersMap which contains keys from Required Parameters to their respective values. On error, the Promise is rejected with an error message. The recommended way to use the function is to call it when the app loads and cache the returned value. This example assumes it’s Server-to-Server (S2S) integration pass ApsIntegrationType.C2S instead if it’s a C2S integration. The example demonstrates handling both success and error cases using the then() construct.

Check Required Parameters

Besides the device parameters retrieved from the API, also capture the IP from the HTTP request sent to the server. Include it as part of the request payload. Refer to the Required Parameters table below for more information.

Complete the payload

Complete the JSON payload creation for a HeaderBidding request and makes an HTTPS request following the remaining cloud interactions based on either the C2S or S2S integration guides.

Required Parameters

Modules


Last modified on October 2, 2025