(Plugin) Authentication

This article will teach you about Stripo Plugin authentication, including how to pass the Plugin ID and Secret Key.

Marina Krivenets avatar
Written by Marina Krivenets
Updated over a week ago

Authentication allows us to get an understanding of details concerning your account and the opportunities/limitations that you have. From the user's side, it allows them to have a real-time connection with our server and understand that everything works as it should.

The Stripo Plugin can't perform any operation without an authentication token.

To authenticate your application with Stripo Plugin Editor, you should call the endpoint, shown in the sample code below, with your PluginId and Secret Key.

POST: /api/v1/auth
Host: https:
Content-Type: application/json
Accept: application/json
Body: {pluginId:YOUR_PLUGIN_ID,secretKey:YOUR_SECRET_KEY,role:PLUGIN_EDITOR_USER_ROLE}
Response: {token:YOUR_AUTH_TOKEN}

Which are available on the "Plugin" details page → "Application Keys":

Plugin configuration contains a parameter called getAuthToken. The plugin calls a function (this parameter value) each time a token is expired to get a new one. You have to implement this method on your side.

The full authentication schema looks like this:

Example of the getAuthToken implementation:

getAuthToken: function(callback) {
   $.ajax({
  type: 'GET',
  url: '/backend/plugin/token',
  contentType: 'application/json; charset=utf-8',
  dataType: 'json',
  success: data => callback(data.token),
  error: error => callback(null)
   });
}

You can see the description of all steps of the schema in our API documentation.


Important to note: Do NOT call Stripo Backend directly from your UI. It is insecure, and your "Secret Key" can be stolen. Keep your "Secret Key" on your back-end, and do not tell anyone it.

Please pay attention that we show only the example of the Authentication process and the real call has to be implemented from your server based on our example.



Thank you for taking the time to read our articles. We hope you will find this information helpful.

If you have any additional questions, please email us at support@stripo.email.

We would be glad to talk with you.


Did this answer your question?