@@ -42,18 +42,18 @@ public function save(): void
4242 $ params = ['subject ' => $ this ->subject , 'content ' => $ this ->content ];
4343 if ($ this ->id === null ) {
4444 // Create new
45- $ result = $ this ->call ('POST ' , '' , $ params , updateSelf: true );
45+ $ result = $ this ->call ('POST ' , 'job/ ' , $ params , updateSelf: true );
4646 } else {
4747 // Update
48- $ result = $ this ->call ('PUT ' , (string ) $ this ->id , $ params );
48+ $ result = $ this ->call ('PUT ' , ' job/ ' . (string ) $ this ->id , $ params );
4949 }
5050 }
5151
5252 public function start (array $ list )
5353 {
5454 $ parameters = ['recipients ' => $ list ];
5555
56- return $ this ->call (method: 'POST ' , endPoint: $ this ->id .'/start ' , params: $ parameters , updateSelf: true );
56+ return $ this ->call (method: 'POST ' , endPoint: ' job/ ' . $ this ->id .'/start ' , params: $ parameters , updateSelf: true );
5757 }
5858
5959 public function result (string $ sort = null , int $ page = 1 , string $ direction = 'desc ' , string $ query = null ): object
@@ -70,15 +70,15 @@ public function result(string $sort = null, int $page = 1, string $direction = '
7070 }
7171
7272 return $ this ->call (
73- endPoint: $ this ->id .'/result ' ,
73+ endPoint: ' job/ ' . $ this ->id .'/result ' ,
7474 params: $ params ,
7575 updateSelf: true
7676 );
7777 }
7878
7979 public function status (): ?JobStatus
8080 {
81- $ status = $ this ->call (endPoint: $ this ->id .'/status ' , updateSelf: true );
81+ $ status = $ this ->call (endPoint: ' job/ ' . $ this ->id .'/status ' , updateSelf: true );
8282
8383 $ this ->statusInfo = $ status ;
8484
@@ -101,7 +101,7 @@ public function preview(string $email, array $params = []): bool
101101 }
102102 $ params = ['recipient ' => $ email , 'parameters ' => (object ) $ params ];
103103
104- $ this ->call ('POST ' , $ this ->id .'/preview ' , $ params , updateSelf: true );
104+ $ this ->call ('POST ' , ' job/ ' . $ this ->id .'/preview ' , $ params , updateSelf: true );
105105
106106 return true ;
107107 }
0 commit comments