Webhook Tests
A WebhookTest is an object that can be sent to your Webhook endpoint for connection and response tests.
Create Webhook Test
Command
files-cli webhook-tests create
Output
Outputs a WebhookTest object according to the output format.
Authorization Requirement
Requires either a Site-Wide API key or User API key or session from a User with Folder Admin permissions.
Flags
| Flag | Description |
|---|---|
| --url= string Required | URL for testing the webhook. |
| --method= string | HTTP method(GET or POST). |
| --encoding= string | HTTP encoding method. Can be JSON, XML, or RAW (form data). |
| --headers= object | Additional request headers. |
| --body= object | Additional body parameters. |
| --raw-body= string | raw body text |
| --file-as-body boolean | Send the file data as the request body? |
| --file-form-field= string | Send the file data as a named parameter in the request POST body |
| --use-dedicated-ips boolean | Use dedicated IPs for sending the webhook? |
The WebhookTest Object
Some of the commands above return a WebhookTest object. The attributes of this object are listed below.
| Attribute | Description |
|---|---|
| code int64 | Status HTTP code |
| message string | Error message |
| status string | Status message |
| data Auto | Additional data |
| success boolean | The success status of the webhook test |