@lap v0.3
# Machine-readable API spec. Each @endpoint block is one API call.
@api Annotations API
@version 1.0.0
@endpoints 7
@toc projects(7)

@endpoint GET /projects/{projectId}/annotations
@returns(200) {status: str, results: [map]}
@errors {401, 403}

@endpoint POST /projects/{projectId}/annotations
@optional {date: str, description: str, tags: [num]}
@returns(201) {status: str, results: map{date: str, description: str, id: num, user: map{id: num, first_name: str, last_name: str}, tags: [map]}}
@errors {401, 403}

@endpoint GET /projects/{projectId}/annotations/{annotationId}
@returns(200) {status: str, results: map{date: str, description: str, id: num, user: map{id: num, first_name: str, last_name: str}, tags: [map]}}
@errors {401, 403}

@endpoint PATCH /projects/{projectId}/annotations/{annotationId}
@optional {description: str, tags: [num]}
@returns(200) {status: str, results: map{date: str, description: str, id: num, user: map{id: num, first_name: str, last_name: str}, tags: [map]}}
@errors {401, 403}

@endpoint DELETE /projects/{projectId}/annotations/{annotationId}
@returns(200) {status: str, results: map{id: num}}
@errors {401, 403}

@endpoint GET /projects/{projectId}/annotations/tags
@returns(200)
@errors {401, 403}

@endpoint POST /projects/{projectId}/annotations/tags
@optional {name: str}
@returns(200) {id: num, name: str, project_id: num, has_annotations: bool}
@errors {401, 403}

@end
