Ir al contenido

Restaurant - Attendance Record

AttendanceRecordController_update

PATCH
/restaurant/attendance-record/{id}
curl --request PATCH \
--url https://api.inspow.tech/api/v1/restaurant/attendance-record/example \
--header 'Content-Type: application/json' \
--data '{ "tenant_id": "645cc3d3f8a9c9a2b88a22a1", "subscription": "645cc3d3f8a9c9a2b88a22f1", "mealType": "BREAKFAST", "serviceDate": "now", "entryMethod": "MANUAL", "methodMeta": { "qrPayload": "subscription_123_meal_lunch_date_2024-08-24", "deviceId": "scanner_001", "locationId": "cafeteria_main", "notes": "Scanned at main entrance" }, "requestId": "req_lunch_2024-08-24_abc123", "timezoneOffset": 300, "createdBy": "645cc3d3f8a9c9a2b88a22c4", "updatedBy": "645cc3d3f8a9c9a2b88a22c5" }'
id
required
string
Media type application/json
object
tenant_id

Tenant ID (automatically injected from JWT)

string
Example
645cc3d3f8a9c9a2b88a22a1
subscription

The ID of the subscription this invoice covers.

string
Example
645cc3d3f8a9c9a2b88a22f1
mealType

Type of meal for this attendance record.

string
default: LUNCH
Allowed values: BREAKFAST LUNCH DINNER SNACK DESSERT
Example
LUNCH
serviceDate

Date of service.

string format: date-time
default: now
Example
2024-08-24T00:00:00Z
entryMethod

Method of entry registration.

string
default: MANUAL
Allowed values: MANUAL QR BARCODE NFC FACE
Example
QR
methodMeta

Metadata specific to the entry method (QR payload, NFC UID, etc.).

object
Example
{
"qrPayload": "subscription_123_meal_lunch_date_2024-08-24",
"deviceId": "scanner_001",
"locationId": "cafeteria_main",
"notes": "Scanned at main entrance"
}
requestId

Unique request ID for idempotency (prevents duplicate records).

string
Example
req_lunch_2024-08-24_abc123
timezoneOffset

Timezone offset in minutes from UTC. Positive values are west of UTC (e.g., 300 for UTC-5).

number
Example
300
createdBy

User who created this attendance record.

string format: MongoId
Example
645cc3d3f8a9c9a2b88a22c4
updatedBy

User who last updated this attendance record.

string format: MongoId
Example
645cc3d3f8a9c9a2b88a22c5