When to use this skill
ALWAYS use this skill when the user mentions:
- HTTP requests from Rust side / HTTP requests initiated from the Rust side
- Bypassing WebView restrictions / Bypassing WebView restrictions
- Domain allowlists and secure request handling / Domain allowlists and secure request handling
Trigger phrases include:
- "http client", "allowlist", "requests", "WebView"
- "HTTP requests", "allowlist", "WebView"
How to use this skill
- Define allowed domains, methods, and headers
- Configure http-client plugin capabilities and scope
- Implement request timeouts, retries, and error handling
- Validate sensitive data handling and logging hygiene
Outputs
- Request policy and allowlist plan / Request policy and allowlist plan
- Security and logging checklist / Security and logging checklist
Scope
- Boundary: HTTP client plugin usage only
- Key points: Domain allowlists and transport security
References
- https://v2.tauri.app/llms.txt
- https://v2.tauri.app/plugin/http-client/
- https://v2.tauri.app/zh-cn/plugin/http-client/
Keywords
tauri http client, requests, allowlist, security
Common Pitfalls (Gotchas)
- Version compatibility: Pay attention to the compatibility between framework versions and dependency libraries; APIs may differ across versions.
- Configuration file format: Configuration file format errors are the most common issue; it is recommended to use the editor's syntax checking.
- Environment variables: Ensure that all necessary environment variables are set correctly, and do not hard-code sensitive information.
- Dependency conflicts: When multiple versions coexist, pay attention to dependency conflicts, and use a lock file to pin versions.
- Performance pitfalls: Pay attention to performance optimization in large-data scenarios, and avoid common issues such as N+1 queries.
Usage flow
Step 1: Environment preparation
Ensure that the necessary dependencies and tools are installed in the development environment.
Step 2: Configuration initialization
Perform basic configuration according to project requirements.
Step 3: Using core features
Implement the core features according to the example code.
Step 4: Test verification
Run tests to ensure the functionality works properly.
Step 5: Deployment and release
After development is complete, proceed with deployment and monitoring.