Last active
February 25, 2016 20:55
-
-
Save fallenhitokiri/7c39106098f7a24230df to your computer and use it in GitHub Desktop.
api blueprint example how to plueprint
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FORMAT: 1A | |
# Foo API | |
API for Foo | |
# Group Foo | |
Foo API | |
## Login [/api/login] | |
Authenticate user and returns api token for use in subsequent requests. | |
### Authenticate user [POST] | |
+ Request (application/json) | |
{ | |
"email":"joe@foo.com", | |
"password":"qq" | |
} | |
+ Header | |
VERSION: "1.0.0" | |
+ Response 200 (application/json) | |
+ Body | |
{ | |
"token": "20fb05c8a42fb346fe578b61296a63e2833ddab1", | |
"user_id": 3456 | |
} | |
+ Response 400 (application/json) | |
Returned when the incorrect email/password is used. | |
+ Body | |
{ | |
"non_field_errors": [ | |
"Unable to log in with provided credentials." | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
line 36 needs to be indented and an empty line needs to be inserted before
section "header" is unknown