رِفد

REST API v1

Base URL https://rifd.jusoor-tech.com/api/v1 · JSON · Bearer token (Sanctum, 30 days) · 60 requests/minute. Amounts are integer halalas (1 SAR = 100). The API applies exactly the same workflow and permissions as the web portals.

MethodPathWhoNotes
POST/loginallemail, password, device_name [, code]. Two-factor users get 202 {otp_required:true}; repeat with the e-mailed code.
POST/logoutallRevokes the current token.
GET/meallUser, role, portal, organization status.
GET/lookupspublicActive categories and cities.
GET/catalogcompanycategory_id, city_id filters. Price is this company's unit price.
GET/requestscompany · clinic · platformScoped to the caller's organization. ?status=
GET/requests/{id}company · clinic · platformEmployees, timeline, quotes, invoice.
POST/requestscompanytype=direct (service_id) or rfq (category_id, title); employees[] {name, id_number, nationality, phone, job_title}.
POST/requests/{id}/accept|reject|schedule|startclinicreject: reason · schedule: scheduled_at (ISO 8601).

Errors: 401 no/expired token · 403 role or organization not active · 404 not yours · 422 validation / workflow rule (message in errors) · 429 rate limit.