1 | <?php |
||
31 | class Vimeo extends AbstractService |
||
32 | { |
||
33 | // API version |
||
34 | const VERSION = '3.2'; |
||
35 | // API Header Accept |
||
36 | const HEADER_ACCEPT = 'application/vnd.vimeo.*+json;version=3.2'; |
||
37 | |||
38 | /** |
||
39 | * Scopes. |
||
40 | * |
||
41 | * @see https://developer.vimeo.com/api/authentication#scope |
||
42 | */ |
||
43 | // View public videos |
||
44 | const SCOPE_PUBLIC = 'public'; |
||
45 | // View private videos |
||
46 | const SCOPE_PRIVATE = 'private'; |
||
47 | // View Vimeo On Demand purchase history |
||
48 | const SCOPE_PURCHASED = 'purchased'; |
||
49 | // Create new videos, groups, albums, etc. |
||
50 | const SCOPE_CREATE = 'create'; |
||
51 | // Edit videos, groups, albums, etc. |
||
52 | const SCOPE_EDIT = 'edit'; |
||
53 | // Delete videos, groups, albums, etc. |
||
54 | const SCOPE_DELETE = 'delete'; |
||
55 | // Interact with a video on behalf of a user, such as liking |
||
56 | // a video or adding it to your watch later queue |
||
57 | const SCOPE_INTERACT = 'interact'; |
||
58 | // Upload a video |
||
59 | const SCOPE_UPLOAD = 'upload'; |
||
60 | |||
61 | public function __construct( |
||
81 | |||
82 | /** |
||
83 | * {@inheritdoc} |
||
84 | */ |
||
85 | public function getAuthorizationEndpoint() |
||
89 | |||
90 | /** |
||
91 | * {@inheritdoc} |
||
92 | */ |
||
93 | public function getAccessTokenEndpoint() |
||
97 | |||
98 | /** |
||
99 | * {@inheritdoc} |
||
100 | */ |
||
101 | protected function getAuthorizationMethod() |
||
105 | |||
106 | /** |
||
107 | * {@inheritdoc} |
||
108 | */ |
||
109 | protected function parseAccessTokenResponse($responseBody) |
||
143 | |||
144 | /** |
||
145 | * {@inheritdoc} |
||
146 | */ |
||
147 | protected function getExtraOAuthHeaders() |
||
151 | |||
152 | /** |
||
153 | * {@inheritdoc} |
||
154 | */ |
||
155 | protected function getExtraApiHeaders() |
||
159 | } |
||
160 |