I’ve noticed that in my own web apps, which calls the Write.as api to get posts from my blogs, they’ve stopped working. When I try a local debug, I am getting back a “The response ended prematurely.” error from the Write.as API. However, when I try the same request using Postman, it does return the expected data. So the Write.as api is working fine, but it seems like it is blocking requests from my web apps.
The only major difference is that, I pass in an API Key when making requests from my web apps. This API Key is specific to my write.as account. I’m wondering if the api key has expired and I just need a new one? Or is there some other security rule blocking my requests?
I am not actually able to get any response back. And so I cannot see any response header values. I even wrote a new console app from scratch and made the call to the write.as api, without having to go through the api/client libary I have, and it still failed with the same error.
However, I think I might have a found a solution to the issue. Somebody on Stack Overflow suggested adding a User-agent request header value, and so I gave it a try, and managed to get a response back from the write.as api. I will test it some more in the coming days and will let you know how it goes.