Recommendation
View Recommendation
Once the consultation is fulfilled and the recommendation is done by the doctor, the recommendation data will be available and included in the Consultation object.
Using getConsultationInfo with the id, you can view the recommendation data.
{
"id": 123,
"user_id": 999999999,
"question": "I want to consult a doctor on ...",
"medium": "chat",
"status": "closed",
"is_fulfilled": 1,
"recommendation": {
"id": 1,
"consultation_id": 123,
"created_at": "2023-12-01 10:00:00",
"data": {
"lab": {
"lab": [
{ "name": "Complete Blood Count (CBC)" }
]
},
"drug": {
"fdaDrug": [
{
"name": "Paracetamol",
"dosage": "500mg",
"duration": 5,
"howToUse": "after food",
"frequency": "three times a day",
"tradeName": "Adol",
"dosageForm": "tablet",
"dosageUnit": "mg",
"packageSize": "20 tablets",
"packageType": "box",
"strengthValue": "500",
"relationWithFood": "after",
"specialInstructions": "drink plenty of water",
"routeOfAdministration": "oral"
}
]
},
"icd10": {
"symptom": [
{
"code": "R05",
"name": "Cough"
}
],
"diagnosis": [
{
"code": "J06.9",
"name": "Acute upper respiratory infection, unspecified"
}
]
},
"followUp": [
{ "name": "Visit a clinic if symptoms persist" }
],
"doctorReferral": {
"name": "ENT Specialist"
},
"postCallAnswer": [
{
"answer": "Yes",
"question": "Did you find the session helpful?"
}
]
}
}
}
Download Prescription
You can get the prescription by using getPrescription with the id for the consultation.
Check the code below:
import AltibbiTelehealth
import PDFKit
var pdfView: PDFView!
let consultationId = 123
ApiService.getPrescription(id: consultationId, completion: {pathUrl, failure, error in
if let error = error {
print("Data Error: \(String(describing: error))")
} else if let failure = failure {
// Handle failure
} else {
if let pathUrl = pathUrl {
self.pdfView = PDFView(frame: self.view.bounds)
self.view.addSubview(self.pdfView)
if let pdfDocument = PDFDocument(url: pathUrl) {
self.pdfView.document = pdfDocument
}
}
}
})