Skip to content

Commit

Permalink
Merge 8f8fce7 into 1248009
Browse files Browse the repository at this point in the history
  • Loading branch information
allebd committed Jul 30, 2019
2 parents 1248009 + 8f8fce7 commit 263ff20
Show file tree
Hide file tree
Showing 18 changed files with 583 additions and 118 deletions.
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

# Authors Haven - A Social platform for the creative at heart.


# Team Dahlia

## Vision
Expand Down
67 changes: 61 additions & 6 deletions docs/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ tags:
- name: Users
description: Operations available for user endpoints

security:
- ApiKeyAuth: []
paths:
/users:
post:
tags:
- Users
summary: Creates a new user
summary: Creates a new user.
security:
- ApiKeyAuth: []
requestBody:
description: fields containing user data
content:
Expand Down Expand Up @@ -84,7 +84,7 @@ paths:
type: string
responses:
200:
description: succesful request
description: successful request
content:
application/json:
schema:
Expand All @@ -101,6 +101,41 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/StandardServerResponse'
description: internal server error
'/profiles/{username}':
get:
summary: View a user profile.
parameters:
- name: username
in: path
required: true
schema:
type: string
example: 'greensprings'
responses:
200:
description: profile details of user
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/Profile'
404:
description: username not found
content:
application/json:
schema:
type: object
properties:
error:
type: object
properties:
message:
type: string
example: 'user not found'


components:
schemas:
User:
Expand Down Expand Up @@ -164,7 +199,7 @@ components:
username:
type: string
bio:
type: string
type: string
ForgotPasswordUser:
required:
- email
Expand All @@ -181,7 +216,27 @@ components:
example: success
message:
type: string
example: internal server error
example: internal server error
Profile:
required:
- username
- bio
- image
- following
type: object
properties:
username:
type: string
example: greensprings
bio:
type: string
example: I love novels
image:
type: string
example: ''
following:
type: boolean
example: true
securitySchemes:
ApiKeyAuth:
type: apiKey
Expand Down
Loading

0 comments on commit 263ff20

Please sign in to comment.