From 9e0ea6fa462c688571371000b97d549247d8f22a Mon Sep 17 00:00:00 2001 From: "workos-sdk-automation[bot]" <255426317+workos-sdk-automation[bot]@users.noreply.github.com> Date: Fri, 25 Sep 2026 17:40:13 +0000 Subject: [PATCH 1/4] feat(pipes)!: Change Pipes API surface --- lib/workos/pipes.rb | 140 ++++++++++-- lib/workos/pipes/create_connected_account.rb | 34 +++ .../create_organization_connected_account.rb | 37 +++ .../data_integration_credentials_response.rb | 2 +- .../data_integration_vended_credential.rb | 40 ++++ ...e_client_credentials_connection_request.rb | 37 +++ ...tions_upsert_client_credentials_request.rb | 3 - ...ons_upsert_client_credentials_request_2.rb | 37 +++ .../pipes/organization_connected_account.rb | 34 +++ ...tions_upsert_client_credentials_request.rb | 40 ++++ .../types/create_connected_account_state.rb | 9 + ...te_organization_connected_account_state.rb | 9 + ...als_connection_request_connection_owner.rb | 9 + ..._credentials_request_2_connection_owner.rb | 9 + .../organization_connected_account_state.rb | 9 + ...nt_credentials_request_connection_owner.rb | 9 + rbi/workos/create_connected_account.rbi | 54 +++++ .../create_organization_connected_account.rbi | 60 +++++ .../data_integration_credentials_response.rbi | 4 +- .../data_integration_vended_credential.rbi | 66 ++++++ ..._client_credentials_connection_request.rbi | 60 +++++ ...ions_upsert_client_credentials_request.rbi | 6 - ...ns_upsert_client_credentials_request_2.rbi | 60 +++++ rbi/workos/organization_connected_account.rbi | 54 +++++ rbi/workos/pipes.rbi | 48 +++- ...ions_upsert_client_credentials_request.rbi | 66 ++++++ test/workos/test_pipes.rb | 24 +- test/workos/test_pipes_model_round_trip.rb | 212 ++++++++++++++++-- 28 files changed, 1111 insertions(+), 61 deletions(-) create mode 100644 lib/workos/pipes/create_connected_account.rb create mode 100644 lib/workos/pipes/create_organization_connected_account.rb create mode 100644 lib/workos/pipes/data_integration_vended_credential.rb create mode 100644 lib/workos/pipes/data_integrations_create_client_credentials_connection_request.rb create mode 100644 lib/workos/pipes/data_integrations_upsert_client_credentials_request_2.rb create mode 100644 lib/workos/pipes/organization_connected_account.rb create mode 100644 lib/workos/pipes/reauthorize_data_integrations_upsert_client_credentials_request.rb create mode 100644 lib/workos/types/create_connected_account_state.rb create mode 100644 lib/workos/types/create_organization_connected_account_state.rb create mode 100644 lib/workos/types/data_integrations_create_client_credentials_connection_request_connection_owner.rb create mode 100644 lib/workos/types/data_integrations_upsert_client_credentials_request_2_connection_owner.rb create mode 100644 lib/workos/types/organization_connected_account_state.rb create mode 100644 lib/workos/types/reauthorize_data_integrations_upsert_client_credentials_request_connection_owner.rb create mode 100644 rbi/workos/create_connected_account.rbi create mode 100644 rbi/workos/create_organization_connected_account.rbi create mode 100644 rbi/workos/data_integration_vended_credential.rbi create mode 100644 rbi/workos/data_integrations_create_client_credentials_connection_request.rbi create mode 100644 rbi/workos/data_integrations_upsert_client_credentials_request_2.rbi create mode 100644 rbi/workos/organization_connected_account.rbi create mode 100644 rbi/workos/reauthorize_data_integrations_upsert_client_credentials_request.rbi diff --git a/lib/workos/pipes.rb b/lib/workos/pipes.rb index 9c271cdf..3e6d5226 100644 --- a/lib/workos/pipes.rb +++ b/lib/workos/pipes.rb @@ -184,13 +184,51 @@ def delete_data_integration( nil end + # Create another API key connected account + # @param slug [String] The identifier of the integration. + # @param user_id [String] A [User](https://workos.com/docs/reference/authkit/user) identifier. + # @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`. + # @param connection_owner [WorkOS::Types::DataIntegrationsCreateApiKeyConnectionRequestConnectionOwner, nil] Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization. + # @param secret [String] The API key secret to store for this integration. + # @param connection_intent [String] Must be `add`: this endpoint only creates another connection. The first connection for an owner shape fills the compatibility slot; later connections are standard. Creating an additional connection is not yet available: until it is, `add` succeeds only when the owner has no connection for this integration and otherwise returns 404 `multiple_connections_unavailable`. + # @param request_options [Hash] (see WorkOS::Types::RequestOptions) + # @return [WorkOS::ConnectedAccount] + def create_data_integration_api_key( + slug:, + user_id:, + secret:, + connection_intent:, + organization_id: nil, + connection_owner: nil, + request_options: {} + ) + body = { + "user_id" => user_id, + "organization_id" => organization_id, + "connection_owner" => connection_owner, + "secret" => secret, + "connection_intent" => connection_intent + }.compact + response = @client.request( + method: :post, + path: "/data-integrations/#{WorkOS::Util.encode_path(slug)}/api-key", + auth: true, + body: body, + request_options: request_options + ) + result = WorkOS::ConnectedAccount.new(response.body) + 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"]) + result + end + # Upsert an API key for a connected account # @param slug [String] The identifier of the integration. # @param user_id [String] A [User](https://workos.com/docs/reference/authkit/user) identifier. # @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`. - # @param connected_account_id [String, nil] A [connected account](https://workos.com/docs/reference/pipes/connected-account) identifier. Use this to rotate a specific existing connection. # @param connection_owner [WorkOS::Types::DataIntegrationsUpsertApiKeyRequestConnectionOwner, nil] Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization. # @param secret [String] The API key secret to store for this integration. + # @param connection_intent [String, nil] Reauthorize exactly the connection named by `connected_account_id`. + # @param connected_account_id [String, nil] The exact connected account to reauthorize. Required with `connection_intent: reauthorize`. # @param request_options [Hash] (see WorkOS::Types::RequestOptions) # @return [WorkOS::ConnectedAccount] def update_data_integration_api_key( @@ -198,16 +236,18 @@ def update_data_integration_api_key( user_id:, secret:, organization_id: nil, - connected_account_id: nil, connection_owner: nil, + connection_intent: nil, + connected_account_id: nil, request_options: {} ) body = { "user_id" => user_id, "organization_id" => organization_id, - "connected_account_id" => connected_account_id, "connection_owner" => connection_owner, - "secret" => secret + "secret" => secret, + "connection_intent" => connection_intent, + "connected_account_id" => connected_account_id }.compact response = @client.request( method: :put, @@ -258,15 +298,59 @@ def authorize_data_integration( result end + # Create another client credentials connected account + # @param slug [String] The identifier of the integration. + # @param user_id [String] A [User](https://workos.com/docs/reference/authkit/user) identifier. + # @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`. + # @param connection_owner [WorkOS::Types::DataIntegrationsCreateClientCredentialsConnectionRequestConnectionOwner, nil] Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization. + # @param client_id [String] The OAuth client ID to store for this integration. + # @param client_secret [String] The OAuth client secret to store for this integration. + # @param config [Hash{String => String}, nil] Provider-specific configuration values collected for this installation, keyed by the provider's config field descriptors. + # @param connection_intent [String] Must be `add`: this endpoint only creates another connection. The first connection for an owner shape fills the compatibility slot; later connections are standard. Creating an additional connection is not yet available: until it is, `add` succeeds only when the owner has no connection for this integration and otherwise returns 404 `multiple_connections_unavailable`. + # @param request_options [Hash] (see WorkOS::Types::RequestOptions) + # @return [WorkOS::ConnectedAccount] + def create_data_integration_client_credential( + slug:, + user_id:, + client_id:, + client_secret:, + connection_intent:, + organization_id: nil, + connection_owner: nil, + config: nil, + request_options: {} + ) + body = { + "user_id" => user_id, + "organization_id" => organization_id, + "connection_owner" => connection_owner, + "client_id" => client_id, + "client_secret" => client_secret, + "config" => config, + "connection_intent" => connection_intent + }.compact + response = @client.request( + method: :post, + path: "/data-integrations/#{WorkOS::Util.encode_path(slug)}/client-credentials", + auth: true, + body: body, + request_options: request_options + ) + result = WorkOS::ConnectedAccount.new(response.body) + 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"]) + result + end + # Upsert client credentials for a connected account # @param slug [String] The identifier of the integration. # @param user_id [String] A [User](https://workos.com/docs/reference/authkit/user) identifier. # @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter to scope the connection to a specific organization. Required when `connection_owner` is `organization`. - # @param connected_account_id [String, nil] A [connected account](https://workos.com/docs/reference/pipes/connected-account) identifier. Use this to rotate a specific existing connection. # @param connection_owner [WorkOS::Types::DataIntegrationsUpsertClientCredentialsRequestConnectionOwner, nil] Whose connection to create or rotate. `user` (the default) addresses the connection owned by `user_id`. `organization` addresses the connection shared by every member of `organization_id`; `user_id` then identifies the member performing the request and must be an active member of the organization. # @param client_id [String] The OAuth client ID to store for this integration. # @param client_secret [String] The OAuth client secret to store for this integration. # @param config [Hash{String => String}, nil] Provider-specific configuration values collected for this installation, keyed by the provider's config field descriptors. + # @param connection_intent [String, nil] Reauthorize exactly the connection named by `connected_account_id`. + # @param connected_account_id [String, nil] The exact connected account to reauthorize. Required with `connection_intent: reauthorize`. # @param request_options [Hash] (see WorkOS::Types::RequestOptions) # @return [WorkOS::ConnectedAccount] def update_data_integration_client_credentials( @@ -275,19 +359,21 @@ def update_data_integration_client_credentials( client_id:, client_secret:, organization_id: nil, - connected_account_id: nil, connection_owner: nil, config: nil, + connection_intent: nil, + connected_account_id: nil, request_options: {} ) body = { "user_id" => user_id, "organization_id" => organization_id, - "connected_account_id" => connected_account_id, "connection_owner" => connection_owner, "client_id" => client_id, "client_secret" => client_secret, - "config" => config + "config" => config, + "connection_intent" => connection_intent, + "connected_account_id" => connected_account_id }.compact response = @client.request( method: :put, @@ -488,17 +574,21 @@ def get_organization_connected_account( # @param refresh_token [String, nil] The OAuth refresh token for the connected account. # @param expires_at [String, nil] The ISO-8601 timestamp when the access token expires. Required when `access_token` is provided for tokens that expire. # @param scopes [Array, nil] The OAuth scopes granted for this connection. - # @param state [WorkOS::Types::ConnectedAccountInputState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided. + # @param state [WorkOS::Types::CreateOrganizationConnectedAccountState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided. + # @param user_id [String] The [User](https://workos.com/docs/reference/authkit/user) identifier of the organization member on whose behalf the connected account is being imported or updated. The user must be an active member of the organization. + # @param connection_intent [String, nil] Set to `add` to create another connected account. Omit this field for permanent compatibility behavior. Creating an additional connection is not yet available: until it is, `add` succeeds only when the owner has no connection for this integration, which creates the compatibility connection, and otherwise returns 404 `multiple_connections_unavailable`. # @param request_options [Hash] (see WorkOS::Types::RequestOptions) # @return [WorkOS::ConnectedAccount] def create_organization_connected_account( organization_id:, slug:, + user_id:, access_token: nil, refresh_token: nil, expires_at: nil, scopes: nil, state: nil, + connection_intent: nil, request_options: {} ) body = { @@ -506,7 +596,9 @@ def create_organization_connected_account( "refresh_token" => refresh_token, "expires_at" => expires_at, "scopes" => scopes, - "state" => state + "state" => state, + "user_id" => user_id, + "connection_intent" => connection_intent }.compact response = @client.request( method: :post, @@ -527,14 +619,17 @@ def create_organization_connected_account( # @param refresh_token [String, nil] The OAuth refresh token for the connected account. # @param expires_at [String, nil] The ISO-8601 timestamp when the access token expires. Required when `access_token` is provided for tokens that expire. # @param scopes [Array, nil] The OAuth scopes granted for this connection. - # @param state [WorkOS::Types::ConnectedAccountInputState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided. - # @param supports_multiple_connections [Boolean, nil] Set to `true` to use the plural connection contract. When omitted or `false`, only the compatibility connection is considered. + # @param state [WorkOS::Types::OrganizationConnectedAccountState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided. + # @param user_id [String] The [User](https://workos.com/docs/reference/authkit/user) identifier of the organization member on whose behalf the connected account is being imported or updated. The user must be an active member of the organization. + # @param supports_multiple_connections [Boolean, nil] Accepted for compatibility; does not change update targeting. Omit intent and selector to update the compatibility connection, or supply `connected_account_id` to update an exact connection. # @param connected_account_id [String, nil] A [connected account](https://workos.com/docs/reference/pipes/connected-account) identifier. Use this to select the connection to update. + # @param connection_intent [String, nil] Set to `reauthorize` with `connected_account_id` to update one exact connection. The intent may be omitted when supplying an ID. Omit both for permanent compatibility behavior. # @param request_options [Hash] (see WorkOS::Types::RequestOptions) # @return [WorkOS::ConnectedAccount] def update_organization_connected_account( organization_id:, slug:, + user_id:, access_token: nil, refresh_token: nil, expires_at: nil, @@ -542,18 +637,21 @@ def update_organization_connected_account( state: nil, supports_multiple_connections: nil, connected_account_id: nil, + connection_intent: nil, request_options: {} ) params = { "supports_multiple_connections" => supports_multiple_connections, - "connected_account_id" => connected_account_id + "connected_account_id" => connected_account_id, + "connection_intent" => connection_intent }.compact body = { "access_token" => access_token, "refresh_token" => refresh_token, "expires_at" => expires_at, "scopes" => scopes, - "state" => state + "state" => state, + "user_id" => user_id }.compact response = @client.request( method: :put, @@ -661,7 +759,8 @@ def get_user_connected_account( # @param refresh_token [String, nil] The OAuth refresh token for the connected account. # @param expires_at [String, nil] The ISO-8601 timestamp when the access token expires. Required when `access_token` is provided for tokens that expire. # @param scopes [Array, nil] The OAuth scopes granted for this connection. - # @param state [WorkOS::Types::ConnectedAccountInputState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided. + # @param state [WorkOS::Types::CreateConnectedAccountState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided. + # @param connection_intent [String, nil] Set to `add` to create another connected account. Omit this field for permanent compatibility behavior. Creating an additional connection is not yet available: until it is, `add` succeeds only when the owner has no connection for this integration, which creates the compatibility connection, and otherwise returns 404 `multiple_connections_unavailable`. # @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter if the connection is scoped to an organization. # @param request_options [Hash] (see WorkOS::Types::RequestOptions) # @return [WorkOS::ConnectedAccount] @@ -673,6 +772,7 @@ def create_user_connected_account( expires_at: nil, scopes: nil, state: nil, + connection_intent: nil, organization_id: nil, request_options: {} ) @@ -684,7 +784,8 @@ def create_user_connected_account( "refresh_token" => refresh_token, "expires_at" => expires_at, "scopes" => scopes, - "state" => state + "state" => state, + "connection_intent" => connection_intent }.compact response = @client.request( method: :post, @@ -708,8 +809,9 @@ def create_user_connected_account( # @param scopes [Array, nil] The OAuth scopes granted for this connection. # @param state [WorkOS::Types::ConnectedAccountInputState, nil] Explicitly set the state of the connected account. When omitted, the state is derived from the token combination provided. # @param organization_id [String, nil] An [Organization](https://workos.com/docs/reference/organization) identifier. Optional parameter if the connection is scoped to an organization. - # @param supports_multiple_connections [Boolean, nil] Set to `true` to use the plural connection contract. When omitted or `false`, only the compatibility connection is considered. + # @param supports_multiple_connections [Boolean, nil] Accepted for compatibility; does not change update targeting. Omit intent and selector to update the compatibility connection, or supply `connected_account_id` to update an exact connection. # @param connected_account_id [String, nil] A [connected account](https://workos.com/docs/reference/pipes/connected-account) identifier. Use this to select the connection to update. + # @param connection_intent [String, nil] Set to `reauthorize` with `connected_account_id` to update one exact connection. The intent may be omitted when supplying an ID. Omit both for permanent compatibility behavior. # @param request_options [Hash] (see WorkOS::Types::RequestOptions) # @return [WorkOS::ConnectedAccount] def update_user_connected_account( @@ -723,12 +825,14 @@ def update_user_connected_account( organization_id: nil, supports_multiple_connections: nil, connected_account_id: nil, + connection_intent: nil, request_options: {} ) params = { "organization_id" => organization_id, "supports_multiple_connections" => supports_multiple_connections, - "connected_account_id" => connected_account_id + "connected_account_id" => connected_account_id, + "connection_intent" => connection_intent }.compact body = { "access_token" => access_token, diff --git a/lib/workos/pipes/create_connected_account.rb b/lib/workos/pipes/create_connected_account.rb new file mode 100644 index 00000000..4bc87ed5 --- /dev/null +++ b/lib/workos/pipes/create_connected_account.rb @@ -0,0 +1,34 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class CreateConnectedAccount < WorkOS::Types::BaseModel + HASH_ATTRS = { + access_token: :access_token, + refresh_token: :refresh_token, + expires_at: :expires_at, + scopes: :scopes, + state: :state, + connection_intent: :connection_intent + }.freeze + + attr_accessor \ + :access_token, + :refresh_token, + :expires_at, + :scopes, + :state, + :connection_intent + + def initialize(json) + hash = self.class.normalize(json) + @access_token = hash[:access_token] + @refresh_token = hash[:refresh_token] + @expires_at = hash[:expires_at] + @scopes = hash[:scopes] || [] + @state = hash[:state] + @connection_intent = hash[:connection_intent] + end + end +end diff --git a/lib/workos/pipes/create_organization_connected_account.rb b/lib/workos/pipes/create_organization_connected_account.rb new file mode 100644 index 00000000..7234280f --- /dev/null +++ b/lib/workos/pipes/create_organization_connected_account.rb @@ -0,0 +1,37 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class CreateOrganizationConnectedAccount < WorkOS::Types::BaseModel + HASH_ATTRS = { + access_token: :access_token, + refresh_token: :refresh_token, + expires_at: :expires_at, + scopes: :scopes, + state: :state, + user_id: :user_id, + connection_intent: :connection_intent + }.freeze + + attr_accessor \ + :access_token, + :refresh_token, + :expires_at, + :scopes, + :state, + :user_id, + :connection_intent + + def initialize(json) + hash = self.class.normalize(json) + @access_token = hash[:access_token] + @refresh_token = hash[:refresh_token] + @expires_at = hash[:expires_at] + @scopes = hash[:scopes] || [] + @state = hash[:state] + @user_id = hash[:user_id] + @connection_intent = hash[:connection_intent] + end + end +end diff --git a/lib/workos/pipes/data_integration_credentials_response.rb b/lib/workos/pipes/data_integration_credentials_response.rb index 97e5fd12..c5aa0d17 100644 --- a/lib/workos/pipes/data_integration_credentials_response.rb +++ b/lib/workos/pipes/data_integration_credentials_response.rb @@ -18,7 +18,7 @@ class DataIntegrationCredentialsResponse < WorkOS::Types::BaseModel def initialize(json) hash = self.class.normalize(json) @active = hash[:active] - @credential = hash[:credential] ? WorkOS::DataIntegrationCredentialsResponseCredential.new(hash[:credential]) : nil + @credential = hash[:credential] ? WorkOS::DataIntegrationVendedCredential.new(hash[:credential]) : nil @error = hash[:error] end end diff --git a/lib/workos/pipes/data_integration_vended_credential.rb b/lib/workos/pipes/data_integration_vended_credential.rb new file mode 100644 index 00000000..e29645cd --- /dev/null +++ b/lib/workos/pipes/data_integration_vended_credential.rb @@ -0,0 +1,40 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class DataIntegrationVendedCredential < WorkOS::Types::BaseModel + HASH_ATTRS = { + object: :object, + auth_method: :auth_method, + value: :value, + expires_at: :expires_at, + scopes: :scopes, + missing_scopes: :missing_scopes, + config: :config, + metadata: :metadata + }.freeze + + attr_accessor \ + :object, + :auth_method, + :value, + :expires_at, + :scopes, + :missing_scopes, + :config, + :metadata + + def initialize(json) + hash = self.class.normalize(json) + @object = hash[:object] + @auth_method = hash[:auth_method] + @value = hash[:value] + @expires_at = hash[:expires_at] + @scopes = hash[:scopes] || [] + @missing_scopes = hash[:missing_scopes] || [] + @config = hash[:config] || {} + @metadata = hash[:metadata] || {} + end + end +end diff --git a/lib/workos/pipes/data_integrations_create_client_credentials_connection_request.rb b/lib/workos/pipes/data_integrations_create_client_credentials_connection_request.rb new file mode 100644 index 00000000..82148ac6 --- /dev/null +++ b/lib/workos/pipes/data_integrations_create_client_credentials_connection_request.rb @@ -0,0 +1,37 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class DataIntegrationsCreateClientCredentialsConnectionRequest < WorkOS::Types::BaseModel + HASH_ATTRS = { + user_id: :user_id, + organization_id: :organization_id, + connection_owner: :connection_owner, + client_id: :client_id, + client_secret: :client_secret, + config: :config, + connection_intent: :connection_intent + }.freeze + + attr_accessor \ + :user_id, + :organization_id, + :connection_owner, + :client_id, + :client_secret, + :config, + :connection_intent + + def initialize(json) + hash = self.class.normalize(json) + @user_id = hash[:user_id] + @organization_id = hash[:organization_id] + @connection_owner = hash[:connection_owner] + @client_id = hash[:client_id] + @client_secret = hash[:client_secret] + @config = hash[:config] || {} + @connection_intent = hash[:connection_intent] + end + end +end diff --git a/lib/workos/pipes/data_integrations_upsert_client_credentials_request.rb b/lib/workos/pipes/data_integrations_upsert_client_credentials_request.rb index 1291389e..18c2ec4b 100644 --- a/lib/workos/pipes/data_integrations_upsert_client_credentials_request.rb +++ b/lib/workos/pipes/data_integrations_upsert_client_credentials_request.rb @@ -7,7 +7,6 @@ class DataIntegrationsUpsertClientCredentialsRequest < WorkOS::Types::BaseModel HASH_ATTRS = { user_id: :user_id, organization_id: :organization_id, - connected_account_id: :connected_account_id, connection_owner: :connection_owner, client_id: :client_id, client_secret: :client_secret, @@ -17,7 +16,6 @@ class DataIntegrationsUpsertClientCredentialsRequest < WorkOS::Types::BaseModel attr_accessor \ :user_id, :organization_id, - :connected_account_id, :connection_owner, :client_id, :client_secret, @@ -27,7 +25,6 @@ def initialize(json) hash = self.class.normalize(json) @user_id = hash[:user_id] @organization_id = hash[:organization_id] - @connected_account_id = hash[:connected_account_id] @connection_owner = hash[:connection_owner] @client_id = hash[:client_id] @client_secret = hash[:client_secret] diff --git a/lib/workos/pipes/data_integrations_upsert_client_credentials_request_2.rb b/lib/workos/pipes/data_integrations_upsert_client_credentials_request_2.rb new file mode 100644 index 00000000..02348eb7 --- /dev/null +++ b/lib/workos/pipes/data_integrations_upsert_client_credentials_request_2.rb @@ -0,0 +1,37 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class DataIntegrationsUpsertClientCredentialsRequest2 < WorkOS::Types::BaseModel + HASH_ATTRS = { + user_id: :user_id, + organization_id: :organization_id, + connection_owner: :connection_owner, + client_id: :client_id, + client_secret: :client_secret, + config: :config, + connected_account_id: :connected_account_id + }.freeze + + attr_accessor \ + :user_id, + :organization_id, + :connection_owner, + :client_id, + :client_secret, + :config, + :connected_account_id + + def initialize(json) + hash = self.class.normalize(json) + @user_id = hash[:user_id] + @organization_id = hash[:organization_id] + @connection_owner = hash[:connection_owner] + @client_id = hash[:client_id] + @client_secret = hash[:client_secret] + @config = hash[:config] || {} + @connected_account_id = hash[:connected_account_id] + end + end +end diff --git a/lib/workos/pipes/organization_connected_account.rb b/lib/workos/pipes/organization_connected_account.rb new file mode 100644 index 00000000..d8b2bbab --- /dev/null +++ b/lib/workos/pipes/organization_connected_account.rb @@ -0,0 +1,34 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class OrganizationConnectedAccount < WorkOS::Types::BaseModel + HASH_ATTRS = { + access_token: :access_token, + refresh_token: :refresh_token, + expires_at: :expires_at, + scopes: :scopes, + state: :state, + user_id: :user_id + }.freeze + + attr_accessor \ + :access_token, + :refresh_token, + :expires_at, + :scopes, + :state, + :user_id + + def initialize(json) + hash = self.class.normalize(json) + @access_token = hash[:access_token] + @refresh_token = hash[:refresh_token] + @expires_at = hash[:expires_at] + @scopes = hash[:scopes] || [] + @state = hash[:state] + @user_id = hash[:user_id] + end + end +end diff --git a/lib/workos/pipes/reauthorize_data_integrations_upsert_client_credentials_request.rb b/lib/workos/pipes/reauthorize_data_integrations_upsert_client_credentials_request.rb new file mode 100644 index 00000000..c468d762 --- /dev/null +++ b/lib/workos/pipes/reauthorize_data_integrations_upsert_client_credentials_request.rb @@ -0,0 +1,40 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class ReauthorizeDataIntegrationsUpsertClientCredentialsRequest < WorkOS::Types::BaseModel + HASH_ATTRS = { + user_id: :user_id, + organization_id: :organization_id, + connection_owner: :connection_owner, + client_id: :client_id, + client_secret: :client_secret, + config: :config, + connection_intent: :connection_intent, + connected_account_id: :connected_account_id + }.freeze + + attr_accessor \ + :user_id, + :organization_id, + :connection_owner, + :client_id, + :client_secret, + :config, + :connection_intent, + :connected_account_id + + def initialize(json) + hash = self.class.normalize(json) + @user_id = hash[:user_id] + @organization_id = hash[:organization_id] + @connection_owner = hash[:connection_owner] + @client_id = hash[:client_id] + @client_secret = hash[:client_secret] + @config = hash[:config] || {} + @connection_intent = hash[:connection_intent] + @connected_account_id = hash[:connected_account_id] + end + end +end diff --git a/lib/workos/types/create_connected_account_state.rb b/lib/workos/types/create_connected_account_state.rb new file mode 100644 index 00000000..8827478e --- /dev/null +++ b/lib/workos/types/create_connected_account_state.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + CreateConnectedAccountState = ConnectedAccountInputState + end +end diff --git a/lib/workos/types/create_organization_connected_account_state.rb b/lib/workos/types/create_organization_connected_account_state.rb new file mode 100644 index 00000000..f27aca38 --- /dev/null +++ b/lib/workos/types/create_organization_connected_account_state.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + CreateOrganizationConnectedAccountState = ConnectedAccountInputState + end +end diff --git a/lib/workos/types/data_integrations_create_client_credentials_connection_request_connection_owner.rb b/lib/workos/types/data_integrations_create_client_credentials_connection_request_connection_owner.rb new file mode 100644 index 00000000..89f0f7db --- /dev/null +++ b/lib/workos/types/data_integrations_create_client_credentials_connection_request_connection_owner.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + DataIntegrationsCreateClientCredentialsConnectionRequestConnectionOwner = CreateDataIntegrationOwnership + end +end diff --git a/lib/workos/types/data_integrations_upsert_client_credentials_request_2_connection_owner.rb b/lib/workos/types/data_integrations_upsert_client_credentials_request_2_connection_owner.rb new file mode 100644 index 00000000..e4d7daa8 --- /dev/null +++ b/lib/workos/types/data_integrations_upsert_client_credentials_request_2_connection_owner.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + DataIntegrationsUpsertClientCredentialsRequest2ConnectionOwner = CreateDataIntegrationOwnership + end +end diff --git a/lib/workos/types/organization_connected_account_state.rb b/lib/workos/types/organization_connected_account_state.rb new file mode 100644 index 00000000..a38dde27 --- /dev/null +++ b/lib/workos/types/organization_connected_account_state.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + OrganizationConnectedAccountState = ConnectedAccountInputState + end +end diff --git a/lib/workos/types/reauthorize_data_integrations_upsert_client_credentials_request_connection_owner.rb b/lib/workos/types/reauthorize_data_integrations_upsert_client_credentials_request_connection_owner.rb new file mode 100644 index 00000000..e9a2f7c2 --- /dev/null +++ b/lib/workos/types/reauthorize_data_integrations_upsert_client_credentials_request_connection_owner.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + ReauthorizeDataIntegrationsUpsertClientCredentialsRequestConnectionOwner = CreateDataIntegrationOwnership + end +end diff --git a/rbi/workos/create_connected_account.rbi b/rbi/workos/create_connected_account.rbi new file mode 100644 index 00000000..294641a3 --- /dev/null +++ b/rbi/workos/create_connected_account.rbi @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class CreateConnectedAccount + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(T.nilable(String)) } + def access_token; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def access_token=(value); end + + sig { returns(T.nilable(String)) } + def refresh_token; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def refresh_token=(value); end + + sig { returns(T.nilable(String)) } + def expires_at; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def expires_at=(value); end + + sig { returns(T.nilable(T::Array[String])) } + def scopes; end + + sig { params(value: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def scopes=(value); end + + sig { returns(T.nilable(String)) } + def state; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def state=(value); end + + sig { returns(T.nilable(String)) } + def connection_intent; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def connection_intent=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/rbi/workos/create_organization_connected_account.rbi b/rbi/workos/create_organization_connected_account.rbi new file mode 100644 index 00000000..69e1e1ed --- /dev/null +++ b/rbi/workos/create_organization_connected_account.rbi @@ -0,0 +1,60 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class CreateOrganizationConnectedAccount + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(T.nilable(String)) } + def access_token; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def access_token=(value); end + + sig { returns(T.nilable(String)) } + def refresh_token; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def refresh_token=(value); end + + sig { returns(T.nilable(String)) } + def expires_at; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def expires_at=(value); end + + sig { returns(T.nilable(T::Array[String])) } + def scopes; end + + sig { params(value: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def scopes=(value); end + + sig { returns(T.nilable(String)) } + def state; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def state=(value); end + + sig { returns(String) } + def user_id; end + + sig { params(value: String).returns(String) } + def user_id=(value); end + + sig { returns(T.nilable(String)) } + def connection_intent; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def connection_intent=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/rbi/workos/data_integration_credentials_response.rbi b/rbi/workos/data_integration_credentials_response.rbi index 8df29240..ac58bf02 100644 --- a/rbi/workos/data_integration_credentials_response.rbi +++ b/rbi/workos/data_integration_credentials_response.rbi @@ -15,10 +15,10 @@ module WorkOS sig { params(value: T.nilable(T::Boolean)).returns(T.nilable(T::Boolean)) } def active=(value); end - sig { returns(T.nilable(WorkOS::DataIntegrationCredentialsResponseCredential)) } + sig { returns(T.nilable(WorkOS::DataIntegrationVendedCredential)) } def credential; end - sig { params(value: T.nilable(WorkOS::DataIntegrationCredentialsResponseCredential)).returns(T.nilable(WorkOS::DataIntegrationCredentialsResponseCredential)) } + sig { params(value: T.nilable(WorkOS::DataIntegrationVendedCredential)).returns(T.nilable(WorkOS::DataIntegrationVendedCredential)) } def credential=(value); end sig { returns(T.nilable(String)) } diff --git a/rbi/workos/data_integration_vended_credential.rbi b/rbi/workos/data_integration_vended_credential.rbi new file mode 100644 index 00000000..529427ec --- /dev/null +++ b/rbi/workos/data_integration_vended_credential.rbi @@ -0,0 +1,66 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class DataIntegrationVendedCredential + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(T.nilable(String)) } + def object; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def object=(value); end + + sig { returns(T.nilable(String)) } + def auth_method; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def auth_method=(value); end + + sig { returns(T.nilable(String)) } + def value; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def value=(value); end + + sig { returns(T.nilable(String)) } + def expires_at; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def expires_at=(value); end + + sig { returns(T.nilable(T::Array[String])) } + def scopes; end + + sig { params(value: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def scopes=(value); end + + sig { returns(T.nilable(T::Array[String])) } + def missing_scopes; end + + sig { params(value: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def missing_scopes=(value); end + + sig { returns(T.nilable(T::Hash[String, String])) } + def config; end + + sig { params(value: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) } + def config=(value); end + + sig { returns(T.nilable(T::Hash[String, T.untyped])) } + def metadata; end + + sig { params(value: T.nilable(T::Hash[String, T.untyped])).returns(T.nilable(T::Hash[String, T.untyped])) } + def metadata=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/rbi/workos/data_integrations_create_client_credentials_connection_request.rbi b/rbi/workos/data_integrations_create_client_credentials_connection_request.rbi new file mode 100644 index 00000000..d38501ad --- /dev/null +++ b/rbi/workos/data_integrations_create_client_credentials_connection_request.rbi @@ -0,0 +1,60 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class DataIntegrationsCreateClientCredentialsConnectionRequest + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(String) } + def user_id; end + + sig { params(value: String).returns(String) } + def user_id=(value); end + + sig { returns(T.nilable(String)) } + def organization_id; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def organization_id=(value); end + + sig { returns(T.nilable(String)) } + def connection_owner; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def connection_owner=(value); end + + sig { returns(String) } + def client_id; end + + sig { params(value: String).returns(String) } + def client_id=(value); end + + sig { returns(String) } + def client_secret; end + + sig { params(value: String).returns(String) } + def client_secret=(value); end + + sig { returns(T.nilable(T::Hash[String, String])) } + def config; end + + sig { params(value: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) } + def config=(value); end + + sig { returns(String) } + def connection_intent; end + + sig { params(value: String).returns(String) } + def connection_intent=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/rbi/workos/data_integrations_upsert_client_credentials_request.rbi b/rbi/workos/data_integrations_upsert_client_credentials_request.rbi index 009da6ef..3cf57af0 100644 --- a/rbi/workos/data_integrations_upsert_client_credentials_request.rbi +++ b/rbi/workos/data_integrations_upsert_client_credentials_request.rbi @@ -21,12 +21,6 @@ module WorkOS sig { params(value: T.nilable(String)).returns(T.nilable(String)) } def organization_id=(value); end - sig { returns(T.nilable(String)) } - def connected_account_id; end - - sig { params(value: T.nilable(String)).returns(T.nilable(String)) } - def connected_account_id=(value); end - sig { returns(T.nilable(String)) } def connection_owner; end diff --git a/rbi/workos/data_integrations_upsert_client_credentials_request_2.rbi b/rbi/workos/data_integrations_upsert_client_credentials_request_2.rbi new file mode 100644 index 00000000..9ec7fae3 --- /dev/null +++ b/rbi/workos/data_integrations_upsert_client_credentials_request_2.rbi @@ -0,0 +1,60 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class DataIntegrationsUpsertClientCredentialsRequest2 + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(String) } + def user_id; end + + sig { params(value: String).returns(String) } + def user_id=(value); end + + sig { returns(T.nilable(String)) } + def organization_id; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def organization_id=(value); end + + sig { returns(T.nilable(String)) } + def connection_owner; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def connection_owner=(value); end + + sig { returns(String) } + def client_id; end + + sig { params(value: String).returns(String) } + def client_id=(value); end + + sig { returns(String) } + def client_secret; end + + sig { params(value: String).returns(String) } + def client_secret=(value); end + + sig { returns(T.nilable(T::Hash[String, String])) } + def config; end + + sig { params(value: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) } + def config=(value); end + + sig { returns(String) } + def connected_account_id; end + + sig { params(value: String).returns(String) } + def connected_account_id=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/rbi/workos/organization_connected_account.rbi b/rbi/workos/organization_connected_account.rbi new file mode 100644 index 00000000..590a2c2a --- /dev/null +++ b/rbi/workos/organization_connected_account.rbi @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class OrganizationConnectedAccount + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(T.nilable(String)) } + def access_token; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def access_token=(value); end + + sig { returns(T.nilable(String)) } + def refresh_token; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def refresh_token=(value); end + + sig { returns(T.nilable(String)) } + def expires_at; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def expires_at=(value); end + + sig { returns(T.nilable(T::Array[String])) } + def scopes; end + + sig { params(value: T.nilable(T::Array[String])).returns(T.nilable(T::Array[String])) } + def scopes=(value); end + + sig { returns(T.nilable(String)) } + def state; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def state=(value); end + + sig { returns(String) } + def user_id; end + + sig { params(value: String).returns(String) } + def user_id=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/rbi/workos/pipes.rbi b/rbi/workos/pipes.rbi index 14d132c6..4e59f456 100644 --- a/rbi/workos/pipes.rbi +++ b/rbi/workos/pipes.rbi @@ -68,18 +68,30 @@ module WorkOS end def delete_data_integration(slug:, request_options:); end + sig do + params( + slug: String, + user_id: String, + secret: String, + connection_intent: String, + organization_id: T.nilable(String), + connection_owner: T.nilable(String), + request_options: T::Hash[Symbol, T.untyped] + ).returns(WorkOS::ConnectedAccount) + end + def create_data_integration_api_key(slug:, user_id:, secret:, connection_intent:, organization_id:, connection_owner:, request_options:); end + sig do params( slug: String, user_id: String, secret: String, organization_id: T.nilable(String), - connected_account_id: T.nilable(String), connection_owner: T.nilable(String), request_options: T::Hash[Symbol, T.untyped] ).returns(WorkOS::ConnectedAccount) end - def update_data_integration_api_key(slug:, user_id:, secret:, organization_id:, connected_account_id:, connection_owner:, request_options:); end + def update_data_integration_api_key(slug:, user_id:, secret:, organization_id:, connection_owner:, request_options:); end sig do params( @@ -94,6 +106,21 @@ module WorkOS end def authorize_data_integration(slug:, user_id:, organization_id:, connection_owner:, return_to:, config:, request_options:); end + sig do + params( + slug: String, + user_id: String, + client_id: String, + client_secret: String, + connection_intent: String, + organization_id: T.nilable(String), + connection_owner: T.nilable(String), + config: T.nilable(T::Hash[String, String]), + request_options: T::Hash[Symbol, T.untyped] + ).returns(WorkOS::ConnectedAccount) + end + def create_data_integration_client_credential(slug:, user_id:, client_id:, client_secret:, connection_intent:, organization_id:, connection_owner:, config:, request_options:); end + sig do params( slug: String, @@ -101,13 +128,12 @@ module WorkOS client_id: String, client_secret: String, organization_id: T.nilable(String), - connected_account_id: T.nilable(String), connection_owner: T.nilable(String), config: T.nilable(T::Hash[String, String]), request_options: T::Hash[Symbol, T.untyped] ).returns(WorkOS::ConnectedAccount) end - def update_data_integration_client_credentials(slug:, user_id:, client_id:, client_secret:, organization_id:, connected_account_id:, connection_owner:, config:, request_options:); end + def update_data_integration_client_credentials(slug:, user_id:, client_id:, client_secret:, organization_id:, connection_owner:, config:, request_options:); end sig do params( @@ -180,20 +206,23 @@ module WorkOS params( organization_id: String, slug: String, + user_id: String, access_token: T.nilable(String), refresh_token: T.nilable(String), expires_at: T.nilable(String), scopes: T.nilable(T::Array[String]), state: T.nilable(String), + connection_intent: T.nilable(String), request_options: T::Hash[Symbol, T.untyped] ).returns(WorkOS::ConnectedAccount) end - def create_organization_connected_account(organization_id:, slug:, access_token:, refresh_token:, expires_at:, scopes:, state:, request_options:); end + def create_organization_connected_account(organization_id:, slug:, user_id:, access_token:, refresh_token:, expires_at:, scopes:, state:, connection_intent:, request_options:); end sig do params( organization_id: String, slug: String, + user_id: String, access_token: T.nilable(String), refresh_token: T.nilable(String), expires_at: T.nilable(String), @@ -201,10 +230,11 @@ module WorkOS state: T.nilable(String), supports_multiple_connections: T.nilable(T::Boolean), connected_account_id: T.nilable(String), + connection_intent: T.nilable(String), request_options: T::Hash[Symbol, T.untyped] ).returns(WorkOS::ConnectedAccount) end - def update_organization_connected_account(organization_id:, slug:, access_token:, refresh_token:, expires_at:, scopes:, state:, supports_multiple_connections:, connected_account_id:, request_options:); end + def update_organization_connected_account(organization_id:, slug:, user_id:, access_token:, refresh_token:, expires_at:, scopes:, state:, supports_multiple_connections:, connected_account_id:, connection_intent:, request_options:); end sig do params( @@ -247,11 +277,12 @@ module WorkOS expires_at: T.nilable(String), scopes: T.nilable(T::Array[String]), state: T.nilable(String), + connection_intent: T.nilable(String), organization_id: T.nilable(String), request_options: T::Hash[Symbol, T.untyped] ).returns(WorkOS::ConnectedAccount) end - def create_user_connected_account(user_id:, slug:, access_token:, refresh_token:, expires_at:, scopes:, state:, organization_id:, request_options:); end + def create_user_connected_account(user_id:, slug:, access_token:, refresh_token:, expires_at:, scopes:, state:, connection_intent:, organization_id:, request_options:); end sig do params( @@ -265,10 +296,11 @@ module WorkOS organization_id: T.nilable(String), supports_multiple_connections: T.nilable(T::Boolean), connected_account_id: T.nilable(String), + connection_intent: T.nilable(String), request_options: T::Hash[Symbol, T.untyped] ).returns(WorkOS::ConnectedAccount) end - def update_user_connected_account(user_id:, slug:, access_token:, refresh_token:, expires_at:, scopes:, state:, organization_id:, supports_multiple_connections:, connected_account_id:, request_options:); end + def update_user_connected_account(user_id:, slug:, access_token:, refresh_token:, expires_at:, scopes:, state:, organization_id:, supports_multiple_connections:, connected_account_id:, connection_intent:, request_options:); end sig do params( diff --git a/rbi/workos/reauthorize_data_integrations_upsert_client_credentials_request.rbi b/rbi/workos/reauthorize_data_integrations_upsert_client_credentials_request.rbi new file mode 100644 index 00000000..c2f53126 --- /dev/null +++ b/rbi/workos/reauthorize_data_integrations_upsert_client_credentials_request.rbi @@ -0,0 +1,66 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class ReauthorizeDataIntegrationsUpsertClientCredentialsRequest + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(String) } + def user_id; end + + sig { params(value: String).returns(String) } + def user_id=(value); end + + sig { returns(T.nilable(String)) } + def organization_id; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def organization_id=(value); end + + sig { returns(T.nilable(String)) } + def connection_owner; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def connection_owner=(value); end + + sig { returns(String) } + def client_id; end + + sig { params(value: String).returns(String) } + def client_id=(value); end + + sig { returns(String) } + def client_secret; end + + sig { params(value: String).returns(String) } + def client_secret=(value); end + + sig { returns(T.nilable(T::Hash[String, String])) } + def config; end + + sig { params(value: T.nilable(T::Hash[String, String])).returns(T.nilable(T::Hash[String, String])) } + def config=(value); end + + sig { returns(String) } + def connection_intent; end + + sig { params(value: String).returns(String) } + def connection_intent=(value); end + + sig { returns(String) } + def connected_account_id; end + + sig { params(value: String).returns(String) } + def connected_account_id=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/test/workos/test_pipes.rb b/test/workos/test_pipes.rb index a59c761c..d9282cf9 100644 --- a/test/workos/test_pipes.rb +++ b/test/workos/test_pipes.rb @@ -46,6 +46,13 @@ def test_delete_data_integration_returns_expected_result assert_nil result end + def test_create_data_integration_api_key_returns_expected_result + stub_request(:post, %r{\Ahttps://api\.workos\.com/data-integrations/stub/api-key(\?|\z)}) + .to_return(body: "{}", status: 200) + result = @client.pipes.create_data_integration_api_key(slug: "stub", user_id: "stub", secret: "stub", connection_intent: "add") + refute_nil result + end + def test_update_data_integration_api_key_returns_expected_result stub_request(:put, %r{\Ahttps://api\.workos\.com/data-integrations/stub/api-key(\?|\z)}) .to_return(body: "{}", status: 200) @@ -60,6 +67,13 @@ def test_authorize_data_integration_returns_expected_result refute_nil result end + def test_create_data_integration_client_credential_returns_expected_result + stub_request(:post, %r{\Ahttps://api\.workos\.com/data-integrations/stub/client-credentials(\?|\z)}) + .to_return(body: "{}", status: 200) + result = @client.pipes.create_data_integration_client_credential(slug: "stub", user_id: "stub", client_id: "stub", client_secret: "stub", connection_intent: "add") + refute_nil result + end + def test_update_data_integration_client_credentials_returns_expected_result stub_request(:put, %r{\Ahttps://api\.workos\.com/data-integrations/stub/client-credentials(\?|\z)}) .to_return(body: "{}", status: 200) @@ -112,14 +126,14 @@ def test_get_organization_connected_account_returns_expected_result def test_create_organization_connected_account_returns_expected_result stub_request(:post, %r{\Ahttps://api\.workos\.com/organizations/stub/connected_accounts/stub(\?|\z)}) .to_return(body: "{}", status: 200) - result = @client.pipes.create_organization_connected_account(organization_id: "stub", slug: "stub") + result = @client.pipes.create_organization_connected_account(organization_id: "stub", slug: "stub", user_id: "stub") refute_nil result end def test_update_organization_connected_account_returns_expected_result stub_request(:put, %r{\Ahttps://api\.workos\.com/organizations/stub/connected_accounts/stub(\?|\z)}) .to_return(body: "{}", status: 200) - result = @client.pipes.update_organization_connected_account(organization_id: "stub", slug: "stub") + result = @client.pipes.update_organization_connected_account(organization_id: "stub", slug: "stub", user_id: "stub") refute_nil result end @@ -179,8 +193,10 @@ def test_list_user_data_providers_returns_expected_result {name: :get_data_integration, verb: :get, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub(\?|\z)}, args: {slug: "stub"}}, {name: :update_data_integration, verb: :put, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub(\?|\z)}, args: {slug: "stub"}}, {name: :delete_data_integration, verb: :delete, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub(\?|\z)}, args: {slug: "stub"}}, + {name: :create_data_integration_api_key, verb: :post, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/api-key(\?|\z)}, args: {slug: "stub", user_id: "stub", secret: "stub", connection_intent: "add"}}, {name: :update_data_integration_api_key, verb: :put, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/api-key(\?|\z)}, args: {slug: "stub", user_id: "stub", secret: "stub"}}, {name: :authorize_data_integration, verb: :post, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/authorize(\?|\z)}, args: {slug: "stub", user_id: "stub"}}, + {name: :create_data_integration_client_credential, verb: :post, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/client-credentials(\?|\z)}, args: {slug: "stub", user_id: "stub", client_id: "stub", client_secret: "stub", connection_intent: "add"}}, {name: :update_data_integration_client_credentials, verb: :put, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/client-credentials(\?|\z)}, args: {slug: "stub", user_id: "stub", client_id: "stub", client_secret: "stub"}}, {name: :create_data_integration_credential, verb: :post, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/credentials(\?|\z)}, args: {slug: "stub", user_id: "stub"}}, {name: :list_data_integration_organization, verb: :get, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/organization(\?|\z)}, args: {slug: "stub"}}, @@ -188,8 +204,8 @@ def test_list_user_data_providers_returns_expected_result {name: :delete_data_integration_organization, verb: :delete, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/organization(\?|\z)}, args: {slug: "stub"}}, {name: :get_access_token, verb: :post, url: %r{\Ahttps://api\.workos\.com/data-integrations/stub/token(\?|\z)}, args: {provider: "stub", user_id: "stub"}}, {name: :get_organization_connected_account, verb: :get, url: %r{\Ahttps://api\.workos\.com/organizations/stub/connected_accounts/stub(\?|\z)}, args: {organization_id: "stub", slug: "stub"}}, - {name: :create_organization_connected_account, verb: :post, url: %r{\Ahttps://api\.workos\.com/organizations/stub/connected_accounts/stub(\?|\z)}, args: {organization_id: "stub", slug: "stub"}}, - {name: :update_organization_connected_account, verb: :put, url: %r{\Ahttps://api\.workos\.com/organizations/stub/connected_accounts/stub(\?|\z)}, args: {organization_id: "stub", slug: "stub"}}, + {name: :create_organization_connected_account, verb: :post, url: %r{\Ahttps://api\.workos\.com/organizations/stub/connected_accounts/stub(\?|\z)}, args: {organization_id: "stub", slug: "stub", user_id: "stub"}}, + {name: :update_organization_connected_account, verb: :put, url: %r{\Ahttps://api\.workos\.com/organizations/stub/connected_accounts/stub(\?|\z)}, args: {organization_id: "stub", slug: "stub", user_id: "stub"}}, {name: :delete_organization_connected_account, verb: :delete, url: %r{\Ahttps://api\.workos\.com/organizations/stub/connected_accounts/stub(\?|\z)}, args: {organization_id: "stub", slug: "stub"}}, {name: :list_organization_data_providers, verb: :get, url: %r{\Ahttps://api\.workos\.com/organizations/stub/data_providers(\?|\z)}, args: {organization_id: "stub"}}, {name: :get_user_connected_account, verb: :get, url: %r{\Ahttps://api\.workos\.com/user_management/users/stub/connected_accounts/stub(\?|\z)}, args: {user_id: "stub", slug: "stub"}}, diff --git a/test/workos/test_pipes_model_round_trip.rb b/test/workos/test_pipes_model_round_trip.rb index cd051116..24a25948 100644 --- a/test/workos/test_pipes_model_round_trip.rb +++ b/test/workos/test_pipes_model_round_trip.rb @@ -107,6 +107,54 @@ def test_update_data_integration_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end + def test_create_organization_connected_account_round_trip + fixture = { + "access_token" => "stub", + "refresh_token" => "stub", + "expires_at" => "stub", + "scopes" => [], + "state" => "stub", + "user_id" => "stub", + "connection_intent" => "add" + } + model = WorkOS::CreateOrganizationConnectedAccount.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["user_id"], json[:user_id] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + + def test_organization_connected_account_round_trip + fixture = { + "access_token" => "stub", + "refresh_token" => "stub", + "expires_at" => "stub", + "scopes" => [], + "state" => "stub", + "user_id" => "stub" + } + model = WorkOS::OrganizationConnectedAccount.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["user_id"], json[:user_id] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + + def test_create_connected_account_round_trip + fixture = { + "access_token" => "stub", + "refresh_token" => "stub", + "expires_at" => "stub", + "scopes" => [], + "state" => "stub", + "connection_intent" => "add" + } + model = WorkOS::CreateConnectedAccount.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + def test_connected_account_input_round_trip fixture = { "access_token" => "stub", @@ -178,6 +226,23 @@ def test_data_integration_access_token_response_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end + def test_data_integration_vended_credential_round_trip + fixture = { + "object" => "credential", + "auth_method" => "oauth", + "value" => "stub", + "expires_at" => nil, + "scopes" => [], + "missing_scopes" => [], + "config" => {}, + "metadata" => {} + } + model = WorkOS::DataIntegrationVendedCredential.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + def test_data_integration_credentials_response_round_trip fixture = { "active" => true, @@ -265,23 +330,6 @@ def test_data_integrations_list_response_data_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end - def test_data_integration_credentials_response_credential_round_trip - fixture = { - "object" => "credential", - "auth_method" => "oauth", - "value" => "stub", - "expires_at" => nil, - "scopes" => [], - "missing_scopes" => [] - } - model = WorkOS::DataIntegrationCredentialsResponseCredential.new(fixture.to_json) - json = model.to_h - assert_kind_of Hash, json - assert_equal fixture["value"], json[:value] - assert_nil json[:expires_at] - fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } - end - def test_data_integration_access_token_response_access_token_round_trip fixture = { "object" => "access_token", @@ -363,11 +411,26 @@ def test_data_integration_custom_provider_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end + def test_data_integrations_create_api_key_connection_request_round_trip + fixture = { + "user_id" => "stub", + "organization_id" => "stub", + "connection_owner" => "stub", + "secret" => "stub", + "connection_intent" => "add" + } + model = WorkOS::DataIntegrationsCreateApiKeyConnectionRequest.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["user_id"], json[:user_id] + assert_equal fixture["secret"], json[:secret] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + def test_data_integrations_upsert_api_key_request_round_trip fixture = { "user_id" => "stub", "organization_id" => "stub", - "connected_account_id" => "stub", "connection_owner" => "stub", "secret" => "stub" } @@ -379,6 +442,41 @@ def test_data_integrations_upsert_api_key_request_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end + def test_reauthorize_data_integrations_upsert_api_key_request_round_trip + fixture = { + "user_id" => "stub", + "organization_id" => "stub", + "connection_owner" => "stub", + "secret" => "stub", + "connection_intent" => "reauthorize", + "connected_account_id" => "stub" + } + model = WorkOS::ReauthorizeDataIntegrationsUpsertApiKeyRequest.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["user_id"], json[:user_id] + assert_equal fixture["secret"], json[:secret] + assert_equal fixture["connected_account_id"], json[:connected_account_id] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + + def test_data_integrations_upsert_api_key_request_2_round_trip + fixture = { + "user_id" => "stub", + "organization_id" => "stub", + "connection_owner" => "stub", + "secret" => "stub", + "connected_account_id" => "stub" + } + model = WorkOS::DataIntegrationsUpsertApiKeyRequest2.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["user_id"], json[:user_id] + assert_equal fixture["secret"], json[:secret] + assert_equal fixture["connected_account_id"], json[:connected_account_id] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + def test_data_integrations_get_data_integration_authorize_url_request_round_trip fixture = { "user_id" => "stub", @@ -394,11 +492,29 @@ def test_data_integrations_get_data_integration_authorize_url_request_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end + def test_data_integrations_create_client_credentials_connection_request_round_trip + fixture = { + "user_id" => "stub", + "organization_id" => "stub", + "connection_owner" => "stub", + "client_id" => "stub", + "client_secret" => "stub", + "config" => {}, + "connection_intent" => "add" + } + model = WorkOS::DataIntegrationsCreateClientCredentialsConnectionRequest.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["user_id"], json[:user_id] + assert_equal fixture["client_id"], json[:client_id] + assert_equal fixture["client_secret"], json[:client_secret] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + def test_data_integrations_upsert_client_credentials_request_round_trip fixture = { "user_id" => "stub", "organization_id" => "stub", - "connected_account_id" => "stub", "connection_owner" => "stub", "client_id" => "stub", "client_secret" => "stub", @@ -413,6 +529,47 @@ def test_data_integrations_upsert_client_credentials_request_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end + def test_reauthorize_data_integrations_upsert_client_credentials_request_round_trip + fixture = { + "user_id" => "stub", + "organization_id" => "stub", + "connection_owner" => "stub", + "client_id" => "stub", + "client_secret" => "stub", + "config" => {}, + "connection_intent" => "reauthorize", + "connected_account_id" => "stub" + } + model = WorkOS::ReauthorizeDataIntegrationsUpsertClientCredentialsRequest.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["user_id"], json[:user_id] + assert_equal fixture["client_id"], json[:client_id] + assert_equal fixture["client_secret"], json[:client_secret] + assert_equal fixture["connected_account_id"], json[:connected_account_id] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + + def test_data_integrations_upsert_client_credentials_request_2_round_trip + fixture = { + "user_id" => "stub", + "organization_id" => "stub", + "connection_owner" => "stub", + "client_id" => "stub", + "client_secret" => "stub", + "config" => {}, + "connected_account_id" => "stub" + } + model = WorkOS::DataIntegrationsUpsertClientCredentialsRequest2.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["user_id"], json[:user_id] + assert_equal fixture["client_id"], json[:client_id] + assert_equal fixture["client_secret"], json[:client_secret] + assert_equal fixture["connected_account_id"], json[:connected_account_id] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + def test_data_integrations_vend_credentials_request_round_trip fixture = { "user_id" => "stub", @@ -476,4 +633,21 @@ def test_data_integrations_list_response_data_connected_account_round_trip assert_nil json[:userlandUserId] fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end + + def test_data_integration_credentials_response_credential_round_trip + fixture = { + "object" => "credential", + "auth_method" => "oauth", + "value" => "stub", + "expires_at" => nil, + "scopes" => [], + "missing_scopes" => [] + } + model = WorkOS::DataIntegrationCredentialsResponseCredential.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["value"], json[:value] + assert_nil json[:expires_at] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end end From c195c9deee5ccdb902641acc2984bb74a0a96b86 Mon Sep 17 00:00:00 2001 From: "workos-sdk-automation[bot]" <255426317+workos-sdk-automation[bot]@users.noreply.github.com> Date: Fri, 25 Sep 2026 17:40:13 +0000 Subject: [PATCH 2/4] chore(generated): regenerate shared files for Pipes --- .last-synced-sha | 2 +- .oagen-manifest.json | 37 ++++++ ...tions_create_api_key_connection_request.rb | 31 +++++ ...ata_integrations_upsert_api_key_request.rb | 3 - ...a_integrations_upsert_api_key_request_2.rb | 31 +++++ ...ata_integrations_upsert_api_key_request.rb | 34 +++++ ...key_connection_request_connection_owner.rb | 9 ++ ...sert_api_key_request_2_connection_owner.rb | 9 ++ ...upsert_api_key_request_connection_owner.rb | 9 ++ ...ions_create_api_key_connection_request.rbi | 48 +++++++ ...ta_integrations_upsert_api_key_request.rbi | 6 - ..._integrations_upsert_api_key_request_2.rbi | 48 +++++++ ...ta_integrations_upsert_api_key_request.rbi | 54 ++++++++ test/workos/test_shared_model_round_trip.rb | 122 +++++++++--------- 14 files changed, 372 insertions(+), 71 deletions(-) create mode 100644 lib/workos/pipes/data_integrations_create_api_key_connection_request.rb create mode 100644 lib/workos/pipes/data_integrations_upsert_api_key_request_2.rb create mode 100644 lib/workos/pipes/reauthorize_data_integrations_upsert_api_key_request.rb create mode 100644 lib/workos/types/data_integrations_create_api_key_connection_request_connection_owner.rb create mode 100644 lib/workos/types/data_integrations_upsert_api_key_request_2_connection_owner.rb create mode 100644 lib/workos/types/reauthorize_data_integrations_upsert_api_key_request_connection_owner.rb create mode 100644 rbi/workos/data_integrations_create_api_key_connection_request.rbi create mode 100644 rbi/workos/data_integrations_upsert_api_key_request_2.rbi create mode 100644 rbi/workos/reauthorize_data_integrations_upsert_api_key_request.rbi diff --git a/.last-synced-sha b/.last-synced-sha index 89fbe35a..9b1ca4f2 100644 --- a/.last-synced-sha +++ b/.last-synced-sha @@ -1 +1 @@ -6f037208ce812063908f97744b4aaf4fdf570351 +e8f39fdd452f5ebca8bcdad9b8436f2bfb1d3ed7 diff --git a/.oagen-manifest.json b/.oagen-manifest.json index ade3f514..46869c8d 100644 --- a/.oagen-manifest.json +++ b/.oagen-manifest.json @@ -281,7 +281,9 @@ "lib/workos/pipes/api_key_installation.rb", "lib/workos/pipes/connected_account.rb", "lib/workos/pipes/connected_account_input.rb", + "lib/workos/pipes/create_connected_account.rb", "lib/workos/pipes/create_data_integration.rb", + "lib/workos/pipes/create_organization_connected_account.rb", "lib/workos/pipes/custom_provider_definition.rb", "lib/workos/pipes/data_integration.rb", "lib/workos/pipes/data_integration_access_token_response.rb", @@ -293,14 +295,22 @@ "lib/workos/pipes/data_integration_credentials_response_credential.rb", "lib/workos/pipes/data_integration_custom_provider.rb", "lib/workos/pipes/data_integration_installation.rb", + "lib/workos/pipes/data_integration_vended_credential.rb", + "lib/workos/pipes/data_integrations_create_api_key_connection_request.rb", + "lib/workos/pipes/data_integrations_create_client_credentials_connection_request.rb", "lib/workos/pipes/data_integrations_get_data_integration_authorize_url_request.rb", "lib/workos/pipes/data_integrations_get_user_token_request.rb", "lib/workos/pipes/data_integrations_list_response.rb", "lib/workos/pipes/data_integrations_list_response_data.rb", "lib/workos/pipes/data_integrations_list_response_data_connected_account.rb", "lib/workos/pipes/data_integrations_upsert_api_key_request.rb", + "lib/workos/pipes/data_integrations_upsert_api_key_request_2.rb", "lib/workos/pipes/data_integrations_upsert_client_credentials_request.rb", + "lib/workos/pipes/data_integrations_upsert_client_credentials_request_2.rb", "lib/workos/pipes/data_integrations_vend_credentials_request.rb", + "lib/workos/pipes/organization_connected_account.rb", + "lib/workos/pipes/reauthorize_data_integrations_upsert_api_key_request.rb", + "lib/workos/pipes/reauthorize_data_integrations_upsert_client_credentials_request.rb", "lib/workos/pipes/update_custom_provider_definition.rb", "lib/workos/pipes/update_data_integration.rb", "lib/workos/pipes_provider.rb", @@ -485,10 +495,12 @@ "lib/workos/types/connection_status.rb", "lib/workos/types/connection_type.rb", "lib/workos/types/connections_connection_type.rb", + "lib/workos/types/create_connected_account_state.rb", "lib/workos/types/create_connection_oidc_options_id_token_signature_algorithm.rb", "lib/workos/types/create_connection_oidc_options_token_authentication_method.rb", "lib/workos/types/create_data_integration_auth_methods.rb", "lib/workos/types/create_data_integration_ownership.rb", + "lib/workos/types/create_organization_connected_account_state.rb", "lib/workos/types/create_user_invite_options_locale.rb", "lib/workos/types/create_user_password_hash_type.rb", "lib/workos/types/create_user_password_salt_position.rb", @@ -504,6 +516,8 @@ "lib/workos/types/data_integration_installation_connection_role.rb", "lib/workos/types/data_integration_ownership.rb", "lib/workos/types/data_integration_state.rb", + "lib/workos/types/data_integrations_create_api_key_connection_request_connection_owner.rb", + "lib/workos/types/data_integrations_create_client_credentials_connection_request_connection_owner.rb", "lib/workos/types/data_integrations_get_data_integration_authorize_url_request_connection_owner.rb", "lib/workos/types/data_integrations_get_user_token_request_connection_owner.rb", "lib/workos/types/data_integrations_list_response_data_auth_methods.rb", @@ -512,7 +526,9 @@ "lib/workos/types/data_integrations_list_response_data_connected_account_state.rb", "lib/workos/types/data_integrations_list_response_data_connection_owner.rb", "lib/workos/types/data_integrations_list_response_data_ownership.rb", + "lib/workos/types/data_integrations_upsert_api_key_request_2_connection_owner.rb", "lib/workos/types/data_integrations_upsert_api_key_request_connection_owner.rb", + "lib/workos/types/data_integrations_upsert_client_credentials_request_2_connection_owner.rb", "lib/workos/types/data_integrations_upsert_client_credentials_request_connection_owner.rb", "lib/workos/types/data_integrations_vend_credentials_request_connection_owner.rb", "lib/workos/types/directory_state.rb", @@ -538,6 +554,7 @@ "lib/workos/types/invitation_revoked_data_state.rb", "lib/workos/types/invitation_state.rb", "lib/workos/types/invite_it_contact_intents.rb", + "lib/workos/types/organization_connected_account_state.rb", "lib/workos/types/organization_created_data_domain_state.rb", "lib/workos/types/organization_created_data_domain_verification_strategy.rb", "lib/workos/types/organization_deleted_data_domain_state.rb", @@ -577,6 +594,8 @@ "lib/workos/types/radar_standalone_response_blocklist_type.rb", "lib/workos/types/radar_standalone_response_control.rb", "lib/workos/types/radar_standalone_response_verdict.rb", + "lib/workos/types/reauthorize_data_integrations_upsert_api_key_request_connection_owner.rb", + "lib/workos/types/reauthorize_data_integrations_upsert_client_credentials_request_connection_owner.rb", "lib/workos/types/resend_user_invite_options_locale.rb", "lib/workos/types/resource_export_completed_data_resource_type.rb", "lib/workos/types/resource_export_created_data_resource_type.rb", @@ -1035,6 +1054,7 @@ "rbi/workos/create_authkit_oauth_resource.rbi", "rbi/workos/create_authorization_permission.rbi", "rbi/workos/create_authorization_resource.rbi", + "rbi/workos/create_connected_account.rbi", "rbi/workos/create_connection.rbi", "rbi/workos/create_connection_attribute_maps.rbi", "rbi/workos/create_connection_key_pair.rbi", @@ -1054,6 +1074,7 @@ "rbi/workos/create_oauth_application.rbi", "rbi/workos/create_object_request.rbi", "rbi/workos/create_organization_api_key.rbi", + "rbi/workos/create_organization_connected_account.rbi", "rbi/workos/create_organization_domain.rbi", "rbi/workos/create_organization_role.rbi", "rbi/workos/create_password_reset.rbi", @@ -1082,13 +1103,18 @@ "rbi/workos/data_integration_credentials_response_credential.rbi", "rbi/workos/data_integration_custom_provider.rbi", "rbi/workos/data_integration_installation.rbi", + "rbi/workos/data_integration_vended_credential.rbi", + "rbi/workos/data_integrations_create_api_key_connection_request.rbi", + "rbi/workos/data_integrations_create_client_credentials_connection_request.rbi", "rbi/workos/data_integrations_get_data_integration_authorize_url_request.rbi", "rbi/workos/data_integrations_get_user_token_request.rbi", "rbi/workos/data_integrations_list_response.rbi", "rbi/workos/data_integrations_list_response_data.rbi", "rbi/workos/data_integrations_list_response_data_connected_account.rbi", "rbi/workos/data_integrations_upsert_api_key_request.rbi", + "rbi/workos/data_integrations_upsert_api_key_request_2.rbi", "rbi/workos/data_integrations_upsert_client_credentials_request.rbi", + "rbi/workos/data_integrations_upsert_client_credentials_request_2.rbi", "rbi/workos/data_integrations_vend_credentials_request.rbi", "rbi/workos/decrypt_request.rbi", "rbi/workos/decrypt_response.rbi", @@ -1225,6 +1251,7 @@ "rbi/workos/organization_api_key_with_value.rbi", "rbi/workos/organization_api_key_with_value_owner.rbi", "rbi/workos/organization_authorized_connect_application_list_data.rbi", + "rbi/workos/organization_connected_account.rbi", "rbi/workos/organization_created.rbi", "rbi/workos/organization_created_data.rbi", "rbi/workos/organization_created_data_domain.rbi", @@ -1313,6 +1340,8 @@ "rbi/workos/radar_standalone_response.rbi", "rbi/workos/radar_standalone_update_radar_attempt_request.rbi", "rbi/workos/radar_standalone_update_radar_list_request.rbi", + "rbi/workos/reauthorize_data_integrations_upsert_api_key_request.rbi", + "rbi/workos/reauthorize_data_integrations_upsert_client_credentials_request.rbi", "rbi/workos/redirect_uri.rbi", "rbi/workos/redirect_uri_input.rbi", "rbi/workos/refresh_token_session_authenticate_request.rbi", @@ -2589,6 +2618,14 @@ "GET /audit_logs/exports/{auditLogExportId}": { "sdkMethod": "get_export", "service": "audit_logs" + }, + "POST /data-integrations/{slug}/api-key": { + "sdkMethod": "create_data_integration_api_key", + "service": "pipes" + }, + "POST /data-integrations/{slug}/client-credentials": { + "sdkMethod": "create_data_integration_client_credential", + "service": "pipes" } } } diff --git a/lib/workos/pipes/data_integrations_create_api_key_connection_request.rb b/lib/workos/pipes/data_integrations_create_api_key_connection_request.rb new file mode 100644 index 00000000..f1de4e63 --- /dev/null +++ b/lib/workos/pipes/data_integrations_create_api_key_connection_request.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class DataIntegrationsCreateApiKeyConnectionRequest < WorkOS::Types::BaseModel + HASH_ATTRS = { + user_id: :user_id, + organization_id: :organization_id, + connection_owner: :connection_owner, + secret: :secret, + connection_intent: :connection_intent + }.freeze + + attr_accessor \ + :user_id, + :organization_id, + :connection_owner, + :secret, + :connection_intent + + def initialize(json) + hash = self.class.normalize(json) + @user_id = hash[:user_id] + @organization_id = hash[:organization_id] + @connection_owner = hash[:connection_owner] + @secret = hash[:secret] + @connection_intent = hash[:connection_intent] + end + end +end diff --git a/lib/workos/pipes/data_integrations_upsert_api_key_request.rb b/lib/workos/pipes/data_integrations_upsert_api_key_request.rb index eb5d2d71..8532fb7e 100644 --- a/lib/workos/pipes/data_integrations_upsert_api_key_request.rb +++ b/lib/workos/pipes/data_integrations_upsert_api_key_request.rb @@ -7,7 +7,6 @@ class DataIntegrationsUpsertApiKeyRequest < WorkOS::Types::BaseModel HASH_ATTRS = { user_id: :user_id, organization_id: :organization_id, - connected_account_id: :connected_account_id, connection_owner: :connection_owner, secret: :secret }.freeze @@ -15,7 +14,6 @@ class DataIntegrationsUpsertApiKeyRequest < WorkOS::Types::BaseModel attr_accessor \ :user_id, :organization_id, - :connected_account_id, :connection_owner, :secret @@ -23,7 +21,6 @@ def initialize(json) hash = self.class.normalize(json) @user_id = hash[:user_id] @organization_id = hash[:organization_id] - @connected_account_id = hash[:connected_account_id] @connection_owner = hash[:connection_owner] @secret = hash[:secret] end diff --git a/lib/workos/pipes/data_integrations_upsert_api_key_request_2.rb b/lib/workos/pipes/data_integrations_upsert_api_key_request_2.rb new file mode 100644 index 00000000..8f19c239 --- /dev/null +++ b/lib/workos/pipes/data_integrations_upsert_api_key_request_2.rb @@ -0,0 +1,31 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class DataIntegrationsUpsertApiKeyRequest2 < WorkOS::Types::BaseModel + HASH_ATTRS = { + user_id: :user_id, + organization_id: :organization_id, + connection_owner: :connection_owner, + secret: :secret, + connected_account_id: :connected_account_id + }.freeze + + attr_accessor \ + :user_id, + :organization_id, + :connection_owner, + :secret, + :connected_account_id + + def initialize(json) + hash = self.class.normalize(json) + @user_id = hash[:user_id] + @organization_id = hash[:organization_id] + @connection_owner = hash[:connection_owner] + @secret = hash[:secret] + @connected_account_id = hash[:connected_account_id] + end + end +end diff --git a/lib/workos/pipes/reauthorize_data_integrations_upsert_api_key_request.rb b/lib/workos/pipes/reauthorize_data_integrations_upsert_api_key_request.rb new file mode 100644 index 00000000..8fbed4b9 --- /dev/null +++ b/lib/workos/pipes/reauthorize_data_integrations_upsert_api_key_request.rb @@ -0,0 +1,34 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + class ReauthorizeDataIntegrationsUpsertApiKeyRequest < WorkOS::Types::BaseModel + HASH_ATTRS = { + user_id: :user_id, + organization_id: :organization_id, + connection_owner: :connection_owner, + secret: :secret, + connection_intent: :connection_intent, + connected_account_id: :connected_account_id + }.freeze + + attr_accessor \ + :user_id, + :organization_id, + :connection_owner, + :secret, + :connection_intent, + :connected_account_id + + def initialize(json) + hash = self.class.normalize(json) + @user_id = hash[:user_id] + @organization_id = hash[:organization_id] + @connection_owner = hash[:connection_owner] + @secret = hash[:secret] + @connection_intent = hash[:connection_intent] + @connected_account_id = hash[:connected_account_id] + end + end +end diff --git a/lib/workos/types/data_integrations_create_api_key_connection_request_connection_owner.rb b/lib/workos/types/data_integrations_create_api_key_connection_request_connection_owner.rb new file mode 100644 index 00000000..0aca43c8 --- /dev/null +++ b/lib/workos/types/data_integrations_create_api_key_connection_request_connection_owner.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + DataIntegrationsCreateApiKeyConnectionRequestConnectionOwner = CreateDataIntegrationOwnership + end +end diff --git a/lib/workos/types/data_integrations_upsert_api_key_request_2_connection_owner.rb b/lib/workos/types/data_integrations_upsert_api_key_request_2_connection_owner.rb new file mode 100644 index 00000000..f406ade7 --- /dev/null +++ b/lib/workos/types/data_integrations_upsert_api_key_request_2_connection_owner.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + DataIntegrationsUpsertApiKeyRequest2ConnectionOwner = CreateDataIntegrationOwnership + end +end diff --git a/lib/workos/types/reauthorize_data_integrations_upsert_api_key_request_connection_owner.rb b/lib/workos/types/reauthorize_data_integrations_upsert_api_key_request_connection_owner.rb new file mode 100644 index 00000000..b8ce97a1 --- /dev/null +++ b/lib/workos/types/reauthorize_data_integrations_upsert_api_key_request_connection_owner.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +module WorkOS + module Types + ReauthorizeDataIntegrationsUpsertApiKeyRequestConnectionOwner = CreateDataIntegrationOwnership + end +end diff --git a/rbi/workos/data_integrations_create_api_key_connection_request.rbi b/rbi/workos/data_integrations_create_api_key_connection_request.rbi new file mode 100644 index 00000000..404014f8 --- /dev/null +++ b/rbi/workos/data_integrations_create_api_key_connection_request.rbi @@ -0,0 +1,48 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class DataIntegrationsCreateApiKeyConnectionRequest + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(String) } + def user_id; end + + sig { params(value: String).returns(String) } + def user_id=(value); end + + sig { returns(T.nilable(String)) } + def organization_id; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def organization_id=(value); end + + sig { returns(T.nilable(String)) } + def connection_owner; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def connection_owner=(value); end + + sig { returns(String) } + def secret; end + + sig { params(value: String).returns(String) } + def secret=(value); end + + sig { returns(String) } + def connection_intent; end + + sig { params(value: String).returns(String) } + def connection_intent=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/rbi/workos/data_integrations_upsert_api_key_request.rbi b/rbi/workos/data_integrations_upsert_api_key_request.rbi index b1d54836..655ef767 100644 --- a/rbi/workos/data_integrations_upsert_api_key_request.rbi +++ b/rbi/workos/data_integrations_upsert_api_key_request.rbi @@ -21,12 +21,6 @@ module WorkOS sig { params(value: T.nilable(String)).returns(T.nilable(String)) } def organization_id=(value); end - sig { returns(T.nilable(String)) } - def connected_account_id; end - - sig { params(value: T.nilable(String)).returns(T.nilable(String)) } - def connected_account_id=(value); end - sig { returns(T.nilable(String)) } def connection_owner; end diff --git a/rbi/workos/data_integrations_upsert_api_key_request_2.rbi b/rbi/workos/data_integrations_upsert_api_key_request_2.rbi new file mode 100644 index 00000000..9bf20ff7 --- /dev/null +++ b/rbi/workos/data_integrations_upsert_api_key_request_2.rbi @@ -0,0 +1,48 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class DataIntegrationsUpsertApiKeyRequest2 + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(String) } + def user_id; end + + sig { params(value: String).returns(String) } + def user_id=(value); end + + sig { returns(T.nilable(String)) } + def organization_id; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def organization_id=(value); end + + sig { returns(T.nilable(String)) } + def connection_owner; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def connection_owner=(value); end + + sig { returns(String) } + def secret; end + + sig { params(value: String).returns(String) } + def secret=(value); end + + sig { returns(String) } + def connected_account_id; end + + sig { params(value: String).returns(String) } + def connected_account_id=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/rbi/workos/reauthorize_data_integrations_upsert_api_key_request.rbi b/rbi/workos/reauthorize_data_integrations_upsert_api_key_request.rbi new file mode 100644 index 00000000..1c4f56fd --- /dev/null +++ b/rbi/workos/reauthorize_data_integrations_upsert_api_key_request.rbi @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# This file is auto-generated by oagen. Do not edit. + +# typed: strong + +module WorkOS + class ReauthorizeDataIntegrationsUpsertApiKeyRequest + sig { params(json: T.any(String, T::Hash[Symbol, T.untyped])).void } + def initialize(json); end + + sig { returns(String) } + def user_id; end + + sig { params(value: String).returns(String) } + def user_id=(value); end + + sig { returns(T.nilable(String)) } + def organization_id; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def organization_id=(value); end + + sig { returns(T.nilable(String)) } + def connection_owner; end + + sig { params(value: T.nilable(String)).returns(T.nilable(String)) } + def connection_owner=(value); end + + sig { returns(String) } + def secret; end + + sig { params(value: String).returns(String) } + def secret=(value); end + + sig { returns(String) } + def connection_intent; end + + sig { params(value: String).returns(String) } + def connection_intent=(value); end + + sig { returns(String) } + def connected_account_id; end + + sig { params(value: String).returns(String) } + def connected_account_id=(value); end + + sig { returns(T::Hash[Symbol, T.untyped]) } + def to_h; end + + sig { params(args: T.untyped).returns(String) } + def to_json(*args); end + end +end diff --git a/test/workos/test_shared_model_round_trip.rb b/test/workos/test_shared_model_round_trip.rb index ad62fabd..81e6a6eb 100644 --- a/test/workos/test_shared_model_round_trip.rb +++ b/test/workos/test_shared_model_round_trip.rb @@ -16,39 +16,6 @@ def test_error_response_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end - def test_object_summary_round_trip - fixture = { - "id" => "stub", - "name" => "stub", - "updated_at" => nil - } - model = WorkOS::ObjectSummary.new(fixture.to_json) - json = model.to_h - assert_kind_of Hash, json - assert_equal fixture["id"], json[:id] - assert_equal fixture["name"], json[:name] - fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } - end - - def test_object_version_round_trip - fixture = { - "created_at" => "stub", - "current_version" => true, - "etag" => "stub", - "id" => "stub", - "size" => 1 - } - model = WorkOS::ObjectVersion.new(fixture.to_json) - json = model.to_h - assert_kind_of Hash, json - assert_equal fixture["created_at"], json[:created_at] - assert_equal fixture["current_version"], json[:current_version] - assert_equal fixture["etag"], json[:etag] - assert_equal fixture["id"], json[:id] - assert_equal fixture["size"], json[:size] - fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } - end - def test_connect_application_oauth_round_trip fixture = { "object" => "connect_application", @@ -202,24 +169,6 @@ def test_waitlist_user_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end - def test_event_schema_round_trip - fixture = { - "object" => "event", - "id" => "stub", - "event" => "stub", - "data" => {}, - "created_at" => "stub", - "context" => {} - } - model = WorkOS::EventSchema.new(fixture.to_json) - json = model.to_h - assert_kind_of Hash, json - assert_equal fixture["id"], json[:id] - assert_equal fixture["event"], json[:event] - assert_equal fixture["created_at"], json[:created_at] - fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } - end - def test_agent_blueprint_created_round_trip fixture = { "object" => "event", @@ -1475,27 +1424,78 @@ def test_auth_method_mismatch_error_round_trip fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end - def test_event_list_list_metadata_round_trip + def test_event_context_google_analytics_session_round_trip fixture = { - "after" => nil + "containerId" => "stub", + "sessionId" => "stub", + "sessionNumber" => "stub" } - model = WorkOS::EventListListMetadata.new(fixture.to_json) + model = WorkOS::EventContextGoogleAnalyticsSession.new(fixture.to_json) json = model.to_h assert_kind_of Hash, json - assert_nil json[:after] + assert_equal fixture["containerId"], json[:containerId] fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end - def test_event_context_google_analytics_session_round_trip + def test_object_summary_round_trip fixture = { - "containerId" => "stub", - "sessionId" => "stub", - "sessionNumber" => "stub" + "id" => "stub", + "name" => "stub", + "updated_at" => nil } - model = WorkOS::EventContextGoogleAnalyticsSession.new(fixture.to_json) + model = WorkOS::ObjectSummary.new(fixture.to_json) json = model.to_h assert_kind_of Hash, json - assert_equal fixture["containerId"], json[:containerId] + assert_equal fixture["id"], json[:id] + assert_equal fixture["name"], json[:name] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + + def test_object_version_round_trip + fixture = { + "created_at" => "stub", + "current_version" => true, + "etag" => "stub", + "id" => "stub", + "size" => 1 + } + model = WorkOS::ObjectVersion.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["created_at"], json[:created_at] + assert_equal fixture["current_version"], json[:current_version] + assert_equal fixture["etag"], json[:etag] + assert_equal fixture["id"], json[:id] + assert_equal fixture["size"], json[:size] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + + def test_event_schema_round_trip + fixture = { + "object" => "event", + "id" => "stub", + "event" => "stub", + "data" => {}, + "created_at" => "stub", + "context" => {} + } + model = WorkOS::EventSchema.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_equal fixture["id"], json[:id] + assert_equal fixture["event"], json[:event] + assert_equal fixture["created_at"], json[:created_at] + fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } + end + + def test_event_list_list_metadata_round_trip + fixture = { + "after" => nil + } + model = WorkOS::EventListListMetadata.new(fixture.to_json) + json = model.to_h + assert_kind_of Hash, json + assert_nil json[:after] fixture.each_key { |k| assert json.key?(k.to_sym) || json.key?(k), "Expected to_h to include key #{k}" } end From 2a8ec83ab3c48fb51324965061a2de1743d889f6 Mon Sep 17 00:00:00 2001 From: "workos-sdk-automation[bot]" <255426317+workos-sdk-automation[bot]@users.noreply.github.com> Date: Fri, 25 Sep 2026 17:40:24 +0000 Subject: [PATCH 3/4] chore(generated): add release notes fragment --- ...b0182d195a272be7528ca26c0ca7f936c8f789f.md | 54 +++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 .changelog-pending/2026-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md diff --git a/.changelog-pending/2026-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md b/.changelog-pending/2026-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md new file mode 100644 index 00000000..9270cf26 --- /dev/null +++ b/.changelog-pending/2026-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md @@ -0,0 +1,54 @@ +* [#561](https://github.com/workos/workos-ruby/pull/561) feat(generated)!: regenerate from spec (1 change) + + **⚠️ Breaking** + * **[pipes](https://workos.com/docs/reference/pipes)**: + * Removed model `AddDataIntegrationsUpsertApiKeyRequest` + * Removed model `AddDataIntegrationsUpsertClientCredentialsRequest` + * Removed enum `AddDataIntegrationsUpsertApiKeyRequestConnectionOwner` + * Removed enum `AddDataIntegrationsUpsertClientCredentialsRequestConnectionOwner` + + **Features** + * **[pipes](https://workos.com/docs/reference/pipes)**: + * Added model `DataIntegrationsCreateApiKeyConnectionRequest` + * Added model `DataIntegrationsCreateClientCredentialsConnectionRequest` + * Added enum `DataIntegrationsCreateApiKeyConnectionRequestConnectionOwner` + * Added enum `DataIntegrationsCreateClientCredentialsConnectionRequestConnectionOwner` + * Added endpoint `POST /data-integrations/{slug}/api-key` + * Added endpoint `POST /data-integrations/{slug}/client-credentials` + * Added `config` to `DataIntegrationVendedCredential` + * Added model `DataIntegrationVendedCredential` + * Added model `CreateOrganizationConnectedAccount` + * Added model `CreateConnectedAccount` + * Added model `AddDataIntegrationsUpsertApiKeyRequest` + * Added model `ReauthorizeDataIntegrationsUpsertApiKeyRequest` + * Added model `DataIntegrationsUpsertApiKeyRequest2` + * Added model `AddDataIntegrationsUpsertClientCredentialsRequest` + * Added model `ReauthorizeDataIntegrationsUpsertClientCredentialsRequest` + * Added model `DataIntegrationsUpsertClientCredentialsRequest2` + * Added enum `CreateOrganizationConnectedAccountState` + * Added enum `CreateConnectedAccountState` + * Added enum `AddDataIntegrationsUpsertApiKeyRequestConnectionOwner` + * Added enum `ReauthorizeDataIntegrationsUpsertApiKeyRequestConnectionOwner` + * Added enum `DataIntegrationsUpsertApiKeyRequest2ConnectionOwner` + * Added enum `AddDataIntegrationsUpsertClientCredentialsRequestConnectionOwner` + * Added enum `ReauthorizeDataIntegrationsUpsertClientCredentialsRequestConnectionOwner` + * Added enum `DataIntegrationsUpsertClientCredentialsRequest2ConnectionOwner` + * Added parameter `OrganizationsDataProviders.updateOrganizationDataInstallation.connection_intent` + * Added parameter `UserManagementDataProviders.updateUserDataInstallation.connection_intent` + * Added model `OrganizationConnectedAccount` + * Added enum `OrganizationConnectedAccountState` + + **Fixes** + * **[pipes](https://workos.com/docs/reference/pipes)**: + * Changed request body for `Pipes.upsertApiKey` + * Changed request body for `Pipes.upsertClientCredentials` + * Changed errors for endpoint `POST /organizations/{organization_id}/connected_accounts/{slug}` + * Changed errors for endpoint `POST /user_management/users/{user_id}/connected_accounts/{slug}` + * Changed the type of `DataIntegrationCredentialsResponse.credential` + * Removed `connected_account_id` from `DataIntegrationsUpsertApiKeyRequest` + * Removed `connected_account_id` from `DataIntegrationsUpsertClientCredentialsRequest` + * Changed request body of `OrganizationsDataProviders.createOrganizationDataInstallation` from `OrganizationConnectedAccount` to `CreateOrganizationConnectedAccount` + * Changed request body of `UserManagementDataProviders.createUserDataInstallation` from `ConnectedAccountInput` to `CreateConnectedAccount` + * Changed request body of `OrganizationsDataProviders.createOrganizationDataInstallation` from `ConnectedAccountInput` to `OrganizationConnectedAccount` + * Changed request body of `OrganizationsDataProviders.updateOrganizationDataInstallation` from `ConnectedAccountInput` to `OrganizationConnectedAccount` + * Changed errors for endpoint `PUT /organizations/{organization_id}/connected_accounts/{slug}` From 99b7ac2eb317f109b65660e6284e4574b77fa66f Mon Sep 17 00:00:00 2001 From: Garen Torikian Date: Fri, 25 Sep 2026 18:38:23 -0400 Subject: [PATCH 4/4] chore(generated): drop breaking marker from release notes fragment header --- ...6-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.changelog-pending/2026-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md b/.changelog-pending/2026-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md index 9270cf26..624c679e 100644 --- a/.changelog-pending/2026-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md +++ b/.changelog-pending/2026-09-25T17-40-24-0b0182d195a272be7528ca26c0ca7f936c8f789f.md @@ -1,4 +1,4 @@ -* [#561](https://github.com/workos/workos-ruby/pull/561) feat(generated)!: regenerate from spec (1 change) +* [#561](https://github.com/workos/workos-ruby/pull/561) feat(generated): regenerate from spec (1 change) **⚠️ Breaking** * **[pipes](https://workos.com/docs/reference/pipes)**: