Class: Updox::Models::PatientMessage

Inherits:
Model
  • Object
show all
Defined in:
lib/updox/models/patient_message.rb

Constant Summary collapse

LIST_ENDPOINT =
'/PatientMessageCountSince'.freeze

Constants inherited from Model

Model::ITEM_TYPE, Model::LIST_NAME, Model::LIST_TYPE

Instance Attribute Summary

Attributes inherited from Model

#updox_status

Class Method Summary collapse

Methods inherited from Model

#as_json, #error_message, from_response, request, #response_code, #response_message, #successful?

Class Method Details

.exists?(patient_id, account_id:) ⇒ Boolean

Returns:

  • (Boolean)


10
11
12
# File 'lib/updox/models/patient_message.rb', line 10

def self.exists?(patient_id, account_id: )
  request(endpoint: LIST_ENDPOINT, body: { patientId: patient_id }, auth: {accountId: }, required_auths: Updox::Models::Auth::AUTH_ACCT).successful?
end

.query(patient_id, account_id:) ⇒ Object



6
7
8
# File 'lib/updox/models/patient_message.rb', line 6

def self.query(patient_id, account_id: )
  request(endpoint: LIST_ENDPOINT, body: { patientId: patient_id }, auth: {accountId: }, required_auths: Updox::Models::Auth::AUTH_ACCT)
end