previewEventDestination
List the organization's recent audit log events of the event types and attributes that a condition passes, newest first. Use it to check event types, attributes, and a condition before you create or change a destination with them.
The condition runs on each page after the event types and attributes select it, so a page can hold fewer
items than limit.
Follow cursor.next until it is null to see every match. If the condition cannot run on an event, the
preview stops at that event and returns an error that names it. Events after it are not checked.
query {
previewEventDestination(organizationId: "my-org", eventTypes: ["deployment.*"]) {
items {
id
type
occurredAt
}
}
}
previewEventDestination(
organizationId: ID!
eventTypes: [String!]
attributes: Map
condition: String
cursor: Cursor
): AuditLogsPage
Arguments
previewEventDestination.organizationId ● ID! non-null scalar {#organization-id}
Your organization's unique identifier.
previewEventDestination.eventTypes ● [String!] list scalar {#event-types}
Event types, or <entity>.* for every event of an entity. An empty list checks every event.
previewEventDestination.attributes ● Map scalar {#attributes}
Attribute values that each event's entity must have had, such as {"md-environment": "prod"}. An empty map checks events of any attributes.
previewEventDestination.condition ● String scalar {#condition}
A jq expression to check on each event. The event matches when it outputs true.
previewEventDestination.cursor ● Cursor input {#cursor}
Pagination cursor from a previous response.