Sha256: b4e5e21113255d6958b466a21d21760645643c43081fcd52822aa3cf14c2df0a

Contents?: true

Size: 815 Bytes

Versions: 2

Compression:

Stored size: 815 Bytes

Contents

# frozen_string_literal: true

module Seam
  module Clients
    class ConnectedAccounts < BaseClient
      def get(connected_account_id_or_params)
        params = if connected_account_id_or_params.is_a?(String)
                   { connected_account_id: connected_account_id_or_params }
                 else
                   connected_account_id_or_params
                 end

        request_seam_object(
          :get,
          "/connected_accounts/get",
          Seam::ConnectedAccount,
          "connected_account",
          params: params
        )
      end

      def list(params = {})
        request_seam_object(
          :get,
          "/connected_accounts/list",
          Seam::ConnectedAccount,
          "connected_accounts",
          params: params
        )
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
seamapi-0.1.0 lib/seam/clients/connected_accounts.rb
seamapi-0.0.5 lib/seam/clients/connected_accounts.rb