workos 9.5.0 → 10.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/block-generated-edits.yml +13 -0
- data/.github/workflows/ci.yml +1 -1
- data/.github/workflows/docs.yml +1 -1
- data/.github/workflows/lint.yml +1 -1
- data/.github/workflows/release-please.yml +7 -1
- data/.github/workflows/release.yml +1 -1
- data/.last-synced-sha +1 -1
- data/.oagen-manifest.json +197 -75
- data/.release-please-manifest.json +1 -1
- data/CHANGELOG.md +87 -0
- data/Gemfile.lock +2 -2
- data/README.md +15 -14
- data/lib/workos/agents/agent_admin_link_claim_attempt_to_external_user_request.rb +28 -0
- data/lib/workos/agents/agent_admin_link_claim_attempt_to_external_user_request_user.rb +22 -0
- data/lib/workos/agents/agent_admin_validate_credential_request.rb +25 -0
- data/lib/workos/agents/agent_credential_validation.rb +25 -0
- data/lib/workos/agents/agent_registration.rb +40 -0
- data/lib/workos/agents/agent_registration_agent_identity.rb +28 -0
- data/lib/workos/agents/agent_registration_claim.rb +31 -0
- data/lib/workos/agents/agent_registration_claim_claim_completion.rb +31 -0
- data/lib/workos/agents/claim_view_response.rb +28 -0
- data/lib/workos/agents/claim_view_response_organization.rb +7 -0
- data/lib/workos/agents.rb +93 -0
- data/lib/workos/api_keys/api_key_validation_response.rb +6 -2
- data/lib/workos/api_keys.rb +3 -4
- data/lib/workos/authorization/permission_created_data.rb +1 -34
- data/lib/workos/authorization/permission_deleted_data.rb +1 -1
- data/lib/workos/authorization/permission_updated_data.rb +1 -1
- data/lib/workos/authorization.rb +24 -24
- data/lib/workos/base_client.rb +4 -4
- data/lib/workos/client.rb +4 -0
- data/lib/workos/connect.rb +23 -19
- data/lib/workos/directory_sync.rb +10 -2
- data/lib/workos/groups.rb +7 -7
- data/lib/workos/inflections.rb +0 -1
- data/lib/workos/organization_domains.rb +4 -4
- data/lib/workos/organizations/organization_authorized_connect_application_list_data.rb +34 -0
- data/lib/workos/organizations.rb +57 -10
- data/lib/workos/pipes/api_key_installation.rb +25 -0
- data/lib/workos/pipes/{connected_account_dto.rb → connected_account_input.rb} +1 -1
- data/lib/workos/pipes/create_data_integration.rb +7 -1
- data/lib/workos/pipes/data_integration.rb +6 -0
- data/lib/workos/pipes/{data_integration_credentials_dto.rb → data_integration_credentials_input.rb} +1 -1
- data/lib/workos/pipes/data_integration_installation.rb +28 -0
- data/lib/workos/pipes/data_integrations_upsert_api_key_request.rb +1 -19
- data/lib/workos/pipes/update_data_integration.rb +4 -1
- data/lib/workos/pipes.rb +25 -16
- data/lib/workos/pipes_provider.rb +2 -2
- data/lib/workos/shared/access_token_agent_registration_credential_issued_data_detail.rb +25 -0
- data/lib/workos/shared/agent_registration_claim_attempt_created.rb +34 -0
- data/lib/workos/shared/agent_registration_claim_attempt_created_data.rb +40 -0
- data/lib/workos/shared/agent_registration_claim_completed.rb +34 -0
- data/lib/workos/shared/agent_registration_claim_completed_data.rb +40 -0
- data/lib/workos/shared/agent_registration_claim_completed_data_claimed_by.rb +22 -0
- data/lib/workos/shared/agent_registration_created.rb +34 -0
- data/lib/workos/{organization_domains/organization_domain_stand_alone.rb → shared/agent_registration_created_data.rb} +13 -16
- data/lib/workos/shared/agent_registration_created_data_agent_identity.rb +25 -0
- data/lib/workos/shared/agent_registration_credential_issued.rb +34 -0
- data/lib/workos/shared/agent_registration_credential_issued_data.rb +34 -0
- data/lib/workos/shared/agent_registration_credential_issued_data_detail.rb +22 -0
- data/lib/workos/shared/agent_registration_deleted.rb +34 -0
- data/lib/workos/shared/agent_registration_deleted_data.rb +18 -0
- data/lib/workos/shared/agent_registration_expired.rb +34 -0
- data/lib/workos/shared/agent_registration_expired_data.rb +7 -0
- data/lib/workos/shared/agent_registration_organization_switched.rb +34 -0
- data/lib/workos/shared/agent_registration_organization_switched_data.rb +25 -0
- data/lib/workos/shared/agent_registration_revoked.rb +34 -0
- data/lib/workos/shared/agent_registration_revoked_data.rb +7 -0
- data/lib/workos/shared/pipes_connected_account_connection_failed.rb +34 -0
- data/lib/workos/shared/pipes_connected_account_connection_failed_data.rb +46 -0
- data/lib/workos/shared/radar_challenge_created.rb +34 -0
- data/lib/workos/shared/radar_challenge_created_data.rb +28 -0
- data/lib/workos/sso/connection.rb +3 -3
- data/lib/workos/types/agent_admin_validate_credential_request_type.rb +13 -0
- data/lib/workos/types/agent_registration_created_data_kind.rb +14 -0
- data/lib/workos/types/agent_registration_created_data_method.rb +14 -0
- data/lib/workos/types/agent_registration_created_data_status.rb +15 -0
- data/lib/workos/types/{data_integration_credentials_type.rb → agent_registration_kind.rb} +1 -1
- data/lib/workos/types/{organization_domain_stand_alone_state.rb → agent_registration_status.rb} +1 -1
- data/lib/workos/types/applications_registration_types.rb +13 -0
- data/lib/workos/types/{organization_domain_stand_alone_verification_strategy.rb → claim_view_response_status.rb} +1 -1
- data/lib/workos/types/connected_account_input_state.rb +13 -0
- data/lib/workos/types/connected_account_state.rb +2 -1
- data/lib/workos/types/create_data_integration_auth_methods.rb +9 -0
- data/lib/workos/types/create_user_password_hash_type.rb +2 -1
- data/lib/workos/types/create_webhook_endpoint_events.rb +5 -1
- data/lib/workos/types/data_integration_auth_methods.rb +9 -0
- data/lib/workos/types/data_integration_credentials_input_type.rb +9 -0
- data/lib/workos/types/data_integrations_list_response_data_connected_account_state.rb +1 -6
- data/lib/workos/types/pipe_connected_account_state.rb +1 -5
- data/lib/workos/types/vault_kek_deleted_data_actor_source.rb +9 -0
- data/lib/workos/user_management/authentication_reauthentication_succeeded.rb +34 -0
- data/lib/workos/user_management/authentication_reauthentication_succeeded_data.rb +34 -0
- data/lib/workos/user_management/radar_challenge.rb +43 -0
- data/lib/workos/user_management.rb +59 -23
- data/lib/workos/vault/vault_kek_deleted.rb +34 -0
- data/lib/workos/vault/vault_kek_deleted_data.rb +31 -0
- data/lib/workos/vault.rb +4 -4
- data/lib/workos/version.rb +1 -1
- data/lib/workos/widgets.rb +2 -2
- data/lib/workos.rb +11 -0
- data/rbi/workos/access_token_agent_registration_credential_issued_data_detail.rbi +36 -0
- data/rbi/workos/agent_admin_link_claim_attempt_to_external_user_request.rbi +42 -0
- data/rbi/workos/agent_admin_link_claim_attempt_to_external_user_request_user.rbi +30 -0
- data/rbi/workos/agent_admin_validate_credential_request.rbi +36 -0
- data/rbi/workos/{sso_intent_options.rbi → agent_credential_validation.rbi} +11 -5
- data/rbi/workos/agent_registration.rbi +66 -0
- data/rbi/workos/agent_registration_agent_identity.rbi +42 -0
- data/rbi/workos/agent_registration_claim.rbi +48 -0
- data/rbi/workos/agent_registration_claim_attempt_created.rbi +54 -0
- data/rbi/workos/agent_registration_claim_attempt_created_data.rbi +66 -0
- data/rbi/workos/agent_registration_claim_claim_completion.rbi +48 -0
- data/rbi/workos/agent_registration_claim_completed.rbi +54 -0
- data/rbi/workos/agent_registration_claim_completed_data.rbi +66 -0
- data/rbi/workos/agent_registration_claim_completed_data_claimed_by.rbi +30 -0
- data/rbi/workos/agent_registration_created.rbi +54 -0
- data/rbi/workos/agent_registration_created_data.rbi +72 -0
- data/rbi/workos/agent_registration_created_data_agent_identity.rbi +36 -0
- data/rbi/workos/agent_registration_credential_issued.rbi +54 -0
- data/rbi/workos/agent_registration_credential_issued_data.rbi +54 -0
- data/rbi/workos/agent_registration_credential_issued_data_detail.rbi +30 -0
- data/rbi/workos/agent_registration_deleted.rbi +54 -0
- data/rbi/workos/{connection_option.rbi → agent_registration_deleted_data.rbi} +5 -5
- data/rbi/workos/agent_registration_expired.rbi +54 -0
- data/rbi/workos/{domain_verification_intent_options.rbi → agent_registration_expired_data.rbi} +5 -5
- data/rbi/workos/agent_registration_organization_switched.rbi +54 -0
- data/rbi/workos/agent_registration_organization_switched_data.rbi +36 -0
- data/rbi/workos/agent_registration_revoked.rbi +54 -0
- data/rbi/workos/agent_registration_revoked_data.rbi +24 -0
- data/rbi/workos/agents.rbi +42 -0
- data/rbi/workos/api_key_installation.rbi +36 -0
- data/rbi/workos/api_key_validation_response.rbi +6 -0
- data/rbi/workos/authentication_reauthentication_succeeded.rbi +54 -0
- data/rbi/workos/authentication_reauthentication_succeeded_data.rbi +54 -0
- data/rbi/workos/claim_view_response.rbi +42 -0
- data/rbi/workos/claim_view_response_organization.rbi +30 -0
- data/rbi/workos/client.rbi +3 -0
- data/rbi/workos/connect.rbi +2 -1
- data/rbi/workos/{connected_account_dto.rbi → connected_account_input.rbi} +1 -1
- data/rbi/workos/connection.rbi +4 -4
- data/rbi/workos/create_data_integration.rbi +14 -2
- data/rbi/workos/data_integration.rbi +12 -0
- data/rbi/workos/{data_integration_credentials_dto.rbi → data_integration_credentials_input.rbi} +1 -1
- data/rbi/workos/data_integration_installation.rbi +42 -0
- data/rbi/workos/directory_sync.rbi +3 -1
- data/rbi/workos/organization_authorized_connect_application_list_data.rbi +54 -0
- data/rbi/workos/organization_domains.rbi +2 -2
- data/rbi/workos/organizations.rbi +12 -0
- data/rbi/workos/permission_created_data.rbi +6 -0
- data/rbi/workos/permission_deleted_data.rbi +6 -0
- data/rbi/workos/permission_updated_data.rbi +6 -0
- data/rbi/workos/pipes.rbi +7 -4
- data/rbi/workos/pipes_connected_account_connection_failed.rbi +54 -0
- data/rbi/workos/{organization_domain_stand_alone.rbi → pipes_connected_account_connection_failed_data.rbi} +23 -23
- data/rbi/workos/radar_challenge.rbi +72 -0
- data/rbi/workos/radar_challenge_created.rbi +54 -0
- data/rbi/workos/radar_challenge_created_data.rbi +42 -0
- data/rbi/workos/update_data_integration.rbi +8 -2
- data/rbi/workos/user_management.rbi +16 -0
- data/rbi/workos/vault_kek_deleted.rbi +54 -0
- data/rbi/workos/vault_kek_deleted_data.rbi +48 -0
- data/rbi/workos/widget_session_token.rbi +2 -2
- data/rbi/workos/widgets.rbi +1 -1
- data/test/workos/test_agents.rb +49 -0
- data/test/workos/test_agents_model_round_trip.rb +165 -0
- data/test/workos/test_api_keys_model_round_trip.rb +307 -0
- data/test/workos/test_authorization_model_round_trip.rb +237 -0
- data/test/workos/test_base_client.rb +27 -0
- data/test/workos/test_client_api_model_round_trip.rb +31 -0
- data/test/workos/test_connect_model_round_trip.rb +175 -0
- data/test/workos/test_directory_sync_model_round_trip.rb +579 -0
- data/test/workos/test_feature_flags_model_round_trip.rb +580 -0
- data/test/workos/test_groups_model_round_trip.rb +56 -0
- data/test/workos/test_multi_factor_auth_model_round_trip.rb +192 -0
- data/test/workos/test_organization_domains_model_round_trip.rb +260 -0
- data/test/workos/test_organization_membership_model_round_trip.rb +89 -0
- data/test/workos/test_organizations.rb +9 -1
- data/test/workos/test_organizations_model_round_trip.rb +602 -0
- data/test/workos/test_pipes_model_round_trip.rb +40 -4
- data/test/workos/test_pipes_provider_model_round_trip.rb +75 -0
- data/test/workos/test_shared_model_round_trip.rb +787 -0
- data/test/workos/test_sso_model_round_trip.rb +422 -0
- data/test/workos/test_user_management.rb +16 -0
- data/test/workos/test_user_management_model_round_trip.rb +1501 -0
- data/test/workos/test_vault_model_round_trip.rb +571 -0
- data/test/workos/test_widgets.rb +2 -2
- data/test/workos/test_widgets_model_round_trip.rb +30 -0
- metadata +118 -19
- data/lib/workos/admin_portal/domain_verification_intent_options.rb +0 -18
- data/lib/workos/admin_portal/intent_options.rb +0 -22
- data/lib/workos/admin_portal/sso_intent_options.rb +0 -22
- data/lib/workos/sso/connection_option.rb +0 -18
- data/rbi/workos/intent_options.rbi +0 -30
- data/test/workos/test_model_round_trip.rb +0 -6
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class RadarChallenge < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
object: :object,
|
|
9
|
+
id: :id,
|
|
10
|
+
type: :type,
|
|
11
|
+
user_id: :user_id,
|
|
12
|
+
email: :email,
|
|
13
|
+
expires_at: :expires_at,
|
|
14
|
+
created_at: :created_at,
|
|
15
|
+
updated_at: :updated_at,
|
|
16
|
+
code: :code
|
|
17
|
+
}.freeze
|
|
18
|
+
|
|
19
|
+
attr_accessor \
|
|
20
|
+
:object,
|
|
21
|
+
:id,
|
|
22
|
+
:type,
|
|
23
|
+
:user_id,
|
|
24
|
+
:email,
|
|
25
|
+
:expires_at,
|
|
26
|
+
:created_at,
|
|
27
|
+
:updated_at,
|
|
28
|
+
:code
|
|
29
|
+
|
|
30
|
+
def initialize(json)
|
|
31
|
+
hash = self.class.normalize(json)
|
|
32
|
+
@object = hash[:object]
|
|
33
|
+
@id = hash[:id]
|
|
34
|
+
@type = hash[:type]
|
|
35
|
+
@user_id = hash[:user_id]
|
|
36
|
+
@email = hash[:email]
|
|
37
|
+
@expires_at = hash[:expires_at]
|
|
38
|
+
@created_at = hash[:created_at]
|
|
39
|
+
@updated_at = hash[:updated_at]
|
|
40
|
+
@code = hash[:code]
|
|
41
|
+
end
|
|
42
|
+
end
|
|
43
|
+
end
|
|
@@ -573,6 +573,25 @@ module WorkOS
|
|
|
573
573
|
result
|
|
574
574
|
end
|
|
575
575
|
|
|
576
|
+
# Get Radar Challenge details
|
|
577
|
+
# @param id [String] The unique ID of the Radar Challenge.
|
|
578
|
+
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
579
|
+
# @return [WorkOS::RadarChallenge]
|
|
580
|
+
def get_radar_challenge(
|
|
581
|
+
id:,
|
|
582
|
+
request_options: {}
|
|
583
|
+
)
|
|
584
|
+
response = @client.request(
|
|
585
|
+
method: :get,
|
|
586
|
+
path: "/user_management/radar_challenges/#{WorkOS::Util.encode_path(id)}",
|
|
587
|
+
auth: true,
|
|
588
|
+
request_options: request_options
|
|
589
|
+
)
|
|
590
|
+
result = WorkOS::RadarChallenge.new(response.body)
|
|
591
|
+
result.last_response = WorkOS::Types::ApiResponse.new(http_status: response.code.to_i, http_headers: response.each_header.to_h, request_id: response["x-request-id"])
|
|
592
|
+
result
|
|
593
|
+
end
|
|
594
|
+
|
|
576
595
|
# Revoke Session
|
|
577
596
|
# @param session_id [String] The ID of the session to revoke. This can be extracted from the `sid` claim of the access token.
|
|
578
597
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
@@ -820,30 +839,30 @@ module WorkOS
|
|
|
820
839
|
# @return [WorkOS::UserCreateResponse]
|
|
821
840
|
def create_user(
|
|
822
841
|
email:,
|
|
823
|
-
first_name:
|
|
824
|
-
last_name:
|
|
825
|
-
name:
|
|
826
|
-
email_verified:
|
|
827
|
-
metadata:
|
|
828
|
-
external_id:
|
|
829
|
-
ip_address:
|
|
830
|
-
user_agent:
|
|
842
|
+
first_name: WorkOS::OMIT,
|
|
843
|
+
last_name: WorkOS::OMIT,
|
|
844
|
+
name: WorkOS::OMIT,
|
|
845
|
+
email_verified: WorkOS::OMIT,
|
|
846
|
+
metadata: WorkOS::OMIT,
|
|
847
|
+
external_id: WorkOS::OMIT,
|
|
848
|
+
ip_address: WorkOS::OMIT,
|
|
849
|
+
user_agent: WorkOS::OMIT,
|
|
831
850
|
signals_id: nil,
|
|
832
851
|
password: nil,
|
|
833
852
|
request_options: {}
|
|
834
853
|
)
|
|
835
854
|
body = {
|
|
836
855
|
"email" => email,
|
|
837
|
-
"first_name" => first_name,
|
|
838
|
-
"last_name" => last_name,
|
|
839
|
-
"name" => name,
|
|
840
|
-
"email_verified" => email_verified,
|
|
841
|
-
"metadata" => metadata,
|
|
842
|
-
"external_id" => external_id,
|
|
843
|
-
"ip_address" => ip_address,
|
|
844
|
-
"user_agent" => user_agent,
|
|
845
856
|
"signals_id" => signals_id
|
|
846
857
|
}.compact
|
|
858
|
+
body["first_name"] = first_name unless first_name.equal?(WorkOS::OMIT)
|
|
859
|
+
body["last_name"] = last_name unless last_name.equal?(WorkOS::OMIT)
|
|
860
|
+
body["name"] = name unless name.equal?(WorkOS::OMIT)
|
|
861
|
+
body["email_verified"] = email_verified unless email_verified.equal?(WorkOS::OMIT)
|
|
862
|
+
body["metadata"] = metadata unless metadata.equal?(WorkOS::OMIT)
|
|
863
|
+
body["external_id"] = external_id unless external_id.equal?(WorkOS::OMIT)
|
|
864
|
+
body["ip_address"] = ip_address unless ip_address.equal?(WorkOS::OMIT)
|
|
865
|
+
body["user_agent"] = user_agent unless user_agent.equal?(WorkOS::OMIT)
|
|
847
866
|
if password
|
|
848
867
|
case password
|
|
849
868
|
when WorkOS::UserManagement::PasswordPlaintext
|
|
@@ -925,9 +944,9 @@ module WorkOS
|
|
|
925
944
|
last_name: nil,
|
|
926
945
|
name: nil,
|
|
927
946
|
email_verified: nil,
|
|
928
|
-
metadata:
|
|
929
|
-
external_id:
|
|
930
|
-
locale:
|
|
947
|
+
metadata: WorkOS::OMIT,
|
|
948
|
+
external_id: WorkOS::OMIT,
|
|
949
|
+
locale: WorkOS::OMIT,
|
|
931
950
|
password: nil,
|
|
932
951
|
request_options: {}
|
|
933
952
|
)
|
|
@@ -936,11 +955,11 @@ module WorkOS
|
|
|
936
955
|
"first_name" => first_name,
|
|
937
956
|
"last_name" => last_name,
|
|
938
957
|
"name" => name,
|
|
939
|
-
"email_verified" => email_verified
|
|
940
|
-
"metadata" => metadata,
|
|
941
|
-
"external_id" => external_id,
|
|
942
|
-
"locale" => locale
|
|
958
|
+
"email_verified" => email_verified
|
|
943
959
|
}.compact
|
|
960
|
+
body["metadata"] = metadata unless metadata.equal?(WorkOS::OMIT)
|
|
961
|
+
body["external_id"] = external_id unless external_id.equal?(WorkOS::OMIT)
|
|
962
|
+
body["locale"] = locale unless locale.equal?(WorkOS::OMIT)
|
|
944
963
|
if password
|
|
945
964
|
case password
|
|
946
965
|
when WorkOS::UserManagement::PasswordPlaintext
|
|
@@ -1493,6 +1512,23 @@ module WorkOS
|
|
|
1493
1512
|
result
|
|
1494
1513
|
end
|
|
1495
1514
|
|
|
1515
|
+
# Delete a redirect URI
|
|
1516
|
+
# @param id [String] The ID of the redirect URI to delete.
|
|
1517
|
+
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
1518
|
+
# @return [void]
|
|
1519
|
+
def delete_redirect_uris(
|
|
1520
|
+
id:,
|
|
1521
|
+
request_options: {}
|
|
1522
|
+
)
|
|
1523
|
+
@client.request(
|
|
1524
|
+
method: :delete,
|
|
1525
|
+
path: "/user_management/redirect_uris/#{WorkOS::Util.encode_path(id)}",
|
|
1526
|
+
auth: true,
|
|
1527
|
+
request_options: request_options
|
|
1528
|
+
)
|
|
1529
|
+
nil
|
|
1530
|
+
end
|
|
1531
|
+
|
|
1496
1532
|
# List authorized applications
|
|
1497
1533
|
# @param user_id [String] The ID of the user.
|
|
1498
1534
|
# @param before [String, nil] An object ID that defines your place in the list. When the ID is not present, you are at the end of the list. For example, if you make a list request and receive 100 objects, ending with `"obj_123"`, your subsequent call can include `before="obj_123"` to fetch a new batch of objects before `"obj_123"`.
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class VaultKekDeleted < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
object: :object,
|
|
9
|
+
id: :id,
|
|
10
|
+
event: :event,
|
|
11
|
+
data: :data,
|
|
12
|
+
created_at: :created_at,
|
|
13
|
+
context: :context
|
|
14
|
+
}.freeze
|
|
15
|
+
|
|
16
|
+
attr_accessor \
|
|
17
|
+
:object,
|
|
18
|
+
:id,
|
|
19
|
+
:event,
|
|
20
|
+
:data,
|
|
21
|
+
:created_at,
|
|
22
|
+
:context
|
|
23
|
+
|
|
24
|
+
def initialize(json)
|
|
25
|
+
hash = self.class.normalize(json)
|
|
26
|
+
@object = hash[:object]
|
|
27
|
+
@id = hash[:id]
|
|
28
|
+
@event = hash[:event]
|
|
29
|
+
@data = hash[:data] ? WorkOS::VaultKekDeletedData.new(hash[:data]) : nil
|
|
30
|
+
@created_at = hash[:created_at]
|
|
31
|
+
@context = hash[:context] ? WorkOS::EventContext.new(hash[:context]) : nil
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
end
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
module WorkOS
|
|
6
|
+
class VaultKekDeletedData < WorkOS::Types::BaseModel
|
|
7
|
+
HASH_ATTRS = {
|
|
8
|
+
actor_id: :actor_id,
|
|
9
|
+
actor_source: :actor_source,
|
|
10
|
+
actor_name: :actor_name,
|
|
11
|
+
key_name: :key_name,
|
|
12
|
+
key_id: :key_id
|
|
13
|
+
}.freeze
|
|
14
|
+
|
|
15
|
+
attr_accessor \
|
|
16
|
+
:actor_id,
|
|
17
|
+
:actor_source,
|
|
18
|
+
:actor_name,
|
|
19
|
+
:key_name,
|
|
20
|
+
:key_id
|
|
21
|
+
|
|
22
|
+
def initialize(json)
|
|
23
|
+
hash = self.class.normalize(json)
|
|
24
|
+
@actor_id = hash[:actor_id]
|
|
25
|
+
@actor_source = hash[:actor_source]
|
|
26
|
+
@actor_name = hash[:actor_name]
|
|
27
|
+
@key_name = hash[:key_name]
|
|
28
|
+
@key_id = hash[:key_id]
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
end
|
data/lib/workos/vault.rb
CHANGED
|
@@ -213,13 +213,13 @@ module WorkOS
|
|
|
213
213
|
def update_kv(
|
|
214
214
|
id:,
|
|
215
215
|
value:,
|
|
216
|
-
version_check:
|
|
216
|
+
version_check: WorkOS::OMIT,
|
|
217
217
|
request_options: {}
|
|
218
218
|
)
|
|
219
219
|
body = {
|
|
220
|
-
"value" => value
|
|
221
|
-
|
|
222
|
-
|
|
220
|
+
"value" => value
|
|
221
|
+
}
|
|
222
|
+
body["version_check"] = version_check unless version_check.equal?(WorkOS::OMIT)
|
|
223
223
|
response = @client.request(
|
|
224
224
|
method: :put,
|
|
225
225
|
path: "/vault/v1/kv/#{WorkOS::Util.encode_path(id)}",
|
data/lib/workos/version.rb
CHANGED
data/lib/workos/widgets.rb
CHANGED
|
@@ -11,13 +11,13 @@ module WorkOS
|
|
|
11
11
|
end
|
|
12
12
|
|
|
13
13
|
# Generate a widget token
|
|
14
|
-
# @param organization_id [String] The ID of the organization to scope the widget session to.
|
|
14
|
+
# @param organization_id [String, nil] The ID of the organization to scope the widget session to. Required when scopes are provided. Optional when issuing a token for user-only widgets (e.g. `UserProfile`, `UserSecurity`) that do not require organization context.
|
|
15
15
|
# @param user_id [String, nil] The ID of the user to issue the widget session token for.
|
|
16
16
|
# @param scopes [Array<WorkOS::Types::WidgetSessionTokenScopes>, nil] The scopes to grant the widget session.
|
|
17
17
|
# @param request_options [Hash] (see WorkOS::Types::RequestOptions)
|
|
18
18
|
# @return [WorkOS::WidgetSessionTokenResponse]
|
|
19
19
|
def create_token(
|
|
20
|
-
organization_id
|
|
20
|
+
organization_id: nil,
|
|
21
21
|
user_id: nil,
|
|
22
22
|
scopes: nil,
|
|
23
23
|
request_options: {}
|
data/lib/workos.rb
CHANGED
|
@@ -5,12 +5,23 @@
|
|
|
5
5
|
require "zeitwerk"
|
|
6
6
|
|
|
7
7
|
module WorkOS
|
|
8
|
+
# Sentinel default for nullable optional parameters. Distinguishes an
|
|
9
|
+
# omitted argument ("leave unchanged") from an explicit `nil`, which
|
|
10
|
+
# clears the field by sending JSON `null`.
|
|
11
|
+
OMIT = Object.new
|
|
12
|
+
|
|
13
|
+
def OMIT.inspect
|
|
14
|
+
"WorkOS::OMIT"
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
OMIT.freeze
|
|
8
18
|
end
|
|
9
19
|
|
|
10
20
|
loader = Zeitwerk::Loader.for_gem
|
|
11
21
|
require_relative "workos/inflections"
|
|
12
22
|
loader.inflector.inflect(WORKOS_INFLECTIONS)
|
|
13
23
|
loader.collapse("#{__dir__}/workos/admin_portal")
|
|
24
|
+
loader.collapse("#{__dir__}/workos/agents")
|
|
14
25
|
loader.collapse("#{__dir__}/workos/api_keys")
|
|
15
26
|
loader.collapse("#{__dir__}/workos/audit_logs")
|
|
16
27
|
loader.collapse("#{__dir__}/workos/authorization")
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
# typed: strong
|
|
6
|
+
|
|
7
|
+
module WorkOS
|
|
8
|
+
class AccessTokenAgentRegistrationCredentialIssuedDataDetail
|
|
9
|
+
sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void }
|
|
10
|
+
def initialize(json); end
|
|
11
|
+
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
def kind; end
|
|
14
|
+
|
|
15
|
+
sig { params(value: String).returns(String) }
|
|
16
|
+
def kind=(value); end
|
|
17
|
+
|
|
18
|
+
sig { returns(String) }
|
|
19
|
+
def jti; end
|
|
20
|
+
|
|
21
|
+
sig { params(value: String).returns(String) }
|
|
22
|
+
def jti=(value); end
|
|
23
|
+
|
|
24
|
+
sig { returns(T.any(String, T.nilable(String))) }
|
|
25
|
+
def expires_at; end
|
|
26
|
+
|
|
27
|
+
sig { params(value: T.any(String, T.nilable(String))).returns(T.any(String, T.nilable(String))) }
|
|
28
|
+
def expires_at=(value); end
|
|
29
|
+
|
|
30
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
31
|
+
def to_h; end
|
|
32
|
+
|
|
33
|
+
sig { params(args: T.untyped).returns(String) }
|
|
34
|
+
def to_json(*args); end
|
|
35
|
+
end
|
|
36
|
+
end
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
# typed: strong
|
|
6
|
+
|
|
7
|
+
module WorkOS
|
|
8
|
+
class AgentAdminLinkClaimAttemptToExternalUserRequest
|
|
9
|
+
sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void }
|
|
10
|
+
def initialize(json); end
|
|
11
|
+
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
def type; end
|
|
14
|
+
|
|
15
|
+
sig { params(value: String).returns(String) }
|
|
16
|
+
def type=(value); end
|
|
17
|
+
|
|
18
|
+
sig { returns(String) }
|
|
19
|
+
def claim_attempt_token; end
|
|
20
|
+
|
|
21
|
+
sig { params(value: String).returns(String) }
|
|
22
|
+
def claim_attempt_token=(value); end
|
|
23
|
+
|
|
24
|
+
sig { returns(WorkOS::AgentAdminLinkClaimAttemptToExternalUserRequestUser) }
|
|
25
|
+
def user; end
|
|
26
|
+
|
|
27
|
+
sig { params(value: WorkOS::AgentAdminLinkClaimAttemptToExternalUserRequestUser).returns(WorkOS::AgentAdminLinkClaimAttemptToExternalUserRequestUser) }
|
|
28
|
+
def user=(value); end
|
|
29
|
+
|
|
30
|
+
sig { returns(T.nilable(String)) }
|
|
31
|
+
def organization_id; end
|
|
32
|
+
|
|
33
|
+
sig { params(value: T.nilable(String)).returns(T.nilable(String)) }
|
|
34
|
+
def organization_id=(value); end
|
|
35
|
+
|
|
36
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
37
|
+
def to_h; end
|
|
38
|
+
|
|
39
|
+
sig { params(args: T.untyped).returns(String) }
|
|
40
|
+
def to_json(*args); end
|
|
41
|
+
end
|
|
42
|
+
end
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
# typed: strong
|
|
6
|
+
|
|
7
|
+
module WorkOS
|
|
8
|
+
class AgentAdminLinkClaimAttemptToExternalUserRequestUser
|
|
9
|
+
sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void }
|
|
10
|
+
def initialize(json); end
|
|
11
|
+
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
def email; end
|
|
14
|
+
|
|
15
|
+
sig { params(value: String).returns(String) }
|
|
16
|
+
def email=(value); end
|
|
17
|
+
|
|
18
|
+
sig { returns(String) }
|
|
19
|
+
def external_id; end
|
|
20
|
+
|
|
21
|
+
sig { params(value: String).returns(String) }
|
|
22
|
+
def external_id=(value); end
|
|
23
|
+
|
|
24
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
25
|
+
def to_h; end
|
|
26
|
+
|
|
27
|
+
sig { params(args: T.untyped).returns(String) }
|
|
28
|
+
def to_json(*args); end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
# typed: strong
|
|
6
|
+
|
|
7
|
+
module WorkOS
|
|
8
|
+
class AgentAdminValidateCredentialRequest
|
|
9
|
+
sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void }
|
|
10
|
+
def initialize(json); end
|
|
11
|
+
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
def type; end
|
|
14
|
+
|
|
15
|
+
sig { params(value: String).returns(String) }
|
|
16
|
+
def type=(value); end
|
|
17
|
+
|
|
18
|
+
sig { returns(String) }
|
|
19
|
+
def credential; end
|
|
20
|
+
|
|
21
|
+
sig { params(value: String).returns(String) }
|
|
22
|
+
def credential=(value); end
|
|
23
|
+
|
|
24
|
+
sig { returns(T.nilable(String)) }
|
|
25
|
+
def audience; end
|
|
26
|
+
|
|
27
|
+
sig { params(value: T.nilable(String)).returns(T.nilable(String)) }
|
|
28
|
+
def audience=(value); end
|
|
29
|
+
|
|
30
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
31
|
+
def to_h; end
|
|
32
|
+
|
|
33
|
+
sig { params(args: T.untyped).returns(String) }
|
|
34
|
+
def to_json(*args); end
|
|
35
|
+
end
|
|
36
|
+
end
|
|
@@ -5,21 +5,27 @@
|
|
|
5
5
|
# typed: strong
|
|
6
6
|
|
|
7
7
|
module WorkOS
|
|
8
|
-
class
|
|
8
|
+
class AgentCredentialValidation
|
|
9
9
|
sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void }
|
|
10
10
|
def initialize(json); end
|
|
11
11
|
|
|
12
|
+
sig { returns(T::Boolean) }
|
|
13
|
+
def valid; end
|
|
14
|
+
|
|
15
|
+
sig { params(value: T::Boolean).returns(T::Boolean) }
|
|
16
|
+
def valid=(value); end
|
|
17
|
+
|
|
12
18
|
sig { returns(T.nilable(String)) }
|
|
13
|
-
def
|
|
19
|
+
def registration_id; end
|
|
14
20
|
|
|
15
21
|
sig { params(value: T.nilable(String)).returns(T.nilable(String)) }
|
|
16
|
-
def
|
|
22
|
+
def registration_id=(value); end
|
|
17
23
|
|
|
18
24
|
sig { returns(T.nilable(String)) }
|
|
19
|
-
def
|
|
25
|
+
def expires_at; end
|
|
20
26
|
|
|
21
27
|
sig { params(value: T.nilable(String)).returns(T.nilable(String)) }
|
|
22
|
-
def
|
|
28
|
+
def expires_at=(value); end
|
|
23
29
|
|
|
24
30
|
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
25
31
|
def to_h; end
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
# typed: strong
|
|
6
|
+
|
|
7
|
+
module WorkOS
|
|
8
|
+
class AgentRegistration
|
|
9
|
+
sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void }
|
|
10
|
+
def initialize(json); end
|
|
11
|
+
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
def id; end
|
|
14
|
+
|
|
15
|
+
sig { params(value: String).returns(String) }
|
|
16
|
+
def id=(value); end
|
|
17
|
+
|
|
18
|
+
sig { returns(WorkOS::AgentRegistrationAgentIdentity) }
|
|
19
|
+
def agent_identity; end
|
|
20
|
+
|
|
21
|
+
sig { params(value: WorkOS::AgentRegistrationAgentIdentity).returns(WorkOS::AgentRegistrationAgentIdentity) }
|
|
22
|
+
def agent_identity=(value); end
|
|
23
|
+
|
|
24
|
+
sig { returns(String) }
|
|
25
|
+
def organization_id; end
|
|
26
|
+
|
|
27
|
+
sig { params(value: String).returns(String) }
|
|
28
|
+
def organization_id=(value); end
|
|
29
|
+
|
|
30
|
+
sig { returns(String) }
|
|
31
|
+
def status; end
|
|
32
|
+
|
|
33
|
+
sig { params(value: String).returns(String) }
|
|
34
|
+
def status=(value); end
|
|
35
|
+
|
|
36
|
+
sig { returns(String) }
|
|
37
|
+
def kind; end
|
|
38
|
+
|
|
39
|
+
sig { params(value: String).returns(String) }
|
|
40
|
+
def kind=(value); end
|
|
41
|
+
|
|
42
|
+
sig { returns(T.nilable(WorkOS::AgentRegistrationClaim)) }
|
|
43
|
+
def claim; end
|
|
44
|
+
|
|
45
|
+
sig { params(value: T.nilable(WorkOS::AgentRegistrationClaim)).returns(T.nilable(WorkOS::AgentRegistrationClaim)) }
|
|
46
|
+
def claim=(value); end
|
|
47
|
+
|
|
48
|
+
sig { returns(String) }
|
|
49
|
+
def created_at; end
|
|
50
|
+
|
|
51
|
+
sig { params(value: String).returns(String) }
|
|
52
|
+
def created_at=(value); end
|
|
53
|
+
|
|
54
|
+
sig { returns(String) }
|
|
55
|
+
def updated_at; end
|
|
56
|
+
|
|
57
|
+
sig { params(value: String).returns(String) }
|
|
58
|
+
def updated_at=(value); end
|
|
59
|
+
|
|
60
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
61
|
+
def to_h; end
|
|
62
|
+
|
|
63
|
+
sig { params(args: T.untyped).returns(String) }
|
|
64
|
+
def to_json(*args); end
|
|
65
|
+
end
|
|
66
|
+
end
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
# typed: strong
|
|
6
|
+
|
|
7
|
+
module WorkOS
|
|
8
|
+
class AgentRegistrationAgentIdentity
|
|
9
|
+
sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void }
|
|
10
|
+
def initialize(json); end
|
|
11
|
+
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
def id; end
|
|
14
|
+
|
|
15
|
+
sig { params(value: String).returns(String) }
|
|
16
|
+
def id=(value); end
|
|
17
|
+
|
|
18
|
+
sig { returns(T.nilable(String)) }
|
|
19
|
+
def userland_user_id; end
|
|
20
|
+
|
|
21
|
+
sig { params(value: T.nilable(String)).returns(T.nilable(String)) }
|
|
22
|
+
def userland_user_id=(value); end
|
|
23
|
+
|
|
24
|
+
sig { returns(String) }
|
|
25
|
+
def created_at; end
|
|
26
|
+
|
|
27
|
+
sig { params(value: String).returns(String) }
|
|
28
|
+
def created_at=(value); end
|
|
29
|
+
|
|
30
|
+
sig { returns(String) }
|
|
31
|
+
def updated_at; end
|
|
32
|
+
|
|
33
|
+
sig { params(value: String).returns(String) }
|
|
34
|
+
def updated_at=(value); end
|
|
35
|
+
|
|
36
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
37
|
+
def to_h; end
|
|
38
|
+
|
|
39
|
+
sig { params(args: T.untyped).returns(String) }
|
|
40
|
+
def to_json(*args); end
|
|
41
|
+
end
|
|
42
|
+
end
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# This file is auto-generated by oagen. Do not edit.
|
|
4
|
+
|
|
5
|
+
# typed: strong
|
|
6
|
+
|
|
7
|
+
module WorkOS
|
|
8
|
+
class AgentRegistrationClaim
|
|
9
|
+
sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void }
|
|
10
|
+
def initialize(json); end
|
|
11
|
+
|
|
12
|
+
sig { returns(String) }
|
|
13
|
+
def id; end
|
|
14
|
+
|
|
15
|
+
sig { params(value: String).returns(String) }
|
|
16
|
+
def id=(value); end
|
|
17
|
+
|
|
18
|
+
sig { returns(T.nilable(WorkOS::AgentRegistrationClaimClaimCompletion)) }
|
|
19
|
+
def claim_completion; end
|
|
20
|
+
|
|
21
|
+
sig { params(value: T.nilable(WorkOS::AgentRegistrationClaimClaimCompletion)).returns(T.nilable(WorkOS::AgentRegistrationClaimClaimCompletion)) }
|
|
22
|
+
def claim_completion=(value); end
|
|
23
|
+
|
|
24
|
+
sig { returns(String) }
|
|
25
|
+
def created_at; end
|
|
26
|
+
|
|
27
|
+
sig { params(value: String).returns(String) }
|
|
28
|
+
def created_at=(value); end
|
|
29
|
+
|
|
30
|
+
sig { returns(String) }
|
|
31
|
+
def updated_at; end
|
|
32
|
+
|
|
33
|
+
sig { params(value: String).returns(String) }
|
|
34
|
+
def updated_at=(value); end
|
|
35
|
+
|
|
36
|
+
sig { returns(String) }
|
|
37
|
+
def expires_at; end
|
|
38
|
+
|
|
39
|
+
sig { params(value: String).returns(String) }
|
|
40
|
+
def expires_at=(value); end
|
|
41
|
+
|
|
42
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
|
43
|
+
def to_h; end
|
|
44
|
+
|
|
45
|
+
sig { params(args: T.untyped).returns(String) }
|
|
46
|
+
def to_json(*args); end
|
|
47
|
+
end
|
|
48
|
+
end
|