SM: How to "publish" webhook connector to process engine?

Ubuntu 24.04.1 LTS
SM Camunda Version 8 deployed via Helm Chart
All pods are running

Hello,
Sorry for long post.
I’m trying to evaluate SM Camunda and I have deployed it successfully on my desktop ubuntu server.

I was able create a bpmn process file

  1. bpmn has simple webhook start event to trigger the process with activate condition set
  2. A task with outbound rest connector to invoke an external service.

Since I was not able deploy/publish from web modeler, I deployed the bpmn file from client zbctl

From zbctl, I’m able to

  1. Deploy the process file
  2. Run the process sucessfully

The issue is that I’m not able to invoke the process via webhook REST call.
From what I understand, webhook should also be deployed/published to process engine. I tried to upload the webhook connector json file but zbctl gave error that file is unkown format

One more thing to note which might be relevant, I’m able to “hit” the REST API’s on camunda zeebe gateway from postman (v1/topology, v1/process-instances/:key) with token generated from keycloak

Would appreciate if someone can shed some light on this issue.

I would like to publish webhook connector either via zbctl or via web modeler.

Via web modeler, I’m facing http2 exception when modeler tries to connect to zeebe gateway. I tried setting up ssl for nginx as mentioned in one of the tutorial but still getting http2 exception
Camunda components are running in kubernetes pods, while web modeler is running as docker container. I’m using kube portforwards and iptables to connect to web modeler to zeebe gateway

Via zbctl client, I can only upload bpmn file. My understanding is that webhook connector needs separate deployment to processing engine (zeebe), how can I do that?

Here is my zbctl status
zbctl status --insecure
2024/09/02 14:43:45 Warning: The configured security level does not guarantee that the credentials will be confidential. If this unintentional, please enable transport security.

Cluster size: 1
Partitions count: 1
Replication factor: 1
Gateway version: 8.5.6
Brokers:
Broker 0 - camunda-zeebe-0.camunda-zeebe:26501
Version: 8.5.6
Partition 1 : Leader, Healthy

Hey @CuttingCrew !

Thank you for your question, and sorry for the delay :slight_smile:

Did you check this page?

In SM the Webhook URL won’t be displayed, you will have to figure it out knowing the baseUrl, the webhook id etc.

You shouldn’t need anything else than deploying the BPMN process though.

Let me know if that helped,
Jonathan

Thanks @jroques for the reply.

Thanks for clarifying that webhook connector does not require separate deployment.

In SM, is the below format correct for calling webhook API?
http://localhost:8090/inbound/6972512e-19ae-4b31-afef-104cf16766fa

Below is the snippet of xml output from operate API (v1/process-definitions/:key/xml)
I got the webhook context from inbound.context tag

        <bpmn:extensionElements>
            <zeebe:properties>
                <zeebe:property name="inbound.type" value="io.camunda:webhook:1" />
                <zeebe:property name="inbound.method" value="post" />
                <zeebe:property name="inbound.context" value="6972512e-19ae-4b31-afef-104cf16766fa" />
                <zeebe:property name="inbound.shouldValidateHmac" value="disabled" />
                <zeebe:property name="inbound.auth.type" value="NONE" />
                <zeebe:property name="activationCondition" value="=(request.body.status = &#34;Start&#34;)" />
                <zeebe:property name="resultVariable" value="" />
                <zeebe:property name="resultExpression" value="" />
            </zeebe:properties>
        </bpmn:extensionElements>

But not able to trigger the webhook

{
“type”: “about:blank”,
“title”: “Not Found”,
“status”: 404,
“instance”: “/inbound/6972512e-19ae-4b31-afef-104cf16766fa”
}

I recommend not using an activationCondition, until you can call your webhook at least. Then you can try adding the condition back.

The URL depends on where you try to call the webhook. localhost would work only from the connectors pod, otherwise you need to use the service name to reach the pod.

How did you try to call this endpoint? And from where?

Thanks for the hint on endpoint.
I was calling zeebegateway to trigger the webhook, but it should have been the connector.

I’m getting 200 OK status and my task in process is executed too.

I went back to webhook documentation and found this
<base URL> is the URL of Connectors component deployment.

My apologies, that I didn’t read this correctly. Hope someone else sees this post and point to correct endpoint.

No worries at all, happy that I could help :slight_smile:

Have fun using Camunda, and please reach out if you have any concern/question.

Jonathan

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.