Class: WorkOS::CreateDataIntegration
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- WorkOS::CreateDataIntegration
- Defined in:
- lib/workos/pipes/create_data_integration.rb
Constant Summary collapse
- HASH_ATTRS =
{ provider: :provider, description: :description, enabled: :enabled, scopes: :scopes, auth_methods: :auth_methods, credentials: :credentials, api_key: :api_key, custom_provider: :custom_provider }.freeze
Instance Attribute Summary collapse
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#auth_methods ⇒ Object
Returns the value of attribute auth_methods.
-
#credentials ⇒ Object
Returns the value of attribute credentials.
-
#custom_provider ⇒ Object
Returns the value of attribute custom_provider.
-
#description ⇒ Object
Returns the value of attribute description.
-
#enabled ⇒ Object
Returns the value of attribute enabled.
-
#provider ⇒ Object
Returns the value of attribute provider.
-
#scopes ⇒ Object
Returns the value of attribute scopes.
Instance Method Summary collapse
-
#initialize(json) ⇒ CreateDataIntegration
constructor
A new instance of CreateDataIntegration.
Constructor Details
#initialize(json) ⇒ CreateDataIntegration
Returns a new instance of CreateDataIntegration.
28 29 30 31 32 33 34 35 36 37 38 |
# File 'lib/workos/pipes/create_data_integration.rb', line 28 def initialize(json) hash = self.class.normalize(json) @provider = hash[:provider] @description = hash[:description] @enabled = hash[:enabled] @scopes = hash[:scopes] || [] @auth_methods = hash[:auth_methods] || [] @credentials = hash[:credentials] ? WorkOS::DataIntegrationCredentialsInput.new(hash[:credentials]) : nil @api_key = hash[:api_key] ? WorkOS::ApiKeyInstallation.new(hash[:api_key]) : nil @custom_provider = hash[:custom_provider] ? WorkOS::CustomProviderDefinition.new(hash[:custom_provider]) : nil end |
Instance Attribute Details
#api_key ⇒ Object
Returns the value of attribute api_key.
18 19 20 |
# File 'lib/workos/pipes/create_data_integration.rb', line 18 def api_key @api_key end |
#auth_methods ⇒ Object
Returns the value of attribute auth_methods.
18 19 20 |
# File 'lib/workos/pipes/create_data_integration.rb', line 18 def auth_methods @auth_methods end |
#credentials ⇒ Object
Returns the value of attribute credentials.
18 19 20 |
# File 'lib/workos/pipes/create_data_integration.rb', line 18 def credentials @credentials end |
#custom_provider ⇒ Object
Returns the value of attribute custom_provider.
18 19 20 |
# File 'lib/workos/pipes/create_data_integration.rb', line 18 def custom_provider @custom_provider end |
#description ⇒ Object
Returns the value of attribute description.
18 19 20 |
# File 'lib/workos/pipes/create_data_integration.rb', line 18 def description @description end |
#enabled ⇒ Object
Returns the value of attribute enabled.
18 19 20 |
# File 'lib/workos/pipes/create_data_integration.rb', line 18 def enabled @enabled end |
#provider ⇒ Object
Returns the value of attribute provider.
18 19 20 |
# File 'lib/workos/pipes/create_data_integration.rb', line 18 def provider @provider end |
#scopes ⇒ Object
Returns the value of attribute scopes.
18 19 20 |
# File 'lib/workos/pipes/create_data_integration.rb', line 18 def scopes @scopes end |