Skip to main content

Communication API Reference

All Communication endpoints are served under the /api/v1/communication prefix via the gateway.

Endpoints

Channels

MethodPathDescription
GET/api/v1/communication/channelsList channels (filter: ?status=active|disabled)
POST/api/v1/communication/channelsCreate channel
GET/api/v1/communication/channels/:idGet channel by ID or name
PATCH/api/v1/communication/channels/:idUpdate channel
DELETE/api/v1/communication/channels/:idDelete channel

Registrations

MethodPathDescription
GET/api/v1/communication/apps/:appId/channelsList app registrations (filter: ?channelId=)
POST/api/v1/communication/apps/:appId/channelsRegister app against channel
GET/api/v1/communication/apps/:appId/channels/:idGet registration
PATCH/api/v1/communication/apps/:appId/channels/:idUpdate registration
DELETE/api/v1/communication/apps/:appId/channels/:idDelete registration

Sending & Deliveries

MethodPathDescription
POST/api/v1/communication/apps/:appId/sendSend message
GET/api/v1/communication/apps/:appId/deliveriesList deliveries (filter: ?channelId=, ?limit=)

Examples

Create a Channel

curl -X POST http://localhost:3000/api/v1/communication/channels \
-H "Content-Type: application/json" \
-d '{
"name": "slack-alerts",
"provider": "slack",
"description": "Team alert notifications",
"config": {
"webhookUrl": "env:SLACK_WEBHOOK_URL"
}
}'

Response:

{
"success": true,
"data": {
"id": "ch_abc123def456",
"name": "slack-alerts",
"provider": "slack",
"description": "Team alert notifications",
"status": "active",
"config": { "webhookUrl": "env:SLACK_WEBHOOK_URL" },
"createdAt": "2026-03-05T12:00:00.000Z",
"updatedAt": "2026-03-05T12:00:00.000Z"
}
}

Register an App

curl -X POST http://localhost:3000/api/v1/communication/apps/my-service/channels \
-H "Content-Type: application/json" \
-d '{
"channelId": "ch_abc123def456",
"target": "#deploy-alerts",
"metadata": { "env": "production" }
}'

Response:

{
"success": true,
"data": {
"id": "reg_xyz789ghi012",
"appId": "my-service",
"channelId": "ch_abc123def456",
"target": "#deploy-alerts",
"metadata": { "env": "production" },
"enabled": true,
"createdAt": "2026-03-05T12:00:00.000Z",
"updatedAt": "2026-03-05T12:00:00.000Z"
}
}

Send a Message

curl -X POST http://localhost:3000/api/v1/communication/apps/my-service/send \
-H "Content-Type: application/json" \
-d '{
"channelId": "ch_abc123def456",
"text": "Deployment to production complete",
"subject": "Deploy notification"
}'

Response:

{
"success": true,
"data": {
"delivery": {
"id": "dl_qrs345tuv678",
"appId": "my-service",
"channelId": "ch_abc123def456",
"provider": "slack",
"target": "#deploy-alerts",
"status": "accepted",
"providerMessageId": "slack-msg-123",
"live": true,
"createdAt": "2026-03-05T12:00:00.000Z"
},
"provider": "slack",
"live": true
}
}

List Deliveries

curl "http://localhost:3000/api/v1/communication/apps/my-service/deliveries?limit=10"

Update a Channel

curl -X PATCH http://localhost:3000/api/v1/communication/channels/ch_abc123def456 \
-H "Content-Type: application/json" \
-d '{"status": "disabled"}'

List Channels

curl "http://localhost:3000/api/v1/communication/channels?status=active"

Response Envelope

All responses follow the standard envelope format:

Success:

{
"success": true,
"data": { ... }
}

Error:

{
"success": false,
"error": {
"code": "NOT_FOUND",
"message": "Channel not found: ch_abc123def456"
}
}