$ npm install @adobe/aio-lib-launch
- Initialize the SDK
const sdk = require('@adobe/aio-lib-launch')
async function sdkTest() {
//initialize sdk
const client = await sdk.init('<ims org id>', 'x-api-key', '<valid auth token>')
}
- Call methods using the initialized SDK
const sdk = require('@adobe/aio-lib-launch')
async function sdkTest() {
// initialize sdk
const client = await sdk.init('<ims org id>', 'x-api-key', '<valid auth token>')
// call methods
try {
// get... something
const result = await client.getEnvironment('my-environment-id')
console.log(result)
} catch (e) {
console.error(e)
}
}
- ExperienceLaunchAPI
This class provides methods to call your ExperienceLaunchAPI APIs. Before calling any method initialize the instance by calling the
init
method on it with valid values for imsOrgId, apiKey and accessToken
- init(imsOrgId, apiKey, accessToken) β
Promise.<ExperienceLaunchAPI>
Returns a Promise that resolves with a new ExperienceLaunchAPI object.
- MyParameters :
object
An example of a typed object.
- AnotherThing :
object
Another typed object.
This class provides methods to call your ExperienceLaunchAPI APIs.
Before calling any method initialize the instance by calling the init
method on it
with valid values for imsOrgId, apiKey and accessToken
Kind: global class
- ExperienceLaunchAPI
- .imsOrgId :
string
- .apiKey :
string
- .accessToken :
string
- .init(imsOrgId, apiKey, accessToken) β
Promise.<ExperienceLaunchAPI>
- .getEnvironment(id) β
Promise.<Response>
- .imsOrgId :
The IMS Org Id
Kind: instance property of ExperienceLaunchAPI
The api key from your integration
Kind: instance property of ExperienceLaunchAPI
The access token from your integration
Kind: instance property of ExperienceLaunchAPI
experienceLaunchAPI.init(imsOrgId, apiKey, accessToken) β Promise.<ExperienceLaunchAPI>
Initializes a ExperienceLaunchAPI object and returns it.
Kind: instance method of ExperienceLaunchAPI
Returns: Promise.<ExperienceLaunchAPI>
- a ExperienceLaunchAPI object
Param | Type | Description |
---|---|---|
imsOrgId | string |
the IMS Org Id |
apiKey | string |
the API key for your integration |
accessToken | string |
the access token for your integration |
Get an Environment by Id.
Kind: instance method of ExperienceLaunchAPI
Returns: Promise.<Response>
- the response
Param | Type | Description |
---|---|---|
id | string |
the environment id |
init(imsOrgId, apiKey, accessToken) β Promise.<ExperienceLaunchAPI>
Returns a Promise that resolves with a new ExperienceLaunchAPI object.
Kind: global function
Returns: Promise.<ExperienceLaunchAPI>
- a Promise with a ExperienceLaunchAPI object
Param | Type | Description |
---|---|---|
imsOrgId | string |
the IMS Org Id |
apiKey | string |
the API key for your integration |
accessToken | string |
the access token for your integration |
An example of a typed object.
Kind: global typedef
Properties
Name | Type | Description |
---|---|---|
optionA | string |
some option |
optionB | string |
another option |
Another typed object.
Kind: global typedef
Properties
Name | Type | Description |
---|---|---|
mayBeSomething | boolean |
an option |
LOG_LEVEL=debug <your_call_here>
Prepend the LOG_LEVEL
environment variable and debug
value to the call that invokes your function, on the command line. This should output a lot of debug data for your SDK calls.
Contributions are welcome! Read the Contributing Guide for more information.
This project is licensed under the Apache V2 License. See LICENSE for more information.