[go: up one dir, main page]

Skip to content

prabincankod/momoKinde

Repository files navigation

momoKinde backend overly simple backend design

momoKinde : degraded version of buymeamomo.com

API Documentation

Endpoints

POST auth/signup

Expects {email, password,userSlug} on req.body


On Success sends token
On Failure sends {error}



POST auth/login

Expects {email, password} on req.body


On Success sends token
On Failure sends {error}



PATCH /campaign

Expects Bearer [token] on req.header.Authorization
Expects {campaignName, campaignDescription} on req.body


On Success {message: {campaign}} on res.body
On Failure sends {error}



PATCH /user/password

Expects Bearer [token] on req.header.Authorization
Expects {currentPassword,newPassword} on req.body


you get the idea this endpoint changes the password



PATCH /user/userSlug

Expects Bearer [token] on req.header.Authorization
Expects {userSlug} on req.body


you get the idea this endpoint changes the userSlug



TODO

  • update wallet
  • update campaign
  • login
  • signup
  • change password
  • change userslug