Auth

User signup

post
/signup/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
emailstring · emailRequired
namestringRequired
passwordstringRequired
confirm_passwordstringRequired
Responses
post
/signup/
POST /api/v1/signup/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 84

{
  "email": "name@gmail.com",
  "name": "text",
  "password": "text",
  "confirm_password": "text"
}
{
  "id": 1,
  "email": "name@gmail.com",
  "name": "text",
  "profile_pic": "text"
}

User login

post
/login/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
emailstring · emailRequired
passwordstringRequired
Responses
200

Tokens returned

application/json
post
/login/
POST /api/v1/login/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 44

{
  "email": "name@gmail.com",
  "password": "text"
}
{
  "access": "text",
  "refresh": "text"
}

Request password reset via email

post
/password-reset/request/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
emailstring · emailRequired
Responses
200

OTP sent if email exists

No content

post
/password-reset/request/
POST /api/v1/password-reset/request/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 26

{
  "email": "name@gmail.com"
}
200

OTP sent if email exists

No content

Verify password reset OTP

post
/password-reset/verify-otp/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
emailstring · emailRequired
otpstringRequired
Responses
200

OTP valid

No content

post
/password-reset/verify-otp/
POST /api/v1/password-reset/verify-otp/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 39

{
  "email": "name@gmail.com",
  "otp": "text"
}
200

OTP valid

No content

Change password after OTP verification

post
/password-reset/change-password/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
emailstring · emailRequired
new_passwordstringRequired
confirm_passwordstringRequired
Responses
200

Password changed

No content

post
/password-reset/change-password/
POST /api/v1/password-reset/change-password/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 74

{
  "email": "name@gmail.com",
  "new_password": "text",
  "confirm_password": "text"
}
200

Password changed

No content

Change password (logged-in user)

put
/change-password/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
old_passwordstringRequired
new_passwordstringRequired
confirm_passwordstringRequired
Responses
200

Password changed

No content

put
/change-password/
PUT /api/v1/change-password/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 71

{
  "old_password": "text",
  "new_password": "text",
  "confirm_password": "text"
}

No content

Refresh access token

post
/refresh/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
refreshstringRequired
Responses
200

New access token

application/json
post
/refresh/
POST /api/v1/refresh/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 18

{
  "refresh": "text"
}
200

New access token

{
  "access": "text"
}

Logout and revoke refresh token

post
/logout/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
refreshstringRequired
Responses
200

Logged out

No content

post
/logout/
POST /api/v1/logout/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 18

{
  "refresh": "text"
}

No content

Delete current account

delete
/delete-account/
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Responses
delete
/delete-account/
DELETE /api/v1/delete-account/ HTTP/1.1
Host: api.therappai.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*

No content

Last updated