Packages

Elixir client library for TTLock Open Platform API with centralized OAuth management

Current section

Files

Jump to
ex_ttlock CHANGELOG.md
Raw

CHANGELOG.md

# Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [0.2.0] - 2025-08-12
### Added
- Automatic token refresh functionality in OAuth module
- `get_valid_access_token/1` function for seamless token management
- `store_tokens/3` function for persisting access and refresh tokens
- Support for TTLOCK_ACCESS_TOKEN environment variable
- Automatic token expiration checking with 5-minute buffer
- Token cleanup when refresh fails
### Changed
- Lock Management and Passcode Management modules now automatically handle token refresh
- Environment variable mapping for consistent naming (TTLOCK_CLIENT_ID, TTLOCK_CLIENT_SECRET, TTLOCK_ACCESS_TOKEN)
- Updated function signatures to make access_token parameter optional
- Enhanced error handling for authentication failures
### Fixed
- Token expiration issues that required manual token management
- Improved error messages for authentication failures
## [0.1.0] - 2024-XX-XX
### Added
- Initial release with basic TTLock API integration
- OAuth authentication with Resource Owner Password Credentials flow
- Lock management operations (list locks, get lock details)
- Passcode management operations (add, delete, change, list passcodes)
- MD5 password hashing for TTLock API compatibility
- Comprehensive documentation and examples