Skip to content

Latest commit

 

History

History
27 lines (18 loc) · 929 Bytes

File metadata and controls

27 lines (18 loc) · 929 Bytes

"Request Interceptor" Cockpit Script

This example shows how to intercept requests made by Camunda Cockpit. This might be useful if you need to set additional properties or request headers on all requests made by Cockpit against the rest API.

Built and tested against Camunda Platform version 7.16.0.

Integrate into Camunda Webapp

Copy the requestInterceptor.js file into the app/cockpit/scripts/ folder in your Camunda webapp distribution. For the Tomcat distribution, this would be server/apache-tomcat-X.X.XX/webapps/camunda/app/cockpit/scripts/.

Add the following content to the customScripts object in the app/cockpit/scripts/config.js file:

  // …
  customScripts: [
    'scripts/requestInterceptor'
  ]
  // …

License

Use under terms of the Apache License, Version 2.0