I noticed today that I’m getting a HTTP status code of 201 sometimes (maybe always?) when uploading a photo. Previously it used to be 202 only, and that’s what’s documented.
Just checking if this is now expected or if it is a backend bug.
I noticed today that I’m getting a HTTP status code of 201 sometimes (maybe always?) when uploading a photo. Previously it used to be 202 only, and that’s what’s documented.
Just checking if this is now expected or if it is a backend bug.
Sorry about this. Last week I was reviewing the Micropub spec and realized that it’s supposed to be a 201 error, so I changed it not thinking it would break anything. But it is breaking things, so I’m going to revert that change for now.
201 is not specified as an error from my quick search on HTTP status codes. Maybe I’m misunderstanding. Either way I’m fine with you reverting it as well. Thank you!
I’ve changed this back to an HTTP 202 response. For client apps, I recommend accepting responses with either 200, 201, 202 in the future.
Sounds good. Can you confirm that a 200
for an image upload will also contain the Location
field in the header with the URL of the uploaded image? I know that 201
, and 202
do contain that. e.g. Mimi Uploader will accept 200
as a response but considers it an error if there is no location field as otherwise it defeats the purpose of the app.
We talked about this a little in person, but to summarize for others: an HTTP 200 isn’t supposed to include a Location header, but Micro.blog will only return 201 and 202 anyway.
Perfect. Thank you!