Skip to content

Commit c88426b

Browse files
committed
prerelease
1 parent aa1a28a commit c88426b

File tree

10 files changed

+815
-18
lines changed

10 files changed

+815
-18
lines changed

.npmignore

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# Source files
2+
src/
3+
examples/
4+
tests/
5+
6+
# Config files
7+
tsconfig.json
8+
tsconfig.build.json
9+
tsconfig.cjs.json
10+
jest.config.ts
11+
12+
# Test and coverage (exclude from dist too)
13+
coverage/
14+
*.test.ts
15+
*.test.js
16+
*.test.js.map
17+
*.test.d.ts
18+
__tests__/
19+
dist/**/__tests__/
20+
dist/**/*.test.*
21+
22+
# Development files
23+
test-*.ts
24+
test-*.js
25+
*.log
26+
.env
27+
.DS_Store
28+
29+
# Build artifacts (keep dist/)
30+
node_modules/
31+
32+
# Documentation and misc
33+
README.md.backup
34+
VOD_GUIDE.md
35+
downloads/
36+
.github/
37+
SUBMISSION_READY.md
38+
PUBLISHING.md
39+
40+
# Scripts
41+
publish.sh
42+
43+
# Example files
44+
example-*.ts

API_DOCUMENTATION.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@
1212
## Installation
1313

1414
```bash
15-
npm install reolink-aio-ts
15+
npm install reolink-aio
1616
```
1717

1818
## Quick Start
1919

2020
```typescript
21-
import { Host } from 'reolink-aio-ts';
21+
import { Host } from 'reolink-aio';
2222

2323
// Create a connection
2424
const host = new Host('192.168.1.100', 'admin', 'your_password');
@@ -77,13 +77,10 @@ Reolink NVRs support multiple cameras (channels). Most methods accept a channel
7777

7878
```typescript
7979
// Single camera (channel 0)
80-
await host.setIrLights(0, true);
81-
8280
// Multiple channels on NVR
8381
for (const channel of host.channels) {
8482
console.log(host.cameraName(channel));
8583
}
86-
```
8784

8885
## API Reference
8986

CHANGELOG.md

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
# Changelog
2+
3+
All notable changes to this project will be documented in this file.
4+
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7+
8+
## [Unreleased]
9+
10+
## [0.1.0-alpha.0] - 2025-11-14
11+
12+
### Added - Initial Release
13+
14+
This is the first pre-release of `reolink-aio` - a TypeScript implementation of Reolink's Baichuan API (the same API used by official Reolink iOS/Android apps and CLI).
15+
16+
#### Core Features
17+
- **Full TypeScript Support** - Complete type safety and IntelliSense
18+
- **HTTP API Client** - Comprehensive REST API implementation
19+
- **Baichuan Protocol** - Real-time push events via TCP
20+
- **NVR & Camera Support** - Works with both standalone cameras and NVR systems
21+
- **Session Management** - Automatic token refresh and connection handling
22+
- **Error Handling** - Rich exception hierarchy for robust error management
23+
24+
#### Real-Time Events
25+
- Motion Detection - Real-time motion alerts via Baichuan
26+
- AI Detection - Person, vehicle, pet/animal, face, and package detection
27+
- Visitor Detection - Doorbell button press events
28+
- State Monitoring - Continuous monitoring of camera states
29+
- Event Subscription - Subscribe to push notifications
30+
31+
#### Video & Media
32+
- VOD File Search - Find recordings by time range and event type
33+
- Video Download - Download MP4 clips from NVR/cameras
34+
- Multiple Streams - Support for main and sub streams
35+
- Stream URLs - Generate FLV, RTMP, and RTSP URLs
36+
37+
#### Device Control
38+
- IR Lights - Control infrared illumination
39+
- Spotlight - Toggle camera spotlight with brightness control
40+
- Siren - Activate camera siren/audio alarm (fully working!)
41+
- Focus Control - Set camera focus position
42+
- Zoom Control - Set camera zoom position
43+
44+
#### Device Information
45+
- Device Discovery - Automatic NVR/camera detection
46+
- Channel Management - Multi-channel support for NVRs
47+
- Capability Detection - Automatic feature detection
48+
- Model Information - Device model, firmware, hardware version
49+
- Network Settings - Port configuration (RTSP, RTMP, ONVIF)
50+
51+
#### Testing & Documentation
52+
- Comprehensive JSDoc documentation across all APIs
53+
- Unit tests for utilities, types, and Baichuan protocol
54+
- Working examples for common use cases
55+
- API documentation guide
56+
57+
### Fixed
58+
- Baichuan TCP protocol XML formatting (critical blank line separator fix for siren/control commands)
59+
- Response future cleanup to prevent accumulation in long-running sessions
60+
61+
### Known Limitations
62+
- PTZ control not yet implemented
63+
- Snapshot capture not yet implemented
64+
- Advanced configuration management (OSD, schedules, zones) not yet implemented
65+
- Integration tests pending
66+
- Code coverage ~30% (baseline established)
67+
68+
### Breaking Changes
69+
- This is an initial pre-release; APIs may change in future versions
70+
71+
### Notes
72+
- Based on the Python [reolink-aio](https://github.com/starkillerOG/reolink_aio) library
73+
- Published under the `next` dist-tag on npm
74+
- Requires Node.js 18+
75+
- TypeScript 5.3+
76+
77+
[Unreleased]: https://github.com/verheesj/reolink-aio-ts/compare/v0.1.0-alpha.0...HEAD
78+
[0.1.0-alpha.0]: https://github.com/verheesj/reolink-aio-ts/releases/tag/v0.1.0-alpha.0

KNOWN_ISSUES.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ All device control features now work correctly:
5050
All features work correctly when using proper initialization:
5151

5252
```typescript
53-
import { Host } from 'reolink-aio-ts';
53+
import { Host } from 'reolink-aio';
5454

5555
const host = new Host('192.168.1.100', 'admin', 'password');
5656

0 commit comments

Comments
 (0)