Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

In this article

...

In this example, the HTTP Router uses this JSON document and the REQUEST_METHOD from the Triggered Task as inputs. Based on the incoming value for REQUEST_METHOD (POST in this example), the HTTP Router routes the document to the corresponding output view (output1 in the validated Pipeline above). The Pipeline execution continues further to finally write the formatted JSON output into a JSON file.

Download this Pipeline

Using HTTP Router Snap to Process an Ultra Task

The following example Pipeline demonstrates how you can use an HTTP Router Snap to process an incoming PATCH request through an Ultra Task. 

First, we create an Ultra Task for the HTTP Router Pipeline with a request to send a notification to the patchadmin@snaplogic.com whenever a patch is completed.

Ultra Task for HTTP Router SnapPipeline with HTTP Router Snap

Image Modified

Image Modified

We configure the HTTP Router Snap to route the incoming data to a corresponding view.
Image Modified

When the Ultra Task - Ultra_Task_On_HTTP_Router is run, the corresponding Pipeline - HTTP Router is executed. Based on the HTTP method, the HTTP router routes the data to the corresponding output view (in this example, the patch request routes to output 4). You can further write the formatted JSON output into a JSON file using the File Writer Snap.

Download this Pipeline.

Downloads

Note
titleImportant Steps to Successfully Reuse Pipelines
  1. Download and import the Pipeline into SnapLogic.
  2. Provide Pipeline parameters as applicable.

...