feat: Improvements-v0.0.2 #8

Merged
rdenadai merged 1 commit from rdenadai/improvements-v.0.0.2 into main 2025-11-06 14:22:18 +00:00
Owner

Improvements v0.0.2

Summary

This release introduces several improvements to enhance the API's functionality, user experience, and scraping reliability.

Key Changes

1. New Landing Page

  • Added a styled welcome page at the root endpoint (/)
  • Provides clear API documentation with example usage
  • Shows current version, rate limits, and cache duration
  • Improves developer experience with direct links and formatted code examples

2. Enhanced Rate Limiting

  • Increased rate limit from 5 to 10 requests per minute per IP
  • Better balance between accessibility and abuse prevention
  • Updated documentation to reflect the new limit

3. Improved User Agent Rotation

  • Replaced single outdated User-Agent with a pool of 6 modern user agents
  • Includes Chrome, Firefox, Opera, Edge, and Safari variants
  • Randomly selects from the pool on each scraper initialization
  • Reduces bot detection and improves scraping success rate

4. Better Error Handling

  • Changed error status code from 500 to 404 when URL data cannot be fetched
  • More semantically correct: indicates resource not found rather than server error
  • Improves API clarity for consumers

5. Development Environment

  • Added .python-version file (Python 3.11.11)
  • Updated VS Code debug configuration name to api.redecapivara.social
  • Better project consistency across development environments

📝 Modified Files

  • app.py - Added index route, increased rate limit, improved error codes
  • scraper.py - Implemented user agent pool with random selection
  • README.md - Updated rate limit documentation
  • launch.json - Updated debug configuration name
  • .python-version - Added Python version specification

Version: v0.0.2

## Improvements v0.0.2 ### Summary This release introduces several improvements to enhance the API's functionality, user experience, and scraping reliability. ### Key Changes #### 1. **New Landing Page** - Added a styled welcome page at the root endpoint (`/`) - Provides clear API documentation with example usage - Shows current version, rate limits, and cache duration - Improves developer experience with direct links and formatted code examples #### 2. **Enhanced Rate Limiting** - Increased rate limit from **5 to 10 requests per minute** per IP - Better balance between accessibility and abuse prevention - Updated documentation to reflect the new limit #### 3. **Improved User Agent Rotation** - Replaced single outdated User-Agent with a **pool of 6 modern user agents** - Includes Chrome, Firefox, Opera, Edge, and Safari variants - Randomly selects from the pool on each scraper initialization - Reduces bot detection and improves scraping success rate #### 4. **Better Error Handling** - Changed error status code from `500` to `404` when URL data cannot be fetched - More semantically correct: indicates resource not found rather than server error - Improves API clarity for consumers #### 5. **Development Environment** - Added .python-version file (Python 3.11.11) - Updated VS Code debug configuration name to `api.redecapivara.social` - Better project consistency across development environments ### 📝 Modified Files - app.py - Added index route, increased rate limit, improved error codes - scraper.py - Implemented user agent pool with random selection - README.md - Updated rate limit documentation - launch.json - Updated debug configuration name - .python-version - Added Python version specification ### 🔗 Related Version: **v0.0.2**
Commenting is not possible because the repository is archived.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
rdenadai/api.redecapivara.social!8
No description provided.