1 | <?php namespace Stevenmaguire\Uber\Resources; |
||
3 | trait Reminders |
||
4 | { |
||
5 | /** |
||
6 | * Cancels a specific reminder. |
||
7 | * |
||
8 | * The Reminders endpoint allows you to remove any reminder in the pending |
||
9 | * state from being sent. |
||
10 | * |
||
11 | * @param string $reminderId Reminder id |
||
12 | * |
||
13 | * @return stdClass The JSON response from the request |
||
14 | * |
||
15 | * @see https://developer.uber.com/docs/riders/references/api/v1.2/reminders-reminder_id-delete |
||
16 | */ |
||
17 | 2 | public function cancelReminder($reminderId) |
|
21 | |||
22 | /** |
||
23 | * Creates a new reminder. |
||
24 | * |
||
25 | * The Reminders endpoint allows developers to set a reminder for a future |
||
26 | * trip. |
||
27 | * |
||
28 | * @param array $attributes Query attributes |
||
29 | * |
||
30 | * @return stdClass The JSON response from the request |
||
31 | * |
||
32 | * @see https://developer.uber.com/docs/riders/references/api/v1.2/reminders-post |
||
33 | */ |
||
34 | 2 | public function createReminder($attributes) |
|
38 | |||
39 | /** |
||
40 | * Fetches a specific reminder. |
||
41 | * |
||
42 | * The Reminders endpoint allows you to get the status of an existing ride |
||
43 | * reminder. |
||
44 | * |
||
45 | * @param string $reminderId Reminder id |
||
46 | * |
||
47 | * @return stdClass The JSON response from the request |
||
48 | * |
||
49 | * @see https://developer.uber.com/docs/riders/references/api/v1.2/reminders-reminder_id-get |
||
50 | */ |
||
51 | 2 | public function getReminder($reminderId) |
|
55 | |||
56 | /** |
||
57 | * Makes a request to the Uber API and returns the response. |
||
58 | * |
||
59 | * @param string $verb The Http verb to use |
||
60 | * @param string $path The path of the APi after the domain |
||
61 | * @param array $parameters Parameters |
||
62 | * |
||
63 | * @return stdClass The JSON response from the request |
||
64 | * @throws Exception |
||
65 | */ |
||
66 | abstract protected function request($verb, $path, $parameters = []); |
||
67 | |||
68 | /** |
||
69 | * Updates a specific reminder. |
||
70 | * |
||
71 | * The Reminders endpoint allows you to update an existing reminder. |
||
72 | * |
||
73 | * @param string $reminderId Reminder id |
||
74 | * @param array $attributes Query attributes |
||
75 | * |
||
76 | * @return stdClass The JSON response from the request |
||
77 | * |
||
78 | * @see https://developer.uber.com/docs/riders/references/api/v1.2/reminders-reminder_id-patch |
||
79 | */ |
||
80 | 2 | public function setReminder($reminderId, $attributes = []) |
|
84 | } |
||
85 |