From 61aca90aebd5f46e607ad65881fc939084fd0001 Mon Sep 17 00:00:00 2001 From: Marcel Schwarz <3233901-marcel.schwarz@users.noreply.gitlab.com> Date: Tue, 21 Apr 2020 06:46:13 +0000 Subject: [PATCH] Update API Endpoints --- API-Endpoints.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/API-Endpoints.md b/API-Endpoints.md index e9b9613..2f22166 100644 --- a/API-Endpoints.md +++ b/API-Endpoints.md @@ -7,13 +7,13 @@ ## Endpoints (GET) * "/login?username=bla&password=bla" → Returns a session token (later for authentication #16) * "/logout?token=tk" → Invalidates the local token -* "/users" → returns list of all users -* "/users/{uid}" → returns a single user -* "/users/{uid}/accounts" → returns all timetrack account ids of that user -* "/accounts/{accountid}" → all metadata of that account -* "/records?uid=bla&[startdate=date, enddate=date, timetrackaccount=[all, account1, account2]]" -> returns all records which match these params -* "/records/start?accountid=bla" → start new record for that account -* "/records/stop?accountid=bla" → stop recording for that account +* "/users?token=tk" → returns list of all users +* "/users/{uid}?token=tk" → returns a single user +* "/users/{uid}/accounts?token=tk" → returns all timetrack account ids of that user +* "/accounts/{accountid}?token=tk" → all metadata of that account +* "/records?token=tk&uid=bla&[startdate=date, enddate=date, timetrackaccount=[all, account1, account2]]" -> returns all records which match these params +* "/records/start?token=tk&accountid=bla" → start new record for that account +* "/records/stop?token=tk&accountid=bla" → stop recording for that account ## Endpoints (POST) * "/users?token=tk" → Payload user data in request body