//// GET: api/Message/5
 public List<Message> Get(string id)
 {
     MessageData messages = new MessageData();
     List<Message> messageList = new List<Message>();
     messageList = messages.CheckMessages(id);
     return messageList;
 }
        // POST: api/Message
        public void Post([FromBody]List<Message> messageList)
        {
            MessageData messageData = new MessageData();

            for (int i = 0; i < messageList.Count; i++)
            {
                messageData.AddMessage(messageList[i]);
            }
        }
        // DELETE: api/Message/5
        public IHttpActionResult Delete(int id)
        {
            OperationResult operationResult = new OperationResult();
            MessageData messageData = new MessageData();
            operationResult = messageData.RemoveMessage(id.ToString());

            if (operationResult.Success)
            {
                return Ok();
            }
            else
            {
                return BadRequest(operationResult.ErrorMessage);
            }
        }
 // GET: api/MessagesPatient
 public IEnumerable<Message> Get(string uniqueId)
 {
     MessageData messages = new MessageData();
     List<Message> Message = new List<Message>();
     return messages.GetPatientMessages(uniqueId);
 }
 // GET: api/MessagesToOffice
 public IEnumerable<Message> Get()
 {
     MessageData messages = new MessageData();
     List<Message> Message = new List<Message>();
     return messages.GetMessagesSentToOffice();
 }
 // POST: api/ReplyToNote
 public void Post([FromBody]Message replyMessage)
 {
     MessageData messages = new MessageData();
     messages.AddMessage(replyMessage);
 }