Mock Camera API
The Mock Camera API (Alert.CA.ImageAcquisition.MockCameraAPI) is an ASP.NET Core 10 Web API that simulates Axis camera responses for local development and testing. It eliminates the need for physical cameras or VPN access during development.
Architectureβ
When to Useβ
Use the Mock Camera API when:
- Developing locally without VPN access to real cameras
- Running unit/integration tests that need camera responses
- Testing orchestration logic without depending on camera availability
- Debugging image storage with consistent, repeatable image data
Controllersβ
CameraControllerβ
Simulates camera status, properties, and PTZ responses:
- Returns mock device information (model number, firmware version)
- Simulates PTZ position queries
- Returns predefined status responses
ImageControllerβ
Serves static images from sample directories:
- Returns JPEG images from preconfigured directories
- Simulates different camera locations with different image sets
Sample Image Dataβ
The Mock API includes static images from real camera locations:
| Directory | Contents |
|---|---|
StaticImages/ | 39 single-capture images across 4 camera locations (East Quincy, Fowler Peak, Golden Gate, Healdsburg) plus 19 generic images |
StaticPanoImages/ | 23 panoramic images mapped to 15 specific device IDs |
Documentation Sectionsβ
- Local Development Setup β How to configure and run the mock API
- Mock Endpoints β Available endpoints and response formats