diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/SparkPost/APIResource.php | 5 | ||||
-rw-r--r-- | lib/SparkPost/MessageEvent.php | 11 |
2 files changed, 16 insertions, 0 deletions
diff --git a/lib/SparkPost/APIResource.php b/lib/SparkPost/APIResource.php index 20e7b19..d0b8a5b 100644 --- a/lib/SparkPost/APIResource.php +++ b/lib/SparkPost/APIResource.php @@ -112,6 +112,11 @@ class APIResource { * @return array Result of the request */ public function get( $resourcePath=null, Array $query=[] ) { + foreach($query as $element) { + if(is_array($element)) { + + } + } return $this->callResource( 'get', $resourcePath, ['query'=>$query] ); } diff --git a/lib/SparkPost/MessageEvent.php b/lib/SparkPost/MessageEvent.php new file mode 100644 index 0000000..a0ab16e --- /dev/null +++ b/lib/SparkPost/MessageEvent.php @@ -0,0 +1,11 @@ +<?php +namespace SparkPost; + + +class MessageEvent extends APIResource { + public $endpoint = 'message-events'; + + public function search(Array $queryParams) { + return $this->get(null, $queryParams); + } +}
\ No newline at end of file |