summaryrefslogtreecommitdiffstats
path: root/examples/transmission/get_all_transmissions.php
diff options
context:
space:
mode:
authornornholdj <nornholdj@gmail.com>2014-10-31 15:10:06 -0400
committernornholdj <nornholdj@gmail.com>2014-10-31 15:10:06 -0400
commit68a7e8ec33f205a71107d924e0d244f5edac97a6 (patch)
tree7e47e9d41a8a3304e32eb0da6219c523f3e9c126 /examples/transmission/get_all_transmissions.php
parentde407ac8bf029e85278eaeb683e6f86c6a11c097 (diff)
downloadphp-sparkpost-68a7e8ec33f205a71107d924e0d244f5edac97a6.zip
php-sparkpost-68a7e8ec33f205a71107d924e0d244f5edac97a6.tar.gz
php-sparkpost-68a7e8ec33f205a71107d924e0d244f5edac97a6.tar.bz2
MA-946 #time 3h 30m Revamped Transmission object to be stateless,
updated tests and examples.
Diffstat (limited to 'examples/transmission/get_all_transmissions.php')
-rw-r--r--examples/transmission/get_all_transmissions.php11
1 files changed, 5 insertions, 6 deletions
diff --git a/examples/transmission/get_all_transmissions.php b/examples/transmission/get_all_transmissions.php
index 9ffc2fd..1425e65 100644
--- a/examples/transmission/get_all_transmissions.php
+++ b/examples/transmission/get_all_transmissions.php
@@ -2,15 +2,14 @@
namespace Examples\Transmisson;
require_once (dirname(__FILE__).'/../bootstrap.php');
- use SparkPost\SparkPost;
+ use MessageSystems\SparkPost;
+ use MessageSystems\Transmission;
- $key = 'YOURAPIKEY';
- $sdk = new SparkPost(['key'=>$key]);
-
- $transmission = $sdk->Transmission();
+ $key = 'YOURAPIKEY';
+ SparkPost::setConfig(['key'=>$key]);
try {
- $results = $transmission->all();
+ $results = Transmission::all();
echo 'Congrats you can use your SDK!';
} catch (\Exception $exception) {
echo $exception->getMessage();