[R5] Update README with API Documentation for POST /patients

This commit is contained in:
Mirna Gama 2024-01-06 18:59:42 -03:00 committed by Mirna Gama
parent 7739b190ac
commit 9c0fec4fdf

View File

@ -186,3 +186,33 @@ Hospital Management API built in Spring Boot
| `200` | _Successful operation_ | | `200` | _Successful operation_ |
| `400` | _Validation Error_ | | `400` | _Validation Error_ |
### /patients
#### POST - [**/api/v1.0/patients**] - Adds a new patient
- **Body:**
```
{
"name" (string, required),
"email" (string, required),
"cpf" (string, required),
"telephone" (string, required),
"address": {
"street" (string, required),
"neighborhood" (string, required),
"zipCode" (string, required),
"city" (string, required),
"state" (string, required),
"additionalDetails" (string, optional),
"houseNumber" (string, optional)
}
}
```
- **Responses:**
| Code | Description |
| ------------- | ------------- |
| `201` | _Successfully created_ |
| `400` | _Validation Error_ |