Back to projects
iOS & Android API

HR & Payroll App — Mobile API

Employee Self-Service: Payslips, Leave, Expenses & Approvals

LaravelPHP 8.2MySQLSanctumQueuesPDFFCM
Platforms
iOS + Android
Auth
Sanctumtokens
Real-time
FCM push
Documents
PDF payslips
iOS & Android · REST APIUI concept
HR & Payroll App — Mobile API — screenshot

Employee self-service API for an HR and payroll system. Employees view and download payslips, apply for leave, submit expense claims and read company announcements. Managers approve requests from the same app, and HR keeps full records.

Architecture & System Design

Requests such as leave and expenses follow a configurable approval chain based on the employee's department and manager. Payslips are generated as PDFs by queued jobs after payroll runs and served through signed, expiring links because they contain sensitive salary data.

Request Flow
Employee Request
Approval Chain
Manager Decision
Notification
HR Records
Payroll & Payslip PDF
  • Configurable approval chains per department
  • Payslip PDFs generated in queued jobs after each payroll run
  • Signed, expiring download links for sensitive documents
  • Role-based access for employees, managers and HR

Engineering Challenges

Protecting Salary Data

Problem

Payslips are highly sensitive and must never be accessible through guessable URLs.

Solution

Stored PDFs privately and issued short-lived signed URLs only after verifying the requester owns the payslip or has an HR role.

Result

Employees can download their payslips easily without exposing anyone else's.

Different Approval Rules per Team

Problem

Some departments needed one approver, others needed a manager and then HR.

Solution

Modelled approval chains as data, so each request type and department defines its own steps without code changes.

Result

New approval rules can be set up by configuration instead of development work.

Core Features

Payslips

Monthly payslips with earnings and deductions, downloadable as PDF.

Clean Code

PayslipController.php
1public function download(Request $request, Payslip $payslip): JsonResponse
2{
3 $this->authorize('view', $payslip);
4
5 $url = Storage::disk('private')->temporaryUrl(
6 $payslip->pdf_path,
7 now()->addMinutes(5)
8 );
9
10 return response()->json(['url' => $url]);
11}

Want something like this for your business?

I design and build full stack products end to end. Tell me about your idea and I'll get back to you with a plan.