Skip to content

An simpel example of ( https://clockify.me/ ) REST-based API you can (Add,Get all or Get a specific,Update,Delete) data by this api cod

Notifications You must be signed in to change notification settings

farhadfarokhseresht/Time-Traker-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

49 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Time-Traker-api

An simpel example of ( https://clockify.me/ ) REST-based API

you can (Add,Get all or Get a specific,Update,Delete) data by this api cod

request parameters

parameter more type
description Optional string
billable True or Fals , Optional , default=Fals Boolean
start_at like : 2022-01-23 14:29:00 date time
end_at Should be less than #start_at date time
pk necessary integer

Add a new time entry

to add new time tracker to data base

path :
127.0.0.1:8000/time_tracker

method : POST
body exampel :

    {"description": "Writing documentation",
    "billable": "True",
    "start_at": "2022-01-22 15:29",
    "end_at": "2021-01-23 14:29"}

Get all time entry

return an dictionary of all time entry

path :
127.0.0.1:8000/time_tracker

method : GET

Get specific time entry

find and return specific time entry from data base with id = pk

path :
127.0.0.1:8000/time_tracker/pk

method : GET

Stop currently running timer

stop running timer with id = pk

path :
127.0.0.1:8000/time_tracker/pk

method : PATCH

Delete time entry

Delete time entry with id = pk

path :
127.0.0.1:8000/time_tracker/pk

method : DELETE

Update time entry

Update time entry with id = pk

path :
127.0.0.1:8000/time_tracker/pk

method : PUT
body exampel :

    {"description": "Writing documentation",
    "billable": "True",
    "start_at": "2022-01-22 15:29",
    "end_at": "2021-01-23 14:29"}

Installation

Requires Python 3 to run.

open CMD , go to your dir and type

git clone https://github.com/farhadfarokhseresht/Time-Traker-api.git
#after Download go to proj directory and type in your CMD :
python manage.py runserver
#use Postman app

About

An simpel example of ( https://clockify.me/ ) REST-based API you can (Add,Get all or Get a specific,Update,Delete) data by this api cod

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages