Service Layer low complexity mobile
3
Dependencies
1
Dependents
1
Entities
0
Integrations

Description

Orchestrates search execution, routing queries to Supabase when online or to the local Drift SQLite cache when offline. Handles debouncing, query normalization, and merging results from both sources. Exposes a unified search stream to the UI layer.

Feature: Contact & Notes Search

contact-search-service

Responsibilities

  • Route search queries to online or offline data source
  • Normalize and sanitize query strings
  • Merge and deduplicate results from multiple sources
  • Expose reactive search result stream

Interfaces

search(String query)
clearResults()
searchStream()
isOffline()
getLastQuery()

Relationships

Dependencies (3)

Components this component depends on

Dependents (1)

Components that depend on this component

Related Data Entities (1)

Data entities managed by this component

API Contract

View full contract →
REST /api/v1/contacts/search 4 endpoints
GET /api/v1/contacts/search/remote Trigger remote (Supabase) search for contacts
POST /api/v1/contacts/search/local Filter a provided contact list locally (client-side subset filtering)
GET /api/v1/contacts/peer-mentors/search/remote Remote search for peer mentors
POST /api/v1/contacts/peer-mentors/search/local Filter a provided peer mentor list locally