fix(backend): use v2 structured search API for OFF
- Switch from /cgi/search.pl (503 errors) to /api/v2/search with brand filter - Add required User-Agent header per OFF documentation - Add OFF_USER_AGENT env var for customization - Update .env.example with User-Agent documentation - Retry logic continues to work with new endpoint
This commit is contained in:
@@ -20,7 +20,9 @@ VAPID_SUBJECT=mailto:admin@example.com
|
||||
# https://expo.dev/accounts/[username]/settings/access-tokens
|
||||
EXPO_ACCESS_TOKEN=
|
||||
|
||||
# Open Food Facts (optional, improves rate limits)
|
||||
# Open Food Facts
|
||||
# Register at: https://world.openfoodfacts.org/
|
||||
# User-Agent is REQUIRED per OFF docs (format: AppName/Version (ContactEmail))
|
||||
OFF_USER_AGENT=FarmaFinder/1.0 (https://github.com/farmafinder)
|
||||
OFF_USERNAME=
|
||||
OFF_PASSWORD=
|
||||
|
||||
Reference in New Issue
Block a user