class Io::Flow::V0::Models::StripeAuthenticationDataForm

Used to specify Stripe API secret key.

Attributes

account_id[R]
key[R]
secret_key[R]

Public Class Methods

new(incoming={}) click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 68852
def initialize(incoming={})
  super(:discriminator => GatewayAuthenticationDataForm::Types::STRIPE_AUTHENTICATION_DATA_FORM)
  opts = HttpClient::Helper.symbolize_keys(incoming)
  HttpClient::Preconditions.require_keys(opts, [:account_id, :secret_key], 'StripeAuthenticationDataForm')
  @account_id = HttpClient::Preconditions.assert_class('account_id', opts.delete(:account_id), String)
  @secret_key = HttpClient::Preconditions.assert_class('secret_key', opts.delete(:secret_key), String)
  @key = (x = opts.delete(:key); x.nil? ? nil : HttpClient::Preconditions.assert_class('key', x, String))
end

Public Instance Methods

copy(incoming={}) click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 68865
def copy(incoming={})
  StripeAuthenticationDataForm.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming)))
end
subtype_to_hash() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 68869
def subtype_to_hash
  {
    :account_id => account_id,
    :secret_key => secret_key,
    :key => key
  }
end
to_json() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 68861
def to_json
  JSON.dump(to_hash)
end