Rocket Visa PR Tool

PDF Service Deployment Files

Download all files needed to deploy the HTML→PDF microservice

Core Service Files
Documentation
Integration Instructions

Step 1: Deploy the PDF Service

  1. Download all files using the buttons above
  2. Create a new directory and extract all files
  3. Follow the deployment instructions for Google Cloud Run
  4. Note the service URL after deployment

Step 2: Update the generatePDF Function

The generatePDF function above is a placeholder. To integrate with your deployed service:

  1. Set the PDF_SERVICE_URL environment variable to your deployed service URL
  2. Set the HMAC_SECRET environment variable (same secret used in PDF service)
  3. Update the function to make actual HTTP calls to your PDF service

Step 3: Update Frontend Integration

Update your SubscriptionForm.jsx to call the generatePDF function instead of generateSignedAgreement.

Step 4: Test the Integration

  1. Use the health check endpoint to verify service is running
  2. Test PDF generation with the client example
  3. Verify fonts and styling match your website

Important Notes:

  • • The PDF service should be deployed privately (no public access)
  • • Use strong HMAC secrets (32+ characters) and rotate them regularly
  • • Monitor service performance and adjust Cloud Run settings as needed
  • • Test thoroughly with real agreement content before production use
  • • Consider keeping min-instances=1 for better response times