SaaS Subscription Agreement Generator

SaaS Subscription Agreement Generator

Parties & Service Definition

Scope & Access

Financial Terms

$

Term and Termination

Configure details in the previous tabs and click "Generate Agreement" to see the full contract here.

Access is limited to ${data.maxUsers} authorized users. The Customer is allocated ${data.storage} of cloud storage. Support level included is ${data.supportLevel}.

3. FEES AND PAYMENT TERMS

The Customer agrees to pay a subscription fee of ${data.feeAmount} USD, billed ${data.feePeriod}. Payments are due within 30 days of invoice receipt. Any late payment shall accrue interest at the rate of ${data.lateFee}% per month.

4. TERM AND RENEWAL

This Agreement begins on the Effective Date and shall continue for an initial term of ${data.initialTerm} months. The Agreement shall automatically renew for successive ${data.renewalTerm} month renewal terms unless either party provides written notice of non-renewal at least ${data.noticeDays} days prior to the end of the current term.

Provider Signature: ${data.providerName}
Date: ${today}
Customer Signature: ${data.customerName}
Date: ${today}
`; agreementContentDiv.innerHTML = agreementHtml; }; // --- Button Event Listeners (Flow Control) --- next1Btn.addEventListener("click", function() { generateAgreement(); // Keep agreement updated showTab('ssa-tab-2'); }); prev2Btn.addEventListener("click", function() { showTab('ssa-tab-1'); }); generateBtn.addEventListener("click", function() { generateAgreement(); showTab('ssa-tab-dashboard'); }); // --- PDF Download --- pdfBtn.addEventListener("click", function() { var jsPDF = window.jspdf.jsPDF; var customer = customerNameInput.value.replace(/[^a-zA-Z0-9]/g, '_') || 'Customer'; var fileName = `${customer}_SaaS_Agreement.pdf`; html2canvas(exportArea, { scale: 2, useCORS: true, backgroundColor: '#ffffff' }).then(function(canvas) { var imgData = canvas.toDataURL('image/png'); var doc = new jsPDF({ orientation: 'p', unit: 'pt', format: 'letter' // Use US Letter format }); var pdfWidth = doc.internal.pageSize.getWidth(); var pdfHeight = doc.internal.pageSize.getHeight(); var imgProps = doc.getImageProperties(imgData); var imgWidth = imgProps.width; var imgHeight = imgProps.height; var margin = 40; var usableWidth = pdfWidth - (2 * margin); var ratio = usableWidth / imgWidth; var scaledHeight = imgHeight * ratio; // Handle multi-page if content exceeds page height if (scaledHeight > pdfHeight - (2 * margin)) { var pageHeight = pdfHeight - (2 * margin); var heightLeft = scaledHeight; var position = 0; while (heightLeft > 0) { doc.addImage(imgData, 'PNG', margin, position + margin, usableWidth, scaledHeight); heightLeft -= pageHeight; position -= pageHeight; if (heightLeft > 0) { doc.addPage(); } } } else { // Single page doc.addImage(imgData, 'PNG', margin, margin, usableWidth, scaledHeight); } doc.save(fileName); }).catch(function(err) { console.error("SSA PDF Error:", err); // alert("An error occurred while generating the PDF."); // Per spec }); }); // --- Initial Load --- generateAgreement(); // Render initial sample content showTab('ssa-tab-1'); // Start on the first configuration tab });
Scroll to Top