Recommendations
Create recommendations for the location schedule
Body
Required
since
string | string(date) Required until
string | string(date) Required -
location
object Required -
assignCaptain
boolean Default value is
false
. -
maxAssignmentsCount
integer Default value is
4
.
POST
/api/assignments/recommendations
curl \
-X POST https://metropolitanabolivia.org/api/assignments/recommendations \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"since":"string","until":"string","location":{"id":"string"},"assignCaptain":false,"maxAssignmentsCount":4}'
Request example
{
"since": "string",
"until": "string",
"location": {
"id": "string"
},
"assignCaptain": false,
"maxAssignmentsCount": 4
}
Response examples (200)
[
{
"date": "string",
"isCaptain": false,
"isAccepted": true,
"isEditable": true,
"id": "string",
"shift": {
"id": "string",
"startTime": "09:42:00+00:00",
"endTime": "09:42:00+00:00",
"location": {
"id": "string",
"name": "string"
},
"dayOfWeek": 42
},
"user": {
"firstName": "string",
"lastName": "string",
"email": "string",
"primaryPhone": "string",
"secondaryPhone": "string",
"isWhatsappEnabled": true,
"isCaptain": true,
"isEnabled": true,
"id": "string",
"name": "string",
"username": "string",
"role": 100,
"congregation": {
"id": "string",
"name": "string",
"city": "string",
"state": "string"
},
"availabilityCount": 42,
"availability": [
{
"id": "string",
"shift": {
"startTime": "09:42:00+00:00",
"endTime": "09:42:00+00:00",
"dayOfWeek": 42,
"seatsCount": 42,
"isEnabled": true,
"id": "string",
"location": {
"id": "string",
"name": "string"
}
}
}
],
"whatsappPrimaryPhone": "string",
"lastSignedInAt": "2024-05-04T09:42:00+00:00",
"createdAt": "2024-05-04T09:42:00+00:00",
"updatedAt": "2024-05-04T09:42:00+00:00"
},
"isSubstitution": false,
"createdAt": "2024-05-04T09:42:00+00:00",
"updatedAt": "2024-05-04T09:42:00+00:00"
}
]
Response examples (422)
{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}