Plugins

Create Your Own Plugin

Plugins are installed in Open MCT by providing a plugin installation function to openmct.install. This function will be invoked on application startup with one parameter — the openmct API object. A common approach used in the Open MCT codebase is to define a plugin as a function that returns this installation function. This allows configuration to be specified when the plugin is included.

An example is provided below :

openmct.install(HelloPlugin({
 who: "World"
}));

function HelloPlugin(config){
 return function(openmctAPI){
  // This defines a new view in Open MCT.
  // A view is typically used as a way to visualize an object or some telemetry.
  // In this case, the view will simply print "Hello <name>."

  openmctAPI.objectViews.addProvider({
   key: 'hello-world',
   name: 'Hello World View',
   // Return true to associate this view with all object types.
   canView(){
    return true;
   },
   view(element){
    element.innerText = 'Hello ' + config.who
   }
  });
 }
}

To learn more about how Open MCT can be extended through plugins, check out our tutorials and API documentation.

Publish Your Plugin

We will leave it up to you to decide where to publish your plugin. We use GitHub, but you may use any source code repository you like. Once your plugin is published, let us know about it and we will add it to the site. All community plugins will be labeled as experimental unless you tell us otherwise

To let us know about a new plugin, please email us the following information:

  • Title
  • Author
  • Description
  • Link
  • Category

eg.

Title: Hello World
Author: John Smith
Description: Outputs "Hello <name>" when provided with a name parameter.
Link: https://github.com/sample-repository-link
Category: telemetry-visualization

You can help us by categorizing your plugin. the Category above can be one of six categories below; for examples of plugins in each category, take a look at our official plugins. Or, if it doesn't fit any of these, make one up and we'll discuss it with you.

  • persistence: plugins that provide persistence for user-created data
  • time: plugins related to the time system
  • telemetry-visualization: plugins that enable new visualizations of telemetry data
  • telemetry-source: plugins that serve as telemetry data sources
  • theme: plugins that define new application themes
  • utility: plugins related to general usage of the application