This repository has been archived on 2023-05-07. You can view files and clone it, but cannot push or open issues or pull requests.
go-sdk/api/swagger.yaml

4701 lines
132 KiB
YAML
Raw Permalink Normal View History

2019-10-19 20:53:41 +00:00
---
swagger: "2.0"
info:
description: "This is the documentation for the [Vikunja](http://vikunja.io) API.\
\ Vikunja is a cross-plattform Todo-application with a lot of features, such as\
\ sharing lists with users or teams. <!-- ReDoc-Inject: <security-definitions>\
\ -->\n# Authorization\n**JWT-Auth:** Main authorization method, used for most\
\ of the requests. Needs `Authorization: Bearer <jwt-token>`-header to authenticate\
\ successfully.\n\n**BasicAuth:** Only used when requesting tasks via caldav.\n\
<!-- ReDoc-Inject: <security-definitions> -->"
version: "0.8+21-854fde1e4c"
title: "Vikunja API"
contact:
name: "General Vikunja contact"
url: "http://vikunja.io/en/contact/"
email: "hello@vikunja.io"
license:
name: "GPLv3"
url: "http://code.vikunja.io/api/src/branch/master/LICENSE"
host: ""
basePath: "/api/v1"
paths:
/info:
get:
tags:
- "service"
summary: "Info"
description: "Returns the version, frontendurl, motd and various settings of\
\ Vikunja"
produces:
- "application/json"
parameters: []
responses:
200:
description: "OK"
schema:
$ref: "#/definitions/v1.vikunjaInfos"
/labels:
get:
tags:
- "labels"
summary: "Get all labels a user has access to"
description: "Returns all labels which are either created by the user or associated\
\ with a task the user has at least read-access to."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search labels by label text."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The labels"
schema:
type: "array"
items:
$ref: "#/definitions/models.Label"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "labels"
summary: "Create a label"
description: "Creates a new label."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "label"
description: "The label object"
required: true
schema:
$ref: "#/definitions/models.Label"
x-exportParamName: "Label"
responses:
200:
description: "The created label object."
schema:
$ref: "#/definitions/models.Label"
400:
description: "Invalid label object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/labels/{id}:
get:
tags:
- "labels"
summary: "Gets one label"
description: "Returns one label by its ID."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Label ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The label"
schema:
$ref: "#/definitions/models.Label"
403:
description: "The user does not have access to the label"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Label not found"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "labels"
summary: "Update a label"
description: "Update an existing label. The user needs to be the creator of\
\ the label to be able to do this."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Label ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "label"
description: "The label object"
required: true
schema:
$ref: "#/definitions/models.Label"
x-exportParamName: "Label"
responses:
200:
description: "The created label object."
schema:
$ref: "#/definitions/models.Label"
400:
description: "Invalid label object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "Not allowed to update the label."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Label not found."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "labels"
summary: "Delete a label"
description: "Delete an existing label. The user needs to be the creator of\
\ the label to be able to do this."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Label ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The label was successfully deleted."
schema:
$ref: "#/definitions/models.Label"
403:
description: "Not allowed to delete the label."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Label not found."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists:
get:
tags:
- "list"
summary: "Get all lists a user has access to"
description: "Returns all lists a user has access to."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search lists by title."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The lists"
schema:
type: "array"
items:
$ref: "#/definitions/models.List"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists/{id}:
get:
tags:
- "list"
summary: "Gets one list"
description: "Returns a list by its ID."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The list"
schema:
$ref: "#/definitions/models.List"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
post:
tags:
- "list"
summary: "Updates a list"
description: "Updates a list. This does not include adding a task (see below)."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "list"
description: "The list with updated values you want to update."
required: true
schema:
$ref: "#/definitions/models.List"
x-exportParamName: "List"
responses:
200:
description: "The updated list."
schema:
$ref: "#/definitions/models.List"
400:
description: "Invalid list object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "task"
summary: "Create a task"
description: "Inserts a task into a list."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "task"
description: "The task object"
required: true
schema:
$ref: "#/definitions/models.Task"
x-exportParamName: "Task"
responses:
200:
description: "The created task object."
schema:
$ref: "#/definitions/models.Task"
400:
description: "Invalid task object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "list"
summary: "Deletes a list"
description: "Delets a list"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The list was successfully deleted."
schema:
$ref: "#/definitions/models.Message"
400:
description: "Invalid list object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists/{id}/listusers:
get:
tags:
- "list"
summary: "Get users"
description: "Lists all users (without emailadresses). Also possible to search\
\ for a specific user."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "s"
in: "query"
description: "Search for a user by its name."
required: false
type: "string"
x-exportParamName: "S"
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "All (found) users."
schema:
type: "array"
items:
$ref: "#/definitions/models.User"
400:
description: "Something's invalid."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
401:
description: "The user does not have the right to see the list."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal server error."
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists/{id}/teams:
get:
tags:
- "sharing"
summary: "Get teams on a list"
description: "Returns a list with all teams which have access on a given list."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search teams by its name."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The teams with their right."
schema:
type: "array"
items:
$ref: "#/definitions/models.TeamWithRight"
403:
description: "No right to see the list."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "sharing"
summary: "Add a team to a list"
description: "Gives a team access to a list."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "list"
description: "The team you want to add to the list."
required: true
schema:
$ref: "#/definitions/models.TeamList"
x-exportParamName: "List"
responses:
200:
description: "The created team<->list relation."
schema:
$ref: "#/definitions/models.TeamList"
400:
description: "Invalid team list object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "The team does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists/{id}/users:
get:
tags:
- "sharing"
summary: "Get users on a list"
description: "Returns a list with all users which have access on a given list."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search users by its name."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The users with the right they have."
schema:
type: "array"
items:
$ref: "#/definitions/models.UserWithRight"
403:
description: "No right to see the list."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "sharing"
summary: "Add a user to a list"
description: "Gives a user access to a list."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "list"
description: "The user you want to add to the list."
required: true
schema:
$ref: "#/definitions/models.ListUser"
x-exportParamName: "List"
responses:
200:
description: "The created user<->list relation."
schema:
$ref: "#/definitions/models.ListUser"
400:
description: "Invalid user list object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "The user does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists/{listID}/teams/{teamID}:
post:
tags:
- "sharing"
summary: "Update a team <-> list relation"
description: "Update a team <-> list relation. Mostly used to update the right\
\ that team has."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "listID"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "ListID"
- name: "teamID"
in: "path"
description: "Team ID"
required: true
type: "integer"
x-exportParamName: "TeamID"
- in: "body"
name: "list"
description: "The team you want to update."
required: true
schema:
$ref: "#/definitions/models.TeamList"
x-exportParamName: "List"
responses:
200:
description: "The updated team <-> list relation."
schema:
$ref: "#/definitions/models.TeamList"
403:
description: "The user does not have admin-access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Team or list does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "sharing"
summary: "Delete a team from a list"
description: "Delets a team from a list. The team won't have access to the list\
\ anymore."
produces:
- "application/json"
parameters:
- name: "listID"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "ListID"
- name: "teamID"
in: "path"
description: "Team ID"
required: true
type: "integer"
x-exportParamName: "TeamID"
responses:
200:
description: "The team was successfully deleted."
schema:
$ref: "#/definitions/models.Message"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Team or list does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists/{listID}/users/{userID}:
post:
tags:
- "sharing"
summary: "Update a user <-> list relation"
description: "Update a user <-> list relation. Mostly used to update the right\
\ that user has."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "listID"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "ListID"
- name: "userID"
in: "path"
description: "User ID"
required: true
type: "integer"
x-exportParamName: "UserID"
- in: "body"
name: "list"
description: "The user you want to update."
required: true
schema:
$ref: "#/definitions/models.ListUser"
x-exportParamName: "List"
responses:
200:
description: "The updated user <-> list relation."
schema:
$ref: "#/definitions/models.ListUser"
403:
description: "The user does not have admin-access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "User or list does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "sharing"
summary: "Delete a user from a list"
description: "Delets a user from a list. The user won't have access to the list\
\ anymore."
produces:
- "application/json"
parameters:
- name: "listID"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "ListID"
- name: "userID"
in: "path"
description: "User ID"
required: true
type: "integer"
x-exportParamName: "UserID"
responses:
200:
description: "The user was successfully removed from the list."
schema:
$ref: "#/definitions/models.Message"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "user or list does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists/{list}/shares:
get:
tags:
- "sharing"
summary: "Get all link shares for a list"
description: "Returns all link shares which exist for a given list"
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "list"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "List"
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search shares by hash."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The share links"
schema:
type: "array"
items:
$ref: "#/definitions/models.LinkSharing"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "sharing"
summary: "Share a list via link"
description: "Share a list via link. The user needs to have write-access to\
\ the list to be able do this."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "list"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "List"
- in: "body"
name: "label"
description: "The new link share object"
required: true
schema:
$ref: "#/definitions/models.LinkSharing"
x-exportParamName: "Label"
responses:
200:
description: "The created link share object."
schema:
$ref: "#/definitions/models.LinkSharing"
400:
description: "Invalid link share object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "Not allowed to add the list share."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "The list does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/lists/{list}/shares/{share}:
get:
tags:
- "sharing"
summary: "Get one link shares for a list"
description: "Returns one link share by its ID."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "list"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "List"
- name: "share"
in: "path"
description: "Share ID"
required: true
type: "integer"
x-exportParamName: "Share"
responses:
200:
description: "The share links"
schema:
$ref: "#/definitions/models.LinkSharing"
403:
description: "No access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Share Link not found."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "sharing"
summary: "Remove a link share"
description: "Remove a link share. The user needs to have write-access to the\
\ list to be able do this."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "list"
in: "path"
description: "List ID"
required: true
type: "integer"
x-exportParamName: "List"
- name: "share"
in: "path"
description: "Share Link ID"
required: true
type: "integer"
x-exportParamName: "Share"
responses:
200:
description: "The link was successfully removed."
schema:
$ref: "#/definitions/models.Message"
403:
description: "Not allowed to remove the link."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Share Link not found."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/login:
post:
tags:
- "user"
summary: "Login"
description: "Logs a user in. Returns a JWT-Token to authenticate further requests."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "credentials"
description: "The login credentials"
required: true
schema:
$ref: "#/definitions/models.UserLogin"
x-exportParamName: "Credentials"
responses:
200:
description: "OK"
schema:
$ref: "#/definitions/v1.Token"
400:
description: "Invalid user password model."
schema:
$ref: "#/definitions/models.Message"
403:
description: "Invalid username or password."
schema:
$ref: "#/definitions/models.Message"
/namespace/{id}:
post:
tags:
- "namespace"
summary: "Updates a namespace"
description: "Updates a namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "namespace"
description: "The namespace with updated values you want to update."
required: true
schema:
$ref: "#/definitions/models.Namespace"
x-exportParamName: "Namespace"
responses:
200:
description: "The updated namespace."
schema:
$ref: "#/definitions/models.Namespace"
400:
description: "Invalid namespace object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/namespaces:
get:
tags:
- "namespace"
summary: "Get all namespaces a user has access to"
description: "Returns all namespaces a user has access to."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search namespaces by name."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The Namespaces."
schema:
type: "array"
items:
$ref: "#/definitions/models.NamespaceWithLists"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "namespace"
summary: "Creates a new namespace"
description: "Creates a new namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "namespace"
description: "The namespace you want to create."
required: true
schema:
$ref: "#/definitions/models.Namespace"
x-exportParamName: "Namespace"
responses:
200:
description: "The created namespace."
schema:
$ref: "#/definitions/models.Namespace"
400:
description: "Invalid namespace object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/namespaces/{id}:
get:
tags:
- "namespace"
summary: "Gets one namespace"
description: "Returns a namespace by its ID."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The Namespace"
schema:
$ref: "#/definitions/models.Namespace"
403:
description: "The user does not have access to that namespace."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "namespace"
summary: "Deletes a namespace"
description: "Delets a namespace"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The namespace was successfully deleted."
schema:
$ref: "#/definitions/models.Message"
400:
description: "Invalid namespace object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/namespaces/{id}/lists:
get:
tags:
- "namespace"
summary: "Get all lists in a namespace"
description: "Returns all lists inside of a namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The lists."
schema:
type: "array"
items:
$ref: "#/definitions/models.List"
403:
description: "No access to that namespace."
schema:
$ref: "#/definitions/models.Message"
404:
description: "The namespace does not exist."
schema:
$ref: "#/definitions/models.Message"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/namespaces/{id}/teams:
get:
tags:
- "sharing"
summary: "Get teams on a namespace"
description: "Returns a namespace with all teams which have access on a given\
\ namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "Id"
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search teams by its name."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The teams with the right they have."
schema:
type: "array"
items:
$ref: "#/definitions/models.TeamWithRight"
403:
description: "No right to see the namespace."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "sharing"
summary: "Add a team to a namespace"
description: "Gives a team access to a namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "namespace"
description: "The team you want to add to the namespace."
required: true
schema:
$ref: "#/definitions/models.TeamNamespace"
x-exportParamName: "Namespace"
responses:
200:
description: "The created team<->namespace relation."
schema:
$ref: "#/definitions/models.TeamNamespace"
400:
description: "Invalid team namespace object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The team does not have access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "The team does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/namespaces/{id}/users:
get:
tags:
- "sharing"
summary: "Get users on a namespace"
description: "Returns a namespace with all users which have access on a given\
\ namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "Id"
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search users by its name."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The users with the right they have."
schema:
type: "array"
items:
$ref: "#/definitions/models.UserWithRight"
403:
description: "No right to see the namespace."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "sharing"
summary: "Add a user to a namespace"
description: "Gives a user access to a namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "namespace"
description: "The user you want to add to the namespace."
required: true
schema:
$ref: "#/definitions/models.NamespaceUser"
x-exportParamName: "Namespace"
responses:
200:
description: "The created user<->namespace relation."
schema:
$ref: "#/definitions/models.NamespaceUser"
400:
description: "Invalid user namespace object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "The user does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/namespaces/{namespaceID}/lists:
put:
tags:
- "list"
summary: "Creates a new list"
description: "Creates a new list in a given namespace. The user needs write-access\
\ to the namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "namespaceID"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "NamespaceID"
- in: "body"
name: "list"
description: "The list you want to create."
required: true
schema:
$ref: "#/definitions/models.List"
x-exportParamName: "List"
responses:
200:
description: "The created list."
schema:
$ref: "#/definitions/models.List"
400:
description: "Invalid list object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/namespaces/{namespaceID}/teams/{teamID}:
post:
tags:
- "sharing"
summary: "Update a team <-> namespace relation"
description: "Update a team <-> namespace relation. Mostly used to update the\
\ right that team has."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "namespaceID"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "NamespaceID"
- name: "teamID"
in: "path"
description: "Team ID"
required: true
type: "integer"
x-exportParamName: "TeamID"
- in: "body"
name: "namespace"
description: "The team you want to update."
required: true
schema:
$ref: "#/definitions/models.TeamNamespace"
x-exportParamName: "Namespace"
responses:
200:
description: "The updated team <-> namespace relation."
schema:
$ref: "#/definitions/models.TeamNamespace"
403:
description: "The team does not have admin-access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Team or namespace does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "sharing"
summary: "Delete a team from a namespace"
description: "Delets a team from a namespace. The team won't have access to\
\ the namespace anymore."
produces:
- "application/json"
parameters:
- name: "namespaceID"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "NamespaceID"
- name: "teamID"
in: "path"
description: "team ID"
required: true
type: "integer"
x-exportParamName: "TeamID"
responses:
200:
description: "The team was successfully deleted."
schema:
$ref: "#/definitions/models.Message"
403:
description: "The team does not have access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "team or namespace does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/namespaces/{namespaceID}/users/{userID}:
post:
tags:
- "sharing"
summary: "Update a user <-> namespace relation"
description: "Update a user <-> namespace relation. Mostly used to update the\
\ right that user has."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "namespaceID"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "NamespaceID"
- name: "userID"
in: "path"
description: "User ID"
required: true
type: "integer"
x-exportParamName: "UserID"
- in: "body"
name: "namespace"
description: "The user you want to update."
required: true
schema:
$ref: "#/definitions/models.NamespaceUser"
x-exportParamName: "Namespace"
responses:
200:
description: "The updated user <-> namespace relation."
schema:
$ref: "#/definitions/models.NamespaceUser"
403:
description: "The user does not have admin-access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "User or namespace does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "sharing"
summary: "Delete a user from a namespace"
description: "Delets a user from a namespace. The user won't have access to\
\ the namespace anymore."
produces:
- "application/json"
parameters:
- name: "namespaceID"
in: "path"
description: "Namespace ID"
required: true
type: "integer"
x-exportParamName: "NamespaceID"
- name: "userID"
in: "path"
description: "user ID"
required: true
type: "integer"
x-exportParamName: "UserID"
responses:
200:
description: "The user was successfully deleted."
schema:
$ref: "#/definitions/models.Message"
403:
description: "The user does not have access to the namespace"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "user or namespace does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/register:
post:
tags:
- "user"
summary: "Register"
description: "Creates a new user account."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "credentials"
description: "The user credentials"
required: true
schema:
$ref: "#/definitions/models.APIUserPassword"
x-exportParamName: "Credentials"
responses:
200:
description: "OK"
schema:
$ref: "#/definitions/models.User"
400:
description: "No or invalid user register object provided / User already\
\ exists."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
/shares/{share}/auth:
post:
tags:
- "sharing"
summary: "Get an auth token for a share"
description: "Get a jwt auth token for a shared list from a share hash."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "share"
in: "path"
description: "The share hash"
required: true
type: "string"
x-exportParamName: "Share"
responses:
200:
description: "The valid jwt auth token."
schema:
$ref: "#/definitions/v1.Token"
400:
description: "Invalid link share object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
/tasks/all:
get:
tags:
- "task"
summary: "Get tasks"
description: "Returns all tasks on any list the user has access to."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search tasks by task text."
required: false
type: "string"
x-exportParamName: "S"
- name: "sort"
in: "query"
description: "The sorting parameter. Possible values to sort by are priority,\
\ prioritydesc, priorityasc, duedate, duedatedesc, duedateasc."
required: false
type: "string"
x-exportParamName: "Sort"
- name: "startdate"
in: "query"
description: "The start date parameter to filter by. Expects a unix timestamp.\
\ If no end date, but a start date is specified, the end date is set to\
\ the current time."
required: false
type: "integer"
x-exportParamName: "Startdate"
- name: "enddate"
in: "query"
description: "The end date parameter to filter by. Expects a unix timestamp.\
\ If no start date, but an end date is specified, the start date is set\
\ to the current time."
required: false
type: "integer"
x-exportParamName: "Enddate"
responses:
200:
description: "The tasks"
schema:
type: "array"
items:
$ref: "#/definitions/models.Task"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/bulk:
post:
tags:
- "task"
summary: "Update a bunch of tasks at once"
description: "Updates a bunch of tasks at once. This includes marking them as\
\ done. Note: although you could supply another ID, it will be ignored. Use\
\ task_ids instead."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "task"
description: "The task object. Looks like a normal task, the only difference\
\ is it uses an array of list_ids to update."
required: true
schema:
$ref: "#/definitions/models.BulkTask"
x-exportParamName: "Task"
responses:
200:
description: "The updated task object."
schema:
$ref: "#/definitions/models.Task"
400:
description: "Invalid task object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the task (aka its list)"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{id}:
post:
tags:
- "task"
summary: "Update a task"
description: "Updates a task. This includes marking it as done. Assignees you\
\ pass will be updated, see their individual endpoints for more details on\
\ how this is done. To update labels, see the description of the endpoint."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "task"
description: "The task object"
required: true
schema:
$ref: "#/definitions/models.Task"
x-exportParamName: "Task"
responses:
200:
description: "The updated task object."
schema:
$ref: "#/definitions/models.Task"
400:
description: "Invalid task object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the task (aka its list)"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "task"
summary: "Delete a task"
description: "Deletes a task from a list. This does not mean \"mark it done\"\
."
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The created task object."
schema:
$ref: "#/definitions/models.Message"
400:
description: "Invalid task ID provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the list"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{id}/attachments:
get:
tags:
- "task"
summary: "Get all attachments for one task."
description: "Get all task attachments for one task."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "All attachments for this task"
schema:
type: "array"
items:
$ref: "#/definitions/models.TaskAttachment"
403:
description: "No access to this task."
schema:
$ref: "#/definitions/models.Message"
404:
description: "The task does not exist."
schema:
$ref: "#/definitions/models.Message"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "task"
summary: "Upload a task attachment"
description: "Upload a task attachment. You can pass multiple files with the\
\ files form param."
consumes:
- "multipart/form-data"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Id"
- name: "files"
in: "formData"
description: "The file, as multipart form file. You can pass multiple."
required: true
type: "string"
x-exportParamName: "Files"
responses:
200:
description: "Attachments were uploaded successfully."
schema:
$ref: "#/definitions/models.Message"
403:
description: "No access to the task."
schema:
$ref: "#/definitions/models.Message"
404:
description: "The task does not exist."
schema:
$ref: "#/definitions/models.Message"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{id}/attachments/{attachmentID}:
get:
tags:
- "task"
summary: "Get one attachment."
description: "Get one attachment for download. **Returns json on error.**"
produces:
- "application/octet-stream"
parameters:
- name: "id"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Id"
- name: "attachmentID"
in: "path"
description: "Attachment ID"
required: true
type: "integer"
x-exportParamName: "AttachmentID"
responses:
200:
description: "The attachment file."
403:
description: "No access to this task."
schema:
$ref: "#/definitions/models.Message"
404:
description: "The task does not exist."
schema:
$ref: "#/definitions/models.Message"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "task"
summary: "Delete an attachment"
description: "Delete an attachment."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Id"
- name: "attachmentID"
in: "path"
description: "Attachment ID"
required: true
type: "integer"
x-exportParamName: "AttachmentID"
responses:
200:
description: "The attachment was deleted successfully."
schema:
$ref: "#/definitions/models.Message"
403:
description: "No access to this task."
schema:
$ref: "#/definitions/models.Message"
404:
description: "The task does not exist."
schema:
$ref: "#/definitions/models.Message"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{taskID}/assignees:
get:
tags:
- "assignees"
summary: "Get all assignees for a task"
description: "Returns an array with all assignees for this task."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search assignees by their username."
required: false
type: "string"
x-exportParamName: "S"
- name: "taskID"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "TaskID"
responses:
200:
description: "The assignees"
schema:
type: "array"
items:
$ref: "#/definitions/models.User"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "assignees"
summary: "Add a new assignee to a task"
description: "Adds a new assignee to a task. The assignee needs to have access\
\ to the list, the doer must be able to edit this task."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "assignee"
description: "The assingee object"
required: true
schema:
$ref: "#/definitions/models.TaskAssginee"
x-exportParamName: "Assignee"
- name: "taskID"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "TaskID"
responses:
200:
description: "The created assingee object."
schema:
$ref: "#/definitions/models.TaskAssginee"
400:
description: "Invalid assignee object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{taskID}/assignees/bulk:
post:
tags:
- "assignees"
summary: "Add multiple new assignees to a task"
description: "Adds multiple new assignees to a task. The assignee needs to have\
\ access to the list, the doer must be able to edit this task. Every user\
\ not in the list will be unassigned from the task, pass an empty array to\
\ unassign everyone."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "assignee"
description: "The array of assignees"
required: true
schema:
$ref: "#/definitions/models.BulkAssignees"
x-exportParamName: "Assignee"
- name: "taskID"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "TaskID"
responses:
200:
description: "The created assingees object."
schema:
$ref: "#/definitions/models.TaskAssginee"
400:
description: "Invalid assignee object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{taskID}/assignees/{userID}:
delete:
tags:
- "assignees"
summary: "Delete an assignee"
description: "Un-assign a user from a task."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "taskID"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "TaskID"
- name: "userID"
in: "path"
description: "Assignee user ID"
required: true
type: "integer"
x-exportParamName: "UserID"
responses:
200:
description: "The assignee was successfully deleted."
schema:
$ref: "#/definitions/models.Message"
403:
description: "Not allowed to delete the assignee."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{taskID}/labels/bulk:
post:
tags:
- "labels"
summary: "Update all labels on a task."
description: "Updates all labels on a task. Every label which is not passed\
\ but exists on the task will be deleted. Every label which does not exist\
\ on the task will be added. All labels which are passed and already exist\
\ on the task won't be touched."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "label"
description: "The array of labels"
required: true
schema:
$ref: "#/definitions/models.LabelTaskBulk"
x-exportParamName: "Label"
- name: "taskID"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "TaskID"
responses:
200:
description: "The updated labels object."
schema:
$ref: "#/definitions/models.LabelTaskBulk"
400:
description: "Invalid label object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{taskID}/relations:
put:
tags:
- "task"
summary: "Create a new relation between two tasks"
description: "Creates a new relation between two tasks. The user needs to have\
\ update rights on the base task and at least read rights on the other task.\
\ Both tasks do not need to be on the same list. Take a look at the docs for\
\ available task relation kinds."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "relation"
description: "The relation object"
required: true
schema:
$ref: "#/definitions/models.TaskRelation"
x-exportParamName: "Relation"
- name: "taskID"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "TaskID"
responses:
200:
description: "The created task relation object."
schema:
$ref: "#/definitions/models.TaskRelation"
400:
description: "Invalid task relation object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "task"
summary: "Remove a task relation"
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "relation"
description: "The relation object"
required: true
schema:
$ref: "#/definitions/models.TaskRelation"
x-exportParamName: "Relation"
- name: "taskID"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "TaskID"
responses:
200:
description: "The task relation was successfully deleted."
schema:
$ref: "#/definitions/models.Message"
400:
description: "Invalid task relation object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "The task relation was not found."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{task}/labels:
get:
tags:
- "labels"
summary: "Get all labels on a task"
description: "Returns all labels which are assicociated with a given task."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "task"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Task"
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search labels by label text."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The labels"
schema:
type: "array"
items:
$ref: "#/definitions/models.Label"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "labels"
summary: "Add a label to a task"
description: "Add a label to a task. The user needs to have write-access to\
\ the list to be able do this."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "task"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Task"
- in: "body"
name: "label"
description: "The label object"
required: true
schema:
$ref: "#/definitions/models.LabelTask"
x-exportParamName: "Label"
responses:
200:
description: "The created label relation object."
schema:
$ref: "#/definitions/models.LabelTask"
400:
description: "Invalid label object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "Not allowed to add the label."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "The label does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/tasks/{task}/labels/{label}:
delete:
tags:
- "labels"
summary: "Remove a label from a task"
description: "Remove a label from a task. The user needs to have write-access\
\ to the list to be able do this."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "task"
in: "path"
description: "Task ID"
required: true
type: "integer"
x-exportParamName: "Task"
- name: "label"
in: "path"
description: "Label ID"
required: true
type: "integer"
x-exportParamName: "Label"
responses:
200:
description: "The label was successfully removed."
schema:
$ref: "#/definitions/models.Message"
403:
description: "Not allowed to remove the label."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "Label not found."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/teams:
get:
tags:
- "team"
summary: "Get teams"
description: "Returns all teams the current user is part of."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "p"
in: "query"
description: "The page number. Used for pagination. If not provided, the first\
\ page of results is returned."
required: false
type: "integer"
x-exportParamName: "P"
- name: "s"
in: "query"
description: "Search teams by its name."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "The teams."
schema:
type: "array"
items:
$ref: "#/definitions/models.Team"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
put:
tags:
- "team"
summary: "Creates a new team"
description: "Creates a new team in a given namespace. The user needs write-access\
\ to the namespace."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "team"
description: "The team you want to create."
required: true
schema:
$ref: "#/definitions/models.Team"
x-exportParamName: "Team"
responses:
200:
description: "The created team."
schema:
$ref: "#/definitions/models.Team"
400:
description: "Invalid team object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/teams/{id}:
post:
tags:
- "team"
summary: "Updates a team"
description: "Updates a team."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Team ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "team"
description: "The team with updated values you want to update."
required: true
schema:
$ref: "#/definitions/models.Team"
x-exportParamName: "Team"
responses:
200:
description: "The updated team."
schema:
$ref: "#/definitions/models.Team"
400:
description: "Invalid team object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
delete:
tags:
- "team"
summary: "Deletes a team"
description: "Delets a team. This will also remove the access for all users\
\ in that team."
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Team ID"
required: true
type: "integer"
x-exportParamName: "Id"
responses:
200:
description: "The team was successfully deleted."
schema:
$ref: "#/definitions/models.Message"
400:
description: "Invalid team object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/teams/{id}/members:
put:
tags:
- "team"
summary: "Add a user to a team"
description: "Add a user to a team."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Team ID"
required: true
type: "integer"
x-exportParamName: "Id"
- in: "body"
name: "team"
description: "The user to be added to a team."
required: true
schema:
$ref: "#/definitions/models.TeamMember"
x-exportParamName: "Team"
responses:
200:
description: "The newly created member object"
schema:
$ref: "#/definitions/models.TeamMember"
400:
description: "Invalid member object provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
403:
description: "The user does not have access to the team"
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/teams/{id}/members/{userID}:
delete:
tags:
- "team"
summary: "Remove a user from a team"
description: "Remove a user from a team. This will also revoke any access this\
\ user might have via that team."
produces:
- "application/json"
parameters:
- name: "id"
in: "path"
description: "Team ID"
required: true
type: "integer"
x-exportParamName: "Id"
- name: "userID"
in: "path"
description: "User ID"
required: true
type: "integer"
x-exportParamName: "UserID"
responses:
200:
description: "The user was successfully removed from the team."
schema:
$ref: "#/definitions/models.Message"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/user:
get:
tags:
- "user"
summary: "Get user information"
description: "Returns the current user object."
consumes:
- "application/json"
produces:
- "application/json"
parameters: []
responses:
200:
description: "OK"
schema:
$ref: "#/definitions/models.User"
404:
description: "User does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal server error."
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/user/confirm:
post:
tags:
- "user"
summary: "Confirm the email of a new user"
description: "Confirms the email of a newly registered user."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "credentials"
description: "The token."
required: true
schema:
$ref: "#/definitions/models.EmailConfirm"
x-exportParamName: "Credentials"
responses:
200:
description: "OK"
schema:
$ref: "#/definitions/models.Message"
412:
description: "Bad token provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
/user/password:
post:
tags:
- "user"
summary: "Change password"
description: "Lets the current user change its password."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "userPassword"
description: "The current and new password."
required: true
schema:
$ref: "#/definitions/v1.UserPassword"
x-exportParamName: "UserPassword"
responses:
200:
description: "OK"
schema:
$ref: "#/definitions/models.Message"
400:
description: "Something's invalid."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
404:
description: "User does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal server error."
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
/user/password/reset:
post:
tags:
- "user"
summary: "Resets a password"
description: "Resets a user email with a previously reset token."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "credentials"
description: "The token with the new password."
required: true
schema:
$ref: "#/definitions/models.PasswordReset"
x-exportParamName: "Credentials"
responses:
200:
description: "OK"
schema:
$ref: "#/definitions/models.Message"
400:
description: "Bad token provided."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
/user/password/token:
post:
tags:
- "user"
summary: "Request password reset token"
description: "Requests a token to reset a users password. The token is sent\
\ via email."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "credentials"
description: "The username of the user to request a token for."
required: true
schema:
$ref: "#/definitions/models.PasswordTokenRequest"
x-exportParamName: "Credentials"
responses:
200:
description: "OK"
schema:
$ref: "#/definitions/models.Message"
404:
description: "The user does not exist."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal error"
schema:
$ref: "#/definitions/models.Message"
/users:
get:
tags:
- "user"
summary: "Get users"
description: "Lists all users (without emailadresses). Also possible to search\
\ for a specific user."
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- name: "s"
in: "query"
description: "Search for a user by its name."
required: false
type: "string"
x-exportParamName: "S"
responses:
200:
description: "All (found) users."
schema:
type: "array"
items:
$ref: "#/definitions/models.User"
400:
description: "Something's invalid."
schema:
$ref: "#/definitions/code.vikunja.io.web.HTTPError"
500:
description: "Internal server error."
schema:
$ref: "#/definitions/models.Message"
security:
- JWTKeyAuth: []
securityDefinitions:
BasicAuth:
type: "basic"
JWTKeyAuth:
type: "apiKey"
name: "Authorization"
in: "header"
definitions:
code.vikunja.io.web.HTTPError:
type: "object"
properties:
code:
type: "integer"
message:
type: "string"
files.File:
type: "object"
properties:
created:
type: "string"
id:
type: "integer"
mime:
type: "string"
name:
type: "string"
size:
type: "integer"
example:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
models.APIUserPassword:
type: "object"
properties:
email:
type: "string"
description: "The user's email address"
maxLength: 250
id:
type: "integer"
description: "The unique, numeric id of this user."
password:
type: "string"
description: "The user's password in clear text. Only used when registering\
\ the user."
minLength: 8
maxLength: 250
username:
type: "string"
description: "The username of the username. Is always unique."
minLength: 3
maxLength: 250
models.BulkAssignees:
type: "object"
properties:
assignees:
type: "array"
description: "A list with all assignees"
items:
$ref: "#/definitions/models.User"
models.BulkTask:
type: "object"
properties:
assignees:
type: "array"
description: "An array of users who are assigned to this task"
items:
$ref: "#/definitions/models.User"
attachments:
type: "array"
description: "All attachments this task has"
items:
$ref: "#/definitions/models.TaskAttachment"
created:
type: "integer"
description: "A unix timestamp when this task was created. You cannot change\
\ this value."
createdBy:
description: "The user who initially created the task."
$ref: "#/definitions/models.User"
description:
type: "string"
description: "The task description."
done:
type: "boolean"
description: "Whether a task is done or not."
doneAt:
type: "integer"
description: "The unix timestamp when a task was marked as done."
dueDate:
type: "integer"
description: "A unix timestamp when the task is due."
endDate:
type: "integer"
description: "When this task ends."
hexColor:
type: "string"
description: "The task color in hex"
maxLength: 6
id:
type: "integer"
description: "The unique, numeric id of this task."
labels:
type: "array"
description: "An array of labels which are associated with this task."
items:
$ref: "#/definitions/models.Label"
listID:
type: "integer"
description: "The list this task belongs to."
percentDone:
type: "number"
description: "Determines how far a task is left from being done"
priority:
type: "integer"
description: "The task priority. Can be anything you want, it is possible\
\ to sort by this later."
related_tasks:
description: "All related tasks, grouped by their relation kind"
$ref: "#/definitions/models.RelatedTaskMap"
reminderDates:
type: "array"
description: "An array of unix timestamps when the user wants to be reminded\
\ of the task."
items:
type: "integer"
repeatAfter:
type: "integer"
description: "An amount in seconds this task repeats itself. If this is set,\
\ when marking the task as done, it will mark itself as \"undone\" and then\
\ increase all remindes and the due date by its amount."
startDate:
type: "integer"
description: "When this task starts."
task_ids:
type: "array"
description: "A list of task ids to update"
items:
type: "integer"
text:
type: "string"
description: "The task text. This is what you'll see in the list."
minLength: 3
maxLength: 250
updated:
type: "integer"
description: "A unix timestamp when this task was last updated. You cannot\
\ change this value."
models.EmailConfirm:
type: "object"
properties:
token:
type: "string"
description: "The email confirm token sent via email."
models.Label:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this label was created. You cannot change\
\ this value."
created_by:
description: "The user who created this label"
$ref: "#/definitions/models.User"
description:
type: "string"
description: "The label description."
hex_color:
type: "string"
description: "The color this label has"
maxLength: 6
id:
type: "integer"
description: "The unique, numeric id of this label."
title:
type: "string"
description: "The title of the lable. You'll see this one on tasks associated\
\ with it."
minLength: 3
maxLength: 250
updated:
type: "integer"
description: "A unix timestamp when this label was last updated. You cannot\
\ change this value."
example:
created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
models.LabelTask:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this task was created. You cannot change\
\ this value."
label_id:
type: "integer"
description: "The label id you want to associate with a task."
example:
created: 0
label_id: 6
models.LabelTaskBulk:
type: "object"
properties:
labels:
type: "array"
description: "All labels you want to update at once."
items:
$ref: "#/definitions/models.Label"
example:
labels:
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
models.LinkSharing:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this list was shared. You cannot change\
\ this value."
hash:
type: "string"
description: "The public id to get this shared list"
id:
type: "integer"
description: "The ID of the shared thing"
right:
type: "integer"
description: "The right this list is shared with. 0 = Read only, 1 = Read\
\ & Write, 2 = Admin. See the docs for more details."
maximum: 2
shared_by:
description: "The user who shared this list"
$ref: "#/definitions/models.User"
sharing_type:
type: "integer"
description: "The kind of this link. 0 = undefined, 1 = without password,\
\ 2 = with password (currently not implemented)."
maximum: 2
updated:
type: "integer"
description: "A unix timestamp when this share was last updated. You cannot\
\ change this value."
example:
created: 0
shared_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
id: 6
right: 0
sharing_type: 1
updated: 5
hash: "hash"
models.List:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this list was created. You cannot change\
\ this value."
description:
type: "string"
description: "The description of the list."
id:
type: "integer"
description: "The unique, numeric id of this list."
owner:
description: "The user who created this list."
$ref: "#/definitions/models.User"
tasks:
type: "array"
description: "An array of tasks which belong to the list."
items:
$ref: "#/definitions/models.Task"
title:
type: "string"
description: "The title of the list. You'll see this in the namespace overview."
minLength: 3
maxLength: 250
updated:
type: "integer"
description: "A unix timestamp when this list was last updated. You cannot\
\ change this value."
example:
owner:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
created: 0
description: "description"
id: 6
title: "title"
updated: 5
tasks:
- doneAt: 3
attachments:
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
percentDone: 1.024645700144157789424070870154537260532379150390625
endDate: 4
created: 9
reminderDates:
- 6
- 6
dueDate: 2
assignees:
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
description: "description"
related_tasks: {}
repeatAfter: 7
priority: 1
done: true
labels:
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
listID: 1
hexColor: "hexColor"
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
id: 7
text: "text"
updated: 4
startDate: 1
- doneAt: 3
attachments:
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
percentDone: 1.024645700144157789424070870154537260532379150390625
endDate: 4
created: 9
reminderDates:
- 6
- 6
dueDate: 2
assignees:
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
description: "description"
related_tasks: {}
repeatAfter: 7
priority: 1
done: true
labels:
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
listID: 1
hexColor: "hexColor"
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
id: 7
text: "text"
updated: 4
startDate: 1
models.ListUser:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this relation was created. You cannot\
\ change this value."
id:
type: "integer"
description: "The unique, numeric id of this list <-> user relation."
right:
type: "integer"
description: "The right this user has. 0 = Read only, 1 = Read & Write, 2\
\ = Admin. See the docs for more details."
maximum: 2
updated:
type: "integer"
description: "A unix timestamp when this relation was last updated. You cannot\
\ change this value."
userID:
type: "string"
description: "The username."
example:
created: 0
id: 6
right: 0
updated: 5
userID: "userID"
models.Message:
type: "object"
properties:
message:
type: "string"
description: "A standard message."
example:
message: "message"
models.Namespace:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this namespace was created. You cannot\
\ change this value."
description:
type: "string"
description: "The description of the namespace"
id:
type: "integer"
description: "The unique, numeric id of this namespace."
name:
type: "string"
description: "The name of this namespace."
minLength: 5
maxLength: 250
owner:
description: "The user who owns this namespace"
$ref: "#/definitions/models.User"
updated:
type: "integer"
description: "A unix timestamp when this namespace was last updated. You cannot\
\ change this value."
example:
owner:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
created: 0
name: "name"
description: "description"
id: 6
updated: 1
models.NamespaceUser:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this relation was created. You cannot\
\ change this value."
id:
type: "integer"
description: "The unique, numeric id of this namespace <-> user relation."
right:
type: "integer"
description: "The right this user has. 0 = Read only, 1 = Read & Write, 2\
\ = Admin. See the docs for more details."
maximum: 2
updated:
type: "integer"
description: "A unix timestamp when this relation was last updated. You cannot\
\ change this value."
userID:
type: "string"
description: "The username."
example:
created: 0
id: 6
right: 0
updated: 5
userID: "userID"
models.NamespaceWithLists:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this namespace was created. You cannot\
\ change this value."
description:
type: "string"
description: "The description of the namespace"
id:
type: "integer"
description: "The unique, numeric id of this namespace."
lists:
type: "array"
items:
$ref: "#/definitions/models.List"
name:
type: "string"
description: "The name of this namespace."
minLength: 5
maxLength: 250
owner:
description: "The user who owns this namespace"
$ref: "#/definitions/models.User"
updated:
type: "integer"
description: "A unix timestamp when this namespace was last updated. You cannot\
\ change this value."
example:
owner:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
created: 0
lists:
- owner:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
created: 0
description: "description"
id: 6
title: "title"
updated: 5
tasks:
- doneAt: 3
attachments:
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
percentDone: 1.024645700144157789424070870154537260532379150390625
endDate: 4
created: 9
reminderDates:
- 6
- 6
dueDate: 2
assignees:
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
description: "description"
related_tasks: {}
repeatAfter: 7
priority: 1
done: true
labels:
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
listID: 1
hexColor: "hexColor"
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
id: 7
text: "text"
updated: 4
startDate: 1
- doneAt: 3
attachments:
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
percentDone: 1.024645700144157789424070870154537260532379150390625
endDate: 4
created: 9
reminderDates:
- 6
- 6
dueDate: 2
assignees:
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
description: "description"
related_tasks: {}
repeatAfter: 7
priority: 1
done: true
labels:
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
listID: 1
hexColor: "hexColor"
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
id: 7
text: "text"
updated: 4
startDate: 1
- owner:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
created: 0
description: "description"
id: 6
title: "title"
updated: 5
tasks:
- doneAt: 3
attachments:
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
percentDone: 1.024645700144157789424070870154537260532379150390625
endDate: 4
created: 9
reminderDates:
- 6
- 6
dueDate: 2
assignees:
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
description: "description"
related_tasks: {}
repeatAfter: 7
priority: 1
done: true
labels:
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
listID: 1
hexColor: "hexColor"
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
id: 7
text: "text"
updated: 4
startDate: 1
- doneAt: 3
attachments:
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
percentDone: 1.024645700144157789424070870154537260532379150390625
endDate: 4
created: 9
reminderDates:
- 6
- 6
dueDate: 2
assignees:
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
description: "description"
related_tasks: {}
repeatAfter: 7
priority: 1
done: true
labels:
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
listID: 1
hexColor: "hexColor"
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
id: 7
text: "text"
updated: 4
startDate: 1
name: "name"
description: "description"
id: 6
updated: 1
models.PasswordReset:
type: "object"
properties:
new_password:
type: "string"
description: "The new password for this user."
token:
type: "string"
description: "The previously issued reset token."
models.PasswordTokenRequest:
type: "object"
properties:
email:
type: "string"
maxLength: 250
models.RelatedTaskMap:
type: "object"
additionalProperties:
type: "array"
items:
type: "object"
properties:
assignees:
type: "array"
description: "An array of users who are assigned to this task"
items:
$ref: "#/definitions/models.User"
attachments:
type: "array"
description: "All attachments this task has"
items:
$ref: "#/definitions/models.TaskAttachment"
created:
type: "integer"
description: "A unix timestamp when this task was created. You cannot\
\ change this value."
createdBy:
description: "The user who initially created the task."
$ref: "#/definitions/models.User"
description:
type: "string"
description: "The task description."
done:
type: "boolean"
description: "Whether a task is done or not."
doneAt:
type: "integer"
description: "The unix timestamp when a task was marked as done."
dueDate:
type: "integer"
description: "A unix timestamp when the task is due."
endDate:
type: "integer"
description: "When this task ends."
hexColor:
type: "string"
description: "The task color in hex"
maxLength: 6
id:
type: "integer"
description: "The unique, numeric id of this task."
labels:
type: "array"
description: "An array of labels which are associated with this task."
items:
$ref: "#/definitions/models.Label"
listID:
type: "integer"
description: "The list this task belongs to."
percentDone:
type: "number"
description: "Determines how far a task is left from being done"
priority:
type: "integer"
description: "The task priority. Can be anything you want, it is possible\
\ to sort by this later."
related_tasks:
description: "All related tasks, grouped by their relation kind"
$ref: "#/definitions/models.RelatedTaskMap"
reminderDates:
type: "array"
description: "An array of unix timestamps when the user wants to be reminded\
\ of the task."
items:
type: "integer"
repeatAfter:
type: "integer"
description: "An amount in seconds this task repeats itself. If this is\
\ set, when marking the task as done, it will mark itself as \"undone\"\
\ and then increase all remindes and the due date by its amount."
startDate:
type: "integer"
description: "When this task starts."
text:
type: "string"
description: "The task text. This is what you'll see in the list."
minLength: 3
maxLength: 250
updated:
type: "integer"
description: "A unix timestamp when this task was last updated. You cannot\
\ change this value."
models.Task:
type: "object"
properties:
assignees:
type: "array"
description: "An array of users who are assigned to this task"
items:
$ref: "#/definitions/models.User"
attachments:
type: "array"
description: "All attachments this task has"
items:
$ref: "#/definitions/models.TaskAttachment"
created:
type: "integer"
description: "A unix timestamp when this task was created. You cannot change\
\ this value."
createdBy:
description: "The user who initially created the task."
$ref: "#/definitions/models.User"
description:
type: "string"
description: "The task description."
done:
type: "boolean"
description: "Whether a task is done or not."
doneAt:
type: "integer"
description: "The unix timestamp when a task was marked as done."
dueDate:
type: "integer"
description: "A unix timestamp when the task is due."
endDate:
type: "integer"
description: "When this task ends."
hexColor:
type: "string"
description: "The task color in hex"
maxLength: 6
id:
type: "integer"
description: "The unique, numeric id of this task."
labels:
type: "array"
description: "An array of labels which are associated with this task."
items:
$ref: "#/definitions/models.Label"
listID:
type: "integer"
description: "The list this task belongs to."
percentDone:
type: "number"
description: "Determines how far a task is left from being done"
priority:
type: "integer"
description: "The task priority. Can be anything you want, it is possible\
\ to sort by this later."
related_tasks:
description: "All related tasks, grouped by their relation kind"
$ref: "#/definitions/models.RelatedTaskMap"
reminderDates:
type: "array"
description: "An array of unix timestamps when the user wants to be reminded\
\ of the task."
items:
type: "integer"
repeatAfter:
type: "integer"
description: "An amount in seconds this task repeats itself. If this is set,\
\ when marking the task as done, it will mark itself as \"undone\" and then\
\ increase all remindes and the due date by its amount."
startDate:
type: "integer"
description: "When this task starts."
text:
type: "string"
description: "The task text. This is what you'll see in the list."
minLength: 3
maxLength: 250
updated:
type: "integer"
description: "A unix timestamp when this task was last updated. You cannot\
\ change this value."
example:
doneAt: 3
attachments:
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
percentDone: 1.024645700144157789424070870154537260532379150390625
endDate: 4
created: 9
reminderDates:
- 6
- 6
dueDate: 2
assignees:
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
description: "description"
related_tasks: {}
repeatAfter: 7
priority: 1
done: true
labels:
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
- created: 0
description: "description"
id: 5
hex_color: "hex_color"
title: "title"
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
updated: 2
listID: 1
hexColor: "hexColor"
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
id: 7
text: "text"
updated: 4
startDate: 1
models.TaskAssginee:
type: "object"
properties:
created:
type: "integer"
user_id:
type: "integer"
example:
user_id: 6
created: 0
models.TaskAttachment:
type: "object"
properties:
created:
type: "integer"
created_by:
$ref: "#/definitions/models.User"
file:
$ref: "#/definitions/files.File"
id:
type: "integer"
task_id:
type: "integer"
example:
file:
size: 5
created: "created"
mime: "mime"
name: "name"
id: 5
created: 1
task_id: 7
id: 2
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
models.TaskRelation:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this label was created. You cannot change\
\ this value."
created_by:
description: "The user who created this relation"
$ref: "#/definitions/models.User"
other_task_id:
type: "integer"
description: "The ID of the other task, the task which is being related."
relation_kind:
type: "string"
description: "The kind of the relation."
task_id:
type: "integer"
description: "The ID of the \"base\" task, the task which has a relation to\
\ another."
example:
created: 0
relation_kind: "relation_kind"
task_id: 1
created_by:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
other_task_id: 6
models.Team:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this relation was created. You cannot\
\ change this value."
createdBy:
description: "The user who created this team."
$ref: "#/definitions/models.User"
description:
type: "string"
description: "The team's description."
id:
type: "integer"
description: "The unique, numeric id of this team."
members:
type: "array"
description: "An array of all members in this team."
items:
$ref: "#/definitions/models.TeamUser"
name:
type: "string"
description: "The name of this team."
minLength: 5
maxLength: 250
updated:
type: "integer"
description: "A unix timestamp when this relation was last updated. You cannot\
\ change this value."
example:
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
created: 0
members:
- avatarUrl: "avatarUrl"
created: 1
admin: true
id: 5
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 1
admin: true
id: 5
updated: 5
email: "email"
username: "username"
name: "name"
description: "description"
id: 6
updated: 1
models.TeamList:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this relation was created. You cannot\
\ change this value."
id:
type: "integer"
description: "The unique, numeric id of this list <-> team relation."
right:
type: "integer"
description: "The right this team has. 0 = Read only, 1 = Read & Write, 2\
\ = Admin. See the docs for more details."
maximum: 2
teamID:
type: "integer"
description: "The team id."
updated:
type: "integer"
description: "A unix timestamp when this relation was last updated. You cannot\
\ change this value."
example:
created: 0
teamID: 5
id: 6
right: 0
updated: 5
models.TeamMember:
type: "object"
properties:
admin:
type: "boolean"
description: "Whether or not the member is an admin of the team. See the docs\
\ for more about what a team admin can do"
created:
type: "integer"
description: "A unix timestamp when this relation was created. You cannot\
\ change this value."
id:
type: "integer"
description: "The unique, numeric id of this team member relation."
username:
type: "string"
description: "The username of the member. We use this to prevent automated\
\ user id entering."
example:
created: 0
admin: true
id: 6
username: "username"
models.TeamNamespace:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this relation was created. You cannot\
\ change this value."
id:
type: "integer"
description: "The unique, numeric id of this namespace <-> team relation."
right:
type: "integer"
description: "The right this team has. 0 = Read only, 1 = Read & Write, 2\
\ = Admin. See the docs for more details."
maximum: 2
teamID:
type: "integer"
description: "The team id."
updated:
type: "integer"
description: "A unix timestamp when this relation was last updated. You cannot\
\ change this value."
example:
created: 0
teamID: 5
id: 6
right: 0
updated: 5
models.TeamUser:
type: "object"
properties:
admin:
type: "boolean"
description: "Whether or not the member is an admin of the team. See the docs\
\ for more about what a team admin can do"
avatarUrl:
type: "string"
description: "The users md5-hashed email address, used to get the avatar from\
\ gravatar and the likes."
created:
type: "integer"
description: "A unix timestamp when this task was created. You cannot change\
\ this value."
email:
type: "string"
description: "The user's email address."
maxLength: 250
id:
type: "integer"
description: "The unique, numeric id of this user."
updated:
type: "integer"
description: "A unix timestamp when this task was last updated. You cannot\
\ change this value."
username:
type: "string"
description: "The username of the user. Is always unique."
minLength: 3
maxLength: 250
example:
avatarUrl: "avatarUrl"
created: 1
admin: true
id: 5
updated: 5
email: "email"
username: "username"
models.TeamWithRight:
type: "object"
properties:
created:
type: "integer"
description: "A unix timestamp when this relation was created. You cannot\
\ change this value."
createdBy:
description: "The user who created this team."
$ref: "#/definitions/models.User"
description:
type: "string"
description: "The team's description."
id:
type: "integer"
description: "The unique, numeric id of this team."
members:
type: "array"
description: "An array of all members in this team."
items:
$ref: "#/definitions/models.TeamUser"
name:
type: "string"
description: "The name of this team."
minLength: 5
maxLength: 250
right:
type: "integer"
updated:
type: "integer"
description: "A unix timestamp when this relation was last updated. You cannot\
\ change this value."
example:
createdBy:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
created: 0
members:
- avatarUrl: "avatarUrl"
created: 1
admin: true
id: 5
updated: 5
email: "email"
username: "username"
- avatarUrl: "avatarUrl"
created: 1
admin: true
id: 5
updated: 5
email: "email"
username: "username"
name: "name"
description: "description"
id: 6
right: 2
updated: 7
models.User:
type: "object"
properties:
avatarUrl:
type: "string"
description: "The users md5-hashed email address, used to get the avatar from\
\ gravatar and the likes."
created:
type: "integer"
description: "A unix timestamp when this task was created. You cannot change\
\ this value."
email:
type: "string"
description: "The user's email address."
maxLength: 250
id:
type: "integer"
description: "The unique, numeric id of this user."
updated:
type: "integer"
description: "A unix timestamp when this task was last updated. You cannot\
\ change this value."
username:
type: "string"
description: "The username of the user. Is always unique."
minLength: 3
maxLength: 250
example:
avatarUrl: "avatarUrl"
created: 6
id: 1
updated: 5
email: "email"
username: "username"
models.UserLogin:
type: "object"
properties:
password:
type: "string"
description: "The password for the user."
username:
type: "string"
description: "The username used to log in."
models.UserWithRight:
type: "object"
properties:
avatarUrl:
type: "string"
description: "The users md5-hashed email address, used to get the avatar from\
\ gravatar and the likes."
created:
type: "integer"
description: "A unix timestamp when this task was created. You cannot change\
\ this value."
email:
type: "string"
description: "The user's email address."
maxLength: 250
id:
type: "integer"
description: "The unique, numeric id of this user."
right:
type: "integer"
updated:
type: "integer"
description: "A unix timestamp when this task was last updated. You cannot\
\ change this value."
username:
type: "string"
description: "The username of the user. Is always unique."
minLength: 3
maxLength: 250
example:
avatarUrl: "avatarUrl"
created: 0
id: 6
right: 1
updated: 5
email: "email"
username: "username"
v1.Token:
type: "object"
properties:
token:
type: "string"
example:
token: "token"
v1.UserPassword:
type: "object"
properties:
new_password:
type: "string"
old_password:
type: "string"
v1.vikunjaInfos:
type: "object"
properties:
frontend_url:
type: "string"
link_sharing_enabled:
type: "boolean"
max_file_size:
type: "integer"
motd:
type: "string"
version:
type: "string"
example:
link_sharing_enabled: true
max_file_size: 0
motd: "motd"
frontend_url: "frontend_url"
version: "version"