Send overdue features to Slack


How to apply this rule?


Warning: sample URLs!

Please make sure to replace with your Slack Webhook URL and with your Targetprocess URL

    "type": "source:schedule",
    "schedule": {
      "kind": "interval",
      "unit": "hour",
      "value": 24
    "type": "action:JavaScript",
    "script": "const api = context.getService(\"targetprocess/api/v2\");\n\n//get the list of overdue features\nconst features = await api.queryAsync(\"Feature\", {\n  select: \"{id, name}\",\n  where: `plannedEndDate < dateTime.parse('${args.fireTime}') and endDate == null`\n});\n\n//IMPORTANT: Change the account name below\nconst featureLinks = => {\n  return `<${}|${}>`;\n});\n\n//IMPORTANT: Update Slack link below\nreturn {\n  command: \"SendHttpRequest\",\n  payload: {\n    url: \"\",\n    body: {\n      text: `Overdue features:\\n ${featureLinks.join('\\n')}`,\n      username: \"TP\"\n    }\n  }\n};"