Added PATCH verb end point for annotation op
Added new PATCH verb annotation endpoint Removed unwanted fmt Added test cases for PATCH verb annotation endpoint Fixed formatting issue Check arr len before proceeding Updated doc to include PATCH verb annotation endpt
This commit is contained in:
@@ -160,15 +160,18 @@ Content-Type: application/json
|
||||
}
|
||||
```
|
||||
|
||||
## Update Annotation
|
||||
## Replace Annotation
|
||||
|
||||
`PUT /api/annotations/:id`
|
||||
|
||||
Replaces the annotation that matches the specified id.
|
||||
|
||||
**Example Request**:
|
||||
|
||||
```json
|
||||
PUT /api/annotations/1141 HTTP/1.1
|
||||
Accept: application/json
|
||||
Authorization: Bearer eyJrIjoiT0tTcG1pUlY2RnVKZTFVaDFsNFZXdE9ZWmNrMkZYbk
|
||||
Content-Type: application/json
|
||||
|
||||
{
|
||||
@@ -180,6 +183,28 @@ Content-Type: application/json
|
||||
}
|
||||
```
|
||||
|
||||
## Update Annotation
|
||||
|
||||
`PATCH /api/annotations/:id`
|
||||
|
||||
Updates one or more properties of an annotation that matches the specified id.
|
||||
|
||||
**Example Request**:
|
||||
|
||||
```json
|
||||
PATCH /api/annotations/1145 HTTP/1.1
|
||||
Accept: application/json
|
||||
Authorization: Bearer eyJrIjoiT0tTcG1pUlY2RnVKZTFVaDFsNFZXdE9ZWmNrMkZYbk
|
||||
Content-Type: application/json
|
||||
|
||||
{
|
||||
"time":1507037197000,
|
||||
"timeEnd":1507180807095,
|
||||
"text":"New Annotation Description",
|
||||
"tags":["tag6","tag7","tag8"]
|
||||
}
|
||||
```
|
||||
|
||||
## Delete Annotation By Id
|
||||
|
||||
`DELETE /api/annotations/:id`
|
||||
|
||||
Reference in New Issue
Block a user