Versions in this module Expand all Collapse all v1 v1.5.0 Aug 29, 2026 v1.4.0 Aug 29, 2026 v1.3.3 Aug 20, 2026 v1.3.2 Aug 20, 2026 v1.3.1 Nov 4, 2025 v1.3.0 Nov 3, 2025 v1.2.2 Oct 19, 2025 Changes in this version + func ExampleArrayFlattening() + func ExampleCustomConverter() + func ExampleDebuggingCapabilities() + func ExampleDebuggingWorkflow() + func ExampleDirectDownload() + func ExampleHTTPMiddlewareDebugging() + func ExampleIntegrationWithAutoPDF() + func ExampleLocalStructToPDF() + func ExampleMalformedConfigHandling() + func ExampleNestedStructs() + func ExamplePDFDownload() + func ExampleRESTAPIUsage() + func ExampleRESTAPIWithPDFGeneration() + func ExampleRequest() + func ExampleStructConversion() + func ExampleStructToPDFWorkflow() + func ExampleTemplateValidationErrors() + func ExampleVariableValidationErrors() + func ExampleWithErrorHandling() + func RESTAPIServerExample() + func RunAllExamples() + func RunRESTAPIServer() + func WatchModeExample() + func WatchModeRESTExample() + type Address struct + City string + State string + Street string + Zip string + type AsyncPDFGenerationResponse struct + Message string + RequestID string + StatusURL string + Success bool + type Contact struct + Email string + Phone string + Website *url.URL + type ConversionOptions struct + DefaultFlatten bool + DurationFormat string + OmitEmpty bool + SliceSeparator string + TagName string + TimeFormat string + type ConvertStructRequest struct + Data interface{} + Metadata map[string]interface{} + Options *ConversionOptions + type ConvertStructResponse struct + Message string + Metadata map[string]interface{} + Success bool + Variables map[string]interface{} + type ConverterConfigResponse struct + ConverterCount int + DefaultFlatten bool + DurationFormat string + OmitEmpty bool + RegisteredTypes []string + SliceSeparator string + TagName string + TimeFormat string + type CustomDocument struct + Custom CustomFormattable + Normal string + Title string + type CustomFormattable struct + Type string + Value string + func (cf CustomFormattable) ToAutoPDFVariable() (config.Variable, error) + type Customer struct + Address string + Email string + Name string + Phone string + type Document struct + Author User + Categories []string + Content string + CreatedAt time.Time + IsPublished bool + Metadata map[string]interface{} + Tags []string + Title string + UpdatedAt *time.Time + type ExampleConversionOptions struct + DPI int + DoConvert bool + Format string + Quality int + Scale float64 + type FlattenedUser struct + Address Address + Contact Contact + CreatedAt time.Time + Email string + ID int + IsActive bool + Name string + Tags []string + type GeneratedFile struct + DownloadURL string + ExpiresAt string + Size int64 + Type string + type GenerationStatusResponse struct + Error string + Files []GeneratedFile + Message string + Progress int + RequestID string + Status string + type HealthResponse struct + Status string + Timestamp string + Version string + type InlinedUser struct + Address Address + Contact Contact + CreatedAt time.Time + Email string + ID int + IsActive bool + Name string + Tags []string + type Invoice struct + Customer Customer + DueDate time.Time + InvoiceNumber string + IssueDate time.Time + Items []LineItem + Notes string + Subtotal float64 + Tax float64 + Total float64 + Vendor Vendor + type LineItem struct + Description string + Quantity int + Total float64 + UnitPrice float64 + type MockPDFGenerationService struct + func (m *MockPDFGenerationService) Generate(ctx context.Context, req generation.PDFGenerationRequest) (generation.PDFGenerationResult, error) + func (m *MockPDFGenerationService) GetSupportedEngines() []string + func (m *MockPDFGenerationService) GetSupportedFormats() []string + func (m *MockPDFGenerationService) ValidateRequest(req generation.PDFGenerationRequest) error + type MockPDFValidator struct + func (m *MockPDFValidator) GetMetadata(pdfPath string) (generation.PDFMetadata, error) + func (m *MockPDFValidator) IsValidPDF(pdfPath string) bool + func (m *MockPDFValidator) Validate(pdfPath string) error + type MockTemplateService struct + func (m *MockTemplateService) GetTemplateVariables(templatePath string) ([]string, error) + func (m *MockTemplateService) Process(ctx context.Context, templatePath string, variables map[string]string) (string, error) + func (m *MockTemplateService) ValidateTemplate(templatePath string) error + type MockVariableResolver struct + func (m *MockVariableResolver) Flatten(variables *generation.TemplateVariables) map[string]string + func (m *MockVariableResolver) Resolve(variables *generation.TemplateVariables) (map[string]string, error) + func (m *MockVariableResolver) Validate(variables *generation.TemplateVariables) error + type PDFDownloadClient struct + BaseURL string + HTTPClient *http.Client + func NewPDFDownloadClient(baseURL string) *PDFDownloadClient + func (client *PDFDownloadClient) DownloadAllFiles(response *PDFGenerationResponse, outputDir string) error + func (client *PDFDownloadClient) DownloadFile(requestID, format, outputPath string) error + func (client *PDFDownloadClient) GeneratePDF(req PDFGenerationRequest) (*PDFGenerationResponse, error) + func (client *PDFDownloadClient) GeneratePDFAsync(req PDFGenerationRequest) (*AsyncPDFGenerationResponse, error) + func (client *PDFDownloadClient) GetGenerationStatus(requestID string) (*GenerationStatusResponse, error) + type PDFGenerationOptions struct + Cleanup bool + Conversion ExampleConversionOptions + Debug bool + Engine string + OutputFormat string + Timeout int + type PDFGenerationRequest struct + Options *PDFGenerationOptions + TemplatePath string + Variables map[string]interface{} + type PDFGenerationResponse struct + DownloadURL string + Files []GeneratedFile + Message string + Metadata map[string]string + RequestID string + Success bool + type PreviewRequest struct + Data interface{} + Limit int + Options *ConversionOptions + type PreviewResponse struct + Count int + Message string + Truncated bool + Variables map[string]interface{} + type RESTAPIClient struct + BaseURL string + HTTPClient *http.Client + func NewRESTAPIClient(baseURL string) *RESTAPIClient + func (client *RESTAPIClient) ConvertStruct(data interface{}, options *ConversionOptions) (*ConvertStructResponse, error) + func (client *RESTAPIClient) ConvertStructFlattened(data interface{}, options *ConversionOptions) (*ConvertStructResponse, error) + func (client *RESTAPIClient) ConvertStructForTemplate(data interface{}, options *ConversionOptions) (*ConvertStructResponse, error) + func (client *RESTAPIClient) GetConverterConfig() (*ConverterConfigResponse, error) + func (client *RESTAPIClient) HealthCheck() (*HealthResponse, error) + func (client *RESTAPIClient) PreviewConversion(data interface{}, options *ConversionOptions, limit int) (*PreviewResponse, error) + func (client *RESTAPIClient) ValidateStruct(data interface{}) (*ValidationResponse, error) + type RESTDocument struct + Author RESTUser + Content string + CreatedAt time.Time + IsPublished bool + Tags []string + Title string + URL url.URL + UpdatedAt *time.Time + Version int + type RESTUser struct + CreatedAt time.Time + Email string + ID int + Name string + Profile struct{ ... } + Settings struct{ ... } + Tags []string + type StructGeneratedFile struct + DownloadURL string + ExpiresAt string + Size int64 + Type string + type StructPDFGenerationRequest struct + Data interface{} + Options *StructPDFOptions + TemplatePath string + type StructPDFGenerationResponse struct + DownloadURL string + Files []StructGeneratedFile + Message string + Metadata map[string]string + RequestID string + Success bool + WatchMode bool + type StructPDFOptions struct + Debug bool + Engine string + WatchMode bool + type StructToPDFClient struct + BaseURL string + HTTPClient *http.Client + func NewStructToPDFClient(baseURL string) *StructToPDFClient + func (client *StructToPDFClient) GeneratePDFFromStruct(templatePath string, data interface{}, options *StructPDFOptions) (*StructPDFGenerationResponse, error) + type User struct + Address Address + Contact Contact + CreatedAt time.Time + Email string + ID int + IsActive bool + Name string + Tags []string + type ValidationRequest struct + Data interface{} + type ValidationResponse struct + Errors []string + Valid bool + Warnings []string + type Vendor struct + Address string + Email string + Name string + Phone string + type WatchModeManagerAdapter struct + func (a *WatchModeManagerAdapter) GetActiveWatches() map[string]generation.WatchInstanceInfo + func (a *WatchModeManagerAdapter) StartWatchMode(ctx context.Context, req generation.PDFGenerationRequest) error + func (a *WatchModeManagerAdapter) StopAllWatchModes() error + func (a *WatchModeManagerAdapter) StopWatchMode(watchID string) error v1.2.0 Oct 7, 2025 Changes in this version + func ExampleBuilderPattern() + func ExampleComplexVariables() + func ExampleTemplateProcessing() + func ExampleTemplateVariables() + func ExampleVariableFlattening() Other modules containing this package github.com/BuddhiLW/AutoPDF/v2