POST /language

Create a language recognition request for a document. This allows you to specify the files you would like to determine the language for. Multiple file_ids can be specified in a single request. Due to the asynchronous nature of processing languages, the results for each of these files will be returned independently. Thus the endpoint will return a number of language identifiers (request_id) which will be then used to retrieve the results for each file.


Authorization (required) - Requires the standard authentication header used in the system.


  • file_ids Body Required

    the id for the document to have language type performed

Code Sample
curl -X POST -H "Accept: application/json"  
-H "Authorization: Bearer <token>"  
-H "Content-Type: application/json"  
-d "{"file_ids": ["<file_id>"]}" 
language_jobs, _ = zdai.language.create(file_ids = ['file_id_1', '...'])
Response Codes
  • 202 Accepted
    Language type has been created successfully.
  • 400 Bad Request
    Malformed request body, or file_id is missing.
  • 403 Forbidden
    Invalid or missing authentication token.
  • 404 Not Found
    The file specified does not exist.
  • 500 Internal Server Error
    Something went wrong unrelated to the users request.

Response Data

  • file_id

    the id of the file

  • status

    the status of the request for each file. Could be queued, processing, or complete

  • request_id

    the identifier used to obtain the language classification

  • error

    if an error occurs, you may get a standard error response

    "file_ids": [
            "file_id": "<file_id>",
            "status": "queued",
            "request_id": "<request_id>"

Need Help?

Couldn’t find the information you were looking for or need more assistance?

Contact Support