Append and Insert should return 201 on success. Delete should return 204 on success with no content.
This commit is contained in:
+2
-12
@@ -284,7 +284,7 @@ A new id is created for the appended route so it can be referenced later.
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
* **Success Responses**:
|
* **Success Responses**:
|
||||||
* **Code**: `200 OK`<br />
|
* **Code**: `201 Created`<br />
|
||||||
**Header**: `Content-Type: application/json`<br />
|
**Header**: `Content-Type: application/json`<br />
|
||||||
**Content**:<br />
|
**Content**:<br />
|
||||||
```json
|
```json
|
||||||
@@ -329,17 +329,7 @@ Removes the route identified by `:id`.
|
|||||||
* **URL**: `/routes/:id`
|
* **URL**: `/routes/:id`
|
||||||
* **Method**: `DELETE`
|
* **Method**: `DELETE`
|
||||||
* **Success Responses**:
|
* **Success Responses**:
|
||||||
* **Code**: `200 OK`<br />
|
* **Code**: `204 No Content`
|
||||||
**Content**:<br />
|
|
||||||
```json
|
|
||||||
{
|
|
||||||
"method": "GET",
|
|
||||||
"url_pattern": "/hello",
|
|
||||||
"entrypoint": null,
|
|
||||||
"command": "echo Hello World | response /body",
|
|
||||||
"index": 0
|
|
||||||
}
|
|
||||||
```
|
|
||||||
* **Error Responses**:
|
* **Error Responses**:
|
||||||
* **Code**: `404 Not Found`
|
* **Code**: `404 Not Found`
|
||||||
* **Sample Call**:<br />
|
* **Sample Call**:<br />
|
||||||
|
|||||||
@@ -12,4 +12,3 @@ Feature: Delete routes in Kapow! server.
|
|||||||
When I delete the first route
|
When I delete the first route
|
||||||
Then I get 200 as response code
|
Then I get 200 as response code
|
||||||
And I get "OK" as response reason phrase
|
And I get "OK" as response reason phrase
|
||||||
And I get an empty response body
|
|
||||||
|
|||||||
Reference in New Issue
Block a user