Skip to content

Commit

Permalink
Merge pull request #32 from Leosten/feature/53902-2
Browse files Browse the repository at this point in the history
[Feature/53902] Ajout de la route recherche de messages sur proxy
  • Loading branch information
Guillaume Dubost authored Oct 4, 2017
2 parents 181eb41 + 6800144 commit a73ffa6
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/MessageManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,15 @@ public function getConversationMessages($conversation_id)
return $response;
}

public function searchMessages($query, $from = 0, $size = 10, $sort = "")
{
$query = urlencode($query);

$response = $this->fireRequest("GET", "/search_messages?q={$query}&from={$from}&size={$size}&sort={$sort}");

return $response;
}

private function fireRequest($method, $uri, $body = [])
{
$method = strtoupper($method);
Expand Down

0 comments on commit a73ffa6

Please sign in to comment.