# govuk-once/govuk-mobile-ios-app architecture

> Architecture diagram of the GitHub repository govuk-once/govuk-mobile-ios-app, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-26). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/govuk-once/govuk-mobile-ios-app
- Repository: https://github.com/govuk-once/govuk-mobile-ios-app

## Overview

GOV.UK for iOS is a user-facing services app. Users enter through launch and authentication, then reach home and navigate to services such as search, topics, chat, DVLA, travel, notifications, local authority lookup and recent activity. Coordinators manage navigation; view controllers and builders connect user interaction to service-facing parts of the app. The excerpts directly support the home-to-search transition and authentication’s calls, but do not show wiring for most feature flows, so those relationships are not inferred. The README describes no additional product capabilities.

Main entry points: [`Production/govuk_ios/Services/AuthenticationService.swift`](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/AuthenticationService.swift) (Authentication), [`Production/govuk_ios/ServiceClients/AuthenticationServiceClient.swift`](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/ServiceClients/AuthenticationServiceClient.swift) (Auth client), [`Production/govuk_ios/ViewControllers/HomeViewController.swift`](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/ViewControllers/HomeViewController.swift) (Home screen), [`Production/govuk_ios/Coordinators/Launch/LaunchCoordinator.swift`](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Coordinators/Launch/LaunchCoordinator.swift) (Launch flow)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["App entry"]
  node_launch["Launch flow"]
  node_appcoord["App coordinator"]
end

subgraph group_experience["User experience"]
  node_home["Home screen"]
  node_search["Search screen"]
  node_builder["Screen builder"]
  node_coord["Feature coordinators"]
end

subgraph group_services["Domain services"]
  node_auth["Authentication"]
  node_searchsvc["Search service"]
  node_topics["Topics service"]
  node_chat["Chat service<br/>[ChatService.swift]"]
  node_dvla["DVLA service<br/>[DVLAService.swift]"]
  node_travel["Travel service"]
  node_local["Authority service"]
  node_notify["Notification service"]
  node_activity["Activity service"]
end

subgraph group_data["Data and networking"]
  node_client["Auth client"]
  node_network["API networking"]
  node_history[("Search history")]
end

subgraph group_platform["Platform integrations"]
  node_secure["Secure token store"]
  node_analytics["Analytics service"]
end

node_user(("App user"))
node_identity{{"Authentication provider"}}

node_user -->|"opens app"| node_launch
node_launch -->|"starts"| node_appcoord
node_appcoord -->|"shows home"| node_home
node_user -->|"uses"| node_home
node_home -->|"presents search"| node_search
node_search -.->|"history storage"| node_history
node_auth -->|"requests auth"| node_client
node_auth -->|"stores tokens"| node_secure
node_auth -->|"tracks errors"| node_analytics
node_auth -->|"authenticates"| node_identity
node_client -->|"performs login"| node_identity
node_client -->|"revokes token"| node_network

click node_launch "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Coordinators/Launch/LaunchCoordinator.swift"
click node_appcoord "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Coordinators/Launch/AppCoordinator.swift"
click node_home "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/ViewControllers/HomeViewController.swift"
click node_search "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/ViewControllers/Search/SearchViewController.swift"
click node_builder "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Builders/ViewControllerBuilder.swift"
click node_coord "https://github.com/govuk-once/govuk-mobile-ios-app/tree/main/Production/govuk_ios/Coordinators"
click node_auth "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/AuthenticationService.swift"
click node_searchsvc "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/SearchService.swift"
click node_topics "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/TopicsService.swift"
click node_chat "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/ChatService.swift"
click node_dvla "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/DVLA/DVLAService.swift"
click node_travel "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/TravelService.swift"
click node_local "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/LocalAuthorityService.swift"
click node_notify "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/NotificationCentreService.swift"
click node_activity "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/ActivityService.swift"
click node_client "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/ServiceClients/AuthenticationServiceClient.swift"
click node_network "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Networking/APIServiceClient.swift"
click node_history "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Repositories/SearchHistoryRepository.swift"
click node_secure "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/AuthenticationService.swift"
click node_analytics "https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/Analytics/AnalyticsService.swift"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_launch,node_appcoord,node_user toneBlue
class node_home,node_search,node_builder,node_coord toneAmber
class node_auth,node_searchsvc,node_topics,node_chat,node_dvla,node_travel,node_local,node_notify,node_activity toneMint
class node_client,node_network,node_history toneRose
class node_secure,node_analytics,node_identity toneIndigo
```

## Components

### App entry

- [Launch flow](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Coordinators/Launch/LaunchCoordinator.swift): `Production/govuk_ios/Coordinators/Launch/LaunchCoordinator.swift`
- [App coordinator](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Coordinators/Launch/AppCoordinator.swift): `Production/govuk_ios/Coordinators/Launch/AppCoordinator.swift`

### User experience

- [Home screen](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/ViewControllers/HomeViewController.swift): `Production/govuk_ios/ViewControllers/HomeViewController.swift`
- [Search screen](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/ViewControllers/Search/SearchViewController.swift): `Production/govuk_ios/ViewControllers/Search/SearchViewController.swift`
- [Screen builder](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Builders/ViewControllerBuilder.swift): `Production/govuk_ios/Builders/ViewControllerBuilder.swift`
- [Feature coordinators](https://github.com/govuk-once/govuk-mobile-ios-app/tree/main/Production/govuk_ios/Coordinators): `Production/govuk_ios/Coordinators`

### Domain services

- [Authentication](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/AuthenticationService.swift): `Production/govuk_ios/Services/AuthenticationService.swift`
- [Search service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/SearchService.swift): `Production/govuk_ios/Services/SearchService.swift`
- [Topics service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/TopicsService.swift): `Production/govuk_ios/Services/TopicsService.swift`
- [Chat service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/ChatService.swift): `Production/govuk_ios/Services/ChatService.swift`
- [DVLA service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/DVLA/DVLAService.swift): `Production/govuk_ios/Services/DVLA/DVLAService.swift`
- [Travel service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/TravelService.swift): `Production/govuk_ios/Services/TravelService.swift`
- [Authority service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/LocalAuthorityService.swift): `Production/govuk_ios/Services/LocalAuthorityService.swift`
- [Notification service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/NotificationCentreService.swift): `Production/govuk_ios/Services/NotificationCentreService.swift`
- [Activity service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/ActivityService.swift): `Production/govuk_ios/Services/ActivityService.swift`

### Data and networking

- [Auth client](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/ServiceClients/AuthenticationServiceClient.swift): `Production/govuk_ios/ServiceClients/AuthenticationServiceClient.swift`
- [API networking](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Networking/APIServiceClient.swift): `Production/govuk_ios/Networking/APIServiceClient.swift`
- [Search history](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Repositories/SearchHistoryRepository.swift): `Production/govuk_ios/Repositories/SearchHistoryRepository.swift`

### Platform integrations

- [Secure token store](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/AuthenticationService.swift): `Production/govuk_ios/Services/AuthenticationService.swift`
- [Analytics service](https://github.com/govuk-once/govuk-mobile-ios-app/blob/main/Production/govuk_ios/Services/Analytics/AnalyticsService.swift): `Production/govuk_ios/Services/Analytics/AnalyticsService.swift`

### Other components

- **App user**
- **Authentication provider**

## Connections

- App user → Launch flow: opens app
- Launch flow → App coordinator: starts
- App coordinator → Home screen: shows home
- App user → Home screen: uses
- Home screen → Search screen: presents search
- Search screen → Search history: history storage
- Authentication → Auth client: requests auth
- Authentication → Secure token store: stores tokens
- Authentication → Analytics service: tracks errors
- Authentication → Authentication provider: authenticates
- Auth client → Authentication provider: performs login
- Auth client → API networking: revokes token
