diff --git a/src/Resources/Mailbox.php b/src/Resources/Mailbox.php index 8cdaaa3..6e7a544 100644 --- a/src/Resources/Mailbox.php +++ b/src/Resources/Mailbox.php @@ -18,6 +18,30 @@ public function find($id) return $this->request->get('mailThreads/:id', compact('id')); } + /** + * Delete Mail threads by ID. + * + * @param $id Mail threads ID to delete. + * @return Response + */ + public function delete($id) + { + return $this->request->delete('mailThreads/:id', compact('id')); + } + + /** + * Update Mail threads by ID. + * + * @param $id + * @param array $values + * @return Response + */ + public function update($id, array $values) + { + $values['id'] = $id; + return $this->request->put('mailThreads/:id', $values); + } + /** * Get list of mail threads * @@ -25,7 +49,7 @@ public function find($id) * @param array $options * @return Response */ - public function mailThreads($folder, $options = []) + public function mailThreads($folder, array $options = []) { $options['folder'] = $folder; @@ -38,8 +62,9 @@ public function mailThreads($folder, $options = []) * @param $id Mail threads ID to find messages. * @return Response */ - public function mailMessages($id) + public function mailMessages($id, $params=[]) { - return $this->request->get('mailThreads/:id/mailMessages', compact('id')); + $params['id'] = $id; + return $this->request->get('mailThreads/:id/mailMessages', $params); } } \ No newline at end of file