Skip to content
This repository was archived by the owner on Oct 6, 2020. It is now read-only.

Commit 14420be

Browse files
committed
Merge pull request #20 from hannesvdvreken/master
Added configuration for Misfit provider
2 parents c62575d + c3e2a28 commit 14420be

File tree

1 file changed

+53
-0
lines changed

1 file changed

+53
-0
lines changed

src/OAuth2/Provider/Misfit.php

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
<?php
2+
3+
namespace OAuth2\Provider;
4+
5+
use OAuth2\Provider;
6+
use OAuth2\Token_Access;
7+
8+
/*
9+
* Misfit API credentials: https://build.misfit.com/apps
10+
* Misfit API docs: https://build.misfit.com/docs
11+
*/
12+
13+
14+
/**
15+
* Misfit OAuth Provider
16+
*
17+
* @package laravel-oauth2
18+
* @category Provider
19+
* @author Hannes Van De Vreken
20+
*/
21+
22+
class Misfit extends Provider {
23+
/**
24+
* @var string provider name
25+
*/
26+
public $name = 'misfit';
27+
28+
/**
29+
* @var string the method to use when requesting tokens
30+
*/
31+
protected $method = 'POST';
32+
33+
/**
34+
* Returns the authorization URL for the provider.
35+
*
36+
* @return string
37+
*/
38+
public function url_authorize()
39+
{
40+
return 'https://api.misfitwearables.com/auth/dialog/authorize';
41+
}
42+
43+
/**
44+
* Returns the access token endpoint for the provider.
45+
*
46+
* @return string
47+
*/
48+
public function url_access_token()
49+
{
50+
return 'https://api.misfitwearables.com/auth/tokens/exchange';
51+
}
52+
}
53+

0 commit comments

Comments
 (0)