Skip to main content

createEventDestination

form schema

Add a destination that receives the organization's audit log events.

eventDestinationAdapters lists each adapter's configSchema and authSchema. Put credentials in auth: the API never returns them. A destination of an adapter that signs gets a signingSecret, and Massdriver signs each event with it.

Pass auth as a variable. Query text can appear in request traces. Variables do not.

mutation CreateEventDestination($auth: Map) {
createEventDestination(
organizationId: "my-org"
input: {
name: "Production deployments"
adapter: HTTP
config: "{\"url\": \"https://hooks.example.com/massdriver\"}"
auth: $auth
filter: { types: ["deployment.*"], attributes: "{\"md-environment\": \"prod\"}" }
}
) {
result { id signingSecret }
successful
messages { field message }
}
}
createEventDestination(
organizationId: ID!
input: CreateEventDestinationInput!
): EventDestinationPayload

Form Schema​

This mutation supports dynamic form generation using JSON Schema.

Loading schema...

Arguments​

createEventDestination.organizationId ● ID! non-null scalar {#organization-id}​

Your organization's unique identifier.

createEventDestination.input ● CreateEventDestinationInput! non-null input {#input}​

Add a destination that receives the organization's audit log events that match its filter.

Type​

EventDestinationPayload object​