mySmartAccessCard API
Read a business's attendance, hours and lateness from your own software, or connect it to an AI assistant.
Not a developer? See what the AI connector doesGetting a key
- The business owner opens AI & API in the dashboard on the website.
- They buy credits once, which unlocks keys, then click Create key.
- The key is shown once. We only keep a scrambled copy, so store it safely.
- Each key reads one business only. It never returns phone numbers, emails or user IDs.
- Keys are read-only unless the owner ticks "Allow jobs" when creating them.
- Nothing can edit attendance, salaries or settings.
Making a request
Send the key in the Authorization header. Every endpoint is a GET and returns JSON.
curl https://api.mysmartaccesscard.com/api/v1/attendance/now \
-H "Authorization: Bearer msac_live_your_key_here"Dates are YYYY-MM-DD in the business's own timezone. If you leave them out, today is used.
GET /api/v1/business
Your business name, type, timezone, opening and closing times, grace period and shifts.
GET /api/v1/attendance/now
Everyone checked in right now, with check-in time, shift and early, on time or late.
GET /api/v1/attendance/day?date=YYYY-MM-DD
One day's attendance: who came, who was late, who is absent (students include their class).
GET /api/v1/attendance?from=YYYY-MM-DD&to=YYYY-MM-DD
Every check-in and check-out between two dates, up to 62 days.
GET /api/v1/hours?from=YYYY-MM-DD&to=YYYY-MM-DD
Hours worked per person: regular, approved overtime and overtime waiting for approval. Same numbers as the salary screen.
GET /api/v1/late?from=YYYY-MM-DD&to=YYYY-MM-DD
Who arrived late, how many times and when.
GET /api/v1/overtime/pending
Overtime tap-outs waiting for a manager to approve, each with its overtime_id.
GET /api/v1/appointments/pending
Hospitals and clinics: appointment requests waiting, each with its appointment_id.
GET /api/v1/payment-claims/pending
Churches: event payment claims waiting, each with its claim_id, amount and reference.
GET /api/v1/leave/pending
Leave requests waiting for a decision, each with its leave_id.
GET /api/v1/reports/morning
Today's summary: checked in, late, not arrived, in now, waiting for approval. ₦20.
GET /api/v1/reports/weekly
Last 7 days per person: days present, times late, hours and overtime. ₦20.
GET /api/v1/reports/pay?month=YYYY-MM
Hours and overtime per person for a month. ₦20.
Jobs (keys with jobs allowed)
- Jobs are POST requests with a JSON body.
- Without "confirm": true, a job returns a free preview of exactly what it would do, and changes nothing.
- Show the preview to the user. Send it again with "confirm": true only when they agree.
- A confirmed job costs ₦10. If it fails, you are not charged.
POST /api/v1/jobs/approve-overtime
{ "overtime_id": "...", "confirm": true }
Approve one overtime record. The staff member is notified.
POST /api/v1/jobs/decide-leave
{ "leave_id": "...", "decision": "approve", "paid": true, "confirm": true }
Approve or reject a leave request. Use "reject" with an optional "reason".
POST /api/v1/jobs/review-appointment
{ "appointment_id": "...", "decision": "approve", "note": "...", "confirm": true }
Hospitals and clinics. Approve or decline an appointment request. The patient is notified.
POST /api/v1/jobs/decide-payment-claim
{ "claim_id": "...", "decision": "approve", "confirm": true }
Churches. Approve or reject an event payment claim. Approving adds the amount to what the person has paid.
POST /api/v1/jobs/school-message
{ "type": "sos", "message": "...", "confirm": true }
Schools only. Send an emergency (sos) or fee_reminder SMS to every parent. 5 of each per term, 160 characters.
AI assistant connector (MCP)
- The same questions, jobs and reports are available as a Model Context Protocol connector, for Claude, ChatGPT, Grok, Gemini and any MCP client.
- Address:
https://api.mysmartaccesscard.com/mcpwith the key as a Bearer token. - For assistants whose connector screen only takes an address, use
https://api.mysmartaccesscard.com/mcp/your_key. - Transport: Streamable HTTP, JSON responses.
- Sign-in connector (OAuth 2.1 with PKCE and dynamic client registration):
https://api.mysmartaccesscard.com/mcp-connect. The person signs in on mySmartAccessCard and chooses their business, or themselves as a parent, staff member or member. No key to copy.
Alerts to your own system (webhooks)
- In AI & API, switch on the alerts you want and add an https address.
- Every 5 minutes, anything new is sent in one POST with a JSON body: business, businessType, sentAt and a list of events.
- Each event has a kind (overtime, leave, autoClosed, appointment, paymentClaim, notCheckedIn) and a plain text message.
- Check the X-MSAC-Signature header: sha256= followed by the HMAC-SHA256 of the body, using your signing secret.
- Each alert costs ₦10, whether it goes to email, your address, or both.
Credits
- A question costs ₦2, a confirmed job ₦10 and a report ₦20. 1 credit is ₦1.
- Job previews are free.
- Failed calls are refunded automatically.
- Listing the connector's tools and connecting are free.
- Businesses on a paid plan get 100 free credits a month, used first.
- The smallest top-up is ₦2,000, paid through Paystack in the dashboard.
Limits
- 60 requests per minute per key.
- Date ranges up to 62 days.
- Up to 2,000 records per attendance request.
Errors
Errors come back as JSON: {"error": "..."}