Tarsheed
  1. Auth
Tarsheed
  • Auth
    • Create Account
      POST
    • Verifiy Email
      POST
    • Login
      POST
    • Resend Verfication Code
      POST
    • Forget Password Request
      POST
    • Forget password Verify Code
      POST
    • Reset Password
      PATCH
    • Login With Google
      POST
    • Login With Facebook
      POST
  • Users
    • Get all users
      GET
    • Get specific user
      GET
    • Delete user account
      DELETE
    • Update user data
      PUT
    • Change user password
      PUT
    • Get Recomendation
      GET
    • Get Avarage Cost For Spesfic User
      GET
    • Get The Power Saving Modes Settings
      GET
    • Update the Usage of the power saving mode
      PATCH
  • Reports
    • GetUserReport
      GET
  • Room
    • Create New Room
      POST
    • Update Room
      PATCH
    • Delete Room
      DELETE
    • Get Room Details
      GET
    • Get all Rooms for spesfic user
      GET
  • Device
    • Create New Device
      POST
    • Update Device
      PATCH
    • Delete Device
      DELETE
    • Get All Devices id For IOT System
      GET
    • Toggle Device Status
      PATCH
  • category
    • get all categories
  • Sensor
    • Create New Sensor
    • Update Sensor
    • Delete Sensor
    • Get All Sensor For Spesfic user
  • Automation
    • Add New Automation
    • Get all Automation for Spesfic User
    • Delete Spesfic Automation
    • Update Spesfic Automation
    • Apply Automation Manually
  1. Auth

Create Account

Developing
POST
/auth/register
auth
This Endpoint to Create a New Account

Request

Body Params application/json
email
string 
required
password
string 
required
username
string 
required
first_name
string 
required
last_name
string 
required
Example
{
    "email": "string",
    "password": "string",
    "username": "string",
    "first_name": "string",
    "last_name": "string"
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/auth/register' \
--header 'Content-Type: application/json' \
--data-raw '{
    "email": "string",
    "password": "string",
    "username": "string",
    "first_name": "string",
    "last_name": "string"
}'

Responses

🟢201Created
application/json
Body
message
string 
required
data
object 
required
Example
{
    "message": "Account created successfully",
    "data": {
        "id": "67d79585ad2213042fef438b",
        "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjY3ZDc5NTg1YWQyMjEzMDQyZmVmNDM4YiIsImVtYWlsIjoiUHJpbmNlc3M1NTU1NTU1NTU1NTU1NTU1NTU1NTU1NTVAZ21haWwuY29tIiwiaWF0IjoxNzQyMTgxNzcwLCJleHAiOjE3NDQ3NzM3NzB9.k_YNjtQkoIgDw_ulgIaOs85QHrGuYatZFwR83vaWpng"
    }
}
🟠400Bad Request
Next
Verifiy Email
Built with