sendmail
[
from: zoho.adminuserid
to: input.customer_email
subject: "Invoice"
message: "Please find your invoice attached"
Attachments: template:Invoice_Template:Form_Name record_id as PDF
]| Workaround Approach | Implementation | Problems | Status |
|---|---|---|---|
| Manual Export | User exports PDF manually and uploads to file field |
- Not acceptable for automated workflows - Defeats purpose of automation - Poor user experience |
✗ Not viable for production |
| Email-to-Form API | Send PDF to another form, fetch via GET API, rename, then send |
- Does NOT work "On Add → On Success" - Timing/race condition issues - Only works manually updating record - Requires additional forms and complexity |
✗ Unreliable without delays |
| Scheduled Workaround | Use scheduled task to trigger GET request and rename |
- Introduces unnecessary delays - Overcomplicated for simple task - Requires schedule management |
⚠ Works but highly inefficient |
// STEP 1: Send PDF to intermediate form via email
sendmail
[
from: zoho.adminuserid
to: "capture_form@creator.zoho.com"
subject: "Temp PDF"
Attachments: template:Invoice_Template:Form_Name record_id as PDF
]
// STEP 2: Schedule a task (not immediate!)
// Wait for email to process...
// STEP 3: Fetch the file via API
file_response = invokeUrl
[
url: api_endpoint
type: GET
connection: "creator_connection"
];
// STEP 4: Rename using setFileName
file_response.setFileName("CustomFileName.pdf");
// STEP 5: Finally send with renamed file
sendmail
[
from: zoho.adminuserid
to: input.customer_email
subject: "Invoice"
Attachments: file:file_response
]sendmail
[
from: zoho.adminuserid
to: input.customer_email
subject: "Invoice"
Attachments: template:Invoice_Template:Form_Name record_id as PDF filename:"Custom_Name.pdf"
]pdf_name = input.Client_Name + "_Invoice_" + input.Invoice_Number + ".pdf";
sendmail
[
from: zoho.adminuserid
to: input.customer_email
subject: "Invoice"
Attachments: template:Invoice_Template:Form_Name record_id as PDF filename:pdf_name
]Developer Impact: What should take 30 seconds (adding a filename parameter) instead requires hours of workaround implementation, creating technical debt and maintenance overhead.
Can this be addressed in a future update?
This is a frequently requested feature that impacts professional presentation and client satisfaction. The current implementation forces developers to choose between:
|
1. Default Naming Accept generic template-based filenames that don't meet client requirements |
2. Complex Workarounds Spend hours implementing unreliable solutions with scheduled tasks and API calls |
We shouldn't have to make this choice for such a basic requirement.
Community Input Requested: Has anyone else encountered this limitation or found a more reliable workaround? This has been an ongoing frustration, and I know many developers would benefit from a native solution.