Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 4 additions & 17 deletions ada-project-docs/wave_01.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,32 +150,19 @@ As a client, I want to be able to make a `PUT` request to `/tasks/1` when there

and get this response:

`200 OK`
`204 No Content`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍


```json
{
"task": {
"id": 1,
"title": "Updated Task Title",
"description": "Updated Test Description",
"is_complete": false
}
}
```
The response should have a mimetype of "application/json" to keep our API response type consistent.

Note that the update endpoint does update the `completed_at` attribute. This will be updated with custom endpoints implemented in Wave 3.

#### Delete Task: Deleting a Task

As a client, I want to be able to make a `DELETE` request to `/tasks/1` when there is at least one saved task and get this response:

`200 OK`
`204 No Content`

```json
{
"details": "Task 1 \"Go on my daily walk 🏞\" successfully deleted"
}
```
The response should have a mimetype of "application/json" to keep our API response type consistent.

#### No Matching Task: Get, Update, and Delete

Expand Down
24 changes: 24 additions & 0 deletions ada-project-docs/wave_03.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ when I send a `PATCH` request to `/tasks/1/mark_complete`,

then the task is updated, so that its `completed_at` value is the current date, and I get this response:

`204 No Content`

The response should have a mimetype of "application/json" to keep our API response type consistent.

After I have made the `PATCH` request, I can submit a `GET` request to `/tasks/1`, which will return the response:

`200 OK`

```json
Expand All @@ -58,6 +64,12 @@ when I send a `PATCH` request to `/tasks/1/mark_incomplete`,

then the task is updated, so that its `completed_at` value is `null`/`None`, and I get this response:

`204 No Content`

The response should have a mimetype of "application/json" to keep our API response type consistent.

After I have made the `PATCH` request, I can submit a `GET` request to `/tasks/1`, which will return the response:

`200 OK`

```json
Expand All @@ -82,6 +94,12 @@ when I send a `PATCH` request to `/tasks/1/mark_complete`,

then I want this to behave exactly like `/tasks/1/mark_complete` for an incomplete task. The task is updated, so that its `completed_at` value is the current date, and I get this response:

`204 No Content`

The response should have a mimetype of "application/json" to keep our API response type consistent.

After I have made the `PATCH` request, I can submit a `GET` request to `/tasks/1`, which will return the response:

`200 OK`

```json
Expand All @@ -106,6 +124,12 @@ when I send a `PATCH` request to `/tasks/1/mark_incomplete`,

then I want this to behave exactly like `/tasks/1/mark_incomplete` for a complete task. Its `completed_at` value remains as `null`/`None`, and I get this response:

`204 No Content`

The response should have a mimetype of "application/json" to keep our API response type consistent.

After I have made the `PATCH` request, I can submit a `GET` request to `/tasks/1`, which will return the response:

`200 OK`

```json
Expand Down
19 changes: 4 additions & 15 deletions ada-project-docs/wave_05.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,28 +125,17 @@ As a client, I want to be able to make a `PUT` request to `/goals/1` when there

and get this response:

`200 OK`
`204 No Content`

```json
{
"goal": {
"id": 1,
"title": "Updated Goal Title"
}
}
```
The response should have a mimetype of "application/json" to keep our API response type consistent.

### Delete Goal: Deleting a Goal

As a client, I want to be able to make a `DELETE` request to `/goals/1` when there is at least one saved goal and get this response:

`200 OK`
`204 No Content`

```json
{
"details": "Goal 1 \"Build a habit of going outside daily\" successfully deleted"
}
```
The response should have a mimetype of "application/json" to keep our API response type consistent.

### No matching Goal: Get, Update, and Delete

Expand Down