add file.path to file properties results

Archived from the Transloadit support forum. Originally posted on April 4, 2014; details may be outdated, see our docs for current behavior. Original thread

Hello all,
If we add a result file to our cloud (eg: /cloudfiles/store robot) we get lots of file cloud properties.
These file cloud properties include file.url, file.ssl_url, file.ios_url and file.streaming_url .. but we don’t have the possibility to retrieve the file path of that stored file.

Example: if in our robot /cloudfiles/store we define:

“cloudfiles”: { “robot”: “/cloudfiles/store”, “path”: “${file.id}.${file.ext}” we would get, as result, a file.path = asdasdasdasdasdasd.jpg

“cloudfiles”: { “robot”: “/cloudfiles/store”, “path”: “${file.basename}${file.id}.${file.ext}” we would get, as result, a file.path = somefilenameasdasdasdasdasdasd.jpg

This can be excellent if we want to get the uploaded resulting filename for store in a db. Yes, we can store all current url properties, but with file.path we could do the same, with a smaller db result and with the possibility to put those files in another server with a different url domain. We can parse the file.url string and delete the domain part, but it would be much cleaner if transloadit had this built-in.

what do you think?

best,
Francisco A

Hey Francisco,

sorry for the delay in getting back to you. : /

Do you mean you want the path that you set in the robot evaluated? Like with all assembly variables replaced?

Kind regards,
Tim

Co-Founder Transloadit
@tim_kos

Hi tim.
Exactly.

Best,
Francisco Azevedo

Hi Tim,
Any news on this ?

best,
Francisco Azevedo

Hey Francisco,

sorry for the delay. You should now be able to access this in “remote_path” of the results. Please let me know if it works.

Kind regards,
Tim

Co-Founder Transloadit
@tim_kos

Hi Tim,
It works as expected. This is a simple but useful feature.
Thanks.

best,
Francisco Azevedo

Most welcome.

Closing this.