Add a webhook endpoint
/v1/webhook_endpointsAdds an endpoint in the key's mode (test or live). The url must be HTTPS on port 443, without a user name or password, and its host a DNS name (not an IP address) whose every A and AAAA record is a public address. A host that does not resolve is refused, so a typo shows now rather than after three days of retries. auth. follows the same rules. The signing secret is in this response only: store it. The endpoint records who created it (created_). Errors: webhook_, webhook_, webhook_, webhook_, webhook_, webhook_, webhook_, webhook_.
Body
Required
-
HTTPS only.
Optional
-
event_typesarray of stringOne ofdelivery.createddelivery.rejecteddelivery.notifieddelivery.openeddelivery.email_openeddelivery.auth_faileddelivery.confirmeddelivery.downloadeddelivery.delivereddelivery.remindeddelivery.bounceddelivery.expireddelivery.revokeddelivery.consignment_faileddelivery.evidence_sealeddelivery.evidence_timestamp_deferreddelivery.evidence_timestamp_recovereddelivery.paper_pending_approvaldelivery.paper_dispatcheddelivery.paper_faileddocument.previewedbatch.finalizedbatch.completedlookup.completedconsent.grantedconsent.withdrawninvitation.sentlink.openedotp.sentotp.verifiedotp.lockedsecret.attachedsecret.availablesecret.revealedsecret.copiedsecret.expiredsecret.exhaustedsecret.revokedrequest.sentrequest.openedrequest.fulfilledrequest.expiredrequest.closedrequest.reopeneddeletion.scheduledrecipient_domain.verifiedrecipient_domain.degradedrecipient_domain.failedmember.suspendedmember.restoredmember.removedbatch.cancelledbatch.policy_changeddelivery.policy_changedemail_sender.verifiedemail_sender.degradedemail_sender.failedemail_sender.restored -
descriptionstring · nullableYour own note about the endpoint, up to 500 characters; null or left out for none.
at most 500 characters -
authobjectHow Parasend authenticates to your endpoint, in addition to the HMAC signature, which is always sent. Secrets are write-only: accepted on create and update, never returned. The endpoint shows
mode, the settings that are not secret, and whether a secret is set.3 fields of
auth-
none = HMAC only. static_bearer = an
Authorizationheader carryingBearer <token>with a customer-supplied token. oauth2_client_credentials = a token obtained from the customer's IdP by the client-credentials grant, cached until expiry, sent as the bearer.One ofnonestatic_beareroauth2_client_credentialsDefault"none" -
auth.static_bearerobject · nullableWith
mode: static_: thebearer tokenParasend sends asAuthorization: Bearer <token>, at most 4,096 characters (write-only; responses showtoken_). null for any other mode.set 1 field of
static_bearer-
auth.static_bearer.tokenstringNever returned. Rotate by writing a new value.
-
-
auth.oauth2object · nullableWith
mode: oauth2_: your token endpoint (client_ credentials token_, HTTPS),url client_,id client_(write-only; responses showsecret client_), optionalsecret_ set scopeandaudience, andauth_. null for any other mode.style 6 fields of
oauth2-
auth.oauth2.token_urlstring · uriHTTPS only.
-
auth.oauth2.client_idstring -
Never returned.
-
auth.oauth2.scopestring · nullable -
auth.oauth2.audiencestring · nullable -
auth.oauth2.auth_stylestringOne ofclient_secret_basicclient_secret_postDefault"client_secret_basic"
-
-
-
delivery_sourcesobject · nullableOmitted or null = every delivery (the default; what every endpoint had before).
Returns
201 application/json. Created (includes secret, shown only now). See the WebhookEndpoint object.
Errors have one shape; see Errors for every code.