> ## Documentation Index
> Fetch the complete documentation index at: https://developers.kit.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Automation nodes plugin flow

> Example flow for the automation node plugin

We offer 2 types of automation node plugins, events and actions. Below highlights an example flow for each node type.

<AccordionGroup>
  <Accordion title="Event node">
    Let’s say you were developing an app that allowed users to trigger an
    automation event from your app when a subscriber makes a purchase on your
    system. The full flow would look like this:

    <Steps>
      <Step title="Create the request URL">
        You create a POST endpoint on your server to generate a list of
        subscribers that have made a purchase on your system. *Details on
        configuring the `request URL` [can be found
        here](/plugins/automation-nodes/plugin-configuration#request-url).*
      </Step>

      <Step title="Create the search products endpoint">
        *Optional* - You create a POST endpoint on your server to allow users to
        search and select the products they want the event to fire for. This is
        only necessary if you add a [search
        input](/plugins/automation-nodes/plugin-settings#search-input), because
        we need to retrieve the results from somewhere.
      </Step>

      <Step title="Create & publish your app">
        You [create your app within Kit](https://app.kit.com/apps?is=created)
        and [configure the *Product purchased*
        plugin](/plugins/automation-nodes/plugin-configuration). Once your app
        and plugin are ready, you submit your app for approval and publish.
      </Step>

      <Step title="Creator installs your app">
        A Kit user installs your app, triggering and completing your plugin's
        OAuth authentication flow.
      </Step>

      <Step title="Creator searches for your Product plugin and adds to their VA">
        The Kit user navigates to a visual automation and creates a new event or
        entry node. They then select your app from the menu, followed by your
        *Product purchased* plugin from the menu that follows to add it. They
        can decide at this point to also add any additional configuration such
        as selecting specific products if configured by the app.
      </Step>

      <Step title="Kit polls request URL for new subscriber events">
        Upon adding the plugin to the visual automation and setting it live, Kit
        will make a request to the endpoint found in step 1, approximately every
        5 minutes, along with the values from the configuration settings
        selected by the creator and access tokens to ensure authentication with
        your servers.
      </Step>

      <Step title="Return the subscribers">
        You will respond to the request, returning a cursor-paginated array of
        subscribers that adhere to all of the setting values selected by the
        creator (such as product selected). At this point we will bring all
        relevant, upstream subscribers to this node, from which they will
        continue their journey within the automation.
      </Step>
    </Steps>
  </Accordion>

  <Accordion title="Action node">
    Let’s say you were developing an app where you want to allow users to take
    an action in your app whenever a set of preconditions is met. The full flow
    would look like this:

    <Steps>
      <Step title="Create the request URL">
        You create a POST endpoint on your server to receive a list of
        subscribers to act on. *Details on configuring the `request URL` [can be
        found
        here](/plugins/automation-nodes/plugin-configuration#request-url).*
      </Step>

      <Step title="Create & publish your app">
        You [create your app within Kit](https://app.kit.com/apps?is=created)
        and [configure your
        plugin](/plugins/automation-nodes/plugin-configuration). Once your app
        and plugin are ready, you submit your app for approval and publish.
      </Step>

      <Step title="Creator installs your app">
        A Kit user installs your app, triggering and completing your plugin's
        OAuth authentication flow.
      </Step>

      <Step title="Creator searches for your plugin and adds to their VA">
        The Kit user navigates to a visual automation and creates a new event or
        entry node. Then they add an action node. They select your app from the
        menu, followed by your plugin from the menu that follows to add it. They
        can decide at this point to also add any additional configuration that
        you set up in your plugin settings.
      </Step>

      <Step title="Kit polls request URL with subscribers">
        Upon adding the plugin to the visual automation and setting it live, Kit
        will make a request to the endpoint found in step 1, whenever
        subscribers are moving through the automation (at most every 5 minutes),
        along with the values from the configuration settings selected by the
        creator and access tokens to ensure authentication with your servers.
      </Step>

      <Step title="Return the subscribers">
        You will respond to the request, returning an object with successes and
        failures. Each being an array of actions with subscriber data. At this
        point we will progress the succeeded subscribers to the next node, from
        which they will continue their journey within the automation.
      </Step>
    </Steps>
  </Accordion>
</AccordionGroup>
