What Are Webhooks?
A webhook lets Werk24 push extraction results to your server once a drawing has been processed. Instead of waiting for messages over a persistent connection, you register a URL and handle the incoming HTTP requests in your own application. This pattern is especially useful when your backend is written in another language—such as Java, JavaScript/Node.js, C#, Go, PHP, Ruby, or Rust—because all you need to implement is a standard HTTPS endpoint.
Register a Callback
Use the read_drawing_with_callback method of Werk24Client to send a drawing and register your callback URL:
Node.js equivalent
Parameters
callback_url– URL that will receive POST requests containingTechreadMessageobjects.callback_headers– Optional headers included with the request. Headers must start withX-or be explicitly whitelisted (e.g.,Authorization).public_key– Optional PEM encoded public key used to encrypt the payload.
The method returns a request_id which you can use to correlate the asynchronous callbacks with your system.
Works with Any Stack
Because callbacks are just HTTPS requests, you can receive them in virtually any programming language.
Handle the Callback in Node.js
Here is a minimal Express server that logs the incoming message and verifies a custom header:
Expose this endpoint over HTTPS and set the callback URL to https://your-host/webhook when submitting the drawing.
Supported languages include:
- Java
- JavaScript / Node.js
- TypeScript
- C#
- Go
- PHP
- Ruby
- Rust
- C++
When to Use Webhooks
Webhooks are ideal for integrations where long‑lived connections are impractical or when you do not want to run a Python client. Because Werk24 sends results via ordinary HTTP POST requests, any language or framework that can handle web requests can consume them—for example Java, JavaScript/Node.js, TypeScript, C#, Go, PHP, Ruby, or Rust. Register the callback and process the results whenever Werk24 calls your endpoint.