aidapov
v2025.11.2
Published
Rest API wrapper for Aida POV NDI cameras with 0 dependencies.
Readme
AidaPOV
A TypeScript REST API wrapper for Aida POV NDI cameras with zero dependencies.
Overview
AidaPOV is a lightweight TypeScript library for controlling Aida POV NDI cameras over HTTP. It provides a simple, promise-based API for camera control, image settings, and configuration management.
Supported Camera: Aida POV NDI
Features
- Zero Dependencies - Pure TypeScript implementation
- Image Settings - Exposure, white balance, iris, shutter control
- Advanced Features - WDR, noise reduction, gamma correction
- Type Safety - Full TypeScript support with type definitions
- Promise-based - Modern async/await API
Installation
npm install aidapovBasic example
import { AidaPOV } from 'aidapov';
// Initialize camera connection
const camera = new AidaPOV('192.168.1.100', 'admin', 'password');
// Wait for authentication
await camera.whenReady();
// Get streaming URL
const streamUrl = await camera.getRTSPUrl('main');
console.log('Stream URL:', streamUrl);
// Set camera exposure mode to auto
await camera.setExposureMode('auto');API Reference
Constructor
Return values
Camera
Exposure
- setExposureMode
- getExposureMode
- setShutter
- getShutter
- setExposureGain
- getExposureGain
- setAntiFlicker
- getAntiFlicker
White Balance
- setWhiteBalanceMode
- getWhiteBalanceMode
- setRedGain
- getRedGain
- setBlueGain
- getBlueGain
- setColorTemperature
- getColorTemperature
Image
- setMirror
- getMirror
- setFlip
- getFlip
- setBacklightCompensation
- getBacklightCompensation
- setGamma
- getGamma
- setWideDynamicRange
- getWideDynamicRange
Image Quality
Noise Reduction
Streaming
Constructor
new AidaPOV(ip: string, username: string, password: string)ip- Camera IP addressusername- Camera login usernamepassword- Camera login password
Return Values
Important: All set methods return a Promise<boolean>:
true- Command executed successfullyfalse- Command failed or something went wrong
Note: get methods return the actual values, while control methods (move, zoom, focus) return boolean success indicators.
Camera
whenReady
await camera.whenReady(): Promise<void>Wait for authentication to complete before sending commands.
onError
camera.onError(callback: (error: Error) => void): voidSet error handler for authentication and request failures.
getInfo
await camera.getInfo(): Promise<{
app_version: string;
bootloader_version: string;
device_name: string;
serial_number: string;
system_version: string;
}>Get camera system information including firmware versions and device details.
Exposure
setExposureMode
await camera.setExposureMode(
mode: 'auto' | 'manual'
): Promise<boolean>Set exposure mode.
getExposureMode
await camera.getExposureMode(): Promise<'auto' | 'manual'>Get current exposure mode.
setShutter
await camera.setShutter(speed: string): Promise<boolean>Only applicable when exposure mode is set to
manualorshutter priority
Set shutter speed.
Available shutter speeds: '1/60', '1/90', '1/100', '1/125', '1/180', '1/250', '1/350', '1/500', '1/725', '1/1000', '1/1500', '1/2000', '1/3000', '1/4000', '1/6000', '1/10000'
getShutter
await camera.getShutter(): Promise<string>Get current shutter speed.
setExposureGain
await camera.setExposureGain(gain: string): Promise<boolean>Only applicable when exposure mode is set to
manual
Set exposure gain.
Available gain values: '0dB' to '30dB' in 2dB increments
getExposureGain
await camera.getExposureGain(): Promise<string>Get current exposure gain.
setAntiFlicker
await camera.setAntiFlicker(frequency: 'Off' | '50Hz' | '60Hz'): Promise<boolean>Only applicable when exposure mode is set to
autooriris priority
Set anti-flicker frequency.
getAntiFlicker
await camera.getAntiFlicker(): Promise<string>Get current anti-flicker setting.
White Balance
setWhiteBalanceMode
await camera.setWhiteBalanceMode(
mode: 'auto' | 'indoor' | 'outdoor' | 'one push' | 'auto tracking' | 'manual' | 'temperature'
): Promise<boolean>Set white balance mode.
getWhiteBalanceMode
await camera.getWhiteBalanceMode(): Promise<'auto' | 'indoor' | 'outdoor' | 'one push' | 'auto tracking' | 'manual' | 'temperature'>Get current white balance mode.
setRedGain
await camera.setRedGain(value: number): Promise<boolean> // 0-255Only applicable when white balance mode is set to
manual
Set red gain.
getRedGain
await camera.getRedGain(): Promise<number>Get current red gain.
setBlueGain
await camera.setBlueGain(value: number): Promise<boolean> // 0-255Only applicable when white balance mode is set to
manual
Set blue gain.
getBlueGain
await camera.getBlueGain(): Promise<number>Get current blue gain.
setColorTemperature
await camera.setColorTemperature(value: number): Promise<boolean> // 1800-10000KOnly applicable when white balance mode is set to
temperature
Set color temperature.
getColorTemperature
await camera.getColorTemperature(): Promise<number>Get current color temperature.
Image
setMirror
await camera.setMirror(enabled: boolean): Promise<boolean>Enable or disable image mirroring.
getMirror
await camera.getMirror(): Promise<boolean>Get current mirror setting.
setFlip
await camera.setFlip(enabled: boolean): Promise<boolean>Enable or disable image flipping.
getFlip
await camera.getFlip(): Promise<boolean>Get current flip setting.
setBacklightCompensation
await camera.setBacklightCompensation(enabled: boolean): Promise<boolean>Enable or disable backlight compensation.
getBacklightCompensation
await camera.getBacklightCompensation(): Promise<boolean>Get current backlight compensation setting.
setGamma
await camera.setGamma(value: number): Promise<boolean> // 0-4Set gamma correction value.
getGamma
await camera.getGamma(): Promise<number>Get current gamma correction value.
setWideDynamicRange
await camera.setWideDynamicRange(mode: 'Off' | 1 | 2 | 3 | 4 | 5 | 6): Promise<boolean>Set wide dynamic range mode.
getWideDynamicRange
await camera.getWideDynamicRange(): Promise<string | number>Get current wide dynamic range setting.
Image Quality
setBrightness
await camera.setBrightness(value: number): Promise<boolean> // 0-15Only applicable when exposure mode is set to
auto,iris priorityorshutter priority
Set image brightness.
getBrightness
await camera.getBrightness(): Promise<number>Get current brightness value.
setSharpness
await camera.setSharpness(value: number): Promise<boolean> // 0-15Set image sharpness.
getSharpness
await camera.getSharpness(): Promise<number>Get current sharpness value.
setContrast
await camera.setContrast(value: number): Promise<boolean> // 0-15Set image contrast.
getContrast
await camera.getContrast(): Promise<number>Get current contrast value.
setSaturation
await camera.setSaturation(value: number): Promise<boolean> // 0-15Set image saturation.
getSaturation
await camera.getSaturation(): Promise<number>Get current saturation value.
Noise Reduction
set2dNoiseReduction
await camera.set2dNoiseReduction(enabled: boolean): Promise<boolean>Enable or disable 2D noise reduction.
get2dNoiseReduction
await camera.get2dNoiseReduction(): Promise<boolean>Get current 2D noise reduction setting.
set3dNoiseReduction
await camera.set3dNoiseReduction(mode: 'Off' | 'Auto' | '1' | '2' | '3' | '4'): Promise<boolean>Set 3D noise reduction mode.
get3dNoiseReduction
await camera.get3dNoiseReduction(): Promise<string>Get current 3D noise reduction setting.
Streaming
getRTSPUrl
await camera.getRTSPUrl(type?: 'main' | 'sub'): Promise<string>Get RTSP streaming URL. Defaults to 'main' stream if type not specified.
getRTMPUrl
await camera.getRTMPUrl(type?: 'main' | 'sub'): Promise<string>Get RTMP streaming URL. Defaults to 'main' stream if type not specified.
getFLVUrl
await camera.getFLVUrl(type?: 'main' | 'sub'): Promise<string>Get FLV streaming URL. Defaults to 'main' stream if type not specified.
getWebRTCUrl
await camera.getWebRTCUrl(type?: 'main' | 'sub'): Promise<string>Get WebRTC streaming URL. Defaults to 'main' stream if type not specified.
Stream Types:
'main'- High quality stream (default) - 1920×1080 up to 60fps'sub'- Lower quality stream - Various resolutions up to 1280×720
