This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
bw:bizweaver_api [2019/05/01 14:56] runger [Bizweaver Action Target String Samples] |
bw:bizweaver_api [2020/07/23 11:26] (current) |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ======Bizweaver API====== | ||
| Bizweaver has its own API that can be used in a variety of ways. This is a directly-called API and does not currently use REST as the communication mechanism. | Bizweaver has its own API that can be used in a variety of ways. This is a directly-called API and does not currently use REST as the communication mechanism. | ||
| - | The two most common uses are to invoke a Bizweaver workflow from a Versago form (or report), and to have one workflow call another workflow. | + | The two most common uses are to invoke a Bizweaver workflow from a Versago form or report, and to have one workflow call another workflow. |
| - | To use the API within | + | To initiate another workflow |
| - | <WRAP center round important | + | <WRAP center round tip 80%> |
| + | Processes beginning with v2.4 should always use POST. Processes from older versions that used GET should be converted to POST as soon as possible. | ||
| + | </ | ||
| + | <WRAP center round important | ||
| + | A token must be generated in order to use the POST processes described below. | ||
| + | </ | ||
| + | <WRAP center round important 80%> | ||
| Use caution when connecting multiple workflows in a sequence. | Use caution when connecting multiple workflows in a sequence. | ||
| </ | </ | ||
| - | The Bizweaver API can be used with any tool that can send a URL. For example, you might create a small VBScript for a specific user to let them execute a workflow on demand. | ||
| - | ===== Bizweaver Action Target String | + | =====Call Another Workflow Using POST===== |
| + | When a Bizweaver workflow is called (initiated) using POST, the configuration of the WebService2 tool involves two sections: the URI and the Body. An example is shown below. | ||
| - | The Action String to invoke a Bizweaver workflow is shown below. | + | {{ : |
| - | http: | ||
| - | The elements in <color # | ||
| - | | + | |
| - | - The port assigned to the Bizweaver web service when the application was installed. | + | * Remember that you will need to use HTTP or HTTPS depending on your environment. |
| - | - The Bizweaver workflow ID to be invoked. This can be found in Bizweaver and will always be numeric. | + | |
| - | | + | |
| - | - Value(s) to be passed to Bizweaver. | + | * Enter " |
| - | - If value(s) are not being passed to Bizweaver, | + | * Select |
| - | - If the value is a value from the form, use the Column Name from the form enclosed in tilde symbols (~) as shown. | + | * Enter the appropriate values in the "Body Information" |
| - | - If the value is static | + | |
| - | - In both cases the value being passed is enclosed in single quotes. | + | |
| - | - If multiple values need to be sent to Bizweaver, separate each pair of values (steps 5 and 6) by a comma. See sample 3 in the next section. | + | |
| - | ===== Bizweaver Action Target String Samples ===== | ||
| - | Example using HTTP to port 8082 on server “TWBSTestserver.demo.com”, | + | <WRAP center round tip 60%> |
| - | < | + | Finding the proper |
| - | http://TWBSTestserver.demo.com:8082/ | + | </ |
| + | |||
| + | Here is a sample of the full URL. Copy and paste this string as a starting point. | ||
| + | |||
| + | < | ||
| + | https://MyPortal.MyCompany.com:443/ | ||
| </ | </ | ||
| - | Example using HTTPS to port 443 on server “TWBSTestserver.demo.com”, | + | < |
| - | < | + | { |
| - | https:// | + | "pTaskID":" |
| + | "pArguments": | ||
| + | | ||
| + | " | ||
| + | " | ||
| + | } | ||
| + | } | ||
| </ | </ | ||
| - | Example using HTTP to port 8082 on server “TWBSTestserver.demo.com,” invoking workflow ID 10, and sending two values; one from form control name “vgoRecNum” to a Bizweaver variable named “vgoRecNum” and a static value “TextString” to a Bizweaver | + | * **NN** is the ID of the workflow being called. |
| - | <code html> | + | * **Arguments** (parameters) are any values being passed |
| - | http:// | + | * Arguments are always sent in pairs. Each paid is separated by a colon **:** as shown. |
| + | * The argument (Arg1, Arg2, etc.) is the variable name expected by the workflow being called. | ||
| + | * Variable names are case-sensitive. | ||
| + | * Values are the value being passed. | ||
| + | * Text and dates are enclosed in double-quotes. | ||
| + | * Numeric values do not require double-quotes. | ||
| + | * "pArguments" is required even if no values are being passed. | ||
| + | |||
| + | <code json> | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | } | ||
| </ | </ | ||