This is an internal project. It is only meant to be used by asset-compute-commons.
For Adobe App Builder applications and other components needing to use I/O Events, please use the aio-lib-events library.
This is an internal library of the Adobe Asset Compute SDK. A simple Javascript/NodeJS client for using Adobe I/O Events.
npm install @adobe/asset-compute-events-client
const { AdobeIOEvents } = require('@adobe/asset-compute-events-client');
// setup using necessary credentials
const ioEvents = new AdobeIOEvents({
// access token from an integration/technical account with I/O Events entitlement
accessToken: "ey...",
// organization sending/receiving events
orgId: "6EEF12345678901234567890@AdobeOrg",
defaults: {
providerId: "my_event_provider_id"
}
});
// send an event
return ioEvents.sendEvent({
code: "my_event_type",
payload: {
hello: "world",
date: new Date()
}
});
const { AdobeIOEvents, AdobeIOEventEmitter } = require('@adobe/asset-compute-events-client');
// setup using necessary credentials
const ioEvents = new AdobeIOEvents({
// access token from an integration/technical account with I/O Events entitlement
accessToken: "access...",
});
// receiving events
const ioEventEmitter = new AdobeIOEventEmitter(ioEvents, 'http://journal-url');
ioEventEmitter.on('event', (event) => {
// handle event
})
ioEventEmitter.on('error', (error) => {
// report error
})
IO Events API: https://www.adobe.io/apis/experienceplatform/events/ioeventsapi.html
Contributions are welcomed! Read the Contributing Guide for more information.
This project is licensed under the Apache V2 License. See LICENSE for more information.