POST ./ani/vacations
It is used to add new period for a school year.
POST parameters
| Name | Value Type | Validation | Details |
|---|
| ascID | int | Required | School Year |
| name | string | Required; min_length[3] | Name of the vacation |
| startDate | date | Required; rfc_date | Sets the begininngs of the vacation. |
| endDate | date | Required; rfc_date | Sets the end of the vacation. |
Validation
| Error Field | Error Code | Error Message |
|---|
| ascID | 101 | Invalid ascID. |
| startDate, endDate | 102 | The date in invalid |
| endDate | 103 | The end date must be higher than start date. |
| endDate | 104 | The selected period is overlaped with other vacation. |
| startDate & endDate | 105 | The period should be fully included in the selected school year. |
Output example
{
"id": 13
}