1.3.1 • Published 12 days ago

@flatfile/plugin-webhook-egress v1.3.1

Weekly downloads
-
License
ISC
Repository
github
Last release
12 days ago

The @flatfile/plugin-webhook-egress plugin egresses Flatfile Workbooks to a webhook.

Event Type: listener.on('{jobParam}') (i.e. listener.on('workbook:submitActionFg'))

Parameters

job - string - (required)

The job parameter takes the job name.

webhookUrl - string

The webhookUrl parameter takes the webhook url.

Usage

The webhookEgress plugin creates an action that will export workbook data via a webhook. It requires an operation parameter which specifies the event that will initiate the egress. The webhook url can either be passed in as a parameter or set as an environment variable WEBHOOK_SITE_URL.

Install

npm i @flatfile/plugin-webhook-egress

Import

import { webhookEgress } from "@flatfile/plugin-webhook-egress";

workbook_actions_primary

workbook.config.json

  // ... inside Workbook configuration
  "actions": [
    {
      operation: 'submitActionFg',
      mode: 'foreground',
      label: 'Send to...',
      type: 'string',
      description: 'Submit this data to a webhook.',
      primary: true,
    }
  ]
  // ...

listener.js

// Using the WEBHOOK_SITE_URL environment variable
listener.use(webhookEgress("workbook:submitActionFg"));

// Passing the webhook url as a parameter
listener.use(webhookEgress("workbook:submitActionFg", "https://webhook.site/...""));
1.3.1

12 days ago

1.3.0

19 days ago

1.2.7

1 month ago

1.2.6

1 month ago

1.2.5

1 month ago

1.2.4

2 months ago

1.2.3

2 months ago

1.2.2

3 months ago

1.2.1

3 months ago

1.2.0

3 months ago

1.1.2

3 months ago

1.1.1

4 months ago

1.1.0

4 months ago

1.0.0

5 months ago

0.1.5

6 months ago

0.1.4

7 months ago

0.1.3

8 months ago

0.1.2

8 months ago

0.1.1

8 months ago

0.1.0

8 months ago

0.0.1

8 months ago