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

SparkPostTransport features a hardcoded endpoint for a service that has multiple endpoints #23864

Closed
Raven0us opened this issue Apr 12, 2018 · 0 comments

Comments

@Raven0us
Copy link

Raven0us commented Apr 12, 2018

In /src/Illuminate/Mail/Transport/SparkPostTransport.php under the method send, the endpoint is hardcoded to https://api.sparkpost.com/api/v1/transmissions.

This should be configurable when setting up SparkPost as the app's mail driver because SparkPost has 4 different endpoints, according to https://developers.sparkpost.com/api/

In my case, it was not about alternative endpoints, but very strict endpoints. SparkPost and SparkPost EU operate independently, that means if I create an API key for SparkPost EU and try to use it in Laravel, it won't work cause the generic endpoint is called instead of https://api.eu.sparkpost.com/api/v1 (where my API key actually exists).

I solved this by extending MailServiceProvider, TransportManager and SparkPostTransport, but that's not a solution.

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