Getting Started
If you are looking to integrate Annoto as a widget without influencing website layout, as an overlay on top your existing video player, you are in the right place :)
At the moment we support the following players:
  • Wistia
  • YouTube
  • Vimeo
  • Kaltura
  • JwPlayer
  • VideoJS
  • FlowPlayer
  • H5P
  • OpenEdx
  • HTML5
  • Custom Player

Setup

Simply add the following script:
<script src="https://cdn.annoto.net/widget/latest/bootstrap.js"></script>
And bootstrap Annoto with the desired Application configuration:
<script>
// Minimal Application configuration
var config = {
/* set to your client id after registration. */
clientId: '',
widgets: [
{
player: {
/* type of the player */
type: 'youtube',
/* DOM element or DOM query selector of the player */
element: '#player-element'
}
}
],
};
window.Annoto.boot(config);
</script>
If you are using a javascript module loader such as RequireJS. Annoto exposes a standard UMD. For example for requireJS:
requirejs(["https://cdn.annoto.net/widget/latest/bootstrap.js"], function(Annoto) {
//This function is called when annoto-bootstrap.js is loaded.
Annoto.boot(config);
});

Configuration

Annoto application providers flexibility in how it integrates in the website. For full configuration options, please refer to the Config Reference. Annoto API Typescript interfaces is available via the @annoto/widget-api package.

Using the API

Annoto application exposes an API. To get access to the API use the "ready" event.
For example to load new application configuration attaching the widget to new dynamically loaded video, or just switching to another video on the page:
Typescript
Javascript
import { Annoto, IAnnotoApi, IConfig } from '@annoto/widget-api';
interface Global extends Window {
Annoto: Annoto;
}
const global = window as Global;
const config: IConfig = {
/* ... */
};
let annotoAPI: IAnnotoApi;
const userToken = '...';
global.Annoto.on('ready', (api: IAnnotoApi) => {
annotoAPI = api;
// Authenticate SSO User
annotoApi.auth(userToken);
});
global.Annoto.boot(config);
function yourTrigger(newConfiguration) {
annotoAPI.load(newConfiguration).then(() => {
console.log('Loaded new Configuration!');
}).catch((err) => {
console.error(err);
});
}
// Application configuration
var config = {
/* ... */
};
var annotoAPI;
var userToken = '...';
window.Annoto.on('ready', function (api) {
annotoAPI = api;
// Authenticate SSO User
annotoApi.auth(userToken);
});
window.Annoto.boot(config);
function yourTrigger(newAnnotoApplicationConfiguration) {
annotoAPI.load(newAnnotoApplicationConfiguration, function(err) {
if (err) {
// error while loading the new configuration
return;
}
console.log('Loaded new Configuration!');
});
}
For full documentation, please refer to the AnnotoApi Reference.

Browser Compatibility

Annoto is compatible with all major evergreen browsers (Edge, Chrome, Mozilla, Safari).
Chrome usually gives best user experience.