SIGN IN SIGN UP

Add missing event types (#543)

* Add 21 missing event and webhook types from WorkOS docs

Add support for the following event types that were documented but
missing from the SDK:

- api_key.created, api_key.revoked
- authentication.email_verification_failed, authentication.mfa_failed,
  authentication.passkey_failed, authentication.passkey_succeeded,
  authentication.radar_risk_detected
- connection.saml_certificate_renewed,
  connection.saml_certificate_renewal_required
- flag.created, flag.updated, flag.deleted, flag.rule_updated
- invitation.resent
- organization_role.created, organization_role.deleted,
  organization_role.updated
- permission.created, permission.deleted, permission.updated

New payload models: ApiKeyPayload, ConnectionSamlCertificate payloads,
FlagPayload, OrganizationRolePayload, PermissionPayload. New auth
payloads for email_verification_failed, mfa_failed, passkey, and
radar_risk_detected.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* adjust requiredness

* Add context field to flag.rule_updated event and webhook

The backend flag.rule_updated event includes a context object (with
actor, access_type, configured_targets, and previous_attributes) as a
sibling of the data field. Without this, the context was silently
dropped during deserialization.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Make sso field required on SSO auth event payloads

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Garen J. Torikian <gjtorikian@users.noreply.github.com>
B
blackmad-cradle committed
c2b251759dd4362cceab82ca7fec07d6db5fb4a6
Parent: 0ac7ff8
Committed by GitHub <noreply@github.com> on 2/12/2026, 8:46:02 PM