Method: Simplify::DataToken.create
- Defined in:
- lib/simplify/datatoken.rb
.create(parms, *auth) ⇒ Object
Creates an DataToken object
- parms
a hash of parameters; valid keys are:
- auth
Authentication information used for the API call. If no value is passed the global keys Simplify::public_key and Simplify::private_key are used. For backwards compatibility the public and private keys may be passed instead of the authentication object.
Returns a DataToken object.
65 66 67 68 69 70 71 72 73 |
# File 'lib/simplify/datatoken.rb', line 65 def self.create(parms, *auth) auth_obj = Simplify::PaymentsApi.create_auth_object(auth) h = Simplify::PaymentsApi.execute("dataToken", 'create', parms, auth_obj) obj = DataToken.new() obj.authentication = auth_obj obj = obj.merge!(h) obj end |