Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rotate hosts #1744

Open
rafaeelaudibert opened this issue Feb 17, 2025 · 0 comments
Open

Rotate hosts #1744

rafaeelaudibert opened this issue Feb 17, 2025 · 0 comments

Comments

@rafaeelaudibert
Copy link
Member

Rather than accepting a single host, some users are interested in accepting more than one host to try and circumvent ad blockers.

The idea is that you'd be able to say posthog.init(<token>, { api_host: ['proxy.posthog.com', 'proxy.third-party.com'] }) and the library would be able to detect that the first request failed, and then attempt a second one against the fallback host.

This is helpful for people that are using our self-provisioned proxy but that are still seeing some usage being blocked, which would then fallback to their self-hosted proxy in something like Vercel, where they're charged by the request. If they can offload most of the requests to us, then their Vercel bill will be much lower.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant