Class: Io::Flow::V0::Clients::EmailVerifications
- Inherits:
-
Object
- Object
- Io::Flow::V0::Clients::EmailVerifications
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Method Summary collapse
-
#initialize(client) ⇒ EmailVerifications
constructor
A new instance of EmailVerifications.
- #post_by_token(token, hash) ⇒ Object
Constructor Details
#initialize(client) ⇒ EmailVerifications
Returns a new instance of EmailVerifications.
3810 3811 3812 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 3810 def initialize(client) @client = HttpClient::Preconditions.assert_class('client', client, ::Io::Flow::V0::Client) end |
Instance Method Details
#post_by_token(token, hash) ⇒ Object
3814 3815 3816 3817 3818 3819 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 3814 def post_by_token(token, hash) HttpClient::Preconditions.assert_class('token', token, String) HttpClient::Preconditions.assert_class('hash', hash, Hash) r = @client.request("/users/emails/verifications/#{CGI.escape(token)}").with_json(hash.to_json).post ::Io::Flow::V0::Models::EmailVerification.new(r) end |