MartService API

MartService exposes the first-pass service marketplace API under /api/v1/mart-service. Routes are authenticated with Sanctum, require an active workspace through the active-workspace header or workspace_id, and remain behind PlanModuleCheck:MartService.

Data Ownership

  • Service catalog records reuse product_service_items with type equal to service or the existing app convention Service.
  • Customer billing reuses sales_invoices and sales_invoice_items with invoice type = service.
  • Provider profiles, servicemen, bookings, booking items, booking status events, service posts, and post bids are owned by MartService package tables prefixed with mart_service_.
  • Controllers delegate to Form Requests, DTOs, services, and repositories. Controllers do not query models directly.

Routes

Example Payloads

Create provider:
Create booking:
Create service post bid:

Permissions

The package seeds MartService permissions such as manage-mart-service, manage-mart-service-providers, manage-mart-service-servicemen, manage-mart-service-bookings, manage-mart-service-requests, and manage-mart-service-bids. This API slice currently relies on module and authenticated workspace access; route-level permission middleware can be layered on top as provider/admin UI roles are introduced.