Skip to content
PharmaFlow Knowledgebase
Esc
↑↓navigate↵open⌘Jpreview

Declare the counted cash

Any signed in user. Files cash counted at the till against the session’s expected amount. It reads as overage, shortage, or balanced, and a caller with no session cannot declare.

POST/api/v1/sessions/tender
Authorization
AuthorizationBearer token (JWT) · headerrequired

JWT from POST /api/v1/auth/login sent as Authorization Bearer.

Request body
requiredapplication/json
declared_cashnumberrequired
notesstring
default: ""
Responses
200

The filed declaration

idstringrequired
session_idstringrequired
declared_cashstringrequired
expected_cashstringrequired
differencestringrequired
statusstringrequired
declared_atstringrequired
400

Invalid request body: a declared cash amount is required

detailstringrequired
401

Not authenticated

detailstringrequired
404

No active session

detailstringrequired
Try it
Server
Authorization
Bodyapplication/json
Request
curl -X POST 'http://localhost:8000/api/v1/sessions/tender' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "declared_cash": 0,
  "notes": ""
}'
Response
{
  "id": "string",
  "session_id": "string",
  "declared_cash": "string",
  "expected_cash": "string",
  "difference": "string",
  "status": "string",
  "declared_at": "string"
}