Important to note: This is an experimental feature.

Plugins enhance and extend the capabilities of your Blnk Ledger by providing additional features and functionalities tailored to meet your needs. In this guide, you’ll learn all about plugins, and how to install and run the plugin on your computer.

Just like the Blnk Ledger, Plugins are also open-source. You can develop your own plugins for your project, but we require you to publish it on the Blnk Plugin public repository to be able to run them on your project using the Blnk CLI.

Installation

To install a plugin, run this command in your terminal

blnk install <pluginName>

You can find the name of the plugin file in the Blnk Plugin public repository.

Basic commands

There are 4 basic commands that you can use to manage your installed plugins.

1

Run plugin

blnk run <pluginName>

This command manually runs the plugin for you in the terminal.

When you run a plugin on a connected instance from your computer, the plugin is run on where the instance is hosted on.

2

Update plugin

blnk update-plugin <pluginName>

This command updates the plugin to its latest version, if any.

3

List installed plugins

blnk list-plugins

This command shows you a list of all your installed plugins and their basic information.

4

Delete plugin

blnk delete-plugin <pluginName>

This command deletes a plugin from your list of installed plugin.

Practical example

In this example, we’ll install the “Hello World” sample plugin. This plugin simply prints “Hello World” once it is run.

1

Install the hello-world plugin

command
blnk install hello-world

When it’s done, you get the following:

response
✔ Plugin hello-world installed successfully.
Warning: Plugin hello-world is not verified by Blnk. Use with caution.

While everyone is welcome to publish their plugins and contribute to Blnk’s open-source plugin directory, all plugins will go through an internal review process to verify their safety and ensure the security of our customers’ ledgers.

The warning sign is shown when the plugin has not yet been verified by the Blnk team.

2

Run the command

command
blnk run hello-world

Here’s the response you get:

response
⠋ Running plugin hello-world...Hello World Plugin initialized
Hello World Plugin executed with event data: http://localhost:5001
✔ Plugin hello-world executed successfully.

Need help?

Are you stuck? Do you have a question that isn’t answered in this doc? Have you run into a problem you can’t solve? Want to file a bug report?

Join our Discord server and share your questions/thoughts with other developers building financial applications like you.

Was this page helpful?