# GetCustomReports - Advanced Documentation ## Model Shape Returns IEnumerable for the current company. See SaveCustomReport's advanced doc for the full CustomReportInfo/FileInfo shape. ## Traps - Every firm is provisioned with a starter set of Custom/Search reports cloned from a template company - these are real, runnable examples, not placeholders, and are a reliable way to find a working WebServiceDataSource setup if you need to build a new Custom report that calls back into SecureApi. - To inspect an existing report's Telerik definition (including its WebServiceDataSource auth setup), download File or CompiledFile via FileService.GetDownloadUrl and unzip it - a .trdp is a zip container (Images/*, definition.xml, [Content_Types].xml), not plain XML. - This returns reports for the current company only - there is no cross-company listing. ## Script Example ```javascript var reports = await CallEndpoint("SecureApi", "GetCustomReports", {}); var sample = reports.find(r => r.Type === "Custom" && r.File); var trdpUrl = await CallEndpoint("FileService", "GetDownloadUrl", { FileID: sample.File.ID }); // download trdpUrl and unzip to inspect definition.xml / the WebServiceDataSource setup ``` ## Cross-References | Endpoint | Relationship | |---|---| | SaveCustomReport | Create/update a report; see its advanced doc for the full model shape and Telerik WebServiceDataSource setup traps | | FileService.GetDownloadUrl | Download a report's .trdp/CompiledFile to inspect it |