gnarroway / hato

An HTTP client for Clojure, wrapping JDK 11's HttpClient
MIT License
380 stars 27 forks source link

Capitalise content type HTTP header #70

Closed dcostaras closed 4 months ago

dcostaras commented 4 months ago

Yesterday this started causing the Notion API to return incorrect results, I assume due a change on their side.

gnarroway commented 4 months ago

Not going to accept this, as it is not an issue with Hato.

You can get notion to fix it on their end, or you can manually provide the headers in your request.

dcostaras commented 4 months ago

Apologies, I always assumed they were case sensitive given the odd case scheme in common use (capitalised kebab case).

If anyone else hits this, supplying a second content type header does not work with the Notion API currently, you need to replace, remove or fork the middleware until they resolve the issue. This is incorrect, we were already adding the second capitalised header, the change on Notions side that happened yesterday is it now no longer functions if both cases are sent.