API documentation inaccurate for resource translations async downloads endpoint

The documentation for the resource_translations_async_downloads endpoint states that the response will have a status attribute to indicate status, and if successful, a 303 response with a Location attribute with the file download URL.

When I tested this endpoint, however, I received the file directly, no status or 303 response or separate download URL.

Hello,

Thank you for your message.
I am Chirstos , a member of the support team in Transifex.
In order to have a better picture, could you share the response and the exact call you made here?

Kind regards
Christos

1 Like

This is the request I made:

curl --request GET \
     --url https://rest.api.transifex.com/resource_translations_async_downloads/daa9a64d-eb0e-4f58-8d5f-e6d715c81c5a \
     --header 'accept: application/vnd.api+json' \
     --header 'authorization: Bearer <token value>

And this is the response I received:

HTTP/1.1 200 OK
Date: Mon, 20 May 2024 13:56:10 GMT
Content-Type: application/json; charset=utf-8
Transfer-Encoding: chunked
Connection: close
Access-Control-Allow-Origin: *
Content-Disposition: attachment; filename="caed6f89c66da0979285773c39e35fac-sv.json"

{
  "units": {
    "factions": {
      "arm": "Teknoarmadan",
      "cor": "Cyberbarken",
 <... rest of JSON file>
}

Hello!

Thank you for your reply, here’s what’s happening:

The resource_translations_async_downloads endpoint does work as documented:

  • If the file is not ready yet, it returns 200 OK with a JSON status attribute (pending, processing, or failed).
  • Once the file is ready, it returns a 303 See Other with a Location header that points to the actual file.

In your test, you got the file directly because your curl request automatically followed the 303 redirect behind the scenes. So you don’t see the 303 — you just see the final response from the storage server (200 OK + file content).

If you want to see the raw 303 and Location header, you can tell curl not to follow redirects, for example:

curl -i --max-redirs 0 \
  --header 'accept: application/vnd.api+json' \
  --header 'authorization: Bearer <your token>' \
  'https://rest.api.transifex.com/resource_translations_async_downloads/<ID>'

This way you’ll see exactly what the API returns before the redirect happens.

Hope this clarifies it!