1 | <?php |
||
19 | class JawboneUP extends AbstractService |
||
20 | { |
||
21 | /** |
||
22 | * Defined scopes |
||
23 | * |
||
24 | * |
||
25 | * @link https://jawbone.com/up/developer/authentication |
||
26 | */ |
||
27 | // general information scopes |
||
28 | const SCOPE_BASIC_READ = 'basic_read'; |
||
29 | const SCOPE_EXTENDED_READ = 'extended_read'; |
||
30 | const SCOPE_LOCATION_READ = 'location_read'; |
||
31 | const SCOPE_FRIENDS_READ = 'friends_read'; |
||
32 | // mood scopes |
||
33 | const SCOPE_MOOD_READ = 'mood_read'; |
||
34 | const SCOPE_MOOD_WRITE = 'mood_write'; |
||
35 | // move scopes |
||
36 | const SCOPE_MOVE_READ = 'move_read'; |
||
37 | const SCOPE_MOVE_WRITE = 'move_write'; |
||
38 | // sleep scopes |
||
39 | const SCOPE_SLEEP_READ = 'sleep_read'; |
||
40 | const SCOPE_SLEEP_WRITE = 'sleep_write'; |
||
41 | // meal scopes |
||
42 | const SCOPE_MEAL_READ = 'meal_read'; |
||
43 | const SCOPE_MEAL_WRITE = 'meal_write'; |
||
44 | // weight scopes |
||
45 | const SCOPE_WEIGHT_READ = 'weight_read'; |
||
46 | const SCOPE_WEIGHT_WRITE = 'weight_write'; |
||
47 | // generic event scopes |
||
48 | const SCOPE_GENERIC_EVENT_READ = 'generic_event_read'; |
||
49 | const SCOPE_GENERIC_EVENT_WRITE = 'generic_event_write'; |
||
50 | |||
51 | |||
52 | public function __construct( |
||
65 | |||
66 | /** |
||
67 | * {@inheritdoc} |
||
68 | */ |
||
69 | public function getAuthorizationUri(array $additionalParameters = array()) |
||
90 | |||
91 | /** |
||
92 | * {@inheritdoc} |
||
93 | */ |
||
94 | public function getAuthorizationEndpoint() |
||
98 | |||
99 | /** |
||
100 | * {@inheritdoc} |
||
101 | */ |
||
102 | public function getAccessTokenEndpoint() |
||
106 | |||
107 | /** |
||
108 | * {@inheritdoc} |
||
109 | */ |
||
110 | protected function getAuthorizationMethod() |
||
114 | |||
115 | /** |
||
116 | * {@inheritdoc} |
||
117 | */ |
||
118 | protected function parseAccessTokenResponse($responseBody) |
||
144 | } |
||
145 |