You are currently working on UAT 

Query TU by ID on the GroupShare REST API

Hi,

is it possible to query one or more TUs by their ID through the GroupShare REST API? I have not found any related method on the swagger definition, and also have not found a way to reference the ID in the filters (http://producthelp.sdl.com/SDL%20studio%20groupshare/en/TM_system_fields.htm)

thanks,

Tamas

Parents
  • Hi ,

    you are right, there is no special end-point to query a specific translation unit using a TU ID or GUID.
    I did find one trick that can be used to get a particular TU by using the /tus endpoint and 'startTuId' and 'count' query parameters.

    Here is what you can try:

    - each TU has a 'tuid' under the 'metadata' object in JSON, for example 5
    (please note that these ids are integers, not guids)

    - when you use the /api/tmservice/tms/{tmId}/tus endopoint to get all TUs you can specify
    'startTuId' and a 'count' as query parameters (they are actually mandatory)

    - so for our example, if you'd need TU with id=5 you would then call that endpoint
    with 'startTuId=4' and 'count=1'

    I did test this on a couple of TMs and various TUs and it works but we're not using this anywhere in production so I cannot guarantee anything.
    Please note that these integer TU IDs do not have to be in order / continuous.

    Give it a try and see if this helps with your problem. If you'd need more info or a demonstration just please contact me directly via email.

    Thanks,
    Mio

    emoji
Reply
  • Hi ,

    you are right, there is no special end-point to query a specific translation unit using a TU ID or GUID.
    I did find one trick that can be used to get a particular TU by using the /tus endpoint and 'startTuId' and 'count' query parameters.

    Here is what you can try:

    - each TU has a 'tuid' under the 'metadata' object in JSON, for example 5
    (please note that these ids are integers, not guids)

    - when you use the /api/tmservice/tms/{tmId}/tus endopoint to get all TUs you can specify
    'startTuId' and a 'count' as query parameters (they are actually mandatory)

    - so for our example, if you'd need TU with id=5 you would then call that endpoint
    with 'startTuId=4' and 'count=1'

    I did test this on a couple of TMs and various TUs and it works but we're not using this anywhere in production so I cannot guarantee anything.
    Please note that these integer TU IDs do not have to be in order / continuous.

    Give it a try and see if this helps with your problem. If you'd need more info or a demonstration just please contact me directly via email.

    Thanks,
    Mio

    emoji
Children