Webhooks
Start an APROS workflow from another system with an inbound webhook, and send HTTP requests from APROS to your system with automation rules.
Webhooks work in two directions in APROS:
- Inbound. Another system calls a URL that APROS gives you, and a published workflow starts with the request body as its input.
- Outbound. An automation rule or a workflow step sends an HTTP request from APROS to a URL you choose when something happens in your workspace.
There is no API for subscribing to events. You set up both directions in the product, in AI Studio, which is part of the AI module.
Inbound webhooks
Set up an inbound webhook
-
Open AI Studio → Workflows and open the workflow that should run, or create one.
-
Add the Webhook trigger to the canvas, or select the existing trigger and set its Trigger Type to Webhook.
-
In HTTP method, choose the method the other system will use:
POST(the default),GET,PUTor Any method. -
Optional: under Header authentication, choose Static header and fill in Header name and Header value if the calling system can send a fixed header. This check comes on top of the secret.
-
Select Publish. On the first publish APROS creates the webhook's URL and a secret, and shows the secret once in a notice: "Webhook secret generated — save it now, it will not be shown again". Copy it.
-
Select the trigger and copy the Webhook URL.
The URL has the form https://<your-workspace>.apros.app/api/hooks/<path>, where the path is a
long random string. Unpublishing and publishing again keeps the same URL and secret.
Call the webhook
Send the secret in the x-api-key header and your data as a JSON body:
curl -X POST "https://<your-workspace>.apros.app/api/hooks/<path>" \
-H "x-api-key: $APROS_WEBHOOK_SECRET" \
-H "Content-Type: application/json" \
-d '{ "email": "olena@example.com", "plan": "pro" }'APROS accepts the request and runs the workflow in the background:
{ "accepted": true }The status is 202 Accepted: the workflow has been queued, not finished. Follow its progress in
the workflow's run history.
How the request becomes workflow input
- The JSON body becomes the trigger's data. Later steps of the workflow read its fields with
trigger tokens, for example
trigger.email. - An empty body or a body that is not valid JSON starts the workflow with empty trigger data. It is not refused.
- The trigger's Last received payload panel shows the body of the most recent request, so you can see the exact shape you are wiring against.
- The workflow runs as the person who created it.
Responses
Inbound webhook responses carry only an error text, with no code:
| Status | Body | Meaning |
|---|---|---|
202 | { "accepted": true } | The workflow run was queued. |
401 | { "error": "Unauthorized" } | Header authentication is on and the header is missing or wrong. While header authentication is selected but its name or value is empty, every request gets this answer. |
404 | { "error": "Not found" } | No published webhook workflow has this URL, or the x-api-key secret is missing or wrong. APROS answers both the same way on purpose, so the response does not reveal which URLs exist. |
405 | { "error": "Method not allowed" } | The request used a method other than the one chosen in HTTP method. |
413 | { "error": "Payload too large" } | The body is larger than 64 KB. |
429 | { "error": "Too many requests" } | Over the rate limit. See Limits. |
503 | { "error": "Service unavailable" } | APROS could not take the request right now. Retry later. |
A 404 can mean a wrong secret
If a webhook that worked starts answering 404, check that the workflow is still published and
that the caller sends the current secret.
Rotate the secret
-
Open the workflow and select its Webhook trigger.
-
Next to Secret (x-api-key), select Regenerate and confirm in Regenerate webhook secret?.
-
Copy the new secret from the notice. It is shown only once.
-
Update every system that calls the webhook.
The old secret stops working immediately. The URL does not change.
Limits
- 60 requests per minute for each webhook URL.
- 300 requests per minute from one IP address, across all webhook URLs.
- Request bodies up to 64 KB.
Outbound webhooks
To call your system when something happens in APROS, add a Webhook action to an automation rule. For a request that is one step in a longer process, use the HTTP Request step of a workflow instead.
Add a webhook action to a rule
-
Open the automation builder: select Automation on the Leads, Deals or Tasks board, or open AI Studio → Automations.
-
Create a rule or open one, and choose its trigger, for example a lead entering a stage.
-
Add the Webhook action and fill in:
- URL: your endpoint.
- Method:
POST,PUT,PATCH,GETorDELETE. - Headers (JSON): optional, for example
{"Authorization": "Bearer <your-token>"}. - Body template (JSON): optional, the exact JSON to send. Insert record fields with the variable picker.
-
Save the rule.
What APROS sends
- The request has
Content-Type: application/json, plus any headers you set. - With a Body template (JSON), the body is your template with the variables filled in. Use a template when your endpoint expects a fixed shape.
- Without a template, the body is a JSON object with
event,entityType,entityId,tenantId,timestampanddata, wheredatacarries the trigger's data and context. Its contents depend on the trigger. - A
GETrequest is sent without a body.
Delivery
- APROS waits up to 10 seconds for your endpoint to answer.
- A
2xxanswer counts as success. Any other status, a timeout or a network error marks the action as failed, and the rule's run shows as failed in the builder's Log. - The URL must be reachable from the internet: APROS refuses to call private, local and other reserved addresses.
- APROS does not sign outbound requests. To let your endpoint check that a request comes from your workspace, put a secret of your own in Headers (JSON) and verify it on your side.