1 | <?php |
||
23 | class Todoist extends AbstractService |
||
24 | { |
||
25 | /** |
||
26 | * Defined scopes, see https://developer.todoist.com/#oauth for definitions. |
||
27 | */ |
||
28 | |||
29 | /** |
||
30 | * Grants permission to add tasks to the Inbox project (The application cannot read tasks data). |
||
31 | */ |
||
32 | const SCOPE_TASK_ADD = 'task:add'; |
||
33 | |||
34 | /** |
||
35 | * Grants read-only access to application data, including tasks, projects, labels, and filters. |
||
36 | */ |
||
37 | const SCOPE_DATA_READ = 'data:read'; |
||
38 | |||
39 | /** |
||
40 | * Grants read and write access to application data, including tasks, projects, labels, and filters. |
||
41 | * |
||
42 | * This scope includes task:add and data:read scopes. |
||
43 | */ |
||
44 | const SCOPE_DATA_READ_WRITE = 'data:read_write'; |
||
45 | |||
46 | /** |
||
47 | * Grants permission to delete application data, including tasks, labels, and filters. |
||
48 | */ |
||
49 | const SCOPE_DATA_DELETE = 'data:delete'; |
||
50 | |||
51 | /** |
||
52 | * Grants permission to delete projects. |
||
53 | */ |
||
54 | const SCOPE_PROJECT_DELETE = 'project:delete'; |
||
55 | |||
56 | |||
57 | public function __construct( |
||
71 | |||
72 | /** |
||
73 | * {@inheritdoc} |
||
74 | */ |
||
75 | public function getAuthorizationEndpoint() |
||
79 | |||
80 | /** |
||
81 | * {@inheritdoc} |
||
82 | */ |
||
83 | public function getAccessTokenEndpoint() |
||
87 | |||
88 | /** |
||
89 | * {@inheritdoc} |
||
90 | */ |
||
91 | protected function getAuthorizationMethod() |
||
95 | |||
96 | /** |
||
97 | * {@inheritdoc} |
||
98 | */ |
||
99 | protected function parseAccessTokenResponse($responseBody) |
||
119 | |||
120 | /** |
||
121 | * {@inheritdoc} |
||
122 | */ |
||
123 | protected function getScopesDelimiter() |
||
127 | } |
||
128 |