Inbound event source and subscription management
List event sources
Authorization
bearerAuth In: header
Query Parameters
Response Body
application/json
curl -X GET "http://localhost:8080/v1/event-sources?project_id=string"[
{
"id": "string",
"project_id": "string",
"name": "string",
"description": "string",
"schema": {},
"enabled": true,
"signature_header": "string",
"signature_algorithm": "hmac-sha256",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
]Create an event source
Authorization
bearerAuth In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "http://localhost:8080/v1/event-sources" \ -H "Content-Type: application/json" \ -d '{ "project_id": "string", "name": "string" }'{
"id": "string",
"project_id": "string",
"name": "string",
"description": "string",
"schema": {},
"enabled": true,
"signature_header": "string",
"signature_algorithm": "hmac-sha256",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}Get an event source
Authorization
bearerAuth In: header
Path Parameters
Query Parameters
Response Body
application/json
curl -X GET "http://localhost:8080/v1/event-sources/string?project_id=string"{
"id": "string",
"project_id": "string",
"name": "string",
"description": "string",
"schema": {},
"enabled": true,
"signature_header": "string",
"signature_algorithm": "hmac-sha256",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}Update an event source
Authorization
bearerAuth In: header
Path Parameters
Query Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
curl -X PATCH "http://localhost:8080/v1/event-sources/string?project_id=string" \ -H "Content-Type: application/json" \ -d '{}'Delete an event source
Authorization
bearerAuth In: header
Path Parameters
Query Parameters
Response Body
curl -X DELETE "http://localhost:8080/v1/event-sources/string?project_id=string"List subscriptions for an event source
Authorization
bearerAuth In: header
Path Parameters
Response Body
application/json
curl -X GET "http://localhost:8080/v1/event-sources/string/subscriptions"[
{
"id": "string",
"source_id": "string",
"target_type": "job",
"target_id": "string",
"filter_expr": {},
"enabled": true,
"created_at": "2019-08-24T14:15:22Z"
}
]Subscribe to an event source
Authorization
bearerAuth In: header
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "http://localhost:8080/v1/event-sources/string/subscribe" \ -H "Content-Type: application/json" \ -d '{ "target_type": "job", "target_id": "string" }'{
"id": "string",
"source_id": "string",
"target_type": "job",
"target_id": "string",
"filter_expr": {},
"enabled": true,
"created_at": "2019-08-24T14:15:22Z"
}Delete a subscription
Authorization
bearerAuth In: header
Path Parameters
Response Body
curl -X DELETE "http://localhost:8080/v1/event-sources/string/subscriptions/string"Dispatch an event
Authorization
bearerAuth In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "http://localhost:8080/v1/events/dispatch" \ -H "Content-Type: application/json" \ -d '{ "source": "string", "project_id": "string" }'{
"dispatched": 0,
"source": "string"
}