Webform Post v2
Web forms submit fields and files with URL-encoded or multipart HTTP request bodies.
Submit URL-encoded and multipart web forms from a Flowgear Workflow and return one normalized response row.
Revision History
0.0.0.1 - Initial release.
0.0.0.2 - Updated the Node icon.
0.0.0.3 - Preserved the complete Connection URL when resolving relative request URLs.
0.0.0.6 - Renamed the Node inputs, outputs, and Connection properties to PascalCase, and added OAuth client credentials, password credentials, and authorization code with PKCE authentication.
Connection
Use this Connection to store a reusable base URL and shared HTTP authentication settings for both form-post methods. Each OAuth Authorization mode keeps its own endpoint, client, scope, and token settings, so switching modes does not overwrite the values saved for another mode.
| Property | Type | Description |
|---|---|---|
Url |
String | Optional base URL used when you supply a relative method Url. The complete path and port are retained. |
Authorization |
Enum | Selects None, Basic, Bearer, OAuthClientCredentials, OAuthPasswordCredentials, OAuthAuthorizationCode, or OAuthAuthorizationCodeWithPkce. The default is None. |
Username |
String | Username used when Authorization is Basic. |
Password |
Masked | Password used when Authorization is Basic. |
BearerToken |
Masked | Token used when Authorization is Bearer. |
AuthUrl |
String | OAuth authorization endpoint used when Authorization is OAuthAuthorizationCode or OAuthAuthorizationCodeWithPkce. |
TokenUrl |
String | OAuth token endpoint used by every OAuth Authorization mode. |
ClientId |
Masked | OAuth client identifier used by every OAuth Authorization mode. |
SecretKey |
Masked | OAuth client secret used by every OAuth Authorization mode. |
Scope |
String | OAuth scopes requested during authentication. |
OAuthUsername |
String | Resource-owner username used when Authorization is OAuthPasswordCredentials. |
OAuthPassword |
Masked | Resource-owner password used when Authorization is OAuthPasswordCredentials. |
AccessToken |
Masked | OAuth access token populated after you connect the account or after the Node obtains a token. |
RefreshToken |
Masked | OAuth refresh token populated when the provider returns one. |
CustomHeaders |
String | Additional headers in Key: Value format, one per line. Do not include Authorization when you also select an authentication mode. |
AuthenticationTestPath |
String | Relative or absolute path used by the Connection test action. |
AuthenticationTestHttpMethod |
Enum | HTTP method used by the Connection test action: Get or Options. The default is Get. |
Return Http Failure Responses |
Boolean | When enabled, HTTP failures and transport errors are returned as normalized response rows instead of being thrown as errors. |
Setup Notes
- Create a Connection when you want to reuse a base URL or shared authentication settings across multiple Workflows.
- Enter an absolute HTTP or HTTPS
Urlon the Connection when the methods will call relative paths such as/submitorresource. - Relative method URLs are appended beneath the complete Connection
Url. The ConnectionUrlis treated as a directory, and one leading/does not discard its path. - Select the
Authorizationmode that matches the upstream form endpoint. Leave it asNonefor anonymous forms. - For
OAuthAuthorizationCodeandOAuthAuthorizationCodeWithPkce, complete the Flowgear connect flow first so theAccessTokenandRefreshTokenare stored on the Connection before runtime calls.OAuthAuthorizationCodeWithPkceprotects the browser redirect with S256 PKCE. - For
OAuthClientCredentialsandOAuthPasswordCredentials, the Node requests an access token fromTokenUrlautomatically when the Connection does not have one yet. - If you want to validate the Connection in the designer, set
AuthenticationTestPathto an authenticated endpoint that can safely handleGetorOptions. The test succeeds only when the endpoint returns a2xxstatus code. - Use
CustomHeadersonly for provider-specific headers. The Node managesAuthorization,Cookie,User-Agent,Content-Type, andContent-Length.
Methods
Both methods submit one HTTP POST request and return one normalized response row.
Post Url Encoded
Use this method when the upstream form expects application/x-www-form-urlencoded data and no file upload is required.
| Parameter | Type | Description |
|---|---|---|
Connection |
Connection | Optional Webform Post Connection with base URL and authentication settings. |
Url |
String | Relative or absolute URL for the target form endpoint. Relative URLs require the Connection Url. If you leave it empty, the Node posts to the Connection Url. |
Request |
Object | Structured request object containing optional Headers, Cookies, UserAgent, and FormFields. |
ReturnBodyAs |
Enum | Choose Text to decode the response body as text or Binary to keep the raw bytes. The default is Text. |
The Request object lets you send form fields by name without building the encoded payload yourself. Header values, cookie values, and field values are sent as supplied.
| Return | Type | Description |
|---|---|---|
StatusCode |
Integer | The upstream HTTP status code, or 0 when no HTTP response was available. |
ResponseHeaders |
Object | The upstream response headers returned by the server. |
ResponseBodyText |
String | The response body as text when ReturnBodyAs is Text. The text is decoded with the server-provided character set, or UTF-8 when none is supplied. |
ResponseBodyBytes |
Byte | The raw response body when ReturnBodyAs is Binary. |
Post Multipart
Use this method when the upstream form expects multipart/form-data and you may need to include one file part.
| Parameter | Type | Description |
|---|---|---|
Connection |
Connection | Optional Webform Post Connection with base URL and authentication settings. |
Url |
String | Relative or absolute URL for the target form endpoint. Relative URLs require the Connection Url. If you leave it empty, the Node posts to the Connection Url. |
Request |
Object | Structured request object containing optional Headers, Cookies, UserAgent, FormFields, and one optional FilePart. |
ReturnBodyAs |
Enum | Choose Text to decode the response body as text or Binary to keep the raw bytes. The default is Text. |
The multipart Request.FilePart object contains Name, FileName, ContentType, and Content. When you supply Content, Name and FileName are required. If you omit ContentType, the Node uses application/octet-stream. If you omit FilePart or leave Content empty, the request is still posted as multipart with only the form fields.
| Return | Type | Description |
|---|---|---|
StatusCode |
Integer | The upstream HTTP status code, or 0 when no HTTP response was available. |
ResponseHeaders |
Object | The upstream response headers returned by the server. |
ResponseBodyText |
String | The response body as text when ReturnBodyAs is Text. The text is decoded with the server-provided character set, or UTF-8 when none is supplied. |
ResponseBodyBytes |
Byte | The raw response body when ReturnBodyAs is Binary. |
Usage Notes
- The Node always emits one response row per invoke. It does not split JSON payloads that contain
items,results, or similar wrappers. - Successful calls return
Status = OK. Emitted failures returnStatus = ERROR, with details inStatusMessageandErrorMessage. ResponseBodyTextis not populated when the response has a non-text content type, such as an image or PDF. UseReturnBodyAs = Binaryfor those responses.- Do not set
Authorization,Cookie,User-Agent,Content-Type, orContent-LengthinRequest.Headers. UseRequest.Cookies,Request.UserAgent, and the Connection authentication settings instead. - Each request times out after 30 seconds.
- The Node only retries automatically for OAuth when the first response is a raw HTTP
401. Provider-specific authentication failures returned as200or403are surfaced without a generic retry. - Use
Return Http Failure Responseswhen you want downstream Workflow logic to branch on failure rows instead of handling thrown errors. - If you need arbitrary HTTP verbs or raw request bodies, use the Web Request Node instead of Webform Post.
Known Issues
- The Node does not preserve a cookie jar across separate invokes. If the upstream form requires a stateful session, you must manage that state outside this Node.