New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@5minds/node-red-contrib-processcube

Package Overview
Dependencies
Maintainers
0
Versions
404
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@5minds/node-red-contrib-processcube - npm Package Compare versions

Comparing version 1.7.5 to 1.7.6-develop-93925b-m6rm6pxa

3

message-event-trigger.js

@@ -9,2 +9,4 @@ module.exports = function (RED) {

const client = node.engine.engineClient;
const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;

@@ -20,2 +22,3 @@ if (!client) {

payload: msg.payload,
identity: userIdentity
})

@@ -22,0 +25,0 @@ .then((result) => {

2

package.json
{
"name": "@5minds/node-red-contrib-processcube",
"version": "1.7.5",
"version": "1.7.6-develop-93925b-m6rm6pxa",
"license": "MIT",

@@ -5,0 +5,0 @@ "description": "Node-RED nodes for ProcessCube",

@@ -43,4 +43,7 @@ module.exports = function (RED) {

const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const identity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;
client.processDefinitions
.startProcessInstance(startParameters)
.startProcessInstance(startParameters, identity)
.then((result) => {

@@ -47,0 +50,0 @@ msg.payload = result;

@@ -9,2 +9,4 @@ module.exports = function (RED) {

const client = node.engine.engineClient;
const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;

@@ -17,3 +19,3 @@ if (!client) {

client.processInstances
.terminateProcessInstance(msg.payload)
.terminateProcessInstance(msg.payload, userIdentity)
.then(() => {

@@ -20,0 +22,0 @@ node.send(msg);

const engine_client = require('@5minds/processcube_engine_client');
const jwt = require('jwt-decode');
const oidc = require('openid-client');

@@ -5,0 +3,0 @@ module.exports = function (RED) {

@@ -9,2 +9,4 @@ module.exports = function (RED) {

const client = node.engine.engineClient;
const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;

@@ -17,3 +19,3 @@ if (!client) {

client.processDefinitions
.persistProcessDefinitions(msg.payload, { overwriteExisting: true })
.persistProcessDefinitions(msg.payload, { overwriteExisting: true, identity: userIdentity })
.then(() => {

@@ -20,0 +22,0 @@ node.send(msg);

@@ -19,2 +19,6 @@ module.exports = function (RED) {

const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const identity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;
query.identity = identity;
client.processDefinitions

@@ -21,0 +25,0 @@ .getAll(query)

@@ -10,2 +10,5 @@ module.exports = function (RED) {

const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;
if (!client || !client.processInstances) {

@@ -68,3 +71,6 @@ node.error('No engine or processInstances API configured.', msg);

},
{ includeXml: false }
{
includeXml: false,
identity: userIdentity
}
);

@@ -82,3 +88,3 @@

try {
await client.processInstances.deleteProcessInstances(ids, true);
await client.processInstances.deleteProcessInstances(ids, true, userIdentity);
msg.payload.successfulDeletions.push(...ids);

@@ -85,0 +91,0 @@ sumSuccessful += ids.length;

@@ -11,2 +11,4 @@ module.exports = function (RED) {

const client = node.engine.engineClient;
const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;

@@ -19,3 +21,3 @@ if (!client) {

client.processInstances
.query(query)
.query(query, { identity: userIdentity })
.then((matchingInstances) => {

@@ -22,0 +24,0 @@ msg.payload = matchingInstances;

@@ -28,9 +28,15 @@ # ProcessCube Node-RED Integration

3. Build the Docker containers:
3. Install the dependencies of the package `@5minds/node-red-contrib-processcube`:
```bash
npm install
```
4. Build the Docker containers:
```bash
docker-compose build
```
4. Start the Docker containers:
5. Start the Docker containers:

@@ -37,0 +43,0 @@ ```bash

@@ -10,2 +10,4 @@ module.exports = function (RED) {

const client = node.engine.engineClient;
const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;

@@ -21,2 +23,3 @@ if (!client) {

payload: msg.payload,
identity: userIdentity
})

@@ -23,0 +26,0 @@ .then((result) => {

@@ -10,2 +10,4 @@ module.exports = function (RED) {

const client = node.engine.engineClient;
const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;

@@ -20,3 +22,3 @@ if (!client) {

client.userTasks
.query(query)
.query(query, {identity: userIdentity})
.then((matchingFlowNodes) => {

@@ -23,0 +25,0 @@ if (config.sendtype === 'array') {

@@ -20,2 +20,4 @@ module.exports = function (RED) {

const client = node.engine.engineClient;
const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;

@@ -28,3 +30,3 @@ if (!client) {

client.userTasks
.finishUserTask(flowNodeInstanceId, userTaskResult)
.finishUserTask(flowNodeInstanceId, userTaskResult, userIdentity)
.then(() => {

@@ -31,0 +33,0 @@ node.send(msg);

@@ -13,2 +13,4 @@ module.exports = function (RED) {

const client = node.engine.engineClient;
const isUser = !!msg._client?.user && !!msg._client.user.accessToken;
const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;
subscribe = async () => {

@@ -29,7 +31,7 @@ if (!client) {

try {
const matchingFlowNodes = await client.userTasks.query(newQuery);
const matchingFlowNodes = await client.userTasks.query(newQuery, {identity: userIdentity});
if (matchingFlowNodes.userTasks && matchingFlowNodes.userTasks.length == 1) {
// remove subscription
client.userTasks.removeSubscription(subscription);
client.userTasks.removeSubscription(subscription, userIdentity);

@@ -46,2 +48,4 @@ const userTask = matchingFlowNodes.userTasks[0];

}
},{
identity: userIdentity,
});

@@ -59,3 +63,3 @@

try {
const matchingFlowNodes = await client.userTasks.query(suspendedQuery);
const matchingFlowNodes = await client.userTasks.query(suspendedQuery, {identity: userIdentity});

@@ -69,3 +73,3 @@ if (matchingFlowNodes.userTasks && matchingFlowNodes.userTasks.length >= 1) {

// remove subscription
client.userTasks.removeSubscription(subscription);
client.userTasks.removeSubscription(subscription, userIdentity);
} else {

@@ -72,0 +76,0 @@ // let the *currentIdentity* be active

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc