> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.cloudraker.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.cloudraker.com/_mcp/server.

# Ingest a direct webhook (no Hookdeck)

POST /api/channels/orgs/{orgSlug}/{channelSlug}

Public endpoint used in local dev / tests when Hookdeck is not configured. Authenticated by the per-channel `X-Channel-Secret`; requires an `X-Idempotency-Key`. Dispatches the payload to the matching channel's routes.

Reference: https://docs.cloudraker.com/api/raker-one-api/webhooks/post-channels-orgs-by-org-slug-by-channel-slug

## OpenAPI Specification

```yaml
openapi: 3.1.0
info:
  title: RakerOne API
  version: 1.0.0
paths:
  /channels/orgs/{orgSlug}/{channelSlug}:
    post:
      operationId: post-channels-orgs-by-org-slug-by-channel-slug
      summary: Ingest a direct webhook (no Hookdeck)
      description: >-
        Public endpoint used in local dev / tests when Hookdeck is not
        configured. Authenticated by the per-channel `X-Channel-Secret`;
        requires an `X-Idempotency-Key`. Dispatches the payload to the matching
        channel's routes.
      tags:
        - subpackage_webhooks
      parameters:
        - name: orgSlug
          in: path
          required: true
          schema:
            type: string
        - name: channelSlug
          in: path
          required: true
          schema:
            type: string
        - name: X-Channel-Secret
          in: header
          description: Per-channel secret authenticating the caller.
          required: true
          schema:
            type: string
        - name: X-Idempotency-Key
          in: header
          description: Caller-supplied key making delivery exactly-once across retries.
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Delivery replayed or skipped.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JsonObject'
        '400':
          description: >-
            Bad request — invalid body, missing idempotency key, or channel does
            not support direct ingest.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Missing or invalid channel secret.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Unknown org or channel.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '409':
          description: Idempotency key reused with a different payload.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '413':
          description: Payload too large.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Internal error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
servers:
  - url: /api
    description: Current origin
  - url: https://app.raker.one/api
    description: Production
components:
  schemas:
    JsonObject:
      type: object
      additionalProperties:
        description: Any type
      description: An arbitrary JSON object.
      title: JsonObject
    ErrorResponse:
      type: object
      properties:
        error:
          type: string
          description: Machine-readable error code (e.g. `invalid_body`, `not_found`).
        issues:
          type: array
          items:
            description: Any type
          description: Schema-validation issues, present when `error` is `invalid_body`.
      required:
        - error
      description: Standard API error response.
      title: ErrorResponse

```

## Examples

### Example 1



**Request**

```json
{
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": {
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  }
}
```

**Response**

```json
{}
```

**SDK Code**

```python
import requests

url = "https://api/channels/orgs/orgSlug/channelSlug"

payload = {
    "event": "user.signup",
    "timestamp": "2024-06-01T12:00:00Z",
    "payload": {
        "userId": "12345",
        "email": "newuser@example.com",
        "name": "Jane Doe"
    }
}
headers = {
    "X-Channel-Secret": "X-Channel-Secret",
    "X-Idempotency-Key": "X-Idempotency-Key",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api/channels/orgs/orgSlug/channelSlug';
const options = {
  method: 'POST',
  headers: {
    'X-Channel-Secret': 'X-Channel-Secret',
    'X-Idempotency-Key': 'X-Idempotency-Key',
    'Content-Type': 'application/json'
  },
  body: '{"event":"user.signup","timestamp":"2024-06-01T12:00:00Z","payload":{"userId":"12345","email":"newuser@example.com","name":"Jane Doe"}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api/channels/orgs/orgSlug/channelSlug"

	payload := strings.NewReader("{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("X-Channel-Secret", "X-Channel-Secret")
	req.Header.Add("X-Idempotency-Key", "X-Idempotency-Key")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api/channels/orgs/orgSlug/channelSlug")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["X-Channel-Secret"] = 'X-Channel-Secret'
request["X-Idempotency-Key"] = 'X-Idempotency-Key'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api/channels/orgs/orgSlug/channelSlug")
  .header("X-Channel-Secret", "X-Channel-Secret")
  .header("X-Idempotency-Key", "X-Idempotency-Key")
  .header("Content-Type", "application/json")
  .body("{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api/channels/orgs/orgSlug/channelSlug', [
  'body' => '{
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": {
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  }
}',
  'headers' => [
    'Content-Type' => 'application/json',
    'X-Channel-Secret' => 'X-Channel-Secret',
    'X-Idempotency-Key' => 'X-Idempotency-Key',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api/channels/orgs/orgSlug/channelSlug");
var request = new RestRequest(Method.POST);
request.AddHeader("X-Channel-Secret", "X-Channel-Secret");
request.AddHeader("X-Idempotency-Key", "X-Idempotency-Key");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "X-Channel-Secret": "X-Channel-Secret",
  "X-Idempotency-Key": "X-Idempotency-Key",
  "Content-Type": "application/json"
]
let parameters = [
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": [
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api/channels/orgs/orgSlug/channelSlug")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### Example 2



**Request**

```json
{
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": {
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  }
}
```

**Response**

```json
{}
```

**SDK Code**

```python
import requests

url = "https://api/channels/orgs/orgSlug/channelSlug"

payload = {
    "event": "user.signup",
    "timestamp": "2024-06-01T12:00:00Z",
    "payload": {
        "userId": "12345",
        "email": "newuser@example.com",
        "name": "Jane Doe"
    }
}
headers = {
    "X-Channel-Secret": "X-Channel-Secret",
    "X-Idempotency-Key": "X-Idempotency-Key",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api/channels/orgs/orgSlug/channelSlug';
const options = {
  method: 'POST',
  headers: {
    'X-Channel-Secret': 'X-Channel-Secret',
    'X-Idempotency-Key': 'X-Idempotency-Key',
    'Content-Type': 'application/json'
  },
  body: '{"event":"user.signup","timestamp":"2024-06-01T12:00:00Z","payload":{"userId":"12345","email":"newuser@example.com","name":"Jane Doe"}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api/channels/orgs/orgSlug/channelSlug"

	payload := strings.NewReader("{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("X-Channel-Secret", "X-Channel-Secret")
	req.Header.Add("X-Idempotency-Key", "X-Idempotency-Key")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api/channels/orgs/orgSlug/channelSlug")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["X-Channel-Secret"] = 'X-Channel-Secret'
request["X-Idempotency-Key"] = 'X-Idempotency-Key'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api/channels/orgs/orgSlug/channelSlug")
  .header("X-Channel-Secret", "X-Channel-Secret")
  .header("X-Idempotency-Key", "X-Idempotency-Key")
  .header("Content-Type", "application/json")
  .body("{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api/channels/orgs/orgSlug/channelSlug', [
  'body' => '{
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": {
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  }
}',
  'headers' => [
    'Content-Type' => 'application/json',
    'X-Channel-Secret' => 'X-Channel-Secret',
    'X-Idempotency-Key' => 'X-Idempotency-Key',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api/channels/orgs/orgSlug/channelSlug");
var request = new RestRequest(Method.POST);
request.AddHeader("X-Channel-Secret", "X-Channel-Secret");
request.AddHeader("X-Idempotency-Key", "X-Idempotency-Key");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "X-Channel-Secret": "X-Channel-Secret",
  "X-Idempotency-Key": "X-Idempotency-Key",
  "Content-Type": "application/json"
]
let parameters = [
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": [
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api/channels/orgs/orgSlug/channelSlug")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```

### Example 3



**Request**

```json
{
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": {
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  }
}
```

**Response**

```json
{}
```

**SDK Code**

```python
import requests

url = "https://api/channels/orgs/orgSlug/channelSlug"

payload = {
    "event": "user.signup",
    "timestamp": "2024-06-01T12:00:00Z",
    "payload": {
        "userId": "12345",
        "email": "newuser@example.com",
        "name": "Jane Doe"
    }
}
headers = {
    "X-Channel-Secret": "X-Channel-Secret",
    "X-Idempotency-Key": "X-Idempotency-Key",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript
const url = 'https://api/channels/orgs/orgSlug/channelSlug';
const options = {
  method: 'POST',
  headers: {
    'X-Channel-Secret': 'X-Channel-Secret',
    'X-Idempotency-Key': 'X-Idempotency-Key',
    'Content-Type': 'application/json'
  },
  body: '{"event":"user.signup","timestamp":"2024-06-01T12:00:00Z","payload":{"userId":"12345","email":"newuser@example.com","name":"Jane Doe"}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api/channels/orgs/orgSlug/channelSlug"

	payload := strings.NewReader("{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("X-Channel-Secret", "X-Channel-Secret")
	req.Header.Add("X-Idempotency-Key", "X-Idempotency-Key")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api/channels/orgs/orgSlug/channelSlug")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["X-Channel-Secret"] = 'X-Channel-Secret'
request["X-Idempotency-Key"] = 'X-Idempotency-Key'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}"

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api/channels/orgs/orgSlug/channelSlug")
  .header("X-Channel-Secret", "X-Channel-Secret")
  .header("X-Idempotency-Key", "X-Idempotency-Key")
  .header("Content-Type", "application/json")
  .body("{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api/channels/orgs/orgSlug/channelSlug', [
  'body' => '{
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": {
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  }
}',
  'headers' => [
    'Content-Type' => 'application/json',
    'X-Channel-Secret' => 'X-Channel-Secret',
    'X-Idempotency-Key' => 'X-Idempotency-Key',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api/channels/orgs/orgSlug/channelSlug");
var request = new RestRequest(Method.POST);
request.AddHeader("X-Channel-Secret", "X-Channel-Secret");
request.AddHeader("X-Idempotency-Key", "X-Idempotency-Key");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"event\": \"user.signup\",\n  \"timestamp\": \"2024-06-01T12:00:00Z\",\n  \"payload\": {\n    \"userId\": \"12345\",\n    \"email\": \"newuser@example.com\",\n    \"name\": \"Jane Doe\"\n  }\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "X-Channel-Secret": "X-Channel-Secret",
  "X-Idempotency-Key": "X-Idempotency-Key",
  "Content-Type": "application/json"
]
let parameters = [
  "event": "user.signup",
  "timestamp": "2024-06-01T12:00:00Z",
  "payload": [
    "userId": "12345",
    "email": "newuser@example.com",
    "name": "Jane Doe"
  ]
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api/channels/orgs/orgSlug/channelSlug")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```