-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathapiary.apib
66 lines (44 loc) · 1.43 KB
/
apiary.apib
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
FORMAT: 1A
HOST: http://polls.apiblueprint.org/
# btc-app-server
Manage your account and interact with the Bicycle Touring Companion.
## Account Management [/register]
### Initiate Account Creation [POST]
You may create your own account at this endpoint. It takes a JSON
object containing all your standard account details. Once you request an
account, we'll send you an email containing a verification token.
+ Request (application/json)
{
"email": "[email protected]",
"password": "12345678",
"first": "john",
"last": "doe",
"username": "johndoe"
}
+ Response 200 (application/json)
+ Response 400 (application/json)
{
"error": "something went wrong!"
}
## Account Management: Verification [/register/{token}]
Respond here with the token we send to your email address.
+ Parameters
+ token (string) - The JWT we sent to your email address
### Verify Email [GET]
+ Response 200 (text/html)
+ Response 400 (text/html)
## Authenticate [/authenticate]
### Retrieve an API token [POST]
+ Request
{
"email": "[email protected]",
"password": "123456"
}
+ Response 200 (applicaiton/json)
{
"auth_token": "header.payload.signature"
}
+ Response 400 (application/json)
{
"error": "something went wrong!"
}