diff --git a/.last-synced-sha b/.last-synced-sha
new file mode 100644
index 00000000..f72eb0e2
--- /dev/null
+++ b/.last-synced-sha
@@ -0,0 +1 @@
+92db0495807c86fbbc4d45bd266a6c1f5bcbb59c
diff --git a/.oagen-manifest.json b/.oagen-manifest.json
index 6b7a0276..748dc3ae 100644
--- a/.oagen-manifest.json
+++ b/.oagen-manifest.json
@@ -1,8 +1,9 @@
{
- "version": 1,
+ "version": 2,
"language": "dotnet",
- "generatedAt": "2026-04-21T03:25:05.813Z",
+ "generatedAt": "2026-04-28T15:07:56.951Z",
"files": [
+ "src/WorkOS.net/Client/Utilities/EventSchemaDiscriminatorConverter.cs",
"src/WorkOS.net/Client/WorkOSClient.Generated.cs",
"src/WorkOS.net/Entities/ActionAuthenticationDenied.cs",
"src/WorkOS.net/Entities/ActionAuthenticationDeniedData.cs",
@@ -111,6 +112,8 @@
"src/WorkOS.net/Entities/CreateAuthorizationPermission.cs",
"src/WorkOS.net/Entities/CreateAuthorizationResource.cs",
"src/WorkOS.net/Entities/CreateCorsOrigin.cs",
+ "src/WorkOS.net/Entities/CreateGroup.cs",
+ "src/WorkOS.net/Entities/CreateGroupMembership.cs",
"src/WorkOS.net/Entities/CreateM2MApplication.cs",
"src/WorkOS.net/Entities/CreateMagicCodeAndReturn.cs",
"src/WorkOS.net/Entities/CreateOAuthApplication.cs",
@@ -141,6 +144,7 @@
"src/WorkOS.net/Entities/DirectoryUser.cs",
"src/WorkOS.net/Entities/DirectoryUserEmail.cs",
"src/WorkOS.net/Entities/DirectoryUserWithGroups.cs",
+ "src/WorkOS.net/Entities/DomainVerificationIntentOptions.cs",
"src/WorkOS.net/Entities/DsyncActivated.cs",
"src/WorkOS.net/Entities/DsyncActivatedData.cs",
"src/WorkOS.net/Entities/DsyncActivatedDataDomain.cs",
@@ -170,11 +174,11 @@
"src/WorkOS.net/Entities/EventContextGoogleAnalyticsSession.cs",
"src/WorkOS.net/Entities/EventListListMetadata.cs",
"src/WorkOS.net/Entities/EventSchema.cs",
- "src/WorkOS.net/Entities/EventSchemaContext.cs",
"src/WorkOS.net/Entities/ExternalAuthCompleteResponse.cs",
"src/WorkOS.net/Entities/FeatureFlag.cs",
"src/WorkOS.net/Entities/FeatureFlagOwner.cs",
"src/WorkOS.net/Entities/FlagCreated.cs",
+ "src/WorkOS.net/Entities/FlagCreatedContext.cs",
"src/WorkOS.net/Entities/FlagCreatedData.cs",
"src/WorkOS.net/Entities/FlagDeleted.cs",
"src/WorkOS.net/Entities/FlagRuleUpdated.cs",
@@ -318,6 +322,10 @@
"src/WorkOS.net/Entities/VaultMetadataRead.cs",
"src/WorkOS.net/Entities/VaultNamesListed.cs",
"src/WorkOS.net/Entities/VaultNamesListedData.cs",
+ "src/WorkOS.net/Entities/WaitlistUser.cs",
+ "src/WorkOS.net/Entities/WaitlistUserApproved.cs",
+ "src/WorkOS.net/Entities/WaitlistUserCreated.cs",
+ "src/WorkOS.net/Entities/WaitlistUserDenied.cs",
"src/WorkOS.net/Entities/WebhookEndpointJson.cs",
"src/WorkOS.net/Entities/WidgetSessionToken.cs",
"src/WorkOS.net/Entities/WidgetSessionTokenResponse.cs",
@@ -374,6 +382,7 @@
"src/WorkOS.net/Enums/UserManagementAuthenticationScreenHint.cs",
"src/WorkOS.net/Enums/VaultByokKeyVerificationCompletedDataKeyProvider.cs",
"src/WorkOS.net/Enums/VaultDataCreatedDataActorSource.cs",
+ "src/WorkOS.net/Enums/WaitlistUserState.cs",
"src/WorkOS.net/Enums/WidgetSessionTokenScopes.cs",
"src/WorkOS.net/Services/AdminPortal/AdminPortalService.cs",
"src/WorkOS.net/Services/AdminPortal/_interfaces/AdminPortalOptions.cs",
@@ -392,6 +401,8 @@
"src/WorkOS.net/Services/Events/_interfaces/EventsOptions.cs",
"src/WorkOS.net/Services/FeatureFlags/FeatureFlagsService.cs",
"src/WorkOS.net/Services/FeatureFlags/_interfaces/FeatureFlagsOptions.cs",
+ "src/WorkOS.net/Services/Groups/GroupsService.cs",
+ "src/WorkOS.net/Services/Groups/_interfaces/GroupsOptions.cs",
"src/WorkOS.net/Services/MultiFactorAuth/MultiFactorAuthService.cs",
"src/WorkOS.net/Services/MultiFactorAuth/_interfaces/MultiFactorAuthOptions.cs",
"src/WorkOS.net/Services/OrganizationDomains/OrganizationDomainsService.cs",
@@ -407,6 +418,8 @@
"src/WorkOS.net/Services/UserManagement/UserManagementService.cs",
"src/WorkOS.net/Services/UserManagement/_interfaces/UserManagementOptions.cs",
"src/WorkOS.net/Services/UserManagement/_interfaces/UserManagementWrapperOptions.cs",
+ "src/WorkOS.net/Services/UserManagementOrganizationMembershipGroups/UserManagementOrganizationMembershipGroupsService.cs",
+ "src/WorkOS.net/Services/UserManagementOrganizationMembershipGroups/_interfaces/UserManagementOrganizationMembershipGroupsOptions.cs",
"src/WorkOS.net/Services/Webhooks/WebhooksService.cs",
"src/WorkOS.net/Services/Webhooks/_interfaces/WebhooksOptions.cs",
"src/WorkOS.net/Services/Widgets/WidgetsService.cs",
@@ -419,12 +432,14 @@
"test/WorkOSTests/Tests/DirectorySyncServiceTest.cs",
"test/WorkOSTests/Tests/EventsServiceTest.cs",
"test/WorkOSTests/Tests/FeatureFlagsServiceTest.cs",
+ "test/WorkOSTests/Tests/GroupsServiceTest.cs",
"test/WorkOSTests/Tests/MultiFactorAuthServiceTest.cs",
"test/WorkOSTests/Tests/OrganizationDomainsServiceTest.cs",
"test/WorkOSTests/Tests/OrganizationsServiceTest.cs",
"test/WorkOSTests/Tests/PipesServiceTest.cs",
"test/WorkOSTests/Tests/RadarServiceTest.cs",
"test/WorkOSTests/Tests/SSOServiceTest.cs",
+ "test/WorkOSTests/Tests/UserManagementOrganizationMembershipGroupsServiceTest.cs",
"test/WorkOSTests/Tests/UserManagementServiceTest.cs",
"test/WorkOSTests/Tests/WebhooksServiceTest.cs",
"test/WorkOSTests/Tests/WidgetsServiceTest.cs",
@@ -649,6 +664,9 @@
"test/WorkOSTests/testdata/create_authorization_resource.json",
"test/WorkOSTests/testdata/create_authorization_resource_nulls.json",
"test/WorkOSTests/testdata/create_cors_origin.json",
+ "test/WorkOSTests/testdata/create_group.json",
+ "test/WorkOSTests/testdata/create_group_membership.json",
+ "test/WorkOSTests/testdata/create_group_nulls.json",
"test/WorkOSTests/testdata/create_m2m_application.json",
"test/WorkOSTests/testdata/create_m2m_application_nulls.json",
"test/WorkOSTests/testdata/create_magic_code_and_return.json",
@@ -704,6 +722,8 @@
"test/WorkOSTests/testdata/directory_user_with_groups_email.json",
"test/WorkOSTests/testdata/directory_user_with_groups_email_nulls.json",
"test/WorkOSTests/testdata/directory_user_with_groups_nulls.json",
+ "test/WorkOSTests/testdata/domain_verification_intent_options.json",
+ "test/WorkOSTests/testdata/domain_verification_intent_options_nulls.json",
"test/WorkOSTests/testdata/dsync_activated.json",
"test/WorkOSTests/testdata/dsync_activated_data.json",
"test/WorkOSTests/testdata/dsync_activated_data_domain.json",
@@ -839,6 +859,7 @@
"test/WorkOSTests/testdata/group_updated.json",
"test/WorkOSTests/testdata/group_updated_nulls.json",
"test/WorkOSTests/testdata/intent_options.json",
+ "test/WorkOSTests/testdata/intent_options_nulls.json",
"test/WorkOSTests/testdata/invitation.json",
"test/WorkOSTests/testdata/invitation_accepted.json",
"test/WorkOSTests/testdata/invitation_accepted_data.json",
@@ -886,6 +907,7 @@
"test/WorkOSTests/testdata/list_empty_directory_user_with_groups.json",
"test/WorkOSTests/testdata/list_empty_event_schema.json",
"test/WorkOSTests/testdata/list_empty_flag.json",
+ "test/WorkOSTests/testdata/list_empty_group.json",
"test/WorkOSTests/testdata/list_empty_organization.json",
"test/WorkOSTests/testdata/list_empty_role_assignment.json",
"test/WorkOSTests/testdata/list_empty_user.json",
@@ -896,6 +918,7 @@
"test/WorkOSTests/testdata/list_empty_webhook_endpoint_json.json",
"test/WorkOSTests/testdata/list_event_schema.json",
"test/WorkOSTests/testdata/list_flag.json",
+ "test/WorkOSTests/testdata/list_group.json",
"test/WorkOSTests/testdata/list_organization.json",
"test/WorkOSTests/testdata/list_role_assignment.json",
"test/WorkOSTests/testdata/list_user.json",
@@ -1085,6 +1108,8 @@
"test/WorkOSTests/testdata/update_authorization_permission_nulls.json",
"test/WorkOSTests/testdata/update_authorization_resource.json",
"test/WorkOSTests/testdata/update_authorization_resource_nulls.json",
+ "test/WorkOSTests/testdata/update_group.json",
+ "test/WorkOSTests/testdata/update_group_nulls.json",
"test/WorkOSTests/testdata/update_jwt_template.json",
"test/WorkOSTests/testdata/update_oauth_application.json",
"test/WorkOSTests/testdata/update_oauth_application_nulls.json",
@@ -1160,9 +1185,687 @@
"test/WorkOSTests/testdata/vault_names_listed_nulls.json",
"test/WorkOSTests/testdata/verify_email_address.json",
"test/WorkOSTests/testdata/verify_email_response.json",
+ "test/WorkOSTests/testdata/waitlist_user.json",
+ "test/WorkOSTests/testdata/waitlist_user_approved.json",
+ "test/WorkOSTests/testdata/waitlist_user_approved_nulls.json",
+ "test/WorkOSTests/testdata/waitlist_user_created.json",
+ "test/WorkOSTests/testdata/waitlist_user_created_nulls.json",
+ "test/WorkOSTests/testdata/waitlist_user_denied.json",
+ "test/WorkOSTests/testdata/waitlist_user_denied_nulls.json",
+ "test/WorkOSTests/testdata/waitlist_user_nulls.json",
"test/WorkOSTests/testdata/webhook_endpoint_json.json",
"test/WorkOSTests/testdata/widget_session_token.json",
"test/WorkOSTests/testdata/widget_session_token_nulls.json",
"test/WorkOSTests/testdata/widget_session_token_response.json"
- ]
+ ],
+ "operations": {
+ "POST /api_keys/validations": {
+ "sdkMethod": "CreateValidationAsync",
+ "service": "api_keys"
+ },
+ "DELETE /api_keys/{id}": {
+ "sdkMethod": "DeleteAsync",
+ "service": "api_keys"
+ },
+ "POST /auth/challenges/{id}/verify": {
+ "sdkMethod": "VerifyChallengeAsync",
+ "service": "multi_factor_auth"
+ },
+ "POST /auth/factors/enroll": {
+ "sdkMethod": "EnrollFactorAsync",
+ "service": "multi_factor_auth"
+ },
+ "GET /auth/factors/{id}": {
+ "sdkMethod": "GetFactorAsync",
+ "service": "multi_factor_auth"
+ },
+ "DELETE /auth/factors/{id}": {
+ "sdkMethod": "DeleteFactorAsync",
+ "service": "multi_factor_auth"
+ },
+ "POST /auth/factors/{id}/challenge": {
+ "sdkMethod": "ChallengeFactorAsync",
+ "service": "multi_factor_auth"
+ },
+ "POST /authkit/oauth2/complete": {
+ "sdkMethod": "CompleteOAuth2Async",
+ "service": "connect"
+ },
+ "POST /authorization/organization_memberships/{organization_membership_id}/check": {
+ "sdkMethod": "CheckAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/organization_memberships/{organization_membership_id}/resources": {
+ "sdkMethod": "ListResourcesForMembershipAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/organization_memberships/{organization_membership_id}/resources/{resource_id}/permissions": {
+ "sdkMethod": "ListEffectivePermissionsAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/organization_memberships/{organization_membership_id}/resources/{resource_type_slug}/{external_id}/permissions": {
+ "sdkMethod": "ListEffectivePermissionsByExternalIdAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/organization_memberships/{organization_membership_id}/role_assignments": {
+ "sdkMethod": "ListRoleAssignmentsAsync",
+ "service": "authorization"
+ },
+ "POST /authorization/organization_memberships/{organization_membership_id}/role_assignments": {
+ "sdkMethod": "AssignRoleAsync",
+ "service": "authorization"
+ },
+ "DELETE /authorization/organization_memberships/{organization_membership_id}/role_assignments": {
+ "sdkMethod": "RemoveRoleAsync",
+ "service": "authorization"
+ },
+ "DELETE /authorization/organization_memberships/{organization_membership_id}/role_assignments/{role_assignment_id}": {
+ "sdkMethod": "RemoveRoleAssignmentAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/organizations/{organizationId}/roles": {
+ "sdkMethod": "ListOrganizationRolesAsync",
+ "service": "authorization"
+ },
+ "POST /authorization/organizations/{organizationId}/roles": {
+ "sdkMethod": "CreateOrganizationRoleAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/organizations/{organizationId}/roles/{slug}": {
+ "sdkMethod": "GetOrganizationRoleAsync",
+ "service": "authorization"
+ },
+ "PATCH /authorization/organizations/{organizationId}/roles/{slug}": {
+ "sdkMethod": "UpdateOrganizationRoleAsync",
+ "service": "authorization"
+ },
+ "DELETE /authorization/organizations/{organizationId}/roles/{slug}": {
+ "sdkMethod": "DeleteOrganizationRoleAsync",
+ "service": "authorization"
+ },
+ "POST /authorization/organizations/{organizationId}/roles/{slug}/permissions": {
+ "sdkMethod": "AddOrganizationRolePermissionAsync",
+ "service": "authorization"
+ },
+ "PUT /authorization/organizations/{organizationId}/roles/{slug}/permissions": {
+ "sdkMethod": "SetOrganizationRolePermissionsAsync",
+ "service": "authorization"
+ },
+ "DELETE /authorization/organizations/{organizationId}/roles/{slug}/permissions/{permissionSlug}": {
+ "sdkMethod": "RemoveOrganizationRolePermissionAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/organizations/{organization_id}/resources/{resource_type_slug}/{external_id}": {
+ "sdkMethod": "GetResourceByExternalIdAsync",
+ "service": "authorization"
+ },
+ "PATCH /authorization/organizations/{organization_id}/resources/{resource_type_slug}/{external_id}": {
+ "sdkMethod": "UpdateResourceByExternalIdAsync",
+ "service": "authorization"
+ },
+ "DELETE /authorization/organizations/{organization_id}/resources/{resource_type_slug}/{external_id}": {
+ "sdkMethod": "DeleteResourceByExternalIdAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/organizations/{organization_id}/resources/{resource_type_slug}/{external_id}/organization_memberships": {
+ "sdkMethod": "ListMembershipsForResourceByExternalIdAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/resources": {
+ "sdkMethod": "ListResourcesAsync",
+ "service": "authorization"
+ },
+ "POST /authorization/resources": {
+ "sdkMethod": "CreateResourceAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/resources/{resource_id}": {
+ "sdkMethod": "GetResourceAsync",
+ "service": "authorization"
+ },
+ "PATCH /authorization/resources/{resource_id}": {
+ "sdkMethod": "UpdateResourceAsync",
+ "service": "authorization"
+ },
+ "DELETE /authorization/resources/{resource_id}": {
+ "sdkMethod": "DeleteResourceAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/resources/{resource_id}/organization_memberships": {
+ "sdkMethod": "ListMembershipsForResourceAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/roles": {
+ "sdkMethod": "ListEnvironmentRolesAsync",
+ "service": "authorization"
+ },
+ "POST /authorization/roles": {
+ "sdkMethod": "CreateEnvironmentRoleAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/roles/{slug}": {
+ "sdkMethod": "GetEnvironmentRoleAsync",
+ "service": "authorization"
+ },
+ "PATCH /authorization/roles/{slug}": {
+ "sdkMethod": "UpdateEnvironmentRoleAsync",
+ "service": "authorization"
+ },
+ "POST /authorization/roles/{slug}/permissions": {
+ "sdkMethod": "AddEnvironmentRolePermissionAsync",
+ "service": "authorization"
+ },
+ "PUT /authorization/roles/{slug}/permissions": {
+ "sdkMethod": "SetEnvironmentRolePermissionsAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/permissions": {
+ "sdkMethod": "ListPermissionsAsync",
+ "service": "authorization"
+ },
+ "POST /authorization/permissions": {
+ "sdkMethod": "CreatePermissionAsync",
+ "service": "authorization"
+ },
+ "GET /authorization/permissions/{slug}": {
+ "sdkMethod": "GetPermissionAsync",
+ "service": "authorization"
+ },
+ "PATCH /authorization/permissions/{slug}": {
+ "sdkMethod": "UpdatePermissionAsync",
+ "service": "authorization"
+ },
+ "DELETE /authorization/permissions/{slug}": {
+ "sdkMethod": "DeletePermissionAsync",
+ "service": "authorization"
+ },
+ "GET /connect/applications": {
+ "sdkMethod": "ListApplicationsAsync",
+ "service": "connect"
+ },
+ "POST /connect/applications": {
+ "sdkMethod": "CreateApplicationAsync",
+ "service": "connect"
+ },
+ "GET /connect/applications/{id}": {
+ "sdkMethod": "GetApplicationAsync",
+ "service": "connect"
+ },
+ "PUT /connect/applications/{id}": {
+ "sdkMethod": "UpdateApplicationAsync",
+ "service": "connect"
+ },
+ "DELETE /connect/applications/{id}": {
+ "sdkMethod": "DeleteApplicationAsync",
+ "service": "connect"
+ },
+ "GET /connect/applications/{id}/client_secrets": {
+ "sdkMethod": "ListApplicationClientSecretsAsync",
+ "service": "connect"
+ },
+ "POST /connect/applications/{id}/client_secrets": {
+ "sdkMethod": "CreateApplicationClientSecretAsync",
+ "service": "connect"
+ },
+ "DELETE /connect/client_secrets/{id}": {
+ "sdkMethod": "DeleteClientSecretAsync",
+ "service": "connect"
+ },
+ "GET /connections": {
+ "sdkMethod": "ListConnectionsAsync",
+ "service": "sso"
+ },
+ "GET /connections/{id}": {
+ "sdkMethod": "GetConnectionAsync",
+ "service": "sso"
+ },
+ "DELETE /connections/{id}": {
+ "sdkMethod": "DeleteConnectionAsync",
+ "service": "sso"
+ },
+ "POST /data-integrations/{slug}/authorize": {
+ "sdkMethod": "AuthorizeDataIntegrationAsync",
+ "service": "pipes"
+ },
+ "POST /data-integrations/{slug}/token": {
+ "sdkMethod": "CreateDataIntegrationTokenAsync",
+ "service": "pipes"
+ },
+ "GET /directories": {
+ "sdkMethod": "ListAsync",
+ "service": "directory_sync"
+ },
+ "GET /directories/{id}": {
+ "sdkMethod": "GetAsync",
+ "service": "directory_sync"
+ },
+ "DELETE /directories/{id}": {
+ "sdkMethod": "DeleteAsync",
+ "service": "directory_sync"
+ },
+ "GET /directory_groups": {
+ "sdkMethod": "ListGroupsAsync",
+ "service": "directory_sync"
+ },
+ "GET /directory_groups/{id}": {
+ "sdkMethod": "GetGroupAsync",
+ "service": "directory_sync"
+ },
+ "GET /directory_users": {
+ "sdkMethod": "ListUsersAsync",
+ "service": "directory_sync"
+ },
+ "GET /directory_users/{id}": {
+ "sdkMethod": "GetUserAsync",
+ "service": "directory_sync"
+ },
+ "GET /events": {
+ "sdkMethod": "ListAsync",
+ "service": "events"
+ },
+ "GET /feature-flags": {
+ "sdkMethod": "ListAsync",
+ "service": "feature_flags"
+ },
+ "GET /feature-flags/{slug}": {
+ "sdkMethod": "GetAsync",
+ "service": "feature_flags"
+ },
+ "PUT /feature-flags/{slug}/disable": {
+ "sdkMethod": "DisableAsync",
+ "service": "feature_flags"
+ },
+ "PUT /feature-flags/{slug}/enable": {
+ "sdkMethod": "EnableAsync",
+ "service": "feature_flags"
+ },
+ "POST /feature-flags/{slug}/targets/{resourceId}": {
+ "sdkMethod": "AddFlagTargetAsync",
+ "service": "feature_flags"
+ },
+ "DELETE /feature-flags/{slug}/targets/{resourceId}": {
+ "sdkMethod": "RemoveFlagTargetAsync",
+ "service": "feature_flags"
+ },
+ "POST /organization_domains": {
+ "sdkMethod": "CreateAsync",
+ "service": "organization_domains"
+ },
+ "GET /organization_domains/{id}": {
+ "sdkMethod": "GetAsync",
+ "service": "organization_domains"
+ },
+ "DELETE /organization_domains/{id}": {
+ "sdkMethod": "DeleteAsync",
+ "service": "organization_domains"
+ },
+ "POST /organization_domains/{id}/verify": {
+ "sdkMethod": "VerifyAsync",
+ "service": "organization_domains"
+ },
+ "GET /organizations": {
+ "sdkMethod": "ListAsync",
+ "service": "organizations"
+ },
+ "POST /organizations": {
+ "sdkMethod": "CreateAsync",
+ "service": "organizations"
+ },
+ "GET /organizations/external_id/{external_id}": {
+ "sdkMethod": "GetByExternalIdAsync",
+ "service": "organizations"
+ },
+ "GET /organizations/{id}": {
+ "sdkMethod": "GetAsync",
+ "service": "organizations"
+ },
+ "PUT /organizations/{id}": {
+ "sdkMethod": "UpdateAsync",
+ "service": "organizations"
+ },
+ "DELETE /organizations/{id}": {
+ "sdkMethod": "DeleteAsync",
+ "service": "organizations"
+ },
+ "GET /organizations/{id}/audit_log_configuration": {
+ "sdkMethod": "GetAuditLogConfigurationAsync",
+ "service": "organizations"
+ },
+ "GET /organizations/{id}/audit_logs_retention": {
+ "sdkMethod": "GetAuditLogsRetentionAsync",
+ "service": "audit_logs"
+ },
+ "PUT /organizations/{id}/audit_logs_retention": {
+ "sdkMethod": "UpdateAuditLogsRetentionAsync",
+ "service": "audit_logs"
+ },
+ "GET /organizations/{organizationId}/api_keys": {
+ "sdkMethod": "ListOrganizationApiKeysAsync",
+ "service": "api_keys"
+ },
+ "POST /organizations/{organizationId}/api_keys": {
+ "sdkMethod": "CreateOrganizationApiKeyAsync",
+ "service": "api_keys"
+ },
+ "GET /organizations/{organizationId}/feature-flags": {
+ "sdkMethod": "ListOrganizationFeatureFlagsAsync",
+ "service": "feature_flags"
+ },
+ "GET /organizations/{organizationId}/groups": {
+ "sdkMethod": "ListOrganizationGroupsAsync",
+ "service": "groups"
+ },
+ "POST /organizations/{organizationId}/groups": {
+ "sdkMethod": "CreateOrganizationGroupAsync",
+ "service": "groups"
+ },
+ "GET /organizations/{organizationId}/groups/{groupId}": {
+ "sdkMethod": "GetOrganizationGroupAsync",
+ "service": "groups"
+ },
+ "PATCH /organizations/{organizationId}/groups/{groupId}": {
+ "sdkMethod": "UpdateOrganizationGroupAsync",
+ "service": "groups"
+ },
+ "DELETE /organizations/{organizationId}/groups/{groupId}": {
+ "sdkMethod": "DeleteOrganizationGroupAsync",
+ "service": "groups"
+ },
+ "GET /organizations/{organizationId}/groups/{groupId}/organization-memberships": {
+ "sdkMethod": "ListOrganizationMembershipsAsync",
+ "service": "groups"
+ },
+ "POST /organizations/{organizationId}/groups/{groupId}/organization-memberships": {
+ "sdkMethod": "CreateOrganizationMembershipAsync",
+ "service": "groups"
+ },
+ "DELETE /organizations/{organizationId}/groups/{groupId}/organization-memberships/{omId}": {
+ "sdkMethod": "DeleteOrganizationMembershipAsync",
+ "service": "groups"
+ },
+ "POST /portal/generate_link": {
+ "sdkMethod": "GenerateLinkAsync",
+ "service": "admin_portal"
+ },
+ "POST /radar/attempts": {
+ "sdkMethod": "CreateAttemptAsync",
+ "service": "radar"
+ },
+ "PUT /radar/attempts/{id}": {
+ "sdkMethod": "UpdateAttemptAsync",
+ "service": "radar"
+ },
+ "POST /radar/lists/{type}/{action}": {
+ "sdkMethod": "AddListEntryAsync",
+ "service": "radar"
+ },
+ "DELETE /radar/lists/{type}/{action}": {
+ "sdkMethod": "RemoveListEntryAsync",
+ "service": "radar"
+ },
+ "GET /sso/authorize": {
+ "sdkMethod": "GetAuthorizationUrl",
+ "service": "sso"
+ },
+ "GET /sso/logout": {
+ "sdkMethod": "GetLogoutUrl",
+ "service": "sso"
+ },
+ "POST /sso/logout/authorize": {
+ "sdkMethod": "AuthorizeLogoutAsync",
+ "service": "sso"
+ },
+ "GET /sso/profile": {
+ "sdkMethod": "GetProfileAsync",
+ "service": "sso"
+ },
+ "POST /sso/token": {
+ "sdkMethod": "GetProfileAndTokenAsync",
+ "service": "sso"
+ },
+ "GET /sso/jwks/{clientId}": {
+ "sdkMethod": "GetJwksAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/authenticate": {
+ "sdkMethod": "CreateAuthenticateAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/authorize": {
+ "sdkMethod": "GetAuthorizationUrl",
+ "service": "user_management"
+ },
+ "POST /user_management/authorize/device": {
+ "sdkMethod": "CreateDeviceAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/sessions/logout": {
+ "sdkMethod": "GetLogoutUrl",
+ "service": "user_management"
+ },
+ "POST /user_management/sessions/revoke": {
+ "sdkMethod": "RevokeSessionAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/cors_origins": {
+ "sdkMethod": "CreateCorsOriginAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/email_verification/{id}": {
+ "sdkMethod": "GetEmailVerificationAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/password_reset": {
+ "sdkMethod": "ResetPasswordAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/password_reset/confirm": {
+ "sdkMethod": "ConfirmPasswordResetAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/password_reset/{id}": {
+ "sdkMethod": "GetPasswordResetAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/users": {
+ "sdkMethod": "ListAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/users": {
+ "sdkMethod": "CreateAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/users/external_id/{external_id}": {
+ "sdkMethod": "GetByExternalIdAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/users/{id}": {
+ "sdkMethod": "GetAsync",
+ "service": "user_management"
+ },
+ "PUT /user_management/users/{id}": {
+ "sdkMethod": "UpdateAsync",
+ "service": "user_management"
+ },
+ "DELETE /user_management/users/{id}": {
+ "sdkMethod": "DeleteAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/users/{id}/email_change/confirm": {
+ "sdkMethod": "ConfirmEmailChangeAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/users/{id}/email_change/send": {
+ "sdkMethod": "SendEmailChangeAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/users/{id}/email_verification/confirm": {
+ "sdkMethod": "VerifyEmailAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/users/{id}/email_verification/send": {
+ "sdkMethod": "SendVerificationEmailAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/users/{id}/identities": {
+ "sdkMethod": "GetIdentitiesAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/users/{id}/sessions": {
+ "sdkMethod": "ListSessionsAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/invitations": {
+ "sdkMethod": "ListInvitationsAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/invitations": {
+ "sdkMethod": "SendInvitationAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/invitations/by_token/{token}": {
+ "sdkMethod": "FindInvitationByTokenAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/invitations/{id}": {
+ "sdkMethod": "GetInvitationAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/invitations/{id}/accept": {
+ "sdkMethod": "AcceptInvitationAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/invitations/{id}/resend": {
+ "sdkMethod": "ResendInvitationAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/invitations/{id}/revoke": {
+ "sdkMethod": "RevokeInvitationAsync",
+ "service": "user_management"
+ },
+ "PUT /user_management/jwt_template": {
+ "sdkMethod": "UpdateJWTTemplateAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/magic_auth": {
+ "sdkMethod": "CreateMagicAuthAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/magic_auth/{id}": {
+ "sdkMethod": "GetMagicAuthAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/organization_memberships": {
+ "sdkMethod": "ListOrganizationMembershipsAsync",
+ "service": "user_management"
+ },
+ "POST /user_management/organization_memberships": {
+ "sdkMethod": "CreateOrganizationMembershipAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/organization_memberships/{id}": {
+ "sdkMethod": "GetOrganizationMembershipAsync",
+ "service": "user_management"
+ },
+ "PUT /user_management/organization_memberships/{id}": {
+ "sdkMethod": "UpdateOrganizationMembershipAsync",
+ "service": "user_management"
+ },
+ "DELETE /user_management/organization_memberships/{id}": {
+ "sdkMethod": "DeleteOrganizationMembershipAsync",
+ "service": "user_management"
+ },
+ "PUT /user_management/organization_memberships/{id}/deactivate": {
+ "sdkMethod": "DeactivateOrganizationMembershipAsync",
+ "service": "user_management"
+ },
+ "PUT /user_management/organization_memberships/{id}/reactivate": {
+ "sdkMethod": "ReactivateOrganizationMembershipAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/organization_memberships/{omId}/groups": {
+ "sdkMethod": "ListOrganizationMembershipGroupsAsync",
+ "service": "user_management_organization_membership_groups"
+ },
+ "POST /user_management/redirect_uris": {
+ "sdkMethod": "CreateRedirectUriAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/users/{userId}/feature-flags": {
+ "sdkMethod": "ListUserFeatureFlagsAsync",
+ "service": "feature_flags"
+ },
+ "GET /user_management/users/{user_id}/authorized_applications": {
+ "sdkMethod": "ListAuthorizedApplicationsAsync",
+ "service": "user_management"
+ },
+ "DELETE /user_management/users/{user_id}/authorized_applications/{application_id}": {
+ "sdkMethod": "DeleteAuthorizedApplicationAsync",
+ "service": "user_management"
+ },
+ "GET /user_management/users/{user_id}/connected_accounts/{slug}": {
+ "sdkMethod": "GetUserConnectedAccountAsync",
+ "service": "pipes"
+ },
+ "DELETE /user_management/users/{user_id}/connected_accounts/{slug}": {
+ "sdkMethod": "DeleteUserConnectedAccountAsync",
+ "service": "pipes"
+ },
+ "GET /user_management/users/{user_id}/data_providers": {
+ "sdkMethod": "ListUserDataProvidersAsync",
+ "service": "pipes"
+ },
+ "GET /user_management/users/{userlandUserId}/auth_factors": {
+ "sdkMethod": "ListUserAuthFactorsAsync",
+ "service": "multi_factor_auth"
+ },
+ "POST /user_management/users/{userlandUserId}/auth_factors": {
+ "sdkMethod": "CreateUserAuthFactorAsync",
+ "service": "multi_factor_auth"
+ },
+ "GET /webhook_endpoints": {
+ "sdkMethod": "ListEndpointsAsync",
+ "service": "webhooks"
+ },
+ "POST /webhook_endpoints": {
+ "sdkMethod": "CreateEndpointAsync",
+ "service": "webhooks"
+ },
+ "PATCH /webhook_endpoints/{id}": {
+ "sdkMethod": "UpdateEndpointAsync",
+ "service": "webhooks"
+ },
+ "DELETE /webhook_endpoints/{id}": {
+ "sdkMethod": "DeleteEndpointAsync",
+ "service": "webhooks"
+ },
+ "POST /widgets/token": {
+ "sdkMethod": "CreateTokenAsync",
+ "service": "widgets"
+ },
+ "GET /audit_logs/actions": {
+ "sdkMethod": "ListActionsAsync",
+ "service": "audit_logs"
+ },
+ "GET /audit_logs/actions/{actionName}/schemas": {
+ "sdkMethod": "ListActionSchemasAsync",
+ "service": "audit_logs"
+ },
+ "POST /audit_logs/actions/{actionName}/schemas": {
+ "sdkMethod": "CreateSchemaAsync",
+ "service": "audit_logs"
+ },
+ "POST /audit_logs/events": {
+ "sdkMethod": "CreateEventAsync",
+ "service": "audit_logs"
+ },
+ "POST /audit_logs/exports": {
+ "sdkMethod": "CreateExportAsync",
+ "service": "audit_logs"
+ },
+ "GET /audit_logs/exports/{auditLogExportId}": {
+ "sdkMethod": "GetExportAsync",
+ "service": "audit_logs"
+ }
+ }
}
diff --git a/src/WorkOS.net/Client/Utilities/EventSchemaDiscriminatorConverter.cs b/src/WorkOS.net/Client/Utilities/EventSchemaDiscriminatorConverter.cs
new file mode 100644
index 00000000..d3d48df5
--- /dev/null
+++ b/src/WorkOS.net/Client/Utilities/EventSchemaDiscriminatorConverter.cs
@@ -0,0 +1,129 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+ using Newtonsoft.Json;
+ using Newtonsoft.Json.Linq;
+
+ ///
+ /// JSON converter that deserializes into the
+ /// correct variant subclass based on the "event" property.
+ ///
+ public class EventSchemaDiscriminatorConverter : Newtonsoft.Json.JsonConverter
+ {
+ public override bool CanConvert(Type objectType) => typeof(EventSchema).IsAssignableFrom(objectType);
+
+ public override object ReadJson(Newtonsoft.Json.JsonReader reader, Type objectType, object? existingValue, Newtonsoft.Json.JsonSerializer serializer)
+ {
+ var jObject = JObject.Load(reader);
+ var discriminatorValue = jObject["event"]?.ToString();
+
+ object target;
+ switch (discriminatorValue)
+ {
+ case "action.authentication.denied": target = new ActionAuthenticationDenied(); break;
+ case "action.user_registration.denied": target = new ActionUserRegistrationDenied(); break;
+ case "api_key.created": target = new ApiKeyCreated(); break;
+ case "api_key.revoked": target = new ApiKeyRevoked(); break;
+ case "authentication.email_verification_failed": target = new AuthenticationEmailVerificationFailed(); break;
+ case "authentication.email_verification_succeeded": target = new AuthenticationEmailVerificationSucceeded(); break;
+ case "authentication.magic_auth_failed": target = new AuthenticationMagicAuthFailed(); break;
+ case "authentication.magic_auth_succeeded": target = new AuthenticationMagicAuthSucceeded(); break;
+ case "authentication.mfa_failed": target = new AuthenticationMfaFailed(); break;
+ case "authentication.mfa_succeeded": target = new AuthenticationMfaSucceeded(); break;
+ case "authentication.oauth_failed": target = new AuthenticationOAuthFailed(); break;
+ case "authentication.oauth_succeeded": target = new AuthenticationOAuthSucceeded(); break;
+ case "authentication.passkey_failed": target = new AuthenticationPasskeyFailed(); break;
+ case "authentication.passkey_succeeded": target = new AuthenticationPasskeySucceeded(); break;
+ case "authentication.password_failed": target = new AuthenticationPasswordFailed(); break;
+ case "authentication.password_succeeded": target = new AuthenticationPasswordSucceeded(); break;
+ case "authentication.radar_risk_detected": target = new AuthenticationRadarRiskDetected(); break;
+ case "authentication.sso_failed": target = new AuthenticationSSOFailed(); break;
+ case "authentication.sso_started": target = new AuthenticationSSOStarted(); break;
+ case "authentication.sso_succeeded": target = new AuthenticationSSOSucceeded(); break;
+ case "authentication.sso_timed_out": target = new AuthenticationSSOTimedOut(); break;
+ case "connection.activated": target = new ConnectionActivated(); break;
+ case "connection.deactivated": target = new ConnectionDeactivated(); break;
+ case "connection.deleted": target = new ConnectionDeleted(); break;
+ case "connection.saml_certificate_renewal_required": target = new ConnectionSAMLCertificateRenewalRequired(); break;
+ case "connection.saml_certificate_renewed": target = new ConnectionSAMLCertificateRenewed(); break;
+ case "dsync.activated": target = new DsyncActivated(); break;
+ case "dsync.deactivated": target = new DsyncDeactivated(); break;
+ case "dsync.deleted": target = new DsyncDeleted(); break;
+ case "dsync.group.created": target = new DsyncGroupCreated(); break;
+ case "dsync.group.deleted": target = new DsyncGroupDeleted(); break;
+ case "dsync.group.updated": target = new DsyncGroupUpdated(); break;
+ case "dsync.group.user_added": target = new DsyncGroupUserAdded(); break;
+ case "dsync.user.created": target = new DsyncUserCreated(); break;
+ case "dsync.user.deleted": target = new DsyncUserDeleted(); break;
+ case "dsync.group.user_removed": target = new DsyncGroupUserRemoved(); break;
+ case "dsync.user.updated": target = new DsyncUserUpdated(); break;
+ case "email_verification.created": target = new EmailVerificationCreated(); break;
+ case "flag.created": target = new FlagCreated(); break;
+ case "flag.deleted": target = new FlagDeleted(); break;
+ case "flag.rule_updated": target = new FlagRuleUpdated(); break;
+ case "flag.updated": target = new FlagUpdated(); break;
+ case "group.created": target = new GroupCreated(); break;
+ case "group.deleted": target = new GroupDeleted(); break;
+ case "group.member_added": target = new GroupMemberAdded(); break;
+ case "group.member_removed": target = new GroupMemberRemoved(); break;
+ case "group.updated": target = new GroupUpdated(); break;
+ case "invitation.accepted": target = new InvitationAccepted(); break;
+ case "invitation.created": target = new InvitationCreated(); break;
+ case "invitation.resent": target = new InvitationResent(); break;
+ case "invitation.revoked": target = new InvitationRevoked(); break;
+ case "magic_auth.created": target = new MagicAuthCreated(); break;
+ case "organization.created": target = new OrganizationCreated(); break;
+ case "organization.deleted": target = new OrganizationDeleted(); break;
+ case "organization_domain.created": target = new OrganizationDomainCreated(); break;
+ case "organization_domain.deleted": target = new OrganizationDomainDeleted(); break;
+ case "organization_domain.updated": target = new OrganizationDomainUpdated(); break;
+ case "organization_domain.verification_failed": target = new OrganizationDomainVerificationFailed(); break;
+ case "organization_domain.verified": target = new OrganizationDomainVerified(); break;
+ case "organization_membership.created": target = new OrganizationMembershipCreated(); break;
+ case "organization_membership.deleted": target = new OrganizationMembershipDeleted(); break;
+ case "organization_membership.updated": target = new OrganizationMembershipUpdated(); break;
+ case "organization_role.created": target = new OrganizationRoleCreated(); break;
+ case "organization_role.deleted": target = new OrganizationRoleDeleted(); break;
+ case "organization_role.updated": target = new OrganizationRoleUpdated(); break;
+ case "organization.updated": target = new OrganizationUpdated(); break;
+ case "password_reset.created": target = new PasswordResetCreated(); break;
+ case "password_reset.succeeded": target = new PasswordResetSucceeded(); break;
+ case "permission.created": target = new PermissionCreated(); break;
+ case "permission.deleted": target = new PermissionDeleted(); break;
+ case "permission.updated": target = new PermissionUpdated(); break;
+ case "role.created": target = new RoleCreated(); break;
+ case "role.deleted": target = new RoleDeleted(); break;
+ case "role.updated": target = new RoleUpdated(); break;
+ case "session.created": target = new SessionCreated(); break;
+ case "session.revoked": target = new SessionRevoked(); break;
+ case "user.created": target = new UserCreated(); break;
+ case "user.deleted": target = new UserDeleted(); break;
+ case "user.updated": target = new UserUpdated(); break;
+ case "vault.byok_key.verification_completed": target = new VaultByokKeyVerificationCompleted(); break;
+ case "vault.data.created": target = new VaultDataCreated(); break;
+ case "vault.data.deleted": target = new VaultDataDeleted(); break;
+ case "vault.data.read": target = new VaultDataRead(); break;
+ case "vault.data.updated": target = new VaultDataUpdated(); break;
+ case "vault.dek.decrypted": target = new VaultDekDecrypted(); break;
+ case "vault.dek.read": target = new VaultDekRead(); break;
+ case "vault.kek.created": target = new VaultKekCreated(); break;
+ case "vault.metadata.read": target = new VaultMetadataRead(); break;
+ case "vault.names.listed": target = new VaultNamesListed(); break;
+ case "waitlist_user.approved": target = new WaitlistUserApproved(); break;
+ case "waitlist_user.created": target = new WaitlistUserCreated(); break;
+ case "waitlist_user.denied": target = new WaitlistUserDenied(); break;
+ default: target = new EventSchema(); break;
+ }
+
+ serializer.Populate(jObject.CreateReader(), target);
+ return target;
+ }
+
+ public override void WriteJson(Newtonsoft.Json.JsonWriter writer, object? value, Newtonsoft.Json.JsonSerializer serializer)
+ {
+ serializer.Serialize(writer, value);
+ }
+ }
+}
diff --git a/src/WorkOS.net/Client/WorkOSClient.Generated.cs b/src/WorkOS.net/Client/WorkOSClient.Generated.cs
index eb48fa3f..424bfa2e 100644
--- a/src/WorkOS.net/Client/WorkOSClient.Generated.cs
+++ b/src/WorkOS.net/Client/WorkOSClient.Generated.cs
@@ -62,6 +62,11 @@ public partial class WorkOSClient
/// Gets the for organizations API operations.
public virtual OrganizationsService Organizations => this.organizations ??= new OrganizationsService(this);
+ private GroupsService groups;
+
+ /// Gets the for groups API operations.
+ public virtual GroupsService Groups => this.groups ??= new GroupsService(this);
+
private AdminPortalService adminPortal;
/// Gets the for admin portal API operations.
@@ -77,6 +82,11 @@ public partial class WorkOSClient
/// Gets the for user management API operations.
public virtual UserManagementService UserManagement => this.userManagement ??= new UserManagementService(this);
+ private UserManagementOrganizationMembershipGroupsService userManagementOrganizationMembershipGroups;
+
+ /// Gets the for user management organization membership groups API operations.
+ public virtual UserManagementOrganizationMembershipGroupsService UserManagementOrganizationMembershipGroups => this.userManagementOrganizationMembershipGroups ??= new UserManagementOrganizationMembershipGroupsService(this);
+
private WebhooksService webhooks;
/// Gets the for webhooks API operations.
diff --git a/src/WorkOS.net/Entities/ActionAuthenticationDenied.cs b/src/WorkOS.net/Entities/ActionAuthenticationDenied.cs
index a84b0cd3..619c4bbb 100644
--- a/src/WorkOS.net/Entities/ActionAuthenticationDenied.cs
+++ b/src/WorkOS.net/Entities/ActionAuthenticationDenied.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an action authentication denied.
- public class ActionAuthenticationDenied
+ public class ActionAuthenticationDenied : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "action.authentication.denied";
-
/// The event payload.
- public ActionAuthenticationDeniedData Data { get; set; } = default!;
- public EventContext? Context { get; set; }
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ActionAuthenticationDeniedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ActionUserRegistrationDenied.cs b/src/WorkOS.net/Entities/ActionUserRegistrationDenied.cs
index 1ccb43a8..bf3ab6f1 100644
--- a/src/WorkOS.net/Entities/ActionUserRegistrationDenied.cs
+++ b/src/WorkOS.net/Entities/ActionUserRegistrationDenied.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an action user registration denied.
- public class ActionUserRegistrationDenied
+ public class ActionUserRegistrationDenied : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "action.user_registration.denied";
-
/// The event payload.
- public ActionUserRegistrationDeniedData Data { get; set; } = default!;
- public EventContext? Context { get; set; }
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ActionUserRegistrationDeniedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ApiKeyCreated.cs b/src/WorkOS.net/Entities/ApiKeyCreated.cs
index aee185c7..810e8031 100644
--- a/src/WorkOS.net/Entities/ApiKeyCreated.cs
+++ b/src/WorkOS.net/Entities/ApiKeyCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an api key created.
- public class ApiKeyCreated
+ public class ApiKeyCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "api_key.created";
-
/// The event payload.
- public ApiKeyCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ApiKeyCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ApiKeyRevoked.cs b/src/WorkOS.net/Entities/ApiKeyRevoked.cs
index 2bf9b574..88cfb4b9 100644
--- a/src/WorkOS.net/Entities/ApiKeyRevoked.cs
+++ b/src/WorkOS.net/Entities/ApiKeyRevoked.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an api key revoked.
- public class ApiKeyRevoked
+ public class ApiKeyRevoked : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "api_key.revoked";
-
/// The event payload.
- public ApiKeyCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ApiKeyCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationEmailVerificationFailed.cs b/src/WorkOS.net/Entities/AuthenticationEmailVerificationFailed.cs
index 882b7fc0..ad6fe1a4 100644
--- a/src/WorkOS.net/Entities/AuthenticationEmailVerificationFailed.cs
+++ b/src/WorkOS.net/Entities/AuthenticationEmailVerificationFailed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication email verification failed.
- public class AuthenticationEmailVerificationFailed
+ public class AuthenticationEmailVerificationFailed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.email_verification_failed";
-
/// The event payload.
- public AuthenticationEmailVerificationFailedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationEmailVerificationFailedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationEmailVerificationSucceeded.cs b/src/WorkOS.net/Entities/AuthenticationEmailVerificationSucceeded.cs
index cf5a8ef2..7f988c91 100644
--- a/src/WorkOS.net/Entities/AuthenticationEmailVerificationSucceeded.cs
+++ b/src/WorkOS.net/Entities/AuthenticationEmailVerificationSucceeded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication email verification succeeded.
- public class AuthenticationEmailVerificationSucceeded
+ public class AuthenticationEmailVerificationSucceeded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.email_verification_succeeded";
-
/// The event payload.
- public AuthenticationEmailVerificationSucceededData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationEmailVerificationSucceededData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationMagicAuthFailed.cs b/src/WorkOS.net/Entities/AuthenticationMagicAuthFailed.cs
index 8d7a8785..19166fa8 100644
--- a/src/WorkOS.net/Entities/AuthenticationMagicAuthFailed.cs
+++ b/src/WorkOS.net/Entities/AuthenticationMagicAuthFailed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication magic auth failed.
- public class AuthenticationMagicAuthFailed
+ public class AuthenticationMagicAuthFailed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.magic_auth_failed";
-
/// The event payload.
- public AuthenticationMagicAuthFailedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationMagicAuthFailedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationMagicAuthSucceeded.cs b/src/WorkOS.net/Entities/AuthenticationMagicAuthSucceeded.cs
index d0bd8a01..a73cab52 100644
--- a/src/WorkOS.net/Entities/AuthenticationMagicAuthSucceeded.cs
+++ b/src/WorkOS.net/Entities/AuthenticationMagicAuthSucceeded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication magic auth succeeded.
- public class AuthenticationMagicAuthSucceeded
+ public class AuthenticationMagicAuthSucceeded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.magic_auth_succeeded";
-
/// The event payload.
- public AuthenticationMagicAuthSucceededData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationMagicAuthSucceededData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationMfaFailed.cs b/src/WorkOS.net/Entities/AuthenticationMfaFailed.cs
index 36e26990..5267f6d9 100644
--- a/src/WorkOS.net/Entities/AuthenticationMfaFailed.cs
+++ b/src/WorkOS.net/Entities/AuthenticationMfaFailed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication mfa failed.
- public class AuthenticationMfaFailed
+ public class AuthenticationMfaFailed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.mfa_failed";
-
/// The event payload.
- public AuthenticationMfaFailedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationMfaFailedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationMfaSucceeded.cs b/src/WorkOS.net/Entities/AuthenticationMfaSucceeded.cs
index fe0ba871..60b05683 100644
--- a/src/WorkOS.net/Entities/AuthenticationMfaSucceeded.cs
+++ b/src/WorkOS.net/Entities/AuthenticationMfaSucceeded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication mfa succeeded.
- public class AuthenticationMfaSucceeded
+ public class AuthenticationMfaSucceeded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.mfa_succeeded";
-
/// The event payload.
- public AuthenticationMfaSucceededData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationMfaSucceededData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationOAuthFailed.cs b/src/WorkOS.net/Entities/AuthenticationOAuthFailed.cs
index 6a279164..34ca69ca 100644
--- a/src/WorkOS.net/Entities/AuthenticationOAuthFailed.cs
+++ b/src/WorkOS.net/Entities/AuthenticationOAuthFailed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication o auth failed.
- public class AuthenticationOAuthFailed
+ public class AuthenticationOAuthFailed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.oauth_failed";
-
/// The event payload.
- public AuthenticationOAuthFailedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationOAuthFailedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationOAuthSucceeded.cs b/src/WorkOS.net/Entities/AuthenticationOAuthSucceeded.cs
index a06152dc..9fef022b 100644
--- a/src/WorkOS.net/Entities/AuthenticationOAuthSucceeded.cs
+++ b/src/WorkOS.net/Entities/AuthenticationOAuthSucceeded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication o auth succeeded.
- public class AuthenticationOAuthSucceeded
+ public class AuthenticationOAuthSucceeded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.oauth_succeeded";
-
/// The event payload.
- public AuthenticationOAuthSucceededData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationOAuthSucceededData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationPasskeyFailed.cs b/src/WorkOS.net/Entities/AuthenticationPasskeyFailed.cs
index eb3ee4b1..dba804d8 100644
--- a/src/WorkOS.net/Entities/AuthenticationPasskeyFailed.cs
+++ b/src/WorkOS.net/Entities/AuthenticationPasskeyFailed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication passkey failed.
- public class AuthenticationPasskeyFailed
+ public class AuthenticationPasskeyFailed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.passkey_failed";
-
/// The event payload.
- public AuthenticationPasskeyFailedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationPasskeyFailedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationPasskeySucceeded.cs b/src/WorkOS.net/Entities/AuthenticationPasskeySucceeded.cs
index 7ad2b0b1..057eb2bf 100644
--- a/src/WorkOS.net/Entities/AuthenticationPasskeySucceeded.cs
+++ b/src/WorkOS.net/Entities/AuthenticationPasskeySucceeded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication passkey succeeded.
- public class AuthenticationPasskeySucceeded
+ public class AuthenticationPasskeySucceeded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.passkey_succeeded";
-
/// The event payload.
- public AuthenticationPasskeySucceededData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationPasskeySucceededData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationPasswordFailed.cs b/src/WorkOS.net/Entities/AuthenticationPasswordFailed.cs
index 9f62411b..f45190a2 100644
--- a/src/WorkOS.net/Entities/AuthenticationPasswordFailed.cs
+++ b/src/WorkOS.net/Entities/AuthenticationPasswordFailed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication password failed.
- public class AuthenticationPasswordFailed
+ public class AuthenticationPasswordFailed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.password_failed";
-
/// The event payload.
- public AuthenticationPasswordFailedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationPasswordFailedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationPasswordSucceeded.cs b/src/WorkOS.net/Entities/AuthenticationPasswordSucceeded.cs
index 024235c2..6f53e5a6 100644
--- a/src/WorkOS.net/Entities/AuthenticationPasswordSucceeded.cs
+++ b/src/WorkOS.net/Entities/AuthenticationPasswordSucceeded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication password succeeded.
- public class AuthenticationPasswordSucceeded
+ public class AuthenticationPasswordSucceeded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.password_succeeded";
-
/// The event payload.
- public AuthenticationPasswordSucceededData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationPasswordSucceededData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationRadarRiskDetected.cs b/src/WorkOS.net/Entities/AuthenticationRadarRiskDetected.cs
index bf2cd49f..c973f04b 100644
--- a/src/WorkOS.net/Entities/AuthenticationRadarRiskDetected.cs
+++ b/src/WorkOS.net/Entities/AuthenticationRadarRiskDetected.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication radar risk detected.
- public class AuthenticationRadarRiskDetected
+ public class AuthenticationRadarRiskDetected : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.radar_risk_detected";
-
/// The event payload.
- public AuthenticationRadarRiskDetectedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationRadarRiskDetectedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationSSOFailed.cs b/src/WorkOS.net/Entities/AuthenticationSSOFailed.cs
index 53d27c9f..3dffbb8d 100644
--- a/src/WorkOS.net/Entities/AuthenticationSSOFailed.cs
+++ b/src/WorkOS.net/Entities/AuthenticationSSOFailed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication SSO failed.
- public class AuthenticationSSOFailed
+ public class AuthenticationSSOFailed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.sso_failed";
-
/// The event payload.
- public AuthenticationSSOFailedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationSSOFailedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationSSOStarted.cs b/src/WorkOS.net/Entities/AuthenticationSSOStarted.cs
index a5a625c9..cd65a91d 100644
--- a/src/WorkOS.net/Entities/AuthenticationSSOStarted.cs
+++ b/src/WorkOS.net/Entities/AuthenticationSSOStarted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication SSO started.
- public class AuthenticationSSOStarted
+ public class AuthenticationSSOStarted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.sso_started";
-
/// The event payload.
- public AuthenticationSSOStartedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationSSOStartedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationSSOSucceeded.cs b/src/WorkOS.net/Entities/AuthenticationSSOSucceeded.cs
index f0ed283f..887e6ce0 100644
--- a/src/WorkOS.net/Entities/AuthenticationSSOSucceeded.cs
+++ b/src/WorkOS.net/Entities/AuthenticationSSOSucceeded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication SSO succeeded.
- public class AuthenticationSSOSucceeded
+ public class AuthenticationSSOSucceeded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.sso_succeeded";
-
/// The event payload.
- public AuthenticationSSOSucceededData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationSSOSucceededData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/AuthenticationSSOTimedOut.cs b/src/WorkOS.net/Entities/AuthenticationSSOTimedOut.cs
index bde23493..db125f06 100644
--- a/src/WorkOS.net/Entities/AuthenticationSSOTimedOut.cs
+++ b/src/WorkOS.net/Entities/AuthenticationSSOTimedOut.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an authentication SSO timed out.
- public class AuthenticationSSOTimedOut
+ public class AuthenticationSSOTimedOut : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "authentication.sso_timed_out";
-
/// The event payload.
- public AuthenticationSSOTimedOutData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new AuthenticationSSOTimedOutData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ConnectApplication.cs b/src/WorkOS.net/Entities/ConnectApplication.cs
index 68f0b823..822c2fba 100644
--- a/src/WorkOS.net/Entities/ConnectApplication.cs
+++ b/src/WorkOS.net/Entities/ConnectApplication.cs
@@ -34,7 +34,7 @@ public class ConnectApplication
public DateTimeOffset UpdatedAt { get; set; }
/// The type of the application.
- public string ApplicationType { get; internal set; } = "m2m";
+ public string? ApplicationType { get; set; }
/// The ID of the organization the application belongs to.
public string? OrganizationId { get; set; }
@@ -46,9 +46,9 @@ public class ConnectApplication
public bool? UsesPkce { get; set; }
/// Whether the application is a first-party application.
- public bool IsFirstParty { get; internal set; } = true;
+ public bool? IsFirstParty { get; set; }
/// Whether the application was dynamically registered.
- public bool WasDynamicallyRegistered { get; internal set; } = false;
+ public bool? WasDynamicallyRegistered { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ConnectionActivated.cs b/src/WorkOS.net/Entities/ConnectionActivated.cs
index 8afd58d0..26bbc9a7 100644
--- a/src/WorkOS.net/Entities/ConnectionActivated.cs
+++ b/src/WorkOS.net/Entities/ConnectionActivated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a connection activated.
- public class ConnectionActivated
+ public class ConnectionActivated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "connection.activated";
-
/// The event payload.
- public ConnectionActivatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ConnectionActivatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ConnectionDeactivated.cs b/src/WorkOS.net/Entities/ConnectionDeactivated.cs
index 56edb266..d451eb4d 100644
--- a/src/WorkOS.net/Entities/ConnectionDeactivated.cs
+++ b/src/WorkOS.net/Entities/ConnectionDeactivated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a connection deactivated.
- public class ConnectionDeactivated
+ public class ConnectionDeactivated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "connection.deactivated";
-
/// The event payload.
- public ConnectionActivatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ConnectionActivatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ConnectionDeleted.cs b/src/WorkOS.net/Entities/ConnectionDeleted.cs
index 1c491907..2c95a49b 100644
--- a/src/WorkOS.net/Entities/ConnectionDeleted.cs
+++ b/src/WorkOS.net/Entities/ConnectionDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a connection deleted.
- public class ConnectionDeleted
+ public class ConnectionDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "connection.deleted";
-
/// The event payload.
- public ConnectionDeletedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ConnectionDeletedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ConnectionSAMLCertificateRenewalRequired.cs b/src/WorkOS.net/Entities/ConnectionSAMLCertificateRenewalRequired.cs
index 60f199ec..27afca44 100644
--- a/src/WorkOS.net/Entities/ConnectionSAMLCertificateRenewalRequired.cs
+++ b/src/WorkOS.net/Entities/ConnectionSAMLCertificateRenewalRequired.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a connection SAML certificate renewal required.
- public class ConnectionSAMLCertificateRenewalRequired
+ public class ConnectionSAMLCertificateRenewalRequired : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "connection.saml_certificate_renewal_required";
-
/// The event payload.
- public ConnectionSAMLCertificateRenewalRequiredData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ConnectionSAMLCertificateRenewalRequiredData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/ConnectionSAMLCertificateRenewed.cs b/src/WorkOS.net/Entities/ConnectionSAMLCertificateRenewed.cs
index d9c8c2df..505ff18f 100644
--- a/src/WorkOS.net/Entities/ConnectionSAMLCertificateRenewed.cs
+++ b/src/WorkOS.net/Entities/ConnectionSAMLCertificateRenewed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a connection SAML certificate renewed.
- public class ConnectionSAMLCertificateRenewed
+ public class ConnectionSAMLCertificateRenewed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "connection.saml_certificate_renewed";
-
/// The event payload.
- public ConnectionSAMLCertificateRenewedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new ConnectionSAMLCertificateRenewedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/CreateGroup.cs b/src/WorkOS.net/Entities/CreateGroup.cs
new file mode 100644
index 00000000..654cbcba
--- /dev/null
+++ b/src/WorkOS.net/Entities/CreateGroup.cs
@@ -0,0 +1,16 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+
+ /// Represents a create group.
+ public class CreateGroup
+ {
+
+ /// The name of the Group.
+ public string Name { get; set; } = default!;
+
+ /// An optional description of the Group.
+ public string? Description { get; set; }
+ }
+}
diff --git a/src/WorkOS.net/Entities/CreateGroupMembership.cs b/src/WorkOS.net/Entities/CreateGroupMembership.cs
new file mode 100644
index 00000000..5b224d5a
--- /dev/null
+++ b/src/WorkOS.net/Entities/CreateGroupMembership.cs
@@ -0,0 +1,13 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+
+ /// Represents a create group membership.
+ public class CreateGroupMembership
+ {
+
+ /// The ID of the Organization Membership to add to the group.
+ public string OrganizationMembershipId { get; set; } = default!;
+ }
+}
diff --git a/src/WorkOS.net/Entities/DataIntegrationAccessTokenResponse.cs b/src/WorkOS.net/Entities/DataIntegrationAccessTokenResponse.cs
index 3f39603f..7c5461c2 100644
--- a/src/WorkOS.net/Entities/DataIntegrationAccessTokenResponse.cs
+++ b/src/WorkOS.net/Entities/DataIntegrationAccessTokenResponse.cs
@@ -8,7 +8,7 @@ public class DataIntegrationAccessTokenResponse
{
/// Indicates whether the access token is valid and ready for use, or if reauthorization is required.
- public bool Active { get; internal set; } = true;
+ public bool? Active { get; set; }
/// The [access token](https://workos.com/docs/reference/pipes/access-token) object, present when `active` is `true`.
public DataIntegrationAccessTokenResponseAccessToken? AccessToken { get; set; }
diff --git a/src/WorkOS.net/Entities/DirectoryUserWithGroups.cs b/src/WorkOS.net/Entities/DirectoryUserWithGroups.cs
index 61266a7f..e311b11b 100644
--- a/src/WorkOS.net/Entities/DirectoryUserWithGroups.cs
+++ b/src/WorkOS.net/Entities/DirectoryUserWithGroups.cs
@@ -69,7 +69,8 @@ public class DirectoryUserWithGroups
/// An ISO 8601 timestamp.
public DateTimeOffset UpdatedAt { get; set; }
- /// The directory groups the user belongs to.
+ /// The directory groups the user belongs to. Use the List Directory Groups endpoint with a user filter instead.
+ [System.Obsolete("This field is deprecated.")]
public List Groups { get; set; } = default!;
///
diff --git a/src/WorkOS.net/Entities/DomainVerificationIntentOptions.cs b/src/WorkOS.net/Entities/DomainVerificationIntentOptions.cs
new file mode 100644
index 00000000..bf376c5e
--- /dev/null
+++ b/src/WorkOS.net/Entities/DomainVerificationIntentOptions.cs
@@ -0,0 +1,13 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+
+ /// Represents a domain verification intent options.
+ public class DomainVerificationIntentOptions
+ {
+
+ /// The domain name to verify. When provided, the domain verification flow will skip the domain entry form and go directly to the verification step.
+ public string? DomainName { get; set; }
+ }
+}
diff --git a/src/WorkOS.net/Entities/DsyncActivated.cs b/src/WorkOS.net/Entities/DsyncActivated.cs
index f6cbfbb2..3b6ab25f 100644
--- a/src/WorkOS.net/Entities/DsyncActivated.cs
+++ b/src/WorkOS.net/Entities/DsyncActivated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync activated.
- public class DsyncActivated
+ public class DsyncActivated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.activated";
-
/// The event payload.
- public DsyncActivatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DsyncActivatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncDeactivated.cs b/src/WorkOS.net/Entities/DsyncDeactivated.cs
index 097be397..ff659947 100644
--- a/src/WorkOS.net/Entities/DsyncDeactivated.cs
+++ b/src/WorkOS.net/Entities/DsyncDeactivated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync deactivated.
- public class DsyncDeactivated
+ public class DsyncDeactivated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.deactivated";
-
/// The event payload.
- public DsyncActivatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DsyncActivatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncDeleted.cs b/src/WorkOS.net/Entities/DsyncDeleted.cs
index 6d15d9c1..a7a282bc 100644
--- a/src/WorkOS.net/Entities/DsyncDeleted.cs
+++ b/src/WorkOS.net/Entities/DsyncDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync deleted.
- public class DsyncDeleted
+ public class DsyncDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.deleted";
-
/// The event payload.
- public DsyncDeletedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DsyncDeletedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncGroupCreated.cs b/src/WorkOS.net/Entities/DsyncGroupCreated.cs
index ee0902e0..ad4cd934 100644
--- a/src/WorkOS.net/Entities/DsyncGroupCreated.cs
+++ b/src/WorkOS.net/Entities/DsyncGroupCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync group created.
- public class DsyncGroupCreated
+ public class DsyncGroupCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.group.created";
-
/// The event payload.
- public DirectoryGroup Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DirectoryGroup Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncGroupDeleted.cs b/src/WorkOS.net/Entities/DsyncGroupDeleted.cs
index 149a3b7a..fdd7257a 100644
--- a/src/WorkOS.net/Entities/DsyncGroupDeleted.cs
+++ b/src/WorkOS.net/Entities/DsyncGroupDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync group deleted.
- public class DsyncGroupDeleted
+ public class DsyncGroupDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.group.deleted";
-
/// The event payload.
- public DirectoryGroup Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DirectoryGroup Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncGroupUpdated.cs b/src/WorkOS.net/Entities/DsyncGroupUpdated.cs
index f0c541ce..8828fe3f 100644
--- a/src/WorkOS.net/Entities/DsyncGroupUpdated.cs
+++ b/src/WorkOS.net/Entities/DsyncGroupUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync group updated.
- public class DsyncGroupUpdated
+ public class DsyncGroupUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.group.updated";
-
/// The event payload.
- public DsyncGroupUpdatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DsyncGroupUpdatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncGroupUserAdded.cs b/src/WorkOS.net/Entities/DsyncGroupUserAdded.cs
index 295c5126..2d9810b4 100644
--- a/src/WorkOS.net/Entities/DsyncGroupUserAdded.cs
+++ b/src/WorkOS.net/Entities/DsyncGroupUserAdded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync group user added.
- public class DsyncGroupUserAdded
+ public class DsyncGroupUserAdded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.group.user_added";
-
/// The event payload.
- public DsyncGroupUserAddedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DsyncGroupUserAddedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncGroupUserRemoved.cs b/src/WorkOS.net/Entities/DsyncGroupUserRemoved.cs
index 360dac04..0f05f626 100644
--- a/src/WorkOS.net/Entities/DsyncGroupUserRemoved.cs
+++ b/src/WorkOS.net/Entities/DsyncGroupUserRemoved.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync group user removed.
- public class DsyncGroupUserRemoved
+ public class DsyncGroupUserRemoved : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.group.user_removed";
-
/// The event payload.
- public DsyncGroupUserAddedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DsyncGroupUserAddedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncUserCreated.cs b/src/WorkOS.net/Entities/DsyncUserCreated.cs
index 533456d2..b63e9370 100644
--- a/src/WorkOS.net/Entities/DsyncUserCreated.cs
+++ b/src/WorkOS.net/Entities/DsyncUserCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync user created.
- public class DsyncUserCreated
+ public class DsyncUserCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.user.created";
-
/// The event payload.
- public DirectoryUser Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DirectoryUser Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncUserDeleted.cs b/src/WorkOS.net/Entities/DsyncUserDeleted.cs
index dfbc4d5d..8c085560 100644
--- a/src/WorkOS.net/Entities/DsyncUserDeleted.cs
+++ b/src/WorkOS.net/Entities/DsyncUserDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync user deleted.
- public class DsyncUserDeleted
+ public class DsyncUserDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.user.deleted";
-
/// The event payload.
- public DirectoryUser Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DirectoryUser Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/DsyncUserUpdated.cs b/src/WorkOS.net/Entities/DsyncUserUpdated.cs
index eda6e626..e810e393 100644
--- a/src/WorkOS.net/Entities/DsyncUserUpdated.cs
+++ b/src/WorkOS.net/Entities/DsyncUserUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a dsync user updated.
- public class DsyncUserUpdated
+ public class DsyncUserUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "dsync.user.updated";
-
/// The event payload.
- public DsyncUserUpdatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new DsyncUserUpdatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/EmailVerificationCreated.cs b/src/WorkOS.net/Entities/EmailVerificationCreated.cs
index 1764c1e7..4a7fd6db 100644
--- a/src/WorkOS.net/Entities/EmailVerificationCreated.cs
+++ b/src/WorkOS.net/Entities/EmailVerificationCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an email verification created.
- public class EmailVerificationCreated
+ public class EmailVerificationCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "email_verification.created";
-
/// The event payload.
- public EmailVerificationCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new EmailVerificationCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/EventSchema.cs b/src/WorkOS.net/Entities/EventSchema.cs
index 6f8f7ac3..0a5e8f8f 100644
--- a/src/WorkOS.net/Entities/EventSchema.cs
+++ b/src/WorkOS.net/Entities/EventSchema.cs
@@ -6,6 +6,7 @@ namespace WorkOS
using System.Collections.Generic;
/// An event emitted by WorkOS.
+ [Newtonsoft.Json.JsonConverter(typeof(EventSchemaDiscriminatorConverter))]
public class EventSchema
{
diff --git a/src/WorkOS.net/Entities/FlagCreated.cs b/src/WorkOS.net/Entities/FlagCreated.cs
index 0eab75b0..e3e05284 100644
--- a/src/WorkOS.net/Entities/FlagCreated.cs
+++ b/src/WorkOS.net/Entities/FlagCreated.cs
@@ -5,23 +5,13 @@ namespace WorkOS
using System;
/// Represents a flag created.
- public class FlagCreated
+ public class FlagCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "flag.created";
-
/// The event payload.
- public FlagCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
+ public new FlagCreatedData Data { get; set; } = default!;
/// Additional context about the event.
- public EventSchemaContext Context { get; set; } = default!;
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new FlagCreatedContext Context { get; set; } = default!;
}
}
diff --git a/src/WorkOS.net/Entities/EventSchemaContext.cs b/src/WorkOS.net/Entities/FlagCreatedContext.cs
similarity index 92%
rename from src/WorkOS.net/Entities/EventSchemaContext.cs
rename to src/WorkOS.net/Entities/FlagCreatedContext.cs
index fa9a4885..f685b616 100644
--- a/src/WorkOS.net/Entities/EventSchemaContext.cs
+++ b/src/WorkOS.net/Entities/FlagCreatedContext.cs
@@ -4,7 +4,7 @@ namespace WorkOS
{
/// Additional context about the event.
- public class EventSchemaContext
+ public class FlagCreatedContext
{
/// The client ID associated with the flag event.
diff --git a/src/WorkOS.net/Entities/FlagDeleted.cs b/src/WorkOS.net/Entities/FlagDeleted.cs
index 7dfa487a..8c554f19 100644
--- a/src/WorkOS.net/Entities/FlagDeleted.cs
+++ b/src/WorkOS.net/Entities/FlagDeleted.cs
@@ -5,23 +5,13 @@ namespace WorkOS
using System;
/// Represents a flag deleted.
- public class FlagDeleted
+ public class FlagDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "flag.deleted";
-
/// The event payload.
- public FlagCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
+ public new FlagCreatedData Data { get; set; } = default!;
/// Additional context about the event.
- public EventSchemaContext Context { get; set; } = default!;
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new FlagCreatedContext Context { get; set; } = default!;
}
}
diff --git a/src/WorkOS.net/Entities/FlagRuleUpdated.cs b/src/WorkOS.net/Entities/FlagRuleUpdated.cs
index 279bfa2e..89f388f8 100644
--- a/src/WorkOS.net/Entities/FlagRuleUpdated.cs
+++ b/src/WorkOS.net/Entities/FlagRuleUpdated.cs
@@ -5,23 +5,13 @@ namespace WorkOS
using System;
/// Represents a flag rule updated.
- public class FlagRuleUpdated
+ public class FlagRuleUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "flag.rule_updated";
-
/// The event payload.
- public FlagCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
+ public new FlagCreatedData Data { get; set; } = default!;
/// Additional context about the event.
- public FlagRuleUpdatedContext Context { get; set; } = default!;
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new FlagRuleUpdatedContext Context { get; set; } = default!;
}
}
diff --git a/src/WorkOS.net/Entities/FlagUpdated.cs b/src/WorkOS.net/Entities/FlagUpdated.cs
index 42e2103f..1d70ff86 100644
--- a/src/WorkOS.net/Entities/FlagUpdated.cs
+++ b/src/WorkOS.net/Entities/FlagUpdated.cs
@@ -5,23 +5,13 @@ namespace WorkOS
using System;
/// Represents a flag updated.
- public class FlagUpdated
+ public class FlagUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "flag.updated";
-
/// The event payload.
- public FlagCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
+ public new FlagCreatedData Data { get; set; } = default!;
/// Additional context about the event.
- public FlagUpdatedContext Context { get; set; } = default!;
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new FlagUpdatedContext Context { get; set; } = default!;
}
}
diff --git a/src/WorkOS.net/Entities/GenerateLink.cs b/src/WorkOS.net/Entities/GenerateLink.cs
index 65c94eed..7faab1f6 100644
--- a/src/WorkOS.net/Entities/GenerateLink.cs
+++ b/src/WorkOS.net/Entities/GenerateLink.cs
@@ -32,7 +32,7 @@ public class GenerateLink
/// Options to configure the Admin Portal based on the intent.
public IntentOptions? IntentOptions { get; set; }
- /// The email addresses of the IT admins to grant access to the Admin Portal for the given organization. Accepts up to 20 emails.
- public List? AdminEmails { get; set; }
+ /// The email addresses of the IT contacts to grant access to the Admin Portal for the given organization. Accepts up to 20 emails.
+ public List? ItContactEmails { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/GroupCreated.cs b/src/WorkOS.net/Entities/GroupCreated.cs
index 533d10f5..bd7bc96f 100644
--- a/src/WorkOS.net/Entities/GroupCreated.cs
+++ b/src/WorkOS.net/Entities/GroupCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a group created.
- public class GroupCreated
+ public class GroupCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "group.created";
-
/// The event payload.
- public Group Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new Group Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/GroupDeleted.cs b/src/WorkOS.net/Entities/GroupDeleted.cs
index 8fd19637..e70dd159 100644
--- a/src/WorkOS.net/Entities/GroupDeleted.cs
+++ b/src/WorkOS.net/Entities/GroupDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a group deleted.
- public class GroupDeleted
+ public class GroupDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "group.deleted";
-
/// The event payload.
- public Group Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new Group Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/GroupMemberAdded.cs b/src/WorkOS.net/Entities/GroupMemberAdded.cs
index ae2a18e5..21d9dd24 100644
--- a/src/WorkOS.net/Entities/GroupMemberAdded.cs
+++ b/src/WorkOS.net/Entities/GroupMemberAdded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a group member added.
- public class GroupMemberAdded
+ public class GroupMemberAdded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "group.member_added";
-
/// The event payload.
- public GroupMemberAddedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new GroupMemberAddedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/GroupMemberRemoved.cs b/src/WorkOS.net/Entities/GroupMemberRemoved.cs
index a1897bbf..f0f7eb06 100644
--- a/src/WorkOS.net/Entities/GroupMemberRemoved.cs
+++ b/src/WorkOS.net/Entities/GroupMemberRemoved.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a group member removed.
- public class GroupMemberRemoved
+ public class GroupMemberRemoved : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "group.member_removed";
-
/// The event payload.
- public GroupMemberAddedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new GroupMemberAddedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/GroupUpdated.cs b/src/WorkOS.net/Entities/GroupUpdated.cs
index 7b89b132..9506894a 100644
--- a/src/WorkOS.net/Entities/GroupUpdated.cs
+++ b/src/WorkOS.net/Entities/GroupUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a group updated.
- public class GroupUpdated
+ public class GroupUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "group.updated";
-
/// The event payload.
- public Group Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new Group Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/IntentOptions.cs b/src/WorkOS.net/Entities/IntentOptions.cs
index 976c8c5c..bc3b1bf6 100644
--- a/src/WorkOS.net/Entities/IntentOptions.cs
+++ b/src/WorkOS.net/Entities/IntentOptions.cs
@@ -8,6 +8,9 @@ public class IntentOptions
{
/// SSO-specific options for the Admin Portal.
- public SSOIntentOptions SSO { get; set; } = default!;
+ public SSOIntentOptions? SSO { get; set; }
+
+ /// Domain verification-specific options for the Admin Portal.
+ public DomainVerificationIntentOptions? DomainVerification { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/Invitation.cs b/src/WorkOS.net/Entities/Invitation.cs
index bccd28bc..b7860008 100644
--- a/src/WorkOS.net/Entities/Invitation.cs
+++ b/src/WorkOS.net/Entities/Invitation.cs
@@ -42,6 +42,9 @@ public class Invitation
/// The ID of the user who accepted the invitation, once accepted.
public string? AcceptedUserId { get; set; }
+ /// Slug of the role the invitee will be assigned on acceptance. Reflects the current role on the invitee's organization membership. null when the invitation has no associated organization.
+ public string? RoleSlug { get; set; }
+
/// An ISO 8601 timestamp.
public DateTimeOffset CreatedAt { get; set; }
diff --git a/src/WorkOS.net/Entities/InvitationAccepted.cs b/src/WorkOS.net/Entities/InvitationAccepted.cs
index cefe5bec..b035ee3a 100644
--- a/src/WorkOS.net/Entities/InvitationAccepted.cs
+++ b/src/WorkOS.net/Entities/InvitationAccepted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an invitation accepted.
- public class InvitationAccepted
+ public class InvitationAccepted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "invitation.accepted";
-
/// The event payload.
- public InvitationAcceptedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new InvitationAcceptedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/InvitationAcceptedData.cs b/src/WorkOS.net/Entities/InvitationAcceptedData.cs
index 400ab4ee..5c1d5e61 100644
--- a/src/WorkOS.net/Entities/InvitationAcceptedData.cs
+++ b/src/WorkOS.net/Entities/InvitationAcceptedData.cs
@@ -42,6 +42,9 @@ public class InvitationAcceptedData
/// The ID of the user who accepted the invitation, once accepted.
public string? AcceptedUserId { get; set; }
+ /// Slug of the role the invitee will be assigned on acceptance. Reflects the current role on the invitee's organization membership. null when the invitation has no associated organization.
+ public string? RoleSlug { get; set; }
+
/// An ISO 8601 timestamp.
public DateTimeOffset CreatedAt { get; set; }
diff --git a/src/WorkOS.net/Entities/InvitationCreated.cs b/src/WorkOS.net/Entities/InvitationCreated.cs
index 6670e85b..7b36902e 100644
--- a/src/WorkOS.net/Entities/InvitationCreated.cs
+++ b/src/WorkOS.net/Entities/InvitationCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an invitation created.
- public class InvitationCreated
+ public class InvitationCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "invitation.created";
-
/// The event payload.
- public InvitationAcceptedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new InvitationAcceptedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/InvitationResent.cs b/src/WorkOS.net/Entities/InvitationResent.cs
index 65159381..23af6d54 100644
--- a/src/WorkOS.net/Entities/InvitationResent.cs
+++ b/src/WorkOS.net/Entities/InvitationResent.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an invitation resent.
- public class InvitationResent
+ public class InvitationResent : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "invitation.resent";
-
/// The event payload.
- public InvitationAcceptedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new InvitationAcceptedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/InvitationRevoked.cs b/src/WorkOS.net/Entities/InvitationRevoked.cs
index 2091be50..db52bb74 100644
--- a/src/WorkOS.net/Entities/InvitationRevoked.cs
+++ b/src/WorkOS.net/Entities/InvitationRevoked.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an invitation revoked.
- public class InvitationRevoked
+ public class InvitationRevoked : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "invitation.revoked";
-
/// The event payload.
- public InvitationAcceptedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new InvitationAcceptedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/MagicAuthCreated.cs b/src/WorkOS.net/Entities/MagicAuthCreated.cs
index 3f16cad2..536a8e89 100644
--- a/src/WorkOS.net/Entities/MagicAuthCreated.cs
+++ b/src/WorkOS.net/Entities/MagicAuthCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a magic auth created.
- public class MagicAuthCreated
+ public class MagicAuthCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "magic_auth.created";
-
/// The event payload.
- public MagicAuthCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new MagicAuthCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationCreated.cs b/src/WorkOS.net/Entities/OrganizationCreated.cs
index 01e37bea..3e8774c4 100644
--- a/src/WorkOS.net/Entities/OrganizationCreated.cs
+++ b/src/WorkOS.net/Entities/OrganizationCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization created.
- public class OrganizationCreated
+ public class OrganizationCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization.created";
-
/// The event payload.
- public OrganizationCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationDeleted.cs b/src/WorkOS.net/Entities/OrganizationDeleted.cs
index f482b82c..c6d0f3d5 100644
--- a/src/WorkOS.net/Entities/OrganizationDeleted.cs
+++ b/src/WorkOS.net/Entities/OrganizationDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization deleted.
- public class OrganizationDeleted
+ public class OrganizationDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization.deleted";
-
/// The event payload.
- public OrganizationCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationDomainCreated.cs b/src/WorkOS.net/Entities/OrganizationDomainCreated.cs
index 4bfb90b7..a14c4517 100644
--- a/src/WorkOS.net/Entities/OrganizationDomainCreated.cs
+++ b/src/WorkOS.net/Entities/OrganizationDomainCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization domain created.
- public class OrganizationDomainCreated
+ public class OrganizationDomainCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_domain.created";
-
/// The event payload.
- public OrganizationCreatedDataDomain Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationCreatedDataDomain Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationDomainDeleted.cs b/src/WorkOS.net/Entities/OrganizationDomainDeleted.cs
index 9dc08995..29a7a678 100644
--- a/src/WorkOS.net/Entities/OrganizationDomainDeleted.cs
+++ b/src/WorkOS.net/Entities/OrganizationDomainDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization domain deleted.
- public class OrganizationDomainDeleted
+ public class OrganizationDomainDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_domain.deleted";
-
/// The event payload.
- public OrganizationCreatedDataDomain Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationCreatedDataDomain Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationDomainUpdated.cs b/src/WorkOS.net/Entities/OrganizationDomainUpdated.cs
index b2d34c32..a91b126f 100644
--- a/src/WorkOS.net/Entities/OrganizationDomainUpdated.cs
+++ b/src/WorkOS.net/Entities/OrganizationDomainUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization domain updated.
- public class OrganizationDomainUpdated
+ public class OrganizationDomainUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_domain.updated";
-
/// The event payload.
- public OrganizationCreatedDataDomain Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationCreatedDataDomain Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationDomainVerificationFailed.cs b/src/WorkOS.net/Entities/OrganizationDomainVerificationFailed.cs
index 7648a9a9..393d382c 100644
--- a/src/WorkOS.net/Entities/OrganizationDomainVerificationFailed.cs
+++ b/src/WorkOS.net/Entities/OrganizationDomainVerificationFailed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization domain verification failed.
- public class OrganizationDomainVerificationFailed
+ public class OrganizationDomainVerificationFailed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_domain.verification_failed";
-
/// The event payload.
- public OrganizationDomainVerificationFailedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationDomainVerificationFailedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationDomainVerified.cs b/src/WorkOS.net/Entities/OrganizationDomainVerified.cs
index 3d82a725..9fd7e091 100644
--- a/src/WorkOS.net/Entities/OrganizationDomainVerified.cs
+++ b/src/WorkOS.net/Entities/OrganizationDomainVerified.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization domain verified.
- public class OrganizationDomainVerified
+ public class OrganizationDomainVerified : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_domain.verified";
-
/// The event payload.
- public OrganizationCreatedDataDomain Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationCreatedDataDomain Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationMembershipCreated.cs b/src/WorkOS.net/Entities/OrganizationMembershipCreated.cs
index e90280e1..a565ab08 100644
--- a/src/WorkOS.net/Entities/OrganizationMembershipCreated.cs
+++ b/src/WorkOS.net/Entities/OrganizationMembershipCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization membership created.
- public class OrganizationMembershipCreated
+ public class OrganizationMembershipCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_membership.created";
-
/// The event payload.
- public OrganizationMembershipCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationMembershipCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationMembershipDeleted.cs b/src/WorkOS.net/Entities/OrganizationMembershipDeleted.cs
index f1ac092d..4993feeb 100644
--- a/src/WorkOS.net/Entities/OrganizationMembershipDeleted.cs
+++ b/src/WorkOS.net/Entities/OrganizationMembershipDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization membership deleted.
- public class OrganizationMembershipDeleted
+ public class OrganizationMembershipDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_membership.deleted";
-
/// The event payload.
- public OrganizationMembershipCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationMembershipCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationMembershipUpdated.cs b/src/WorkOS.net/Entities/OrganizationMembershipUpdated.cs
index 5b95f41e..624b0320 100644
--- a/src/WorkOS.net/Entities/OrganizationMembershipUpdated.cs
+++ b/src/WorkOS.net/Entities/OrganizationMembershipUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization membership updated.
- public class OrganizationMembershipUpdated
+ public class OrganizationMembershipUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_membership.updated";
-
/// The event payload.
- public OrganizationMembershipCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationMembershipCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationRoleCreated.cs b/src/WorkOS.net/Entities/OrganizationRoleCreated.cs
index 0fd377ce..6b9b3770 100644
--- a/src/WorkOS.net/Entities/OrganizationRoleCreated.cs
+++ b/src/WorkOS.net/Entities/OrganizationRoleCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization role created.
- public class OrganizationRoleCreated
+ public class OrganizationRoleCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_role.created";
-
/// The event payload.
- public OrganizationRoleCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationRoleCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationRoleDeleted.cs b/src/WorkOS.net/Entities/OrganizationRoleDeleted.cs
index c7295ba7..317cb50c 100644
--- a/src/WorkOS.net/Entities/OrganizationRoleDeleted.cs
+++ b/src/WorkOS.net/Entities/OrganizationRoleDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization role deleted.
- public class OrganizationRoleDeleted
+ public class OrganizationRoleDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_role.deleted";
-
/// The event payload.
- public OrganizationRoleCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationRoleCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationRoleUpdated.cs b/src/WorkOS.net/Entities/OrganizationRoleUpdated.cs
index 47bb7fa4..ffa03b10 100644
--- a/src/WorkOS.net/Entities/OrganizationRoleUpdated.cs
+++ b/src/WorkOS.net/Entities/OrganizationRoleUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization role updated.
- public class OrganizationRoleUpdated
+ public class OrganizationRoleUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization_role.updated";
-
/// The event payload.
- public OrganizationRoleCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationRoleCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/OrganizationUpdated.cs b/src/WorkOS.net/Entities/OrganizationUpdated.cs
index 354dc381..101c02c5 100644
--- a/src/WorkOS.net/Entities/OrganizationUpdated.cs
+++ b/src/WorkOS.net/Entities/OrganizationUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an organization updated.
- public class OrganizationUpdated
+ public class OrganizationUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "organization.updated";
-
/// The event payload.
- public OrganizationCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new OrganizationCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/PasswordResetCreated.cs b/src/WorkOS.net/Entities/PasswordResetCreated.cs
index e6e5d220..cef0c0ab 100644
--- a/src/WorkOS.net/Entities/PasswordResetCreated.cs
+++ b/src/WorkOS.net/Entities/PasswordResetCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a password reset created.
- public class PasswordResetCreated
+ public class PasswordResetCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "password_reset.created";
-
/// The event payload.
- public PasswordResetCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new PasswordResetCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/PasswordResetSucceeded.cs b/src/WorkOS.net/Entities/PasswordResetSucceeded.cs
index 06edf471..a4cfac0f 100644
--- a/src/WorkOS.net/Entities/PasswordResetSucceeded.cs
+++ b/src/WorkOS.net/Entities/PasswordResetSucceeded.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a password reset succeeded.
- public class PasswordResetSucceeded
+ public class PasswordResetSucceeded : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "password_reset.succeeded";
-
/// The event payload.
- public PasswordResetCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new PasswordResetCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/PermissionCreated.cs b/src/WorkOS.net/Entities/PermissionCreated.cs
index c1f23b30..0578d7a6 100644
--- a/src/WorkOS.net/Entities/PermissionCreated.cs
+++ b/src/WorkOS.net/Entities/PermissionCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a permission created.
- public class PermissionCreated
+ public class PermissionCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "permission.created";
-
/// The event payload.
- public PermissionCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new PermissionCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/PermissionDeleted.cs b/src/WorkOS.net/Entities/PermissionDeleted.cs
index b9b6ca8f..c9ab35a2 100644
--- a/src/WorkOS.net/Entities/PermissionDeleted.cs
+++ b/src/WorkOS.net/Entities/PermissionDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a permission deleted.
- public class PermissionDeleted
+ public class PermissionDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "permission.deleted";
-
/// The event payload.
- public PermissionCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new PermissionCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/PermissionUpdated.cs b/src/WorkOS.net/Entities/PermissionUpdated.cs
index abb97026..43de09e8 100644
--- a/src/WorkOS.net/Entities/PermissionUpdated.cs
+++ b/src/WorkOS.net/Entities/PermissionUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a permission updated.
- public class PermissionUpdated
+ public class PermissionUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "permission.updated";
-
/// The event payload.
- public PermissionCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new PermissionCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/RadarStandaloneUpdateRadarAttemptRequest.cs b/src/WorkOS.net/Entities/RadarStandaloneUpdateRadarAttemptRequest.cs
index 11f69682..2c27d5b7 100644
--- a/src/WorkOS.net/Entities/RadarStandaloneUpdateRadarAttemptRequest.cs
+++ b/src/WorkOS.net/Entities/RadarStandaloneUpdateRadarAttemptRequest.cs
@@ -8,9 +8,9 @@ public class RadarStandaloneUpdateRadarAttemptRequest
{
/// Set to `"success"` to mark the challenge as completed.
- public string ChallengeStatus { get; internal set; } = "success";
+ public string? ChallengeStatus { get; set; }
/// Set to `"success"` to mark the authentication attempt as successful.
- public string AttemptStatus { get; internal set; } = "success";
+ public string? AttemptStatus { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/RoleCreated.cs b/src/WorkOS.net/Entities/RoleCreated.cs
index a88b784f..e4d5d212 100644
--- a/src/WorkOS.net/Entities/RoleCreated.cs
+++ b/src/WorkOS.net/Entities/RoleCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a role created.
- public class RoleCreated
+ public class RoleCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "role.created";
-
/// The event payload.
- public RoleCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new RoleCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/RoleDeleted.cs b/src/WorkOS.net/Entities/RoleDeleted.cs
index d233661f..b47ce499 100644
--- a/src/WorkOS.net/Entities/RoleDeleted.cs
+++ b/src/WorkOS.net/Entities/RoleDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a role deleted.
- public class RoleDeleted
+ public class RoleDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "role.deleted";
-
/// The event payload.
- public RoleCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new RoleCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/RoleUpdated.cs b/src/WorkOS.net/Entities/RoleUpdated.cs
index ddeae863..74cd0207 100644
--- a/src/WorkOS.net/Entities/RoleUpdated.cs
+++ b/src/WorkOS.net/Entities/RoleUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a role updated.
- public class RoleUpdated
+ public class RoleUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "role.updated";
-
/// The event payload.
- public RoleCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new RoleCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/SSOIntentOptions.cs b/src/WorkOS.net/Entities/SSOIntentOptions.cs
index 72b71373..2f43234f 100644
--- a/src/WorkOS.net/Entities/SSOIntentOptions.cs
+++ b/src/WorkOS.net/Entities/SSOIntentOptions.cs
@@ -11,6 +11,6 @@ public class SSOIntentOptions
public string? BookmarkSlug { get; set; }
/// The SSO provider type to configure.
- public string ProviderType { get; internal set; } = "GoogleSAML";
+ public string? ProviderType { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/SessionCreated.cs b/src/WorkOS.net/Entities/SessionCreated.cs
index 6344d12b..6bed0af2 100644
--- a/src/WorkOS.net/Entities/SessionCreated.cs
+++ b/src/WorkOS.net/Entities/SessionCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a session created.
- public class SessionCreated
+ public class SessionCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "session.created";
-
/// The event payload.
- public SessionCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new SessionCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/SessionRevoked.cs b/src/WorkOS.net/Entities/SessionRevoked.cs
index 9b9125fd..f50057a5 100644
--- a/src/WorkOS.net/Entities/SessionRevoked.cs
+++ b/src/WorkOS.net/Entities/SessionRevoked.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a session revoked.
- public class SessionRevoked
+ public class SessionRevoked : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "session.revoked";
-
/// The event payload.
- public SessionCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new SessionCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/UserCreated.cs b/src/WorkOS.net/Entities/UserCreated.cs
index 8453283a..ceab5289 100644
--- a/src/WorkOS.net/Entities/UserCreated.cs
+++ b/src/WorkOS.net/Entities/UserCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an user created.
- public class UserCreated
+ public class UserCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "user.created";
-
/// The event payload.
- public User Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new User Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/UserDeleted.cs b/src/WorkOS.net/Entities/UserDeleted.cs
index a94602f0..fb1deb6e 100644
--- a/src/WorkOS.net/Entities/UserDeleted.cs
+++ b/src/WorkOS.net/Entities/UserDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an user deleted.
- public class UserDeleted
+ public class UserDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "user.deleted";
-
/// The event payload.
- public User Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new User Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/UserUpdated.cs b/src/WorkOS.net/Entities/UserUpdated.cs
index 72218edc..9523d5db 100644
--- a/src/WorkOS.net/Entities/UserUpdated.cs
+++ b/src/WorkOS.net/Entities/UserUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents an user updated.
- public class UserUpdated
+ public class UserUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "user.updated";
-
/// The event payload.
- public User Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new User Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultByokKeyVerificationCompleted.cs b/src/WorkOS.net/Entities/VaultByokKeyVerificationCompleted.cs
index aa93a39b..fd107ac0 100644
--- a/src/WorkOS.net/Entities/VaultByokKeyVerificationCompleted.cs
+++ b/src/WorkOS.net/Entities/VaultByokKeyVerificationCompleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault byok key verification completed.
- public class VaultByokKeyVerificationCompleted
+ public class VaultByokKeyVerificationCompleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.byok_key.verification_completed";
-
/// The event payload.
- public VaultByokKeyVerificationCompletedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultByokKeyVerificationCompletedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultDataCreated.cs b/src/WorkOS.net/Entities/VaultDataCreated.cs
index faf43381..b3ce7738 100644
--- a/src/WorkOS.net/Entities/VaultDataCreated.cs
+++ b/src/WorkOS.net/Entities/VaultDataCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault data created.
- public class VaultDataCreated
+ public class VaultDataCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.data.created";
-
/// The event payload.
- public VaultDataCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultDataCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultDataDeleted.cs b/src/WorkOS.net/Entities/VaultDataDeleted.cs
index 8e9af7b1..54ada35e 100644
--- a/src/WorkOS.net/Entities/VaultDataDeleted.cs
+++ b/src/WorkOS.net/Entities/VaultDataDeleted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault data deleted.
- public class VaultDataDeleted
+ public class VaultDataDeleted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.data.deleted";
-
/// The event payload.
- public VaultDataDeletedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultDataDeletedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultDataRead.cs b/src/WorkOS.net/Entities/VaultDataRead.cs
index 9c16d155..e007ce9c 100644
--- a/src/WorkOS.net/Entities/VaultDataRead.cs
+++ b/src/WorkOS.net/Entities/VaultDataRead.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault data read.
- public class VaultDataRead
+ public class VaultDataRead : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.data.read";
-
/// The event payload.
- public VaultDataReadData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultDataReadData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultDataUpdated.cs b/src/WorkOS.net/Entities/VaultDataUpdated.cs
index 48d56486..2d864dc6 100644
--- a/src/WorkOS.net/Entities/VaultDataUpdated.cs
+++ b/src/WorkOS.net/Entities/VaultDataUpdated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault data updated.
- public class VaultDataUpdated
+ public class VaultDataUpdated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.data.updated";
-
/// The event payload.
- public VaultDataCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultDataCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultDekDecrypted.cs b/src/WorkOS.net/Entities/VaultDekDecrypted.cs
index 3de0d580..232398cb 100644
--- a/src/WorkOS.net/Entities/VaultDekDecrypted.cs
+++ b/src/WorkOS.net/Entities/VaultDekDecrypted.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault dek decrypted.
- public class VaultDekDecrypted
+ public class VaultDekDecrypted : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.dek.decrypted";
-
/// The event payload.
- public VaultDekDecryptedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultDekDecryptedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultDekRead.cs b/src/WorkOS.net/Entities/VaultDekRead.cs
index d1cb6503..0db467ba 100644
--- a/src/WorkOS.net/Entities/VaultDekRead.cs
+++ b/src/WorkOS.net/Entities/VaultDekRead.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault dek read.
- public class VaultDekRead
+ public class VaultDekRead : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.dek.read";
-
/// The event payload.
- public VaultDekReadData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultDekReadData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultKekCreated.cs b/src/WorkOS.net/Entities/VaultKekCreated.cs
index 997f6a2d..ad9123d5 100644
--- a/src/WorkOS.net/Entities/VaultKekCreated.cs
+++ b/src/WorkOS.net/Entities/VaultKekCreated.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault kek created.
- public class VaultKekCreated
+ public class VaultKekCreated : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.kek.created";
-
/// The event payload.
- public VaultKekCreatedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultKekCreatedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultMetadataRead.cs b/src/WorkOS.net/Entities/VaultMetadataRead.cs
index c01c724c..16d5222b 100644
--- a/src/WorkOS.net/Entities/VaultMetadataRead.cs
+++ b/src/WorkOS.net/Entities/VaultMetadataRead.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault metadata read.
- public class VaultMetadataRead
+ public class VaultMetadataRead : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.metadata.read";
-
/// The event payload.
- public VaultDataDeletedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultDataDeletedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/VaultNamesListed.cs b/src/WorkOS.net/Entities/VaultNamesListed.cs
index 558ef517..9f27cd99 100644
--- a/src/WorkOS.net/Entities/VaultNamesListed.cs
+++ b/src/WorkOS.net/Entities/VaultNamesListed.cs
@@ -5,21 +5,11 @@ namespace WorkOS
using System;
/// Represents a vault names listed.
- public class VaultNamesListed
+ public class VaultNamesListed : EventSchema
{
- /// Unique identifier for the event.
- public string Id { get; set; } = default!;
- public string Event { get; internal set; } = "vault.names.listed";
-
/// The event payload.
- public VaultNamesListedData Data { get; set; } = default!;
-
- /// An ISO 8601 timestamp.
- public DateTimeOffset CreatedAt { get; set; }
- public EventContext? Context { get; set; }
-
- /// Distinguishes the Event object.
- public string Object { get; internal set; } = "event";
+ public new VaultNamesListedData Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
}
}
diff --git a/src/WorkOS.net/Entities/WaitlistUser.cs b/src/WorkOS.net/Entities/WaitlistUser.cs
new file mode 100644
index 00000000..0304b98c
--- /dev/null
+++ b/src/WorkOS.net/Entities/WaitlistUser.cs
@@ -0,0 +1,36 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+ using Newtonsoft.Json;
+ using STJS = System.Text.Json.Serialization;
+
+ /// Represents a waitlist user.
+ public class WaitlistUser
+ {
+
+ /// Distinguishes the Waitlist User object.
+ public string Object { get; internal set; } = "waitlist_user";
+
+ /// The unique ID of the Waitlist User.
+ public string Id { get; set; } = default!;
+
+ /// The email address of the Waitlist User.
+ public string Email { get; set; } = default!;
+
+ /// The state of the Waitlist User.
+ [JsonProperty(DefaultValueHandling = DefaultValueHandling.Ignore)]
+ [STJS.JsonIgnore(Condition = STJS.JsonIgnoreCondition.WhenWritingDefault)]
+ public WaitlistUserState State { get; set; }
+
+ /// The timestamp when the Waitlist User was approved, or null if not yet approved.
+ public DateTimeOffset? ApprovedAt { get; set; }
+
+ /// An ISO 8601 timestamp.
+ public DateTimeOffset CreatedAt { get; set; }
+
+ /// An ISO 8601 timestamp.
+ public DateTimeOffset UpdatedAt { get; set; }
+ }
+}
diff --git a/src/WorkOS.net/Entities/WaitlistUserApproved.cs b/src/WorkOS.net/Entities/WaitlistUserApproved.cs
new file mode 100644
index 00000000..a245ed05
--- /dev/null
+++ b/src/WorkOS.net/Entities/WaitlistUserApproved.cs
@@ -0,0 +1,15 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+
+ /// Represents a waitlist user approved.
+ public class WaitlistUserApproved : EventSchema
+ {
+
+ /// The event payload.
+ public new WaitlistUser Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
+ }
+}
diff --git a/src/WorkOS.net/Entities/WaitlistUserCreated.cs b/src/WorkOS.net/Entities/WaitlistUserCreated.cs
new file mode 100644
index 00000000..8b1fb02f
--- /dev/null
+++ b/src/WorkOS.net/Entities/WaitlistUserCreated.cs
@@ -0,0 +1,15 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+
+ /// Represents a waitlist user created.
+ public class WaitlistUserCreated : EventSchema
+ {
+
+ /// The event payload.
+ public new WaitlistUser Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
+ }
+}
diff --git a/src/WorkOS.net/Entities/WaitlistUserDenied.cs b/src/WorkOS.net/Entities/WaitlistUserDenied.cs
new file mode 100644
index 00000000..a5c30d89
--- /dev/null
+++ b/src/WorkOS.net/Entities/WaitlistUserDenied.cs
@@ -0,0 +1,15 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+
+ /// Represents a waitlist user denied.
+ public class WaitlistUserDenied : EventSchema
+ {
+
+ /// The event payload.
+ public new WaitlistUser Data { get; set; } = default!;
+ public new EventContext? Context { get; set; }
+ }
+}
diff --git a/src/WorkOS.net/Enums/CreateWebhookEndpointEvents.cs b/src/WorkOS.net/Enums/CreateWebhookEndpointEvents.cs
index 3f22176b..b0c9260e 100644
--- a/src/WorkOS.net/Enums/CreateWebhookEndpointEvents.cs
+++ b/src/WorkOS.net/Enums/CreateWebhookEndpointEvents.cs
@@ -162,5 +162,11 @@ public enum CreateWebhookEndpointEvents
SessionCreated,
[EnumMember(Value = "session.revoked")]
SessionRevoked,
+ [EnumMember(Value = "waitlist_user.approved")]
+ WaitlistUserApproved,
+ [EnumMember(Value = "waitlist_user.created")]
+ WaitlistUserCreated,
+ [EnumMember(Value = "waitlist_user.denied")]
+ WaitlistUserDenied,
}
}
diff --git a/src/WorkOS.net/Enums/SSOProvider.cs b/src/WorkOS.net/Enums/SSOProvider.cs
index 479cc684..bc3532a9 100644
--- a/src/WorkOS.net/Enums/SSOProvider.cs
+++ b/src/WorkOS.net/Enums/SSOProvider.cs
@@ -16,11 +16,29 @@ public enum SSOProvider
[EnumMember(Value = "AppleOAuth")]
AppleOAuth,
+ [EnumMember(Value = "BitbucketOAuth")]
+ BitbucketOAuth,
[EnumMember(Value = "GitHubOAuth")]
GitHubOAuth,
+ [EnumMember(Value = "GitLabOAuth")]
+ GitLabOAuth,
[EnumMember(Value = "GoogleOAuth")]
GoogleOAuth,
+ [EnumMember(Value = "IntuitOAuth")]
+ IntuitOAuth,
+ [EnumMember(Value = "LinkedInOAuth")]
+ LinkedInOAuth,
[EnumMember(Value = "MicrosoftOAuth")]
MicrosoftOAuth,
+ [EnumMember(Value = "SalesforceOAuth")]
+ SalesforceOAuth,
+ [EnumMember(Value = "SlackOAuth")]
+ SlackOAuth,
+ [EnumMember(Value = "VercelMarketplaceOAuth")]
+ VercelMarketplaceOAuth,
+ [EnumMember(Value = "VercelOAuth")]
+ VercelOAuth,
+ [EnumMember(Value = "XeroOAuth")]
+ XeroOAuth,
}
}
diff --git a/src/WorkOS.net/Enums/UserManagementAuthenticationProvider.cs b/src/WorkOS.net/Enums/UserManagementAuthenticationProvider.cs
index a10f8be2..b886d0a3 100644
--- a/src/WorkOS.net/Enums/UserManagementAuthenticationProvider.cs
+++ b/src/WorkOS.net/Enums/UserManagementAuthenticationProvider.cs
@@ -18,11 +18,29 @@ public enum UserManagementAuthenticationProvider
Authkit,
[EnumMember(Value = "AppleOAuth")]
AppleOAuth,
+ [EnumMember(Value = "BitbucketOAuth")]
+ BitbucketOAuth,
[EnumMember(Value = "GitHubOAuth")]
GitHubOAuth,
+ [EnumMember(Value = "GitLabOAuth")]
+ GitLabOAuth,
[EnumMember(Value = "GoogleOAuth")]
GoogleOAuth,
+ [EnumMember(Value = "IntuitOAuth")]
+ IntuitOAuth,
+ [EnumMember(Value = "LinkedInOAuth")]
+ LinkedInOAuth,
[EnumMember(Value = "MicrosoftOAuth")]
MicrosoftOAuth,
+ [EnumMember(Value = "SalesforceOAuth")]
+ SalesforceOAuth,
+ [EnumMember(Value = "SlackOAuth")]
+ SlackOAuth,
+ [EnumMember(Value = "VercelMarketplaceOAuth")]
+ VercelMarketplaceOAuth,
+ [EnumMember(Value = "VercelOAuth")]
+ VercelOAuth,
+ [EnumMember(Value = "XeroOAuth")]
+ XeroOAuth,
}
}
diff --git a/src/WorkOS.net/Enums/WaitlistUserState.cs b/src/WorkOS.net/Enums/WaitlistUserState.cs
new file mode 100644
index 00000000..10cdd29f
--- /dev/null
+++ b/src/WorkOS.net/Enums/WaitlistUserState.cs
@@ -0,0 +1,24 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System.Runtime.Serialization;
+ using Newtonsoft.Json;
+ using STJS = System.Text.Json.Serialization;
+
+ /// Represents waitlist user state values.
+ [JsonConverter(typeof(WorkOSNewtonsoftStringEnumConverter))]
+ [STJS.JsonConverter(typeof(WorkOSStringEnumConverterFactory))]
+ public enum WaitlistUserState
+ {
+ [EnumMember(Value = "unknown")]
+ Unknown,
+
+ [EnumMember(Value = "pending")]
+ Pending,
+ [EnumMember(Value = "approved")]
+ Approved,
+ [EnumMember(Value = "denied")]
+ Denied,
+ }
+}
diff --git a/src/WorkOS.net/Services/AdminPortal/_interfaces/AdminPortalOptions.cs b/src/WorkOS.net/Services/AdminPortal/_interfaces/AdminPortalOptions.cs
index 21b61b5f..c01829b3 100644
--- a/src/WorkOS.net/Services/AdminPortal/_interfaces/AdminPortalOptions.cs
+++ b/src/WorkOS.net/Services/AdminPortal/_interfaces/AdminPortalOptions.cs
@@ -34,8 +34,8 @@ public class AdminPortalGenerateLinkOptions : BaseOptions
/// Options to configure the Admin Portal based on the intent.
public IntentOptions? IntentOptions { get; set; }
- /// The email addresses of the IT admins to grant access to the Admin Portal for the given organization. Accepts up to 20 emails.
- public List? AdminEmails { get; set; }
+ /// The email addresses of the IT contacts to grant access to the Admin Portal for the given organization. Accepts up to 20 emails.
+ public List? ItContactEmails { get; set; }
}
}
diff --git a/src/WorkOS.net/Services/Authorization/AuthorizationService.cs b/src/WorkOS.net/Services/Authorization/AuthorizationService.cs
index 603bd14c..be4bc53b 100644
--- a/src/WorkOS.net/Services/Authorization/AuthorizationService.cs
+++ b/src/WorkOS.net/Services/Authorization/AuthorizationService.cs
@@ -82,7 +82,7 @@ public virtual Task Check(string organizationMembershipId, A
/// Per-request configuration overrides.
/// Cancellation token.
/// A page of results.
- public virtual async Task> ListOrganizationMembershipResourcesAsync(string organizationMembershipId, AuthorizationListOrganizationMembershipResourcesOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task> ListResourcesForMembershipAsync(string organizationMembershipId, AuthorizationListResourcesForMembershipOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
var request = new WorkOSRequest
{
@@ -115,19 +115,19 @@ public virtual async Task> ListOrganizationMem
return await this.Client.MakeAPIRequest>(request, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task> ListOrganizationMembershipResources(string organizationMembershipId, AuthorizationListOrganizationMembershipResourcesOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task> ListResourcesForMembership(string organizationMembershipId, AuthorizationListResourcesForMembershipOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.ListOrganizationMembershipResourcesAsync(organizationMembershipId, options, requestOptions, cancellationToken);
+ return this.ListResourcesForMembershipAsync(organizationMembershipId, options, requestOptions, cancellationToken);
}
- /// Auto-paging variant of . Yields individual items across all pages.
+ /// Auto-paging variant of . Yields individual items across all pages.
/// The ID of the organization membership.
/// Request options.
/// Per-request configuration overrides.
/// Cancellation token.
/// An async sequence of items.
- public virtual IAsyncEnumerable ListOrganizationMembershipResourcesAutoPagingAsync(string organizationMembershipId, AuthorizationListOrganizationMembershipResourcesOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual IAsyncEnumerable ListResourcesForMembershipAutoPagingAsync(string organizationMembershipId, AuthorizationListResourcesForMembershipOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return this.ListAutoPagingAsync($"/authorization/organization_memberships/{Uri.EscapeDataString(organizationMembershipId)}/resources", options, requestOptions, cancellationToken);
}
@@ -142,25 +142,25 @@ public virtual IAsyncEnumerable ListOrganizationMembershi
/// Per-request configuration overrides.
/// Cancellation token.
/// A page of results.
- public virtual async Task> ListResourcePermissionsAsync(string organizationMembershipId, string resourceId, AuthorizationListResourcePermissionsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task> ListEffectivePermissionsAsync(string organizationMembershipId, string resourceId, AuthorizationListEffectivePermissionsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return await this.GetAsync>($"/authorization/organization_memberships/{Uri.EscapeDataString(organizationMembershipId)}/resources/{Uri.EscapeDataString(resourceId)}/permissions", options, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task> ListResourcePermissions(string organizationMembershipId, string resourceId, AuthorizationListResourcePermissionsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task> ListEffectivePermissions(string organizationMembershipId, string resourceId, AuthorizationListEffectivePermissionsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.ListResourcePermissionsAsync(organizationMembershipId, resourceId, options, requestOptions, cancellationToken);
+ return this.ListEffectivePermissionsAsync(organizationMembershipId, resourceId, options, requestOptions, cancellationToken);
}
- /// Auto-paging variant of . Yields individual items across all pages.
+ /// Auto-paging variant of . Yields individual items across all pages.
/// The ID of the organization membership.
/// The ID of the authorization resource.
/// Request options.
/// Per-request configuration overrides.
/// Cancellation token.
/// An async sequence of items.
- public virtual IAsyncEnumerable ListResourcePermissionsAutoPagingAsync(string organizationMembershipId, string resourceId, AuthorizationListResourcePermissionsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual IAsyncEnumerable ListEffectivePermissionsAutoPagingAsync(string organizationMembershipId, string resourceId, AuthorizationListEffectivePermissionsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return this.ListAutoPagingAsync($"/authorization/organization_memberships/{Uri.EscapeDataString(organizationMembershipId)}/resources/{Uri.EscapeDataString(resourceId)}/permissions", options, requestOptions, cancellationToken);
}
@@ -209,24 +209,24 @@ public virtual IAsyncEnumerable ListEffectivePermission
/// Per-request configuration overrides.
/// Cancellation token.
/// A page of results.
- public virtual async Task> ListOrganizationMembershipRoleAssignmentsAsync(string organizationMembershipId, AuthorizationListOrganizationMembershipRoleAssignmentsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task> ListRoleAssignmentsAsync(string organizationMembershipId, AuthorizationListRoleAssignmentsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return await this.GetAsync>($"/authorization/organization_memberships/{Uri.EscapeDataString(organizationMembershipId)}/role_assignments", options, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task> ListOrganizationMembershipRoleAssignments(string organizationMembershipId, AuthorizationListOrganizationMembershipRoleAssignmentsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task> ListRoleAssignments(string organizationMembershipId, AuthorizationListRoleAssignmentsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.ListOrganizationMembershipRoleAssignmentsAsync(organizationMembershipId, options, requestOptions, cancellationToken);
+ return this.ListRoleAssignmentsAsync(organizationMembershipId, options, requestOptions, cancellationToken);
}
- /// Auto-paging variant of . Yields individual items across all pages.
+ /// Auto-paging variant of . Yields individual items across all pages.
/// The ID of the organization membership.
/// Request options.
/// Per-request configuration overrides.
/// Cancellation token.
/// An async sequence of items.
- public virtual IAsyncEnumerable ListOrganizationMembershipRoleAssignmentsAutoPagingAsync(string organizationMembershipId, AuthorizationListOrganizationMembershipRoleAssignmentsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual IAsyncEnumerable ListRoleAssignmentsAutoPagingAsync(string organizationMembershipId, AuthorizationListRoleAssignmentsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return this.ListAutoPagingAsync($"/authorization/organization_memberships/{Uri.EscapeDataString(organizationMembershipId)}/role_assignments", options, requestOptions, cancellationToken);
}
@@ -334,15 +334,15 @@ public virtual Task RemoveRole(string organizationMembershipId, AuthorizationRem
/// The ID of the role assignment to remove.
/// Per-request configuration overrides.
/// Cancellation token.
- public virtual async Task DeleteOrganizationMembershipRoleAssignmentAsync(string organizationMembershipId, string roleAssignmentId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task RemoveRoleAssignmentAsync(string organizationMembershipId, string roleAssignmentId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
await this.DeleteAsync($"/authorization/organization_memberships/{Uri.EscapeDataString(organizationMembershipId)}/role_assignments/{Uri.EscapeDataString(roleAssignmentId)}", null, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task DeleteOrganizationMembershipRoleAssignment(string organizationMembershipId, string roleAssignmentId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task RemoveRoleAssignment(string organizationMembershipId, string roleAssignmentId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.DeleteOrganizationMembershipRoleAssignmentAsync(organizationMembershipId, roleAssignmentId, requestOptions, cancellationToken);
+ return this.RemoveRoleAssignmentAsync(organizationMembershipId, roleAssignmentId, requestOptions, cancellationToken);
}
/// List custom roles
@@ -454,15 +454,15 @@ public virtual Task DeleteOrganizationRole(string organizationId, string slug, R
/// Per-request configuration overrides.
/// Cancellation token.
/// The result.
- public virtual async Task CreateRolePermissionAsync(string organizationId, string slug, AuthorizationCreateRolePermissionOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task AddOrganizationRolePermissionAsync(string organizationId, string slug, AuthorizationAddOrganizationRolePermissionOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return await this.PostAsync($"/authorization/organizations/{Uri.EscapeDataString(organizationId)}/roles/{Uri.EscapeDataString(slug)}/permissions", options, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task CreateRolePermission(string organizationId, string slug, AuthorizationCreateRolePermissionOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task AddOrganizationRolePermission(string organizationId, string slug, AuthorizationAddOrganizationRolePermissionOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.CreateRolePermissionAsync(organizationId, slug, options, requestOptions, cancellationToken);
+ return this.AddOrganizationRolePermissionAsync(organizationId, slug, options, requestOptions, cancellationToken);
}
/// Set permissions for a custom role
@@ -475,15 +475,15 @@ public virtual Task CreateRolePermission(string organizationId, string slu
/// Per-request configuration overrides.
/// Cancellation token.
/// The result.
- public virtual async Task UpdateRolePermissionsAsync(string organizationId, string slug, AuthorizationUpdateRolePermissionsOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task SetOrganizationRolePermissionsAsync(string organizationId, string slug, AuthorizationSetOrganizationRolePermissionsOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return await this.PutAsync($"/authorization/organizations/{Uri.EscapeDataString(organizationId)}/roles/{Uri.EscapeDataString(slug)}/permissions", options, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task UpdateRolePermissions(string organizationId, string slug, AuthorizationUpdateRolePermissionsOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task SetOrganizationRolePermissions(string organizationId, string slug, AuthorizationSetOrganizationRolePermissionsOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.UpdateRolePermissionsAsync(organizationId, slug, options, requestOptions, cancellationToken);
+ return this.SetOrganizationRolePermissionsAsync(organizationId, slug, options, requestOptions, cancellationToken);
}
/// Remove a permission from a custom role
@@ -495,15 +495,15 @@ public virtual Task UpdateRolePermissions(string organizationId, string sl
/// The slug of the permission to remove.
/// Per-request configuration overrides.
/// Cancellation token.
- public virtual async Task DeleteRolePermissionAsync(string organizationId, string slug, string permissionSlug, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task RemoveOrganizationRolePermissionAsync(string organizationId, string slug, string permissionSlug, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
await this.DeleteAsync($"/authorization/organizations/{Uri.EscapeDataString(organizationId)}/roles/{Uri.EscapeDataString(slug)}/permissions/{Uri.EscapeDataString(permissionSlug)}", null, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task DeleteRolePermission(string organizationId, string slug, string permissionSlug, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task RemoveOrganizationRolePermission(string organizationId, string slug, string permissionSlug, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.DeleteRolePermissionAsync(organizationId, slug, permissionSlug, requestOptions, cancellationToken);
+ return this.RemoveOrganizationRolePermissionAsync(organizationId, slug, permissionSlug, requestOptions, cancellationToken);
}
/// Get a resource by external ID
@@ -516,15 +516,15 @@ public virtual Task DeleteRolePermission(string organizationId, string slug, str
/// Per-request configuration overrides.
/// Cancellation token.
/// The result.
- public virtual async Task GetOrganizationResourceAsync(string organizationId, string resourceTypeSlug, string externalId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task GetResourceByExternalIdAsync(string organizationId, string resourceTypeSlug, string externalId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return await this.GetAsync($"/authorization/organizations/{Uri.EscapeDataString(organizationId)}/resources/{Uri.EscapeDataString(resourceTypeSlug)}/{Uri.EscapeDataString(externalId)}", null, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task GetOrganizationResource(string organizationId, string resourceTypeSlug, string externalId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task GetResourceByExternalId(string organizationId, string resourceTypeSlug, string externalId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.GetOrganizationResourceAsync(organizationId, resourceTypeSlug, externalId, requestOptions, cancellationToken);
+ return this.GetResourceByExternalIdAsync(organizationId, resourceTypeSlug, externalId, requestOptions, cancellationToken);
}
/// Update a resource by external ID
@@ -538,7 +538,7 @@ public virtual Task GetOrganizationResource(string organi
/// Per-request configuration overrides.
/// Cancellation token.
/// The result.
- public virtual async Task UpdateOrganizationResourceAsync(string organizationId, string resourceTypeSlug, string externalId, AuthorizationUpdateOrganizationResourceOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task UpdateResourceByExternalIdAsync(string organizationId, string resourceTypeSlug, string externalId, AuthorizationUpdateResourceByExternalIdOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
var request = new WorkOSRequest
{
@@ -571,10 +571,10 @@ public virtual async Task UpdateOrganizationResourceAsync
return await this.Client.MakeAPIRequest(request, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task UpdateOrganizationResource(string organizationId, string resourceTypeSlug, string externalId, AuthorizationUpdateOrganizationResourceOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task UpdateResourceByExternalId(string organizationId, string resourceTypeSlug, string externalId, AuthorizationUpdateResourceByExternalIdOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.UpdateOrganizationResourceAsync(organizationId, resourceTypeSlug, externalId, options, requestOptions, cancellationToken);
+ return this.UpdateResourceByExternalIdAsync(organizationId, resourceTypeSlug, externalId, options, requestOptions, cancellationToken);
}
/// Delete an authorization resource by external ID
@@ -587,15 +587,15 @@ public virtual Task UpdateOrganizationResource(string org
/// Request options.
/// Per-request configuration overrides.
/// Cancellation token.
- public virtual async Task DeleteOrganizationResourceAsync(string organizationId, string resourceTypeSlug, string externalId, AuthorizationDeleteOrganizationResourceOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task DeleteResourceByExternalIdAsync(string organizationId, string resourceTypeSlug, string externalId, AuthorizationDeleteResourceByExternalIdOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
await this.DeleteAsync($"/authorization/organizations/{Uri.EscapeDataString(organizationId)}/resources/{Uri.EscapeDataString(resourceTypeSlug)}/{Uri.EscapeDataString(externalId)}", options, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task DeleteOrganizationResource(string organizationId, string resourceTypeSlug, string externalId, AuthorizationDeleteOrganizationResourceOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task DeleteResourceByExternalId(string organizationId, string resourceTypeSlug, string externalId, AuthorizationDeleteResourceByExternalIdOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.DeleteOrganizationResourceAsync(organizationId, resourceTypeSlug, externalId, options, requestOptions, cancellationToken);
+ return this.DeleteResourceByExternalIdAsync(organizationId, resourceTypeSlug, externalId, options, requestOptions, cancellationToken);
}
/// List memberships for a resource by external ID
@@ -609,18 +609,18 @@ public virtual Task DeleteOrganizationResource(string organizationId, string res
/// Per-request configuration overrides.
/// Cancellation token.
/// A page of results.
- public virtual async Task> ListResourceOrganizationMembershipsAsync(string organizationId, string resourceTypeSlug, string externalId, AuthorizationListResourceOrganizationMembershipsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual async Task> ListMembershipsForResourceByExternalIdAsync(string organizationId, string resourceTypeSlug, string externalId, AuthorizationListMembershipsForResourceByExternalIdOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return await this.GetAsync>($"/authorization/organizations/{Uri.EscapeDataString(organizationId)}/resources/{Uri.EscapeDataString(resourceTypeSlug)}/{Uri.EscapeDataString(externalId)}/organization_memberships", options, requestOptions, cancellationToken);
}
- /// Compatibility wrapper for .
- public virtual Task> ListResourceOrganizationMemberships(string organizationId, string resourceTypeSlug, string externalId, AuthorizationListResourceOrganizationMembershipsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ /// Compatibility wrapper for .
+ public virtual Task> ListMembershipsForResourceByExternalId(string organizationId, string resourceTypeSlug, string externalId, AuthorizationListMembershipsForResourceByExternalIdOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
- return this.ListResourceOrganizationMembershipsAsync(organizationId, resourceTypeSlug, externalId, options, requestOptions, cancellationToken);
+ return this.ListMembershipsForResourceByExternalIdAsync(organizationId, resourceTypeSlug, externalId, options, requestOptions, cancellationToken);
}
- /// Auto-paging variant of . Yields individual items across all pages.
+ /// Auto-paging variant of . Yields individual items across all pages.
/// The ID of the organization that owns the resource.
/// The slug of the resource type this resource belongs to.
/// An identifier you provide to reference the resource in your system.
@@ -628,7 +628,7 @@ public virtual Task> ListReso
/// Per-request configuration overrides.
/// Cancellation token.
/// An async sequence of items.
- public virtual IAsyncEnumerable ListResourceOrganizationMembershipsAutoPagingAsync(string organizationId, string resourceTypeSlug, string externalId, AuthorizationListResourceOrganizationMembershipsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ public virtual IAsyncEnumerable ListMembershipsForResourceByExternalIdAutoPagingAsync(string organizationId, string resourceTypeSlug, string externalId, AuthorizationListMembershipsForResourceByExternalIdOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
{
return this.ListAutoPagingAsync($"/authorization/organizations/{Uri.EscapeDataString(organizationId)}/resources/{Uri.EscapeDataString(resourceTypeSlug)}/{Uri.EscapeDataString(externalId)}/organization_memberships", options, requestOptions, cancellationToken);
}
diff --git a/src/WorkOS.net/Services/Authorization/_interfaces/AuthorizationOptions.cs b/src/WorkOS.net/Services/Authorization/_interfaces/AuthorizationOptions.cs
index 3b24cc0d..baafb8e9 100644
--- a/src/WorkOS.net/Services/Authorization/_interfaces/AuthorizationOptions.cs
+++ b/src/WorkOS.net/Services/Authorization/_interfaces/AuthorizationOptions.cs
@@ -35,8 +35,8 @@ public class AuthorizationResourceTargetByExternalId : AuthorizationResourceTarg
}
- /// Request options for : List resources for organization membership
- public class AuthorizationListOrganizationMembershipResourcesOptions : ListOptions
+ /// Request options for : List resources for organization membership
+ public class AuthorizationListResourcesForMembershipOptions : ListOptions
{
/// The permission slug to filter by. Only child resources where the organization membership has this permission are returned.
public string PermissionSlug { get; set; } = default!;
@@ -63,8 +63,8 @@ public class AuthorizationParentResourceByExternalId : AuthorizationParentResour
}
- /// Request options for : List effective permissions for an organization membership on a resource
- public class AuthorizationListResourcePermissionsOptions : ListOptions
+ /// Request options for : List effective permissions for an organization membership on a resource
+ public class AuthorizationListEffectivePermissionsOptions : ListOptions
{
}
@@ -73,8 +73,8 @@ public class AuthorizationListEffectivePermissionsByExternalIdOptions : ListOpti
{
}
- /// Request options for : List role assignments
- public class AuthorizationListOrganizationMembershipRoleAssignmentsOptions : ListOptions
+ /// Request options for : List role assignments
+ public class AuthorizationListRoleAssignmentsOptions : ListOptions
{
}
@@ -130,24 +130,24 @@ public class AuthorizationUpdateOrganizationRoleOptions : BaseOptions
}
- /// Request options for : Add a permission to a custom role
- public class AuthorizationCreateRolePermissionOptions : BaseOptions
+ /// Request options for : Add a permission to a custom role
+ public class AuthorizationAddOrganizationRolePermissionOptions : BaseOptions
{
/// The slug of the permission to add to the role.
public string Slug { get; set; } = default!;
}
- /// Request options for : Set permissions for a custom role
- public class AuthorizationUpdateRolePermissionsOptions : BaseOptions
+ /// Request options for : Set permissions for a custom role
+ public class AuthorizationSetOrganizationRolePermissionsOptions : BaseOptions
{
/// The permission slugs to assign to the role.
public List Permissions { get; set; } = default!;
}
- /// Request options for : Update a resource by external ID
- public class AuthorizationUpdateOrganizationResourceOptions : BaseOptions
+ /// Request options for : Update a resource by external ID
+ public class AuthorizationUpdateResourceByExternalIdOptions : BaseOptions
{
/// A display name for the resource.
public string? Name { get; set; }
@@ -161,16 +161,16 @@ public class AuthorizationUpdateOrganizationResourceOptions : BaseOptions
}
- /// Request options for : Delete an authorization resource by external ID
- public class AuthorizationDeleteOrganizationResourceOptions : BaseOptions
+ /// Request options for : Delete an authorization resource by external ID
+ public class AuthorizationDeleteResourceByExternalIdOptions : BaseOptions
{
/// If true, deletes all descendant resources and role assignments. If not set and the resource has children or assignments, the request will fail.
public bool? CascadeDelete { get; set; }
}
- /// Request options for : List memberships for a resource by external ID
- public class AuthorizationListResourceOrganizationMembershipsOptions : ListOptions
+ /// Request options for : List memberships for a resource by external ID
+ public class AuthorizationListMembershipsForResourceByExternalIdOptions : ListOptions
{
/// The permission slug to filter by. Only users with this permission on the resource are returned.
public string PermissionSlug { get; set; } = default!;
@@ -189,6 +189,9 @@ public class AuthorizationListResourcesOptions : ListOptions
/// Filter resources by resource type slug.
public string? ResourceTypeSlug { get; set; }
+ /// Filter resources by external ID.
+ public string? ResourceExternalId { get; set; }
+
/// Search resources by name.
public string? Search { get; set; }
diff --git a/src/WorkOS.net/Services/Groups/GroupsService.cs b/src/WorkOS.net/Services/Groups/GroupsService.cs
new file mode 100644
index 00000000..294bfd4d
--- /dev/null
+++ b/src/WorkOS.net/Services/Groups/GroupsService.cs
@@ -0,0 +1,212 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+ using System.Collections.Generic;
+ using System.Net.Http;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ /// Service that exposes the groups API operations on .
+ public class GroupsService : Service
+ {
+ ///
+ /// Initializes a new instance of the class for mocking. The service uses the singleton
+ /// client configured via .
+ ///
+ public GroupsService() { }
+
+ ///
+ /// Initializes a new instance of the class bound to the
+ /// supplied .
+ ///
+ /// The HTTP client used to make API requests.
+ public GroupsService(WorkOSClient client) : base(client) { }
+
+ /// List groups
+ ///
+ /// Get a paginated list of groups within an organization.
+ ///
+ /// The ID of the organization.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// A page of results.
+ public virtual async Task> ListOrganizationGroupsAsync(string organizationId, GroupsListOrganizationGroupsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return await this.GetAsync>($"/organizations/{Uri.EscapeDataString(organizationId)}/groups", options, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task> ListOrganizationGroups(string organizationId, GroupsListOrganizationGroupsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.ListOrganizationGroupsAsync(organizationId, options, requestOptions, cancellationToken);
+ }
+
+ /// Auto-paging variant of . Yields individual items across all pages.
+ /// The ID of the organization.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// An async sequence of items.
+ public virtual IAsyncEnumerable ListOrganizationGroupsAutoPagingAsync(string organizationId, GroupsListOrganizationGroupsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.ListAutoPagingAsync($"/organizations/{Uri.EscapeDataString(organizationId)}/groups", options, requestOptions, cancellationToken);
+ }
+
+ /// Create a group
+ ///
+ /// Create a new group within an organization.
+ ///
+ /// The ID of the organization.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// The result.
+ public virtual async Task CreateOrganizationGroupAsync(string organizationId, GroupsCreateOrganizationGroupOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return await this.PostAsync($"/organizations/{Uri.EscapeDataString(organizationId)}/groups", options, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task CreateOrganizationGroup(string organizationId, GroupsCreateOrganizationGroupOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.CreateOrganizationGroupAsync(organizationId, options, requestOptions, cancellationToken);
+ }
+
+ /// Get a group
+ ///
+ /// Retrieve a group by its ID within an organization.
+ ///
+ /// The ID of the organization.
+ /// The ID of the group.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// The result.
+ public virtual async Task GetOrganizationGroupAsync(string organizationId, string groupId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return await this.GetAsync($"/organizations/{Uri.EscapeDataString(organizationId)}/groups/{Uri.EscapeDataString(groupId)}", null, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task GetOrganizationGroup(string organizationId, string groupId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.GetOrganizationGroupAsync(organizationId, groupId, requestOptions, cancellationToken);
+ }
+
+ /// Update a group
+ ///
+ /// Update an existing group. Only the fields provided in the request body will be updated.
+ ///
+ /// The ID of the organization.
+ /// The ID of the group.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// The result.
+ public virtual async Task UpdateOrganizationGroupAsync(string organizationId, string groupId, GroupsUpdateOrganizationGroupOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return await this.PatchAsync($"/organizations/{Uri.EscapeDataString(organizationId)}/groups/{Uri.EscapeDataString(groupId)}", options, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task UpdateOrganizationGroup(string organizationId, string groupId, GroupsUpdateOrganizationGroupOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.UpdateOrganizationGroupAsync(organizationId, groupId, options, requestOptions, cancellationToken);
+ }
+
+ /// Delete a group
+ ///
+ /// Delete a group from an organization.
+ ///
+ /// The ID of the organization.
+ /// The ID of the group.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ public virtual async Task DeleteOrganizationGroupAsync(string organizationId, string groupId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ await this.DeleteAsync($"/organizations/{Uri.EscapeDataString(organizationId)}/groups/{Uri.EscapeDataString(groupId)}", null, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task DeleteOrganizationGroup(string organizationId, string groupId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.DeleteOrganizationGroupAsync(organizationId, groupId, requestOptions, cancellationToken);
+ }
+
+ /// List Group members
+ ///
+ /// Get a list of organization memberships in a group.
+ ///
+ /// Unique identifier of the Organization.
+ /// Unique identifier of the Group.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// A page of results.
+ public virtual async Task> ListOrganizationMembershipsAsync(string organizationId, string groupId, GroupsListOrganizationMembershipsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return await this.GetAsync>($"/organizations/{Uri.EscapeDataString(organizationId)}/groups/{Uri.EscapeDataString(groupId)}/organization-memberships", options, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task> ListOrganizationMemberships(string organizationId, string groupId, GroupsListOrganizationMembershipsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.ListOrganizationMembershipsAsync(organizationId, groupId, options, requestOptions, cancellationToken);
+ }
+
+ /// Auto-paging variant of . Yields individual items across all pages.
+ /// Unique identifier of the Organization.
+ /// Unique identifier of the Group.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// An async sequence of items.
+ public virtual IAsyncEnumerable ListOrganizationMembershipsAutoPagingAsync(string organizationId, string groupId, GroupsListOrganizationMembershipsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.ListAutoPagingAsync($"/organizations/{Uri.EscapeDataString(organizationId)}/groups/{Uri.EscapeDataString(groupId)}/organization-memberships", options, requestOptions, cancellationToken);
+ }
+
+ /// Add a member to a Group
+ ///
+ /// Add an organization membership to a group.
+ ///
+ /// Unique identifier of the Organization.
+ /// Unique identifier of the Group.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// The result.
+ public virtual async Task CreateOrganizationMembershipAsync(string organizationId, string groupId, GroupsCreateOrganizationMembershipOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return await this.PostAsync($"/organizations/{Uri.EscapeDataString(organizationId)}/groups/{Uri.EscapeDataString(groupId)}/organization-memberships", options, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task CreateOrganizationMembership(string organizationId, string groupId, GroupsCreateOrganizationMembershipOptions options, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.CreateOrganizationMembershipAsync(organizationId, groupId, options, requestOptions, cancellationToken);
+ }
+
+ /// Remove a member from a Group
+ ///
+ /// Remove an organization membership from a group.
+ ///
+ /// Unique identifier of the Organization.
+ /// Unique identifier of the Group.
+ /// Unique identifier of the Organization Membership.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ public virtual async Task DeleteOrganizationMembershipAsync(string organizationId, string groupId, string omId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ await this.DeleteAsync($"/organizations/{Uri.EscapeDataString(organizationId)}/groups/{Uri.EscapeDataString(groupId)}/organization-memberships/{Uri.EscapeDataString(omId)}", null, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task DeleteOrganizationMembership(string organizationId, string groupId, string omId, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.DeleteOrganizationMembershipAsync(organizationId, groupId, omId, requestOptions, cancellationToken);
+ }
+ }
+}
diff --git a/src/WorkOS.net/Services/Groups/_interfaces/GroupsOptions.cs b/src/WorkOS.net/Services/Groups/_interfaces/GroupsOptions.cs
new file mode 100644
index 00000000..03a20d29
--- /dev/null
+++ b/src/WorkOS.net/Services/Groups/_interfaces/GroupsOptions.cs
@@ -0,0 +1,49 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+ using System.Collections.Generic;
+ using Newtonsoft.Json;
+ using STJS = System.Text.Json.Serialization;
+
+ /// Request options for : List groups
+ public class GroupsListOrganizationGroupsOptions : ListOptions
+ {
+ }
+
+ /// Request options for : Create a group
+ public class GroupsCreateOrganizationGroupOptions : BaseOptions
+ {
+ /// The name of the Group.
+ public string Name { get; set; } = default!;
+
+ /// An optional description of the Group.
+ public string? Description { get; set; }
+
+ }
+
+ /// Request options for : Update a group
+ public class GroupsUpdateOrganizationGroupOptions : BaseOptions
+ {
+ /// The name of the Group.
+ public string? Name { get; set; }
+
+ /// An optional description of the Group.
+ public string? Description { get; set; }
+
+ }
+
+ /// Request options for : List Group members
+ public class GroupsListOrganizationMembershipsOptions : ListOptions
+ {
+ }
+
+ /// Request options for : Add a member to a Group
+ public class GroupsCreateOrganizationMembershipOptions : BaseOptions
+ {
+ /// The ID of the Organization Membership to add to the group.
+ public string OrganizationMembershipId { get; set; } = default!;
+
+ }
+}
diff --git a/src/WorkOS.net/Services/SSO/_interfaces/SSOOptions.cs b/src/WorkOS.net/Services/SSO/_interfaces/SSOOptions.cs
index 245be594..651f8051 100644
--- a/src/WorkOS.net/Services/SSO/_interfaces/SSOOptions.cs
+++ b/src/WorkOS.net/Services/SSO/_interfaces/SSOOptions.cs
@@ -37,7 +37,7 @@ public class SSOGetAuthorizationUrlOptions : BaseOptions
[System.Obsolete("Deprecated. Use `connection` or `organization` instead.")]
public string? Domain { get; set; }
- /// Used to initiate OAuth authentication with Google, Microsoft, GitHub, or Apple.
+ /// Used to initiate OAuth authentication with various providers.
public SSOProvider? Provider { get; set; }
/// Where to redirect the user after they complete the authentication process. You must use one of the redirect URIs configured via the [Redirects](https://dashboard.workos.com/redirects) page on the dashboard.
diff --git a/src/WorkOS.net/Services/UserManagementOrganizationMembershipGroups/UserManagementOrganizationMembershipGroupsService.cs b/src/WorkOS.net/Services/UserManagementOrganizationMembershipGroups/UserManagementOrganizationMembershipGroupsService.cs
new file mode 100644
index 00000000..bdfbcd6b
--- /dev/null
+++ b/src/WorkOS.net/Services/UserManagementOrganizationMembershipGroups/UserManagementOrganizationMembershipGroupsService.cs
@@ -0,0 +1,58 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+ using System.Collections.Generic;
+ using System.Net.Http;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ /// Service that exposes the user management organization membership groups API operations on .
+ public class UserManagementOrganizationMembershipGroupsService : Service
+ {
+ ///
+ /// Initializes a new instance of the class for mocking. The service uses the singleton
+ /// client configured via .
+ ///
+ public UserManagementOrganizationMembershipGroupsService() { }
+
+ ///
+ /// Initializes a new instance of the class bound to the
+ /// supplied .
+ ///
+ /// The HTTP client used to make API requests.
+ public UserManagementOrganizationMembershipGroupsService(WorkOSClient client) : base(client) { }
+
+ /// List groups
+ ///
+ /// Get a list of groups that an organization membership belongs to.
+ ///
+ /// Unique identifier of the Organization Membership.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// A page of results.
+ public virtual async Task> ListOrganizationMembershipGroupsAsync(string omId, UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return await this.GetAsync>($"/user_management/organization_memberships/{Uri.EscapeDataString(omId)}/groups", options, requestOptions, cancellationToken);
+ }
+
+ /// Compatibility wrapper for .
+ public virtual Task> ListOrganizationMembershipGroups(string omId, UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.ListOrganizationMembershipGroupsAsync(omId, options, requestOptions, cancellationToken);
+ }
+
+ /// Auto-paging variant of . Yields individual items across all pages.
+ /// Unique identifier of the Organization Membership.
+ /// Request options.
+ /// Per-request configuration overrides.
+ /// Cancellation token.
+ /// An async sequence of items.
+ public virtual IAsyncEnumerable ListOrganizationMembershipGroupsAutoPagingAsync(string omId, UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions? options = null, RequestOptions? requestOptions = null, CancellationToken cancellationToken = default)
+ {
+ return this.ListAutoPagingAsync($"/user_management/organization_memberships/{Uri.EscapeDataString(omId)}/groups", options, requestOptions, cancellationToken);
+ }
+ }
+}
diff --git a/src/WorkOS.net/Services/UserManagementOrganizationMembershipGroups/_interfaces/UserManagementOrganizationMembershipGroupsOptions.cs b/src/WorkOS.net/Services/UserManagementOrganizationMembershipGroups/_interfaces/UserManagementOrganizationMembershipGroupsOptions.cs
new file mode 100644
index 00000000..94155c74
--- /dev/null
+++ b/src/WorkOS.net/Services/UserManagementOrganizationMembershipGroups/_interfaces/UserManagementOrganizationMembershipGroupsOptions.cs
@@ -0,0 +1,14 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOS
+{
+ using System;
+ using System.Collections.Generic;
+ using Newtonsoft.Json;
+ using STJS = System.Text.Json.Serialization;
+
+ /// Request options for : List groups
+ public class UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions : ListOptions
+ {
+ }
+}
diff --git a/test/WorkOSTests/Tests/AuthorizationServiceTest.cs b/test/WorkOSTests/Tests/AuthorizationServiceTest.cs
index d86b6646..6c1db3de 100644
--- a/test/WorkOSTests/Tests/AuthorizationServiceTest.cs
+++ b/test/WorkOSTests/Tests/AuthorizationServiceTest.cs
@@ -40,41 +40,41 @@ public async Task TestCheckAsync()
}
[Fact]
- public async Task TestListOrganizationMembershipResourcesAsync()
+ public async Task TestListResourcesForMembershipAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/list_authorization_resource.json");
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources", HttpStatusCode.OK, fixture);
- var result = await this.service.ListOrganizationMembershipResourcesAsync("test_organization_membership_id", new AuthorizationListOrganizationMembershipResourcesOptions());
+ var result = await this.service.ListResourcesForMembershipAsync("test_organization_membership_id", new AuthorizationListResourcesForMembershipOptions());
Assert.NotNull(result);
Assert.NotEmpty(result.Data);
this.httpMock.AssertRequestWasMade(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources");
}
[Fact]
- public async Task TestListOrganizationMembershipResourcesAsyncEmpty()
+ public async Task TestListResourcesForMembershipAsyncEmpty()
{
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources", HttpStatusCode.OK, "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}");
- var result = await this.service.ListOrganizationMembershipResourcesAsync("test_organization_membership_id", new AuthorizationListOrganizationMembershipResourcesOptions());
+ var result = await this.service.ListResourcesForMembershipAsync("test_organization_membership_id", new AuthorizationListResourcesForMembershipOptions());
Assert.NotNull(result);
Assert.Empty(result.Data);
}
[Fact]
- public async Task TestListResourcePermissionsAsync()
+ public async Task TestListEffectivePermissionsAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/list_authorization_permission.json");
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources/test_resource_id/permissions", HttpStatusCode.OK, fixture);
- var result = await this.service.ListResourcePermissionsAsync("test_organization_membership_id", "test_resource_id", new AuthorizationListResourcePermissionsOptions());
+ var result = await this.service.ListEffectivePermissionsAsync("test_organization_membership_id", "test_resource_id", new AuthorizationListEffectivePermissionsOptions());
Assert.NotNull(result);
Assert.NotEmpty(result.Data);
this.httpMock.AssertRequestWasMade(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources/test_resource_id/permissions");
}
[Fact]
- public async Task TestListResourcePermissionsAsyncEmpty()
+ public async Task TestListEffectivePermissionsAsyncEmpty()
{
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources/test_resource_id/permissions", HttpStatusCode.OK, "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}");
- var result = await this.service.ListResourcePermissionsAsync("test_organization_membership_id", "test_resource_id", new AuthorizationListResourcePermissionsOptions());
+ var result = await this.service.ListEffectivePermissionsAsync("test_organization_membership_id", "test_resource_id", new AuthorizationListEffectivePermissionsOptions());
Assert.NotNull(result);
Assert.Empty(result.Data);
}
@@ -100,21 +100,21 @@ public async Task TestListEffectivePermissionsByExternalIdAsyncEmpty()
}
[Fact]
- public async Task TestListOrganizationMembershipRoleAssignmentsAsync()
+ public async Task TestListRoleAssignmentsAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/list_role_assignment.json");
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/role_assignments", HttpStatusCode.OK, fixture);
- var result = await this.service.ListOrganizationMembershipRoleAssignmentsAsync("test_organization_membership_id", new AuthorizationListOrganizationMembershipRoleAssignmentsOptions());
+ var result = await this.service.ListRoleAssignmentsAsync("test_organization_membership_id", new AuthorizationListRoleAssignmentsOptions());
Assert.NotNull(result);
Assert.NotEmpty(result.Data);
this.httpMock.AssertRequestWasMade(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/role_assignments");
}
[Fact]
- public async Task TestListOrganizationMembershipRoleAssignmentsAsyncEmpty()
+ public async Task TestListRoleAssignmentsAsyncEmpty()
{
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/role_assignments", HttpStatusCode.OK, "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}");
- var result = await this.service.ListOrganizationMembershipRoleAssignmentsAsync("test_organization_membership_id", new AuthorizationListOrganizationMembershipRoleAssignmentsOptions());
+ var result = await this.service.ListRoleAssignmentsAsync("test_organization_membership_id", new AuthorizationListRoleAssignmentsOptions());
Assert.NotNull(result);
Assert.Empty(result.Data);
}
@@ -142,10 +142,10 @@ public async Task TestRemoveRoleAsync()
}
[Fact]
- public async Task TestDeleteOrganizationMembershipRoleAssignmentAsync()
+ public async Task TestRemoveRoleAssignmentAsync()
{
this.httpMock.MockResponse(HttpMethod.Delete, "/authorization/organization_memberships/test_organization_membership_id/role_assignments/test_role_assignment_id", HttpStatusCode.NoContent, "");
- await this.service.DeleteOrganizationMembershipRoleAssignmentAsync("test_organization_membership_id", "test_role_assignment_id");
+ await this.service.RemoveRoleAssignmentAsync("test_organization_membership_id", "test_role_assignment_id");
this.httpMock.AssertRequestWasMade(HttpMethod.Delete, "/authorization/organization_memberships/test_organization_membership_id/role_assignments/test_role_assignment_id");
}
@@ -210,13 +210,13 @@ public async Task TestDeleteOrganizationRoleAsync()
}
[Fact]
- public async Task TestCreateRolePermissionAsync()
+ public async Task TestAddOrganizationRolePermissionAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/role.json");
this.httpMock.MockResponse(HttpMethod.Post, "/authorization/organizations/test_organizationId/roles/test_slug/permissions", HttpStatusCode.OK, fixture);
- var options = new AuthorizationCreateRolePermissionOptions();
+ var options = new AuthorizationAddOrganizationRolePermissionOptions();
options.Slug = "test_slug";
- var result = await this.service.CreateRolePermissionAsync("test_organizationId", "test_slug", options);
+ var result = await this.service.AddOrganizationRolePermissionAsync("test_organizationId", "test_slug", options);
Assert.NotNull(result);
Assert.Equal("role_01EHQMYV6MBK39QC5PZXHY59C3", result.Id);
Assert.Equal("admin", result.Slug);
@@ -226,11 +226,11 @@ public async Task TestCreateRolePermissionAsync()
}
[Fact]
- public async Task TestUpdateRolePermissionsAsync()
+ public async Task TestSetOrganizationRolePermissionsAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/role.json");
this.httpMock.MockResponse(HttpMethod.Put, "/authorization/organizations/test_organizationId/roles/test_slug/permissions", HttpStatusCode.OK, fixture);
- var result = await this.service.UpdateRolePermissionsAsync("test_organizationId", "test_slug", new AuthorizationUpdateRolePermissionsOptions());
+ var result = await this.service.SetOrganizationRolePermissionsAsync("test_organizationId", "test_slug", new AuthorizationSetOrganizationRolePermissionsOptions());
Assert.NotNull(result);
Assert.Equal("role_01EHQMYV6MBK39QC5PZXHY59C3", result.Id);
Assert.Equal("admin", result.Slug);
@@ -239,19 +239,19 @@ public async Task TestUpdateRolePermissionsAsync()
}
[Fact]
- public async Task TestDeleteRolePermissionAsync()
+ public async Task TestRemoveOrganizationRolePermissionAsync()
{
this.httpMock.MockResponse(HttpMethod.Delete, "/authorization/organizations/test_organizationId/roles/test_slug/permissions/test_permissionSlug", HttpStatusCode.NoContent, "");
- await this.service.DeleteRolePermissionAsync("test_organizationId", "test_slug", "test_permissionSlug");
+ await this.service.RemoveOrganizationRolePermissionAsync("test_organizationId", "test_slug", "test_permissionSlug");
this.httpMock.AssertRequestWasMade(HttpMethod.Delete, "/authorization/organizations/test_organizationId/roles/test_slug/permissions/test_permissionSlug");
}
[Fact]
- public async Task TestGetOrganizationResourceAsync()
+ public async Task TestGetResourceByExternalIdAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/authorization_resource.json");
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id", HttpStatusCode.OK, fixture);
- var result = await this.service.GetOrganizationResourceAsync("test_organization_id", "test_resource_type_slug", "test_external_id");
+ var result = await this.service.GetResourceByExternalIdAsync("test_organization_id", "test_resource_type_slug", "test_external_id");
Assert.NotNull(result);
Assert.Equal("authz_resource_01HXYZ123456789ABCDEFGH", result.Id);
Assert.Equal("Website Redesign", result.Name);
@@ -260,11 +260,11 @@ public async Task TestGetOrganizationResourceAsync()
}
[Fact]
- public async Task TestUpdateOrganizationResourceAsync()
+ public async Task TestUpdateResourceByExternalIdAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/authorization_resource.json");
this.httpMock.MockResponse(HttpMethod.Patch, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id", HttpStatusCode.OK, fixture);
- var result = await this.service.UpdateOrganizationResourceAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationUpdateOrganizationResourceOptions());
+ var result = await this.service.UpdateResourceByExternalIdAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationUpdateResourceByExternalIdOptions());
Assert.NotNull(result);
Assert.Equal("authz_resource_01HXYZ123456789ABCDEFGH", result.Id);
Assert.Equal("Website Redesign", result.Name);
@@ -273,29 +273,29 @@ public async Task TestUpdateOrganizationResourceAsync()
}
[Fact]
- public async Task TestDeleteOrganizationResourceAsync()
+ public async Task TestDeleteResourceByExternalIdAsync()
{
this.httpMock.MockResponse(HttpMethod.Delete, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id", HttpStatusCode.NoContent, "");
- await this.service.DeleteOrganizationResourceAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationDeleteOrganizationResourceOptions());
+ await this.service.DeleteResourceByExternalIdAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationDeleteResourceByExternalIdOptions());
this.httpMock.AssertRequestWasMade(HttpMethod.Delete, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id");
}
[Fact]
- public async Task TestListResourceOrganizationMembershipsAsync()
+ public async Task TestListMembershipsForResourceByExternalIdAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/list_user_organization_membership_base_list_data.json");
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id/organization_memberships", HttpStatusCode.OK, fixture);
- var result = await this.service.ListResourceOrganizationMembershipsAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationListResourceOrganizationMembershipsOptions());
+ var result = await this.service.ListMembershipsForResourceByExternalIdAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationListMembershipsForResourceByExternalIdOptions());
Assert.NotNull(result);
Assert.NotEmpty(result.Data);
this.httpMock.AssertRequestWasMade(HttpMethod.Get, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id/organization_memberships");
}
[Fact]
- public async Task TestListResourceOrganizationMembershipsAsyncEmpty()
+ public async Task TestListMembershipsForResourceByExternalIdAsyncEmpty()
{
this.httpMock.MockResponse(HttpMethod.Get, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id/organization_memberships", HttpStatusCode.OK, "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}");
- var result = await this.service.ListResourceOrganizationMembershipsAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationListResourceOrganizationMembershipsOptions());
+ var result = await this.service.ListMembershipsForResourceByExternalIdAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationListMembershipsForResourceByExternalIdOptions());
Assert.NotNull(result);
Assert.Empty(result.Data);
}
@@ -548,7 +548,7 @@ public async Task TestDeletePermissionAsync()
}
[Fact]
- public async Task TestListOrganizationMembershipResourcesAutoPagingAsync()
+ public async Task TestListResourcesForMembershipAutoPagingAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/authorization_resource.json");
var page1 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":\"cursor_123\"}}";
@@ -556,7 +556,7 @@ public async Task TestListOrganizationMembershipResourcesAutoPagingAsync()
this.httpMock.MockSequentialResponses(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources", HttpStatusCode.OK, new[] { page1, page2 });
var items = new List();
- await foreach (var item in this.service.ListOrganizationMembershipResourcesAutoPagingAsync("test_organization_membership_id", new AuthorizationListOrganizationMembershipResourcesOptions()))
+ await foreach (var item in this.service.ListResourcesForMembershipAutoPagingAsync("test_organization_membership_id", new AuthorizationListResourcesForMembershipOptions()))
{
items.Add(item);
}
@@ -565,13 +565,13 @@ public async Task TestListOrganizationMembershipResourcesAutoPagingAsync()
}
[Fact]
- public async Task TestListOrganizationMembershipResourcesAutoPagingAsyncEmpty()
+ public async Task TestListResourcesForMembershipAutoPagingAsyncEmpty()
{
var empty = "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}";
this.httpMock.MockSequentialResponses(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources", HttpStatusCode.OK, new[] { empty });
var items = new List();
- await foreach (var item in this.service.ListOrganizationMembershipResourcesAutoPagingAsync("test_organization_membership_id", new AuthorizationListOrganizationMembershipResourcesOptions()))
+ await foreach (var item in this.service.ListResourcesForMembershipAutoPagingAsync("test_organization_membership_id", new AuthorizationListResourcesForMembershipOptions()))
{
items.Add(item);
}
@@ -580,7 +580,7 @@ public async Task TestListOrganizationMembershipResourcesAutoPagingAsyncEmpty()
}
[Fact]
- public async Task TestListResourcePermissionsAutoPagingAsync()
+ public async Task TestListEffectivePermissionsAutoPagingAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/authorization_permission.json");
var page1 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":\"cursor_123\"}}";
@@ -588,7 +588,7 @@ public async Task TestListResourcePermissionsAutoPagingAsync()
this.httpMock.MockSequentialResponses(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources/test_resource_id/permissions", HttpStatusCode.OK, new[] { page1, page2 });
var items = new List();
- await foreach (var item in this.service.ListResourcePermissionsAutoPagingAsync("test_organization_membership_id", "test_resource_id", new AuthorizationListResourcePermissionsOptions()))
+ await foreach (var item in this.service.ListEffectivePermissionsAutoPagingAsync("test_organization_membership_id", "test_resource_id", new AuthorizationListEffectivePermissionsOptions()))
{
items.Add(item);
}
@@ -597,13 +597,13 @@ public async Task TestListResourcePermissionsAutoPagingAsync()
}
[Fact]
- public async Task TestListResourcePermissionsAutoPagingAsyncEmpty()
+ public async Task TestListEffectivePermissionsAutoPagingAsyncEmpty()
{
var empty = "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}";
this.httpMock.MockSequentialResponses(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/resources/test_resource_id/permissions", HttpStatusCode.OK, new[] { empty });
var items = new List();
- await foreach (var item in this.service.ListResourcePermissionsAutoPagingAsync("test_organization_membership_id", "test_resource_id", new AuthorizationListResourcePermissionsOptions()))
+ await foreach (var item in this.service.ListEffectivePermissionsAutoPagingAsync("test_organization_membership_id", "test_resource_id", new AuthorizationListEffectivePermissionsOptions()))
{
items.Add(item);
}
@@ -644,7 +644,7 @@ public async Task TestListEffectivePermissionsByExternalIdAutoPagingAsyncEmpty()
}
[Fact]
- public async Task TestListOrganizationMembershipRoleAssignmentsAutoPagingAsync()
+ public async Task TestListRoleAssignmentsAutoPagingAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/role_assignment.json");
var page1 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":\"cursor_123\"}}";
@@ -652,7 +652,7 @@ public async Task TestListOrganizationMembershipRoleAssignmentsAutoPagingAsync()
this.httpMock.MockSequentialResponses(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/role_assignments", HttpStatusCode.OK, new[] { page1, page2 });
var items = new List();
- await foreach (var item in this.service.ListOrganizationMembershipRoleAssignmentsAutoPagingAsync("test_organization_membership_id", new AuthorizationListOrganizationMembershipRoleAssignmentsOptions()))
+ await foreach (var item in this.service.ListRoleAssignmentsAutoPagingAsync("test_organization_membership_id", new AuthorizationListRoleAssignmentsOptions()))
{
items.Add(item);
}
@@ -661,13 +661,13 @@ public async Task TestListOrganizationMembershipRoleAssignmentsAutoPagingAsync()
}
[Fact]
- public async Task TestListOrganizationMembershipRoleAssignmentsAutoPagingAsyncEmpty()
+ public async Task TestListRoleAssignmentsAutoPagingAsyncEmpty()
{
var empty = "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}";
this.httpMock.MockSequentialResponses(HttpMethod.Get, "/authorization/organization_memberships/test_organization_membership_id/role_assignments", HttpStatusCode.OK, new[] { empty });
var items = new List();
- await foreach (var item in this.service.ListOrganizationMembershipRoleAssignmentsAutoPagingAsync("test_organization_membership_id", new AuthorizationListOrganizationMembershipRoleAssignmentsOptions()))
+ await foreach (var item in this.service.ListRoleAssignmentsAutoPagingAsync("test_organization_membership_id", new AuthorizationListRoleAssignmentsOptions()))
{
items.Add(item);
}
@@ -676,7 +676,7 @@ public async Task TestListOrganizationMembershipRoleAssignmentsAutoPagingAsyncEm
}
[Fact]
- public async Task TestListResourceOrganizationMembershipsAutoPagingAsync()
+ public async Task TestListMembershipsForResourceByExternalIdAutoPagingAsync()
{
var fixture = System.IO.File.ReadAllText("testdata/user_organization_membership_base_list_data.json");
var page1 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":\"cursor_123\"}}";
@@ -684,7 +684,7 @@ public async Task TestListResourceOrganizationMembershipsAutoPagingAsync()
this.httpMock.MockSequentialResponses(HttpMethod.Get, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id/organization_memberships", HttpStatusCode.OK, new[] { page1, page2 });
var items = new List();
- await foreach (var item in this.service.ListResourceOrganizationMembershipsAutoPagingAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationListResourceOrganizationMembershipsOptions()))
+ await foreach (var item in this.service.ListMembershipsForResourceByExternalIdAutoPagingAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationListMembershipsForResourceByExternalIdOptions()))
{
items.Add(item);
}
@@ -693,13 +693,13 @@ public async Task TestListResourceOrganizationMembershipsAutoPagingAsync()
}
[Fact]
- public async Task TestListResourceOrganizationMembershipsAutoPagingAsyncEmpty()
+ public async Task TestListMembershipsForResourceByExternalIdAutoPagingAsyncEmpty()
{
var empty = "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}";
this.httpMock.MockSequentialResponses(HttpMethod.Get, "/authorization/organizations/test_organization_id/resources/test_resource_type_slug/test_external_id/organization_memberships", HttpStatusCode.OK, new[] { empty });
var items = new List();
- await foreach (var item in this.service.ListResourceOrganizationMembershipsAutoPagingAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationListResourceOrganizationMembershipsOptions()))
+ await foreach (var item in this.service.ListMembershipsForResourceByExternalIdAutoPagingAsync("test_organization_id", "test_resource_type_slug", "test_external_id", new AuthorizationListMembershipsForResourceByExternalIdOptions()))
{
items.Add(item);
}
diff --git a/test/WorkOSTests/Tests/GroupsServiceTest.cs b/test/WorkOSTests/Tests/GroupsServiceTest.cs
new file mode 100644
index 00000000..54e9002b
--- /dev/null
+++ b/test/WorkOSTests/Tests/GroupsServiceTest.cs
@@ -0,0 +1,242 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOSTests
+{
+ using System.Collections.Generic;
+ using System.Net;
+ using System.Net.Http;
+ using System.Threading.Tasks;
+ using WorkOS;
+ using Xunit;
+
+ public class GroupsServiceTest
+ {
+ private readonly HttpMock httpMock;
+ private readonly GroupsService service;
+
+ public GroupsServiceTest()
+ {
+ this.httpMock = new HttpMock();
+ var client = new WorkOSClient(new WorkOSOptions
+ {
+ ApiKey = "sk_test",
+ ClientId = "client_test",
+ HttpClient = this.httpMock.HttpClient,
+ });
+ this.service = new GroupsService(client);
+ }
+
+ [Fact]
+ public async Task TestListOrganizationGroupsAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/list_group.json");
+ this.httpMock.MockResponse(HttpMethod.Get, "/organizations/test_organizationId/groups", HttpStatusCode.OK, fixture);
+ var result = await this.service.ListOrganizationGroupsAsync("test_organizationId", new GroupsListOrganizationGroupsOptions());
+ Assert.NotNull(result);
+ Assert.NotEmpty(result.Data);
+ this.httpMock.AssertRequestWasMade(HttpMethod.Get, "/organizations/test_organizationId/groups");
+ }
+
+ [Fact]
+ public async Task TestListOrganizationGroupsAsyncEmpty()
+ {
+ this.httpMock.MockResponse(HttpMethod.Get, "/organizations/test_organizationId/groups", HttpStatusCode.OK, "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}");
+ var result = await this.service.ListOrganizationGroupsAsync("test_organizationId", new GroupsListOrganizationGroupsOptions());
+ Assert.NotNull(result);
+ Assert.Empty(result.Data);
+ }
+
+ [Fact]
+ public async Task TestCreateOrganizationGroupAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/group.json");
+ this.httpMock.MockResponse(HttpMethod.Post, "/organizations/test_organizationId/groups", HttpStatusCode.OK, fixture);
+ var options = new GroupsCreateOrganizationGroupOptions();
+ options.Name = "test_name";
+ var result = await this.service.CreateOrganizationGroupAsync("test_organizationId", options);
+ Assert.NotNull(result);
+ Assert.Equal("group_01HXYZ123456789ABCDEFGHIJ", result.Id);
+ Assert.Equal("org_01EHWNCE74X7JSDV0X3SZ3KJNY", result.OrganizationId);
+ Assert.Equal("Engineering", result.Name);
+ this.httpMock.AssertRequestWasMade(HttpMethod.Post, "/organizations/test_organizationId/groups");
+ await this.httpMock.AssertRequestBodyContainsAsync("name", "test_name");
+ }
+
+ [Fact]
+ public async Task TestGetOrganizationGroupAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/group.json");
+ this.httpMock.MockResponse(HttpMethod.Get, "/organizations/test_organizationId/groups/test_groupId", HttpStatusCode.OK, fixture);
+ var result = await this.service.GetOrganizationGroupAsync("test_organizationId", "test_groupId");
+ Assert.NotNull(result);
+ Assert.Equal("group_01HXYZ123456789ABCDEFGHIJ", result.Id);
+ Assert.Equal("org_01EHWNCE74X7JSDV0X3SZ3KJNY", result.OrganizationId);
+ Assert.Equal("Engineering", result.Name);
+ this.httpMock.AssertRequestWasMade(HttpMethod.Get, "/organizations/test_organizationId/groups/test_groupId");
+ }
+
+ [Fact]
+ public async Task TestUpdateOrganizationGroupAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/group.json");
+ this.httpMock.MockResponse(HttpMethod.Patch, "/organizations/test_organizationId/groups/test_groupId", HttpStatusCode.OK, fixture);
+ var result = await this.service.UpdateOrganizationGroupAsync("test_organizationId", "test_groupId", new GroupsUpdateOrganizationGroupOptions());
+ Assert.NotNull(result);
+ Assert.Equal("group_01HXYZ123456789ABCDEFGHIJ", result.Id);
+ Assert.Equal("org_01EHWNCE74X7JSDV0X3SZ3KJNY", result.OrganizationId);
+ Assert.Equal("Engineering", result.Name);
+ this.httpMock.AssertRequestWasMade(HttpMethod.Patch, "/organizations/test_organizationId/groups/test_groupId");
+ }
+
+ [Fact]
+ public async Task TestDeleteOrganizationGroupAsync()
+ {
+ this.httpMock.MockResponse(HttpMethod.Delete, "/organizations/test_organizationId/groups/test_groupId", HttpStatusCode.NoContent, "");
+ await this.service.DeleteOrganizationGroupAsync("test_organizationId", "test_groupId");
+ this.httpMock.AssertRequestWasMade(HttpMethod.Delete, "/organizations/test_organizationId/groups/test_groupId");
+ }
+
+ [Fact]
+ public async Task TestListOrganizationMembershipsAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/list_user_organization_membership_base_list_data.json");
+ this.httpMock.MockResponse(HttpMethod.Get, "/organizations/test_organizationId/groups/test_groupId/organization-memberships", HttpStatusCode.OK, fixture);
+ var result = await this.service.ListOrganizationMembershipsAsync("test_organizationId", "test_groupId", new GroupsListOrganizationMembershipsOptions());
+ Assert.NotNull(result);
+ Assert.NotEmpty(result.Data);
+ this.httpMock.AssertRequestWasMade(HttpMethod.Get, "/organizations/test_organizationId/groups/test_groupId/organization-memberships");
+ }
+
+ [Fact]
+ public async Task TestListOrganizationMembershipsAsyncEmpty()
+ {
+ this.httpMock.MockResponse(HttpMethod.Get, "/organizations/test_organizationId/groups/test_groupId/organization-memberships", HttpStatusCode.OK, "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}");
+ var result = await this.service.ListOrganizationMembershipsAsync("test_organizationId", "test_groupId", new GroupsListOrganizationMembershipsOptions());
+ Assert.NotNull(result);
+ Assert.Empty(result.Data);
+ }
+
+ [Fact]
+ public async Task TestCreateOrganizationMembershipAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/group.json");
+ this.httpMock.MockResponse(HttpMethod.Post, "/organizations/test_organizationId/groups/test_groupId/organization-memberships", HttpStatusCode.OK, fixture);
+ var options = new GroupsCreateOrganizationMembershipOptions();
+ options.OrganizationMembershipId = "test_organization_membership_id";
+ var result = await this.service.CreateOrganizationMembershipAsync("test_organizationId", "test_groupId", options);
+ Assert.NotNull(result);
+ Assert.Equal("group_01HXYZ123456789ABCDEFGHIJ", result.Id);
+ Assert.Equal("org_01EHWNCE74X7JSDV0X3SZ3KJNY", result.OrganizationId);
+ Assert.Equal("Engineering", result.Name);
+ this.httpMock.AssertRequestWasMade(HttpMethod.Post, "/organizations/test_organizationId/groups/test_groupId/organization-memberships");
+ await this.httpMock.AssertRequestBodyContainsAsync("organization_membership_id", "test_organization_membership_id");
+ }
+
+ [Fact]
+ public async Task TestDeleteOrganizationMembershipAsync()
+ {
+ this.httpMock.MockResponse(HttpMethod.Delete, "/organizations/test_organizationId/groups/test_groupId/organization-memberships/test_omId", HttpStatusCode.NoContent, "");
+ await this.service.DeleteOrganizationMembershipAsync("test_organizationId", "test_groupId", "test_omId");
+ this.httpMock.AssertRequestWasMade(HttpMethod.Delete, "/organizations/test_organizationId/groups/test_groupId/organization-memberships/test_omId");
+ }
+
+ [Fact]
+ public async Task TestListOrganizationGroupsAutoPagingAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/group.json");
+ var page1 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":\"cursor_123\"}}";
+ var page2 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":null}}";
+ this.httpMock.MockSequentialResponses(HttpMethod.Get, "/organizations/test_organizationId/groups", HttpStatusCode.OK, new[] { page1, page2 });
+
+ var items = new List();
+ await foreach (var item in this.service.ListOrganizationGroupsAutoPagingAsync("test_organizationId", new GroupsListOrganizationGroupsOptions()))
+ {
+ items.Add(item);
+ }
+
+ Assert.Equal(2, items.Count);
+ }
+
+ [Fact]
+ public async Task TestListOrganizationGroupsAutoPagingAsyncEmpty()
+ {
+ var empty = "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}";
+ this.httpMock.MockSequentialResponses(HttpMethod.Get, "/organizations/test_organizationId/groups", HttpStatusCode.OK, new[] { empty });
+
+ var items = new List();
+ await foreach (var item in this.service.ListOrganizationGroupsAutoPagingAsync("test_organizationId", new GroupsListOrganizationGroupsOptions()))
+ {
+ items.Add(item);
+ }
+
+ Assert.Empty(items);
+ }
+
+ [Fact]
+ public async Task TestListOrganizationMembershipsAutoPagingAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/user_organization_membership_base_list_data.json");
+ var page1 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":\"cursor_123\"}}";
+ var page2 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":null}}";
+ this.httpMock.MockSequentialResponses(HttpMethod.Get, "/organizations/test_organizationId/groups/test_groupId/organization-memberships", HttpStatusCode.OK, new[] { page1, page2 });
+
+ var items = new List();
+ await foreach (var item in this.service.ListOrganizationMembershipsAutoPagingAsync("test_organizationId", "test_groupId", new GroupsListOrganizationMembershipsOptions()))
+ {
+ items.Add(item);
+ }
+
+ Assert.Equal(2, items.Count);
+ }
+
+ [Fact]
+ public async Task TestListOrganizationMembershipsAutoPagingAsyncEmpty()
+ {
+ var empty = "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}";
+ this.httpMock.MockSequentialResponses(HttpMethod.Get, "/organizations/test_organizationId/groups/test_groupId/organization-memberships", HttpStatusCode.OK, new[] { empty });
+
+ var items = new List();
+ await foreach (var item in this.service.ListOrganizationMembershipsAutoPagingAsync("test_organizationId", "test_groupId", new GroupsListOrganizationMembershipsOptions()))
+ {
+ items.Add(item);
+ }
+
+ Assert.Empty(items);
+ }
+
+ [Fact]
+ public async Task TestError401()
+ {
+ this.httpMock.MockResponseForAnyRequest(HttpStatusCode.Unauthorized, "{\"code\":\"unauthorized\",\"message\":\"Unauthorized\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationGroupsAsync("test_organizationId", new GroupsListOrganizationGroupsOptions()));
+ }
+
+ [Fact]
+ public async Task TestError404()
+ {
+ this.httpMock.MockResponseForAnyRequest(HttpStatusCode.NotFound, "{\"code\":\"not_found\",\"message\":\"Not Found\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationGroupsAsync("test_organizationId", new GroupsListOrganizationGroupsOptions()));
+ }
+
+ [Fact]
+ public async Task TestError422()
+ {
+ this.httpMock.MockResponseForAnyRequest((HttpStatusCode)422, "{\"code\":\"unprocessable_entity\",\"message\":\"Unprocessable\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationGroupsAsync("test_organizationId", new GroupsListOrganizationGroupsOptions()));
+ }
+
+ [Fact]
+ public async Task TestError429()
+ {
+ this.httpMock.MockResponseForAnyRequest((HttpStatusCode)429, "{\"code\":\"too_many_requests\",\"message\":\"Too Many Requests\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationGroupsAsync("test_organizationId", new GroupsListOrganizationGroupsOptions()));
+ }
+
+ [Fact]
+ public async Task TestError500()
+ {
+ this.httpMock.MockResponseForAnyRequest(HttpStatusCode.InternalServerError, "{\"code\":\"server_error\",\"message\":\"Server Error\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationGroupsAsync("test_organizationId", new GroupsListOrganizationGroupsOptions()));
+ }
+ }
+}
diff --git a/test/WorkOSTests/Tests/UserManagementOrganizationMembershipGroupsServiceTest.cs b/test/WorkOSTests/Tests/UserManagementOrganizationMembershipGroupsServiceTest.cs
new file mode 100644
index 00000000..b0e14999
--- /dev/null
+++ b/test/WorkOSTests/Tests/UserManagementOrganizationMembershipGroupsServiceTest.cs
@@ -0,0 +1,116 @@
+// This file is auto-generated by oagen. Do not edit.
+
+namespace WorkOSTests
+{
+ using System.Collections.Generic;
+ using System.Net;
+ using System.Net.Http;
+ using System.Threading.Tasks;
+ using WorkOS;
+ using Xunit;
+
+ public class UserManagementOrganizationMembershipGroupsServiceTest
+ {
+ private readonly HttpMock httpMock;
+ private readonly UserManagementOrganizationMembershipGroupsService service;
+
+ public UserManagementOrganizationMembershipGroupsServiceTest()
+ {
+ this.httpMock = new HttpMock();
+ var client = new WorkOSClient(new WorkOSOptions
+ {
+ ApiKey = "sk_test",
+ ClientId = "client_test",
+ HttpClient = this.httpMock.HttpClient,
+ });
+ this.service = new UserManagementOrganizationMembershipGroupsService(client);
+ }
+
+ [Fact]
+ public async Task TestListOrganizationMembershipGroupsAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/list_group.json");
+ this.httpMock.MockResponse(HttpMethod.Get, "/user_management/organization_memberships/test_omId/groups", HttpStatusCode.OK, fixture);
+ var result = await this.service.ListOrganizationMembershipGroupsAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions());
+ Assert.NotNull(result);
+ Assert.NotEmpty(result.Data);
+ this.httpMock.AssertRequestWasMade(HttpMethod.Get, "/user_management/organization_memberships/test_omId/groups");
+ }
+
+ [Fact]
+ public async Task TestListOrganizationMembershipGroupsAsyncEmpty()
+ {
+ this.httpMock.MockResponse(HttpMethod.Get, "/user_management/organization_memberships/test_omId/groups", HttpStatusCode.OK, "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}");
+ var result = await this.service.ListOrganizationMembershipGroupsAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions());
+ Assert.NotNull(result);
+ Assert.Empty(result.Data);
+ }
+
+ [Fact]
+ public async Task TestListOrganizationMembershipGroupsAutoPagingAsync()
+ {
+ var fixture = System.IO.File.ReadAllText("testdata/group.json");
+ var page1 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":\"cursor_123\"}}";
+ var page2 = "{\"data\":[" + fixture + "],\"list_metadata\":{\"before\":null,\"after\":null}}";
+ this.httpMock.MockSequentialResponses(HttpMethod.Get, "/user_management/organization_memberships/test_omId/groups", HttpStatusCode.OK, new[] { page1, page2 });
+
+ var items = new List();
+ await foreach (var item in this.service.ListOrganizationMembershipGroupsAutoPagingAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions()))
+ {
+ items.Add(item);
+ }
+
+ Assert.Equal(2, items.Count);
+ }
+
+ [Fact]
+ public async Task TestListOrganizationMembershipGroupsAutoPagingAsyncEmpty()
+ {
+ var empty = "{\"data\":[],\"list_metadata\":{\"before\":null,\"after\":null}}";
+ this.httpMock.MockSequentialResponses(HttpMethod.Get, "/user_management/organization_memberships/test_omId/groups", HttpStatusCode.OK, new[] { empty });
+
+ var items = new List();
+ await foreach (var item in this.service.ListOrganizationMembershipGroupsAutoPagingAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions()))
+ {
+ items.Add(item);
+ }
+
+ Assert.Empty(items);
+ }
+
+ [Fact]
+ public async Task TestError401()
+ {
+ this.httpMock.MockResponseForAnyRequest(HttpStatusCode.Unauthorized, "{\"code\":\"unauthorized\",\"message\":\"Unauthorized\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationMembershipGroupsAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions()));
+ }
+
+ [Fact]
+ public async Task TestError404()
+ {
+ this.httpMock.MockResponseForAnyRequest(HttpStatusCode.NotFound, "{\"code\":\"not_found\",\"message\":\"Not Found\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationMembershipGroupsAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions()));
+ }
+
+ [Fact]
+ public async Task TestError422()
+ {
+ this.httpMock.MockResponseForAnyRequest((HttpStatusCode)422, "{\"code\":\"unprocessable_entity\",\"message\":\"Unprocessable\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationMembershipGroupsAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions()));
+ }
+
+ [Fact]
+ public async Task TestError429()
+ {
+ this.httpMock.MockResponseForAnyRequest((HttpStatusCode)429, "{\"code\":\"too_many_requests\",\"message\":\"Too Many Requests\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationMembershipGroupsAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions()));
+ }
+
+ [Fact]
+ public async Task TestError500()
+ {
+ this.httpMock.MockResponseForAnyRequest(HttpStatusCode.InternalServerError, "{\"code\":\"server_error\",\"message\":\"Server Error\"}");
+ await Assert.ThrowsAsync(() => this.service.ListOrganizationMembershipGroupsAsync("test_omId", new UserManagementOrganizationMembershipGroupsListOrganizationMembershipGroupsOptions()));
+ }
+ }
+}
diff --git a/test/WorkOSTests/testdata/create_group.json b/test/WorkOSTests/testdata/create_group.json
new file mode 100644
index 00000000..bcb47249
--- /dev/null
+++ b/test/WorkOSTests/testdata/create_group.json
@@ -0,0 +1,4 @@
+{
+ "name": "Engineering",
+ "description": "The engineering team"
+}
diff --git a/test/WorkOSTests/testdata/create_group_membership.json b/test/WorkOSTests/testdata/create_group_membership.json
new file mode 100644
index 00000000..45ebd1dd
--- /dev/null
+++ b/test/WorkOSTests/testdata/create_group_membership.json
@@ -0,0 +1,3 @@
+{
+ "organization_membership_id": "om_01HXYZ123456789ABCDEFGHIJ"
+}
diff --git a/test/WorkOSTests/testdata/create_group_nulls.json b/test/WorkOSTests/testdata/create_group_nulls.json
new file mode 100644
index 00000000..3002f315
--- /dev/null
+++ b/test/WorkOSTests/testdata/create_group_nulls.json
@@ -0,0 +1,4 @@
+{
+ "name": "Engineering",
+ "description": null
+}
diff --git a/test/WorkOSTests/testdata/domain_verification_intent_options.json b/test/WorkOSTests/testdata/domain_verification_intent_options.json
new file mode 100644
index 00000000..d132a78a
--- /dev/null
+++ b/test/WorkOSTests/testdata/domain_verification_intent_options.json
@@ -0,0 +1,3 @@
+{
+ "domain_name": "example.com"
+}
diff --git a/test/WorkOSTests/testdata/domain_verification_intent_options_nulls.json b/test/WorkOSTests/testdata/domain_verification_intent_options_nulls.json
new file mode 100644
index 00000000..00fca91e
--- /dev/null
+++ b/test/WorkOSTests/testdata/domain_verification_intent_options_nulls.json
@@ -0,0 +1,3 @@
+{
+ "domain_name": null
+}
diff --git a/test/WorkOSTests/testdata/generate_link.json b/test/WorkOSTests/testdata/generate_link.json
index 660b36a7..4be367d9 100644
--- a/test/WorkOSTests/testdata/generate_link.json
+++ b/test/WorkOSTests/testdata/generate_link.json
@@ -7,9 +7,15 @@
"sso": {
"bookmark_slug": "chatgpt",
"provider_type": "GoogleSAML"
+ },
+ "domain_verification": {
+ "domain_name": "example.com"
}
},
"admin_emails": [
"admin@example.com"
+ ],
+ "it_contact_emails": [
+ "it-contact@example.com"
]
}
diff --git a/test/WorkOSTests/testdata/generate_link_nulls.json b/test/WorkOSTests/testdata/generate_link_nulls.json
index 942c6ea8..d4129de8 100644
--- a/test/WorkOSTests/testdata/generate_link_nulls.json
+++ b/test/WorkOSTests/testdata/generate_link_nulls.json
@@ -4,5 +4,6 @@
"organization": "org_01EHZNVPK3SFK441A1RGBFSHRT",
"intent": null,
"intent_options": null,
- "admin_emails": null
+ "admin_emails": null,
+ "it_contact_emails": null
}
diff --git a/test/WorkOSTests/testdata/intent_options.json b/test/WorkOSTests/testdata/intent_options.json
index 31bad913..894d5998 100644
--- a/test/WorkOSTests/testdata/intent_options.json
+++ b/test/WorkOSTests/testdata/intent_options.json
@@ -2,5 +2,8 @@
"sso": {
"bookmark_slug": "chatgpt",
"provider_type": "GoogleSAML"
+ },
+ "domain_verification": {
+ "domain_name": "example.com"
}
}
diff --git a/test/WorkOSTests/testdata/intent_options_nulls.json b/test/WorkOSTests/testdata/intent_options_nulls.json
new file mode 100644
index 00000000..b75aeabd
--- /dev/null
+++ b/test/WorkOSTests/testdata/intent_options_nulls.json
@@ -0,0 +1,4 @@
+{
+ "sso": null,
+ "domain_verification": null
+}
diff --git a/test/WorkOSTests/testdata/invitation.json b/test/WorkOSTests/testdata/invitation.json
index c2019df7..5dabcd8e 100644
--- a/test/WorkOSTests/testdata/invitation.json
+++ b/test/WorkOSTests/testdata/invitation.json
@@ -12,5 +12,6 @@
"created_at": "2026-01-15T12:00:00.000Z",
"updated_at": "2026-01-15T12:00:00.000Z",
"token": "Z1uX3RbwcIl5fIGJJJCXXisdI",
- "accept_invitation_url": "https://your-app.com/invite?invitation_token=Z1uX3RbwcIl5fIGJJJCXXisdI"
+ "accept_invitation_url": "https://your-app.com/invite?invitation_token=Z1uX3RbwcIl5fIGJJJCXXisdI",
+ "role_slug": "admin"
}
diff --git a/test/WorkOSTests/testdata/invitation_accepted.json b/test/WorkOSTests/testdata/invitation_accepted.json
index 61b93ab4..100adfa9 100644
--- a/test/WorkOSTests/testdata/invitation_accepted.json
+++ b/test/WorkOSTests/testdata/invitation_accepted.json
@@ -13,7 +13,8 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
},
"created_at": "2026-01-15T12:00:00.000Z",
"context": {
diff --git a/test/WorkOSTests/testdata/invitation_accepted_data.json b/test/WorkOSTests/testdata/invitation_accepted_data.json
index 66102c6b..94f2e81d 100644
--- a/test/WorkOSTests/testdata/invitation_accepted_data.json
+++ b/test/WorkOSTests/testdata/invitation_accepted_data.json
@@ -10,5 +10,6 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
}
diff --git a/test/WorkOSTests/testdata/invitation_accepted_data_nulls.json b/test/WorkOSTests/testdata/invitation_accepted_data_nulls.json
index cc675407..90adba7d 100644
--- a/test/WorkOSTests/testdata/invitation_accepted_data_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_accepted_data_nulls.json
@@ -10,5 +10,6 @@
"inviter_user_id": null,
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": null
}
diff --git a/test/WorkOSTests/testdata/invitation_accepted_nulls.json b/test/WorkOSTests/testdata/invitation_accepted_nulls.json
index a8692414..c9bf9790 100644
--- a/test/WorkOSTests/testdata/invitation_accepted_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_accepted_nulls.json
@@ -13,7 +13,8 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
},
"created_at": "2026-01-15T12:00:00.000Z",
"context": null,
diff --git a/test/WorkOSTests/testdata/invitation_created.json b/test/WorkOSTests/testdata/invitation_created.json
index c83b104d..b1398e12 100644
--- a/test/WorkOSTests/testdata/invitation_created.json
+++ b/test/WorkOSTests/testdata/invitation_created.json
@@ -13,7 +13,8 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
},
"created_at": "2026-01-15T12:00:00.000Z",
"context": {
diff --git a/test/WorkOSTests/testdata/invitation_created_data.json b/test/WorkOSTests/testdata/invitation_created_data.json
index 66102c6b..94f2e81d 100644
--- a/test/WorkOSTests/testdata/invitation_created_data.json
+++ b/test/WorkOSTests/testdata/invitation_created_data.json
@@ -10,5 +10,6 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
}
diff --git a/test/WorkOSTests/testdata/invitation_created_data_nulls.json b/test/WorkOSTests/testdata/invitation_created_data_nulls.json
index cc675407..90adba7d 100644
--- a/test/WorkOSTests/testdata/invitation_created_data_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_created_data_nulls.json
@@ -10,5 +10,6 @@
"inviter_user_id": null,
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": null
}
diff --git a/test/WorkOSTests/testdata/invitation_created_nulls.json b/test/WorkOSTests/testdata/invitation_created_nulls.json
index 57fbabee..5d322576 100644
--- a/test/WorkOSTests/testdata/invitation_created_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_created_nulls.json
@@ -13,7 +13,8 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
},
"created_at": "2026-01-15T12:00:00.000Z",
"context": null,
diff --git a/test/WorkOSTests/testdata/invitation_nulls.json b/test/WorkOSTests/testdata/invitation_nulls.json
index 8f0332fe..5f335e99 100644
--- a/test/WorkOSTests/testdata/invitation_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_nulls.json
@@ -12,5 +12,6 @@
"created_at": "2026-01-15T12:00:00.000Z",
"updated_at": "2026-01-15T12:00:00.000Z",
"token": "Z1uX3RbwcIl5fIGJJJCXXisdI",
- "accept_invitation_url": "https://your-app.com/invite?invitation_token=Z1uX3RbwcIl5fIGJJJCXXisdI"
+ "accept_invitation_url": "https://your-app.com/invite?invitation_token=Z1uX3RbwcIl5fIGJJJCXXisdI",
+ "role_slug": null
}
diff --git a/test/WorkOSTests/testdata/invitation_resent.json b/test/WorkOSTests/testdata/invitation_resent.json
index 7ace11e7..17adc958 100644
--- a/test/WorkOSTests/testdata/invitation_resent.json
+++ b/test/WorkOSTests/testdata/invitation_resent.json
@@ -13,7 +13,8 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
},
"created_at": "2026-01-15T12:00:00.000Z",
"context": {
diff --git a/test/WorkOSTests/testdata/invitation_resent_data.json b/test/WorkOSTests/testdata/invitation_resent_data.json
index 66102c6b..94f2e81d 100644
--- a/test/WorkOSTests/testdata/invitation_resent_data.json
+++ b/test/WorkOSTests/testdata/invitation_resent_data.json
@@ -10,5 +10,6 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
}
diff --git a/test/WorkOSTests/testdata/invitation_resent_data_nulls.json b/test/WorkOSTests/testdata/invitation_resent_data_nulls.json
index cc675407..90adba7d 100644
--- a/test/WorkOSTests/testdata/invitation_resent_data_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_resent_data_nulls.json
@@ -10,5 +10,6 @@
"inviter_user_id": null,
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": null
}
diff --git a/test/WorkOSTests/testdata/invitation_resent_nulls.json b/test/WorkOSTests/testdata/invitation_resent_nulls.json
index eebb9054..7e6b98c9 100644
--- a/test/WorkOSTests/testdata/invitation_resent_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_resent_nulls.json
@@ -13,7 +13,8 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
},
"created_at": "2026-01-15T12:00:00.000Z",
"context": null,
diff --git a/test/WorkOSTests/testdata/invitation_revoked.json b/test/WorkOSTests/testdata/invitation_revoked.json
index e8f8ff62..e22216e3 100644
--- a/test/WorkOSTests/testdata/invitation_revoked.json
+++ b/test/WorkOSTests/testdata/invitation_revoked.json
@@ -13,7 +13,8 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
},
"created_at": "2026-01-15T12:00:00.000Z",
"context": {
diff --git a/test/WorkOSTests/testdata/invitation_revoked_data.json b/test/WorkOSTests/testdata/invitation_revoked_data.json
index 66102c6b..94f2e81d 100644
--- a/test/WorkOSTests/testdata/invitation_revoked_data.json
+++ b/test/WorkOSTests/testdata/invitation_revoked_data.json
@@ -10,5 +10,6 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
}
diff --git a/test/WorkOSTests/testdata/invitation_revoked_data_nulls.json b/test/WorkOSTests/testdata/invitation_revoked_data_nulls.json
index cc675407..90adba7d 100644
--- a/test/WorkOSTests/testdata/invitation_revoked_data_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_revoked_data_nulls.json
@@ -10,5 +10,6 @@
"inviter_user_id": null,
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": null
}
diff --git a/test/WorkOSTests/testdata/invitation_revoked_nulls.json b/test/WorkOSTests/testdata/invitation_revoked_nulls.json
index bc7f5efd..4c389b79 100644
--- a/test/WorkOSTests/testdata/invitation_revoked_nulls.json
+++ b/test/WorkOSTests/testdata/invitation_revoked_nulls.json
@@ -13,7 +13,8 @@
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
"created_at": "2026-01-15T12:00:00.000Z",
- "updated_at": "2026-01-15T12:00:00.000Z"
+ "updated_at": "2026-01-15T12:00:00.000Z",
+ "role_slug": "admin"
},
"created_at": "2026-01-15T12:00:00.000Z",
"context": null,
diff --git a/test/WorkOSTests/testdata/list_empty_group.json b/test/WorkOSTests/testdata/list_empty_group.json
new file mode 100644
index 00000000..b11391a0
--- /dev/null
+++ b/test/WorkOSTests/testdata/list_empty_group.json
@@ -0,0 +1,7 @@
+{
+ "data": [],
+ "list_metadata": {
+ "before": null,
+ "after": null
+ }
+}
diff --git a/test/WorkOSTests/testdata/list_group.json b/test/WorkOSTests/testdata/list_group.json
new file mode 100644
index 00000000..9516016b
--- /dev/null
+++ b/test/WorkOSTests/testdata/list_group.json
@@ -0,0 +1,17 @@
+{
+ "data": [
+ {
+ "object": "group",
+ "id": "group_01HXYZ123456789ABCDEFGHIJ",
+ "organization_id": "org_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "name": "Engineering",
+ "description": "The engineering team",
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+ }
+ ],
+ "list_metadata": {
+ "before": null,
+ "after": null
+ }
+}
diff --git a/test/WorkOSTests/testdata/list_user_invite.json b/test/WorkOSTests/testdata/list_user_invite.json
index 355f3e44..6288c488 100644
--- a/test/WorkOSTests/testdata/list_user_invite.json
+++ b/test/WorkOSTests/testdata/list_user_invite.json
@@ -11,6 +11,7 @@
"organization_id": "org_01E4ZCR3C56J083X43JQXF3JK5",
"inviter_user_id": "user_01HYGBX8ZGD19949T3BM4FW1C3",
"accepted_user_id": null,
+ "role_slug": "admin",
"created_at": "2026-01-15T12:00:00.000Z",
"updated_at": "2026-01-15T12:00:00.000Z",
"token": "Z1uX3RbwcIl5fIGJJJCXXisdI",
diff --git a/test/WorkOSTests/testdata/update_group.json b/test/WorkOSTests/testdata/update_group.json
new file mode 100644
index 00000000..bcb47249
--- /dev/null
+++ b/test/WorkOSTests/testdata/update_group.json
@@ -0,0 +1,4 @@
+{
+ "name": "Engineering",
+ "description": "The engineering team"
+}
diff --git a/test/WorkOSTests/testdata/update_group_nulls.json b/test/WorkOSTests/testdata/update_group_nulls.json
new file mode 100644
index 00000000..7de5d2c4
--- /dev/null
+++ b/test/WorkOSTests/testdata/update_group_nulls.json
@@ -0,0 +1,4 @@
+{
+ "name": null,
+ "description": null
+}
diff --git a/test/WorkOSTests/testdata/user_invite.json b/test/WorkOSTests/testdata/user_invite.json
index b3a1dbbd..9c91ed19 100644
--- a/test/WorkOSTests/testdata/user_invite.json
+++ b/test/WorkOSTests/testdata/user_invite.json
@@ -12,5 +12,6 @@
"created_at": "2026-01-15T12:00:00.000Z",
"updated_at": "2026-01-15T12:00:00.000Z",
"token": "Z1uX3RbwcIl5fIGJJJCXXisdI",
- "accept_invitation_url": "https://your-app.com/invite?invitation_token=Z1uX3RbwcIl5fIGJJJCXXisdI"
+ "accept_invitation_url": "https://your-app.com/invite?invitation_token=Z1uX3RbwcIl5fIGJJJCXXisdI",
+ "role_slug": "admin"
}
diff --git a/test/WorkOSTests/testdata/user_invite_nulls.json b/test/WorkOSTests/testdata/user_invite_nulls.json
index abc995cb..b3526d3a 100644
--- a/test/WorkOSTests/testdata/user_invite_nulls.json
+++ b/test/WorkOSTests/testdata/user_invite_nulls.json
@@ -12,5 +12,6 @@
"created_at": "2026-01-15T12:00:00.000Z",
"updated_at": "2026-01-15T12:00:00.000Z",
"token": "Z1uX3RbwcIl5fIGJJJCXXisdI",
- "accept_invitation_url": "https://your-app.com/invite?invitation_token=Z1uX3RbwcIl5fIGJJJCXXisdI"
+ "accept_invitation_url": "https://your-app.com/invite?invitation_token=Z1uX3RbwcIl5fIGJJJCXXisdI",
+ "role_slug": null
}
diff --git a/test/WorkOSTests/testdata/waitlist_user.json b/test/WorkOSTests/testdata/waitlist_user.json
new file mode 100644
index 00000000..05973598
--- /dev/null
+++ b/test/WorkOSTests/testdata/waitlist_user.json
@@ -0,0 +1,9 @@
+{
+ "object": "waitlist_user",
+ "id": "wl_user_01E4ZCR3C56J083X43JQXF3JK5",
+ "email": "marcelina.davis@example.com",
+ "state": "pending",
+ "approved_at": null,
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+}
diff --git a/test/WorkOSTests/testdata/waitlist_user_approved.json b/test/WorkOSTests/testdata/waitlist_user_approved.json
new file mode 100644
index 00000000..eddf230b
--- /dev/null
+++ b/test/WorkOSTests/testdata/waitlist_user_approved.json
@@ -0,0 +1,35 @@
+{
+ "id": "event_01EHZNVPK3SFK441A1RGBFSHRT",
+ "event": "waitlist_user.approved",
+ "data": {
+ "object": "waitlist_user",
+ "id": "wl_user_01E4ZCR3C56J083X43JQXF3JK5",
+ "email": "marcelina.davis@example.com",
+ "state": "pending",
+ "approved_at": null,
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+ },
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "context": {
+ "google_analytics_client_id": "GA1.2.1234567890.1234567890",
+ "google_analytics_sessions": [
+ {
+ "containerId": "GTM-ABCDEF",
+ "sessionId": "1234567890",
+ "sessionNumber": "1"
+ }
+ ],
+ "ajs_anonymous_id": "ajs_anon_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "client_id": "client_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "actor": {
+ "id": "user_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "source": "api",
+ "name": "Jane Doe"
+ },
+ "previous_attributes": {
+ "key": {}
+ }
+ },
+ "object": "event"
+}
diff --git a/test/WorkOSTests/testdata/waitlist_user_approved_nulls.json b/test/WorkOSTests/testdata/waitlist_user_approved_nulls.json
new file mode 100644
index 00000000..b1fe27af
--- /dev/null
+++ b/test/WorkOSTests/testdata/waitlist_user_approved_nulls.json
@@ -0,0 +1,16 @@
+{
+ "id": "event_01EHZNVPK3SFK441A1RGBFSHRT",
+ "event": "waitlist_user.approved",
+ "data": {
+ "object": "waitlist_user",
+ "id": "wl_user_01E4ZCR3C56J083X43JQXF3JK5",
+ "email": "marcelina.davis@example.com",
+ "state": "pending",
+ "approved_at": null,
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+ },
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "context": null,
+ "object": "event"
+}
diff --git a/test/WorkOSTests/testdata/waitlist_user_created.json b/test/WorkOSTests/testdata/waitlist_user_created.json
new file mode 100644
index 00000000..c3faaad7
--- /dev/null
+++ b/test/WorkOSTests/testdata/waitlist_user_created.json
@@ -0,0 +1,35 @@
+{
+ "id": "event_01EHZNVPK3SFK441A1RGBFSHRT",
+ "event": "waitlist_user.created",
+ "data": {
+ "object": "waitlist_user",
+ "id": "wl_user_01E4ZCR3C56J083X43JQXF3JK5",
+ "email": "marcelina.davis@example.com",
+ "state": "pending",
+ "approved_at": null,
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+ },
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "context": {
+ "google_analytics_client_id": "GA1.2.1234567890.1234567890",
+ "google_analytics_sessions": [
+ {
+ "containerId": "GTM-ABCDEF",
+ "sessionId": "1234567890",
+ "sessionNumber": "1"
+ }
+ ],
+ "ajs_anonymous_id": "ajs_anon_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "client_id": "client_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "actor": {
+ "id": "user_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "source": "api",
+ "name": "Jane Doe"
+ },
+ "previous_attributes": {
+ "key": {}
+ }
+ },
+ "object": "event"
+}
diff --git a/test/WorkOSTests/testdata/waitlist_user_created_nulls.json b/test/WorkOSTests/testdata/waitlist_user_created_nulls.json
new file mode 100644
index 00000000..611e5c79
--- /dev/null
+++ b/test/WorkOSTests/testdata/waitlist_user_created_nulls.json
@@ -0,0 +1,16 @@
+{
+ "id": "event_01EHZNVPK3SFK441A1RGBFSHRT",
+ "event": "waitlist_user.created",
+ "data": {
+ "object": "waitlist_user",
+ "id": "wl_user_01E4ZCR3C56J083X43JQXF3JK5",
+ "email": "marcelina.davis@example.com",
+ "state": "pending",
+ "approved_at": null,
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+ },
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "context": null,
+ "object": "event"
+}
diff --git a/test/WorkOSTests/testdata/waitlist_user_denied.json b/test/WorkOSTests/testdata/waitlist_user_denied.json
new file mode 100644
index 00000000..6079919b
--- /dev/null
+++ b/test/WorkOSTests/testdata/waitlist_user_denied.json
@@ -0,0 +1,35 @@
+{
+ "id": "event_01EHZNVPK3SFK441A1RGBFSHRT",
+ "event": "waitlist_user.denied",
+ "data": {
+ "object": "waitlist_user",
+ "id": "wl_user_01E4ZCR3C56J083X43JQXF3JK5",
+ "email": "marcelina.davis@example.com",
+ "state": "pending",
+ "approved_at": null,
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+ },
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "context": {
+ "google_analytics_client_id": "GA1.2.1234567890.1234567890",
+ "google_analytics_sessions": [
+ {
+ "containerId": "GTM-ABCDEF",
+ "sessionId": "1234567890",
+ "sessionNumber": "1"
+ }
+ ],
+ "ajs_anonymous_id": "ajs_anon_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "client_id": "client_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "actor": {
+ "id": "user_01EHWNCE74X7JSDV0X3SZ3KJNY",
+ "source": "api",
+ "name": "Jane Doe"
+ },
+ "previous_attributes": {
+ "key": {}
+ }
+ },
+ "object": "event"
+}
diff --git a/test/WorkOSTests/testdata/waitlist_user_denied_nulls.json b/test/WorkOSTests/testdata/waitlist_user_denied_nulls.json
new file mode 100644
index 00000000..cc8ac520
--- /dev/null
+++ b/test/WorkOSTests/testdata/waitlist_user_denied_nulls.json
@@ -0,0 +1,16 @@
+{
+ "id": "event_01EHZNVPK3SFK441A1RGBFSHRT",
+ "event": "waitlist_user.denied",
+ "data": {
+ "object": "waitlist_user",
+ "id": "wl_user_01E4ZCR3C56J083X43JQXF3JK5",
+ "email": "marcelina.davis@example.com",
+ "state": "pending",
+ "approved_at": null,
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+ },
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "context": null,
+ "object": "event"
+}
diff --git a/test/WorkOSTests/testdata/waitlist_user_nulls.json b/test/WorkOSTests/testdata/waitlist_user_nulls.json
new file mode 100644
index 00000000..05973598
--- /dev/null
+++ b/test/WorkOSTests/testdata/waitlist_user_nulls.json
@@ -0,0 +1,9 @@
+{
+ "object": "waitlist_user",
+ "id": "wl_user_01E4ZCR3C56J083X43JQXF3JK5",
+ "email": "marcelina.davis@example.com",
+ "state": "pending",
+ "approved_at": null,
+ "created_at": "2026-01-15T12:00:00.000Z",
+ "updated_at": "2026-01-15T12:00:00.000Z"
+}