ReferenceNotifications (webhooks)

sendTestNotification mutation

Sends a test notification using the specified event type and payload. The notification is sent to the notification profile's configured callback URL.

Syntax

1mutation {
2 sendTestNotification(
5}

Example

1mutation {
2 sendTestNotification (
3 input: {
4 eventType : "messageReceived",
5 payload : {
6 payloadField: "Test message"
7 }
8 })
9 {
10 outcome
11 httpStatusCode
12 error {
13 code
14 message
15 }
16 }
17}

Arguments

NameDescription

input

Required.
Type: SendTestNotificationInput

Types


Name
Type
Int
Int

The Int scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.

JSON
JSON

JSON values as specified by ECMA-404.

SendTestNotificationInput
InputObject

Event type and payload to send with testing notifications.

FieldDescription
eventTypeNot nullable.

Event type name for testing notifications.

Type: String
payloadNot nullable.

Payload for testing notifications.

Type: JSON
SendTestNotificationPayload
Object

Payload to send when testing notifications.

FieldDescription
error

Human-readable description of errors encountered when attempting to deliver the notification, if the test failed.

Type: TestNotificationError
httpStatusCode

HTTP status code returned by the endpoint where the notification was sent.

Type: Int
outcomeNot nullable.

Outcome of the test payload sent.

Type: TestNotificationOutcome
String
String

The String scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.

TestNotificationError
Object

Error details sent during test notification, if an error occurs.

FieldDescription
codeNot nullable.

Code that reflects the specific error encountered during the test.

Type: String
messageNot nullable.

Human-readable message describing the error encountered.

Type: String
TestNotificationOutcome
Enum

Test notification error values.

NameDescription
SUCCESS
FAILURE