URL of uploaded document


Can someone please help me to find out the URL of the documents that are uploaded to SuiteCRM ?
It should be something like this : http://localhost/Documents/modulename/lead/filename/docname.doc . I am trying to get that through URL field datatype but its not showing any URL.
How should I move further with this?

Hi Kinjal,

SuiteCRM handles it in the very different way then you understood it. You can refer SugarCRM CE 6.5 developer guide to get the understanding of code structure.

Have a look at the save method of modules/Documents/Document.php

Each document is saved as a revision. Revision Id is file id. Files are stored in upload folder on the root of CRM.

document table has document_revision_id column.

You can download file with the help of entry point.

Something like this


I hope it will be helpful to you.

Thank you for the reply. But can i get the complete URL of all the documents in the documents module as we need it for developing the mobile app. I know i can get the document_revision_id through web services but what about the URL of the documents.

Can someone please help me on this.


I actually found out a solution for this. I created a new field in studio with field type as URL and then checked the Generate URL check-box and entered this in to the default value

http://localhost/instancename/index.php?entryPoint=download&id=document_revision_id&type=Documents and it gave me the correct URL in the web instance. But when i ma trying to call this field through web service it is showing the same link and not replacing the document_revision_id with the actual value of the id of the document. How am i suppose to pass the actual value of the document through the web service in the above link only?