Skip to content

Create an inbound endpoint​

POST
/v1/endpoints

Create an endpoint by its full RECEIVE URL — the thing you hand to a provider. The URL IS the endpoint's identity: host plus ANY number of path segments, matched exactly (no wildcards, no prefix matching) after one normalization — the host and path are lowercased and empty segments (a trailing or doubled slash) are ignored. So https://wh.emhk.in/acme/Orders/ and https://wh.emhk.in/acme/orders are the same endpoint, while …/acme/orders/v2 is a different one.

The host MUST be one of the org's ingest domains (GET /v1/ingest-domains) — an unknown host is refused with 422 (details.check: url) and never auto-registered. The URL must start with that domain's prefix: on a SHARED platform host that is https://<host>/<org-slug>/, and at least one segment must follow the org slug (this is what keeps two orgs' URLs apart on one host); on a custom domain it is https://<host>/, and the path may not start with /t/ (instant endpoints). A URL that breaks these rules is refused with 422 naming the expected prefix.

A URL another of your live endpoints already receives on returns 409.

Authorizations​

apiKey

Scoped API key. Scopes are read ⊂ write ⊂ admin. A call needing more scope than the key holds returns 403 insufficient_scope.

Type
HTTP (bearer)

Request Body​

application/json
JSON
{
  
"url": "https://wh.emhk.in/acme/shopify-store/orders",
  
"name": "Shopify orders",
  
"preset": "shopify",
  
"destinations": [
  
  
"string"
  
],
  
"responseRules": {
  
  
"rules": [
  
  
  
{
  
  
  
  
"when": {
  
  
  
  
  
"type": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"path": "string",
  
  
  
  
  
"op": "string",
  
  
  
  
  
"value": "string",
  
  
  
  
  
"all": [
  
  
  
  
  
  
{
  
  
  
  
  
  
}
  
  
  
  
  
],
  
  
  
  
  
"any": [
  
  
  
  
  
  
{
  
  
  
  
  
  
}
  
  
  
  
  
],
  
  
  
  
  
"not": "[Circular Reference]"
  
  
  
  
},
  
  
  
  
"respond": {
  
  
  
  
  
"status": 201,
  
  
  
  
  
"body": "{"pong":true}",
  
  
  
  
  
"headers": {
  
  
  
  
  
  
"additionalProperties": "string"
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
],
  
  
"default": {
  
  
  
"status": 201,
  
  
  
"body": "{"pong":true}",
  
  
  
"headers": {
  
  
  
  
"additionalProperties": "string"
  
  
  
}
  
  
}
  
},
  
"responseProxy": {
  
  
"target": "managed",
  
  
"code": "string",
  
  
"url": "string",
  
  
"timeoutMs": 0,
  
  
"onUnavailable": "string"
  
},
  
"transform": {
  
  
"engine": "managed",
  
  
"code": "string",
  
  
"url": "string",
  
  
"failMode": "string",
  
  
"timeoutMs": 0
  
},
  
"response": {
  
  
"type": "meta-challenge",
  
  
"verifyToken": "string",
  
  
"secret": "string",
  
  
"verificationToken": "string",
  
  
"endpointUrl": "string",
  
  
"status": 0,
  
  
"body": "string",
  
  
"headers": {
  
  
  
"additionalProperties": "string"
  
  
}
  
}
}

Responses​

Created.

application/json
JSON
{
  
"id": "ep_01JX9",
  
"path": "/acme/shopify-store/orders",
  
"name": "Shopify orders",
  
"preset": "shopify",
  
"url": "https://wh.emhk.in/acme/shopify-store/orders",
  
"domain": {
  
  
"id": "pdom_wh_emhk_in",
  
  
"host": "wh.emhk.in",
  
  
"kind": "platform"
  
},
  
"destinations": [
  
  
"string"
  
],
  
"responseRules": {
  
  
"rules": [
  
  
  
{
  
  
  
  
"when": {
  
  
  
  
  
"type": "string",
  
  
  
  
  
"name": "string",
  
  
  
  
  
"path": "string",
  
  
  
  
  
"op": "string",
  
  
  
  
  
"value": "string",
  
  
  
  
  
"all": [
  
  
  
  
  
  
{
  
  
  
  
  
  
}
  
  
  
  
  
],
  
  
  
  
  
"any": [
  
  
  
  
  
  
{
  
  
  
  
  
  
}
  
  
  
  
  
],
  
  
  
  
  
"not": "[Circular Reference]"
  
  
  
  
},
  
  
  
  
"respond": {
  
  
  
  
  
"status": 201,
  
  
  
  
  
"body": "{"pong":true}",
  
  
  
  
  
"headers": {
  
  
  
  
  
  
"additionalProperties": "string"
  
  
  
  
  
}
  
  
  
  
}
  
  
  
}
  
  
],
  
  
"default": {
  
  
  
"status": 201,
  
  
  
"body": "{"pong":true}",
  
  
  
"headers": {
  
  
  
  
"additionalProperties": "string"
  
  
  
}
  
  
}
  
},
  
"responseProxy": {
  
  
"target": "managed",
  
  
"code": "string",
  
  
"url": "string",
  
  
"timeoutMs": 0,
  
  
"onUnavailable": "string"
  
},
  
"transform": {
  
  
"engine": "managed",
  
  
"code": "string",
  
  
"url": "string",
  
  
"failMode": "string",
  
  
"timeoutMs": 0
  
},
  
"response": {
  
  
"type": "meta-challenge",
  
  
"verifyToken": "string",
  
  
"secret": "string",
  
  
"verificationToken": "string",
  
  
"endpointUrl": "string",
  
  
"status": 0,
  
  
"body": "string",
  
  
"headers": {
  
  
  
"additionalProperties": "string"
  
  
}
  
},
  
"verification": "hmac-sha256",
  
"status": "active"
}

Playground​

Authorization
Body

Samples​

Powered by VitePress OpenAPI

Emithook · a Finnoto product