Introduction
This comprehensive API reference provides detailed documentation for all methods available in the ESP32_AI_Connect library. Each method includes syntax examples, parameter explanations, return values, and practical code samples to help you integrate AI capabilities into your ESP32 projects effectively.
📚 What You’ll Find Here:
- Complete Method Documentation: Every function with detailed parameters and return values
- Practical Code Examples: Real-world usage scenarios for each method
- Security Considerations: Best practices and security guidelines
- Platform-Specific Notes: Important differences between AI platforms
- Error Handling: Common issues and troubleshooting tips
API Methods by Category
Explore our detailed API documentation with syntax examples, parameter explanations, return values, and practical code samples for every method. Each function is thoroughly documented with security considerations and best practices.
🔧 Library Initialization
Core setup and configuration methods for initializing the library with your chosen AI platform.
- ESP32_AI_Connect() – Create library instance
- begin() – Initialize with API credentials
- getLastError() – Retrieve error messages
- getTotalTokens() – Get token consumption stats
- getFinishReason() – Check response completion status
💬 Standard Chat Operations
Essential methods for implementing conversational AI with customizable parameters and settings.
- chat() – Send messages and get responses
- setChatSystemRole() – Define AI behavior and context
- setChatTemperature() – Control response creativity
- setChatMaxTokens() – Limit response length
- setChatParameters() – Platform-specific settings
- chatReset() – Clear conversation history
🛠️ Tool Calling (Function Calling)
Advanced functionality for enabling AI to execute functions and interact with your hardware systems.
- setTCTools() – Define available functions
- tcChat() – Chat with tool calling enabled
- tcReply() – Respond to tool call requests
- setTCChatSystemRole() – Set system role for tools
- setTCChatToolChoice() – Control tool selection
- tcChatReset() – Reset tool conversation
📡 Streaming Chat
Real-time response streaming methods for interactive applications and live user experiences.
- streamChat() – Start streaming conversation
- isStreaming() – Check streaming status
- stopStreaming() – Interrupt ongoing stream
- streamChatReset() – Reset streaming session
- Stream Configuration – Advanced streaming options
🚧 Documentation In Progress
We’re currently working on expanding this API reference with detailed documentation for each method. This will include:
- Complete syntax and parameter descriptions
- Return value specifications
- Practical code examples
- Platform-specific implementation notes
- Common use cases and best practices
Check back soon for the complete documentation, or visit our Quick Start Examples for practical implementation guides.
AvantMaker.com
Your Premier Hub for DIY, AI, IoT, and STEM Innovation
© 2025 AvantMaker. All rights reserved.
Home | ESP32 | ToolBox | Blog | FAQ | About
Ready to experiment and explore more about ESP32?
Visit our website’s All About ESP32 Resources Hub, packed with tutorials, guides, and tools to inspire your maker journey. Experiment, explore, and elevate your skills with everything you need to master this powerful microcontroller platform!