Commit Graph

3 Commits

Author SHA1 Message Date
Xin Wang
b322ef1d7a Add comprehensive unit test suite
- Add 111 unit tests covering all client classes and exceptions
- Test BaseClientMixin: initialization, validation, retry logic
- Test FastGPTClient: HTTP requests, streaming, error handling, context manager
- Test ChatClient: all chat operations (completion, histories, records, feedback)
- Test AppClient: app analytics and logs
- Test all exception classes with various configurations
- Add shared pytest fixtures in conftest.py

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-06 16:17:43 +08:00
Xin Wang
017bdc4b53 fix stream issue 2026-01-06 15:48:05 +08:00
Xin Wang
0495dd4676 Initial commit: FastGPT Python SDK Phase 1
Implement core infrastructure:

- BaseClientMixin with retry logic and validation
- FastGPTClient base class with httpx
- ChatClient with 11 chat operation methods
- AppClient for analytics and logs
- Custom exceptions (APIError, AuthenticationError, etc.)
- Package configuration (pyproject.toml, setup.py)
- Documentation (README.md, CLAUDE.md)
- Basic usage examples

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-06 14:39:33 +08:00