lib/tokyo_api/identity.rb in tokyo_api-0.6.1 vs lib/tokyo_api/identity.rb in tokyo_api-1.0.1

- old
+ new

@@ -3,13 +3,18 @@ def base_path 'identity' end def full_user(id) - client.get_request("#{normalized_base_path}full_user/#{id}").body + client.get_request("#{normalized_base_path}full_user/#{url_escape(id)}").body end - def tokyo_identity_user_path(id, phone_required) - "/#{normalized_base_path}user/#{id}?phone_required=#{phone_required}" + def tokyo_identity_user_path(id, required_fields: nil) + path = "/#{normalized_base_path}user/#{url_escape(id)}" + + unless required_fields.nil? + path << "?#{required_fields_param(required_fields)}" + end + path end end end