const response = await fetch("https://api.sudomock.com/api/v1/webhook-endpoints", {
method: "POST",
headers: {
"x-api-key": "sm_your_api_key",
"Content-Type": "application/json",
},
body: JSON.stringify({
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}),
});
const data = await response.json();
console.log(data);
<?php
$payload = <<<'JSON'
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
JSON;
$ch = curl_init("https://api.sudomock.com/api/v1/webhook-endpoints");
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "POST");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"x-api-key: sm_your_api_key",
"Content-Type: application/json",
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
payload = {
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
response = requests.post(
"https://api.sudomock.com/api/v1/webhook-endpoints",
headers={"x-api-key": "sm_your_api_key"},
json=payload,
)
response.raise_for_status()
print(response.json())
require "net/http"
require "uri"
uri = URI("https://api.sudomock.com/api/v1/webhook-endpoints")
request = Net::HTTP::Post.new(uri)
request["x-api-key"] = "sm_your_api_key"
request["Content-Type"] = "application/json"
request.body = <<~JSON
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
JSON
response = Net::HTTP.start(uri.host, uri.port, use_ssl: true) do |http|
http.request(request)
end
puts response.body
package main
import (
"bytes"
"fmt"
"io"
"net/http"
)
func main() {
payload := []byte(`{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}`)
req, err := http.NewRequest("POST", "https://api.sudomock.com/api/v1/webhook-endpoints", bytes.NewBuffer(payload))
if err != nil {
panic(err)
}
req.Header.Set("x-api-key", "sm_your_api_key")
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
String payload = """
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.sudomock.com/api/v1/webhook-endpoints"))
.header("x-api-key", "sm_your_api_key")
.header("Content-Type", "application/json")
.POST(HttpRequest.BodyPublishers.ofString(payload))
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
using System.Net.Http;
using System.Text;
var payload = """
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
""";
var request = new HttpRequestMessage(HttpMethod.Post, "https://api.sudomock.com/api/v1/webhook-endpoints");
request.Headers.Add("x-api-key", "sm_your_api_key");
request.Content = new StringContent(payload, Encoding.UTF8, "application/json");
var client = new HttpClient();
var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());
curl -X POST "https://api.sudomock.com/api/v1/webhook-endpoints" \
-H "x-api-key: sm_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}'
{
"id": "string",
"url": "https://example.com/artwork.png",
"secret": "string",
"enabled": false,
"created_at": "2026-01-01T00:00:00Z"
}
Create a new webhook endpoint
Create an endpoint. The signing secret is returned in FULL here, once.
const response = await fetch("https://api.sudomock.com/api/v1/webhook-endpoints", {
method: "POST",
headers: {
"x-api-key": "sm_your_api_key",
"Content-Type": "application/json",
},
body: JSON.stringify({
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}),
});
const data = await response.json();
console.log(data);
<?php
$payload = <<<'JSON'
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
JSON;
$ch = curl_init("https://api.sudomock.com/api/v1/webhook-endpoints");
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "POST");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"x-api-key: sm_your_api_key",
"Content-Type: application/json",
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
payload = {
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
response = requests.post(
"https://api.sudomock.com/api/v1/webhook-endpoints",
headers={"x-api-key": "sm_your_api_key"},
json=payload,
)
response.raise_for_status()
print(response.json())
require "net/http"
require "uri"
uri = URI("https://api.sudomock.com/api/v1/webhook-endpoints")
request = Net::HTTP::Post.new(uri)
request["x-api-key"] = "sm_your_api_key"
request["Content-Type"] = "application/json"
request.body = <<~JSON
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
JSON
response = Net::HTTP.start(uri.host, uri.port, use_ssl: true) do |http|
http.request(request)
end
puts response.body
package main
import (
"bytes"
"fmt"
"io"
"net/http"
)
func main() {
payload := []byte(`{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}`)
req, err := http.NewRequest("POST", "https://api.sudomock.com/api/v1/webhook-endpoints", bytes.NewBuffer(payload))
if err != nil {
panic(err)
}
req.Header.Set("x-api-key", "sm_your_api_key")
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
String payload = """
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.sudomock.com/api/v1/webhook-endpoints"))
.header("x-api-key", "sm_your_api_key")
.header("Content-Type", "application/json")
.POST(HttpRequest.BodyPublishers.ofString(payload))
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
using System.Net.Http;
using System.Text;
var payload = """
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
""";
var request = new HttpRequestMessage(HttpMethod.Post, "https://api.sudomock.com/api/v1/webhook-endpoints");
request.Headers.Add("x-api-key", "sm_your_api_key");
request.Content = new StringContent(payload, Encoding.UTF8, "application/json");
var client = new HttpClient();
var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());
curl -X POST "https://api.sudomock.com/api/v1/webhook-endpoints" \
-H "x-api-key: sm_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}'
{
"id": "string",
"url": "https://example.com/artwork.png",
"secret": "string",
"enabled": false,
"created_at": "2026-01-01T00:00:00Z"
}
const response = await fetch("https://api.sudomock.com/api/v1/webhook-endpoints", {
method: "POST",
headers: {
"x-api-key": "sm_your_api_key",
"Content-Type": "application/json",
},
body: JSON.stringify({
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}),
});
const data = await response.json();
console.log(data);
<?php
$payload = <<<'JSON'
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
JSON;
$ch = curl_init("https://api.sudomock.com/api/v1/webhook-endpoints");
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "POST");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"x-api-key: sm_your_api_key",
"Content-Type: application/json",
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
payload = {
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
response = requests.post(
"https://api.sudomock.com/api/v1/webhook-endpoints",
headers={"x-api-key": "sm_your_api_key"},
json=payload,
)
response.raise_for_status()
print(response.json())
require "net/http"
require "uri"
uri = URI("https://api.sudomock.com/api/v1/webhook-endpoints")
request = Net::HTTP::Post.new(uri)
request["x-api-key"] = "sm_your_api_key"
request["Content-Type"] = "application/json"
request.body = <<~JSON
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
JSON
response = Net::HTTP.start(uri.host, uri.port, use_ssl: true) do |http|
http.request(request)
end
puts response.body
package main
import (
"bytes"
"fmt"
"io"
"net/http"
)
func main() {
payload := []byte(`{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}`)
req, err := http.NewRequest("POST", "https://api.sudomock.com/api/v1/webhook-endpoints", bytes.NewBuffer(payload))
if err != nil {
panic(err)
}
req.Header.Set("x-api-key", "sm_your_api_key")
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
String payload = """
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
""";
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.sudomock.com/api/v1/webhook-endpoints"))
.header("x-api-key", "sm_your_api_key")
.header("Content-Type", "application/json")
.POST(HttpRequest.BodyPublishers.ofString(payload))
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
using System.Net.Http;
using System.Text;
var payload = """
{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}
""";
var request = new HttpRequestMessage(HttpMethod.Post, "https://api.sudomock.com/api/v1/webhook-endpoints");
request.Headers.Add("x-api-key", "sm_your_api_key");
request.Content = new StringContent(payload, Encoding.UTF8, "application/json");
var client = new HttpClient();
var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());
curl -X POST "https://api.sudomock.com/api/v1/webhook-endpoints" \
-H "x-api-key: sm_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"description": "Production render notifications",
"event_types": [
"render.succeeded",
"render.failed"
],
"url": "https://your-app.example.com/hooks/sudomock"
}'
{
"id": "string",
"url": "https://example.com/artwork.png",
"secret": "string",
"enabled": false,
"created_at": "2026-01-01T00:00:00Z"
}
Authorizations
API key with sm_ prefix. Get your key at https://sudomock.com/dashboard/api-keys
Body
Create a webhook endpoint. URL SSRF-validation happens in the route (it needs DNS resolution and returns a clean 400); here we only enforce shape.
https endpoint URL
1 - 2048255Subscribed event types; empty = all events (wildcard).
render.succeeded, render.failed, upload.succeeded, video.succeeded, video.failed, 2d_mockup.ready, 2d_mockup.rejected, 2d_mockup.failed, 2d_render.succeeded, 2d_render.failed, photo_mockup.ready, photo_mockup.rejected, photo_mockup.failed, photo_mockup_render.succeeded, photo_mockup_render.failed, webhook.test Which spelling of the photo-mockup events this endpoint receives: 'current' (photo_mockup., photo_mockup_render.) or 'legacy' (2d_mockup., 2d_render.). The payload's kind follows. Omit it and the endpoint is pinned to the spelling event_types is written in: the family names for a list that subscribes to them, otherwise 'legacy', the spelling this contract publishes.
legacy, current Response
Successful Response
Returned ONLY by create + rotate-secret: the FULL plaintext secret.
Overrides the masked secret field with the real value (shown once).
"b5cd6284-f6a0-4cfc-94df-781353e30dfd"
"https://your-app.example.com/hooks/sudomock"
FULL signing secret. Shown only once.
"whsec_cb79146988c2f928cc0760c737c67368080948cdadf7a20c14311290682ee865"
true
"2026-09-18T09:24:11.482713Z"
"Production render notifications"
["render.succeeded", "render.failed"]
The event-name spelling this endpoint is pinned to: 'legacy' or 'current'.
"2026-09-18T09:31:02.117845Z"
Was this page helpful?