List the offers of an App
GET
/apps/{appId}/offers
const url = 'https://api.passion.io/v1/apps/example/offers';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.passion.io/v1/apps/example/offersParameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”appId
required
The id of the App, as Studio shows it.
string
Responses
Section titled “Responses”OK
Media typeapplication/json
object
offers
required
Array<object>
object
id
required
string
name
required
string
benefits
required
What the offer gives, in the creator’s words and order.
Array<string>
price
required
recurring
required
True when members pay again every billing period.
boolean
access
required
Public: every member of the App gets it when they sign in, free. Restricted: members buy it.
string
availability
required
object
native
required
Sold inside the iOS and Android apps.
boolean
web
required
Listed in the web price list of the App.
boolean
products
required
What the offer gives access to. A course id here is the id the course list answers.
Array<object>
object
id
required
string
type
required
string
Example
{ "offers": [ { "billingPeriod": "OneWeek", "trialPeriod": "ThreeDays", "access": "Public", "products": [ { "type": "Course" } ] } ]}