Get a date string N days ago
@dylburger
code:
data:privatelast updated:2 years ago
today
Build integrations remarkably fast!
You're viewing a public workflow template.
Sign up to customize, add steps, modify code and more.
Join 800,000+ developers using the Pipedream platform
steps.
trigger
HTTP API
Deploy to generate unique URL
This workflow runs on Pipedream's servers and is triggered by HTTP / Webhook requests.
steps.
get_iso_string_n_days_ago
Returns an ISO string (UTC TZ) N days ago
params
N Days Ago
1
string ·params.days
code
async params => {
1
2
3
}
4
const moment = require("moment")
this.date = moment().subtract(params.days, "days").toISOString();