
Security News
Package Maintainers Call for Improvements to GitHub’s New npm Security Plan
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
pipedream-step-utils
Advanced tools
A collection of features that can be useful in Pipedream steps.
The best way to include Pipedream Step Utils on Pipedream is to type within each single step where it should be used:
const PipedreamStepUtils = require("pipedream-step-utils").default;
const stepUtils = new PipedreamStepUtils(process, event);
If your step necessarily requires some parameters, which must be passed via query, you can use the checkRequiredStepParams
method:
const PipedreamStepUtils = require("pipedream-step-utils").default;
const stepUtils = new PipedreamStepUtils(process, event);
const requiredParams = ["foo", "bar"];
stepUtils.checkRequiredStepParams(requiredParams);
Will throw an exception if it does not find all required parameters or returns an object with all required parameters and their respective values.
If you want to specify a step to start from in the endpoint (example: https: //myendpoint.m.pipedream.net?step=foo
), you will need to insert the following code in each step of the workflow:
const stepName = params.stepName;
if (stepUtils.skipStep(stepName)) {
console.log(`Skip "${stepName}" step`);
return false;
}
If you want to specify a step at which to stop the endpoint process (for example: https: //myendpoint.m.pipedream.net?stopToStep=foo
), you will need to insert the following code in each step of the workflow:
const stepName = params.stepName;
if (stepUtils.stopToStep(stepName)) {
$end(`Stop to "${stepName}" step`);
}
In this way if the name attributed to the current step (stepName
) is not the one specified in the query (step=foo
) then it will not execute the code contained in it, passing to the next step.
If you need to know the url of the current endpoint you can use the following method:
const PipedreamStepUtils = require("pipedream-step-utils").default;
const stepUtils = new PipedreamStepUtils(process, event);
const currentEnpoint = stepUtils.getCurrentEndpointUrl();
If you need to make a GET request, for example to invoke the same or another workflow asynchronously, you can use the method:
const PipedreamStepUtils = require("pipedream-step-utils").default;
const stepUtils = new PipedreamStepUtils(process, event);
const url = stepUtils.getCurrentEndpointUrl();
await stepUtils.get(url, {
params: {
foo: "bar",
step: "stepFoo",
offset: 10,
limit: 100,
...
},
});
FAQs
A collection of features that can be useful in pipedream steps
We found that pipedream-step-utils demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
Product
Socket Firewall is a free tool that blocks malicious packages at install time, giving developers proactive protection against rising supply chain attacks.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.