Class: ThePlaidApi::ExtendedRecipientMetadata
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- ThePlaidApi::ExtendedRecipientMetadata
- Defined in:
- lib/the_plaid_api/models/extended_recipient_metadata.rb
Overview
Plaid and FDX-defined recipient metadata fields
Instance Attribute Summary collapse
-
#category ⇒ String
The category that the recipient falls under.
-
#client_name ⇒ String
The recipient name displayed by the Data Provider during the consent flow.
-
#connection_count ⇒ Integer
The number of Data Partner consumers that are connected to the recipient for the specific Data Partner.
-
#joined_date ⇒ Date
The date at which the recipient gained production access to Plaid.
-
#logo_uri ⇒ String
Data Recipient Logo URL location.
-
#recipient_id ⇒ String
The recipient identifier.
-
#third_party_legal_name ⇒ String
The legal name of the recipient.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(recipient_id:, client_name:, third_party_legal_name:, category:, joined_date:, connection_count:, logo_uri: SKIP, additional_properties: nil) ⇒ ExtendedRecipientMetadata
constructor
A new instance of ExtendedRecipientMetadata.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(recipient_id:, client_name:, third_party_legal_name:, category:, joined_date:, connection_count:, logo_uri: SKIP, additional_properties: nil) ⇒ ExtendedRecipientMetadata
Returns a new instance of ExtendedRecipientMetadata.
68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 68 def initialize(recipient_id:, client_name:, third_party_legal_name:, category:, joined_date:, connection_count:, logo_uri: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @recipient_id = recipient_id @client_name = client_name @logo_uri = logo_uri unless logo_uri == SKIP @third_party_legal_name = third_party_legal_name @category = category @joined_date = joined_date @connection_count = connection_count @additional_properties = additional_properties end |
Instance Attribute Details
#category ⇒ String
The category that the recipient falls under
30 31 32 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 30 def category @category end |
#client_name ⇒ String
The recipient name displayed by the Data Provider during the consent flow
18 19 20 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 18 def client_name @client_name end |
#connection_count ⇒ Integer
The number of Data Partner consumers that are connected to the recipient for the specific Data Partner
39 40 41 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 39 def connection_count @connection_count end |
#joined_date ⇒ Date
The date at which the recipient gained production access to Plaid
34 35 36 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 34 def joined_date @joined_date end |
#logo_uri ⇒ String
Data Recipient Logo URL location
22 23 24 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 22 def logo_uri @logo_uri end |
#recipient_id ⇒ String
The recipient identifier
14 15 16 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 14 def recipient_id @recipient_id end |
#third_party_legal_name ⇒ String
The legal name of the recipient
26 27 28 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 26 def third_party_legal_name @third_party_legal_name end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 85 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. recipient_id = hash.key?('recipient_id') ? hash['recipient_id'] : nil client_name = hash.key?('client_name') ? hash['client_name'] : nil third_party_legal_name = hash.key?('third_party_legal_name') ? hash['third_party_legal_name'] : nil category = hash.key?('category') ? hash['category'] : nil joined_date = hash.key?('joined_date') ? hash['joined_date'] : nil connection_count = hash.key?('connection_count') ? hash['connection_count'] : nil logo_uri = hash.key?('logo_uri') ? hash['logo_uri'] : SKIP # Create a new hash for additional properties, removing known properties. new_hash = hash.reject { |k, _| names.value?(k) } additional_properties = APIHelper.get_additional_properties( new_hash, proc { |value| value } ) # Create object from extracted values. ExtendedRecipientMetadata.new(recipient_id: recipient_id, client_name: client_name, third_party_legal_name: third_party_legal_name, category: category, joined_date: joined_date, connection_count: connection_count, logo_uri: logo_uri, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 42 def self.names @_hash = {} if @_hash.nil? @_hash['recipient_id'] = 'recipient_id' @_hash['client_name'] = 'client_name' @_hash['logo_uri'] = 'logo_uri' @_hash['third_party_legal_name'] = 'third_party_legal_name' @_hash['category'] = 'category' @_hash['joined_date'] = 'joined_date' @_hash['connection_count'] = 'connection_count' @_hash end |
.nullables ⇒ Object
An array for nullable fields
62 63 64 65 66 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 62 def self.nullables %w[ logo_uri ] end |
.optionals ⇒ Object
An array for optional fields
55 56 57 58 59 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 55 def self.optionals %w[ logo_uri ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
127 128 129 130 131 132 133 134 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 127 def inspect class_name = self.class.name.split('::').last "<#{class_name} recipient_id: #{@recipient_id.inspect}, client_name:"\ " #{@client_name.inspect}, logo_uri: #{@logo_uri.inspect}, third_party_legal_name:"\ " #{@third_party_legal_name.inspect}, category: #{@category.inspect}, joined_date:"\ " #{@joined_date.inspect}, connection_count: #{@connection_count.inspect},"\ " additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
118 119 120 121 122 123 124 |
# File 'lib/the_plaid_api/models/extended_recipient_metadata.rb', line 118 def to_s class_name = self.class.name.split('::').last "<#{class_name} recipient_id: #{@recipient_id}, client_name: #{@client_name}, logo_uri:"\ " #{@logo_uri}, third_party_legal_name: #{@third_party_legal_name}, category: #{@category},"\ " joined_date: #{@joined_date}, connection_count: #{@connection_count},"\ " additional_properties: #{@additional_properties}>" end |