workos-php
workos-php copied to clipboard
Add Actions helper class for WorkOS Actions support
Description
Add Actions helper class for WorkOS Actions support
- Add Actions.php service class with convenient wrapper methods for WebhookResponse and Webhook functionality
- Add test suite
- Include detailed docblocks with usage examples for all methods
New Methods:
- allowUserRegistration() / denyUserRegistration() - User registration responses
- allowAuthentication() / denyAuthentication() - Authentication responses
- verifyWebhook() / parseWebhook() - Webhook handling
- isUserRegistrationWebhook() / isAuthenticationWebhook() - Type checking
- extractEmail() / extractUserId() / extractOrganizationId() - Data extraction
This makes WorkOS Actions support highly discoverable while maintaining consistency with existing SDK patterns. All methods delegate to existing WebhookResponse and Webhook classes without duplication.
Documentation
Does this require changes to the WorkOS Docs? E.g. the API Reference or code snippets need updates.
[ ] Yes
If yes, link a related docs PR and add a docs maintainer as a reviewer. Their approval is required.