flickr / flickr-sdk

Almost certainly the best Flickr API client in the world for node and the browser
https://www.flickr.com/services/api
MIT License
131 stars 29 forks source link

Add user-agent #156

Closed davidsandoz closed 1 year ago

davidsandoz commented 1 year ago

In light of the announcement to require a user-agent for requests made to the Flickr API, it would be good to ensure that a user-agent header is set by the Flickr SDK, for situations when it used server-side, from a Node.js process.

The Flickr SDK uses superagent v6.1.0, which, from the look of this test, doesn't set a user-agent by default (and it's still not the case in the latest version).

Is it planned to make that change? Searching in the code base, I can only find TODOs about user-agent, but nothing else.

ebisbe commented 1 year ago

I've just came here to say the same. That change should be something implemented by the package itself.

jeremyruppel commented 1 year ago

Thanks! I hadn't realized superagent removed their user-agent header 🙀 I'll get a release going to address this.

jeremyruppel commented 1 year ago

flickr-sdk@6.1.0 is out. This release includes a user-agent header for all requests.

davidsandoz commented 1 year ago

Thank you @jeremyruppel!