Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
appointment_plus / lib / appointment_plus / client / appointments.rb
Size: Mime:
module AppointmentPlus
  class Client
    module Appointments

      # NOTE: appointments requires date range parameters to be passed in the below datetime format:
      # {start_date: yyyymmdd, end_date: yyyymmdd}
      # Without these parameters, appointments will return only the most recent appointment
      # Default response_type is json
      def appointments(params = {})
        params[:response_type] = 'json'
        query_string = generate_query_string(params)
        response = post("Appointments/GetAppointments#{query_string}", params)
      end

      def appointment(appt_id, params = {})
        params[:response_type] = 'json'
        params[:appointment] = "#{appt_id}"
        query_string = generate_query_string(params)
        response = post("Appointments/GetAppointments#{query_string}", params)
      end

    end
  end
end