Closed phinpho closed 1 year ago
Hi @phinpho,
The property localeIds can also be undefined, because the API docs are currently missing this value, the interface assumes it can be present or not.
Seems like the api reference doc is a bit outdated on that endpoint. I believe response for
getJobFiles
call should includelocaleIds
in every source file object, I believe it's not necessary to mark it optional (at least tried manually and got this property for every file in the response). But it can be an empty array though.Other than that PR looks good to me.
So, in case the response for getJobFiles
can return the localeIds
always, I think it isn't up to me to define that, I'm adding this change based on what I'm seeing on the API response, but because I cannot be sure about the response structure, I believe that Smartling devs should set the property localeIds
as not optional for FullSourceFileDto
object.
Can you consider adding this change right after this PR?
Hi @phinpho,
The property localeIds can also be undefined, because the API docs are currently missing this value, the interface assumes it can be present or not.
Seems like the api reference doc is a bit outdated on that endpoint. I believe response for
getJobFiles
call should includelocaleIds
in every source file object, I believe it's not necessary to mark it optional (at least tried manually and got this property for every file in the response). But it can be an empty array though. Other than that PR looks good to me.So, in case the response for
getJobFiles
can return thelocaleIds
always, I think it isn't up to me to define that, I'm adding this change based on what I'm seeing on the API response, but because I cannot be sure about the response structure, I believe that Smartling devs should set the propertylocaleIds
as not optional forFullSourceFileDto
object.Can you consider adding this change right after this PR?
Sure. Released 1.5.1
To represent the current response of the
getJobFiles
endpoint, the object to represent the items has been changed to allow the usage of the following properties:localeIds
: An array of the locales assigned for the files;fileUid
: The Uid of the file, also present in thegetJob
response;name
: The name of the file, also present in thegetJob
response.The property
localeIds
can also be undefined, because the API docs are currently missing this value, the interface assumes it can be present or not.