trm/status
Gets the status of an asynchronous operation.
An operation can be in progress, completed or failed.
NOTE: If you want to poll the system to know when an operation is done, please make sure to properly wait in between calls to this method.
For example you should wait 5 seconds or more in between calls. The system may automatically disable the API if it is called too frequently.
URL
(GET) /api/trm/status?requestid=
PARAMETERS
URL parameters are:
requestid | The ID of the operation as returned by an asynchronous API method | int, Mandatory |
RESULTS
See Asynchronous OperationÂ
EXAMPLES
The result if the operation still runs in the background.
{ "trm": { "requestid": 559, "isbatch": false, "status": "Waiting", "statusText": "Waiting..." } }
Oups, this operation failed:
{ "trm": { "requestid": 559, "isbatch": false, "status": "Failed", "statusText": "Operation failed!", "statusInfo": "The parameter xy was not properly supplied" } }
The operation terminated with success. Results are included in the custom and/or results nodes.
Note that this is a sample result from resources/segments/view/export. It is used to export a job or project to XLIFF. The XLIFF file itself is downloaded with the "fileref" token - please see the documentation for more details.
{ "trm": { "requestid": 0, "isbatch": false, "status": "Finished", "statusText": "Finished!" }, "custom": { "fileref": "ea9c1adeb02f4a9ebe8771583c12fa6b", "filename": "export_wm-1180_en_fr.xlf", "segments": 10 } }
Copyright Wordbee - Buzzin' Outside the Box since 2008