# All exported global Apex declarations This inventory is generated from the same source checkout as the guide. It includes core global types, nested request/result types and fields, interface methods, and the optional Agentforce extension. It gives you an exact place to check an overload or DTO field while using the worked integration articles. **Before you start:** Use the `portwoodglobal` namespace for core types in subscriber Apex. The optional extension requires its own installation/setup. Published legacy members remain in this list; their presence does not make them the preferred API for new work. Read the [action compatibility notes](#apex-actions) and [utility limits](#apex-utilities). A source update that changes an exported declaration makes the generated guide stale until it is rebuilt. Review the related integration article and test your subscriber code against the new released package before marking the next release reviewed. #### DocGenAiProvider Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenAiProvider.cls) ```apex global interface DocGenAiProvider Boolean isAvailable() String getName() String generateHtml(String prompt) ``` #### DocGenBulkFlowAction Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenBulkFlowAction.cls) ```apex global with sharing class DocGenBulkFlowAction global class Request global Id templateId global String templateApiName global String queryCondition global List recordIds global String sortOrder global String jobLabel global Boolean combinedPdfOnly global Boolean keepIndividualFiles global Boolean duplexPadding global Integer batchSize global class Response global Id jobId global String errorMessage global Boolean success global static List generateBulkDocuments(List requests) ``` #### DocGenChartCvReaper Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenChartCvReaper.cls) ```apex global with sharing class DocGenChartCvReaper implements Schedulable global void execute(SchedulableContext ctx) global static Integer reap() ``` #### DocGenDataProvider Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenDataProvider.cls) ```apex global interface DocGenDataProvider Map getData(Id recordId) List getFieldNames() ``` #### DocGenEmailTemplateInstall Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenEmailTemplateInstall.cls) ```apex global with sharing class DocGenEmailTemplateInstall implements InstallHandler global void onInstall(InstallContext context) global static Integer seedDefaults() ``` #### DocGenEmailTemplateService Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenEmailTemplateService.cls) ```apex global with sharing class DocGenEmailTemplateService global static final String TYPE_REQUEST = 'Signature_Request' global static final String TYPE_REMINDER = 'Signature_Reminder' global static final String TYPE_PIN = 'Verification_PIN' global static final String TYPE_SIGNER_COMPLETED = 'Signer_Completed' global static final String TYPE_ALL_SIGNED = 'All_Signed' global static final String TYPE_DECLINED = 'Signer_Declined' global static final String TYPE_REVOKED = 'Signature_Revoked' global static final String TYPE_COMPLETION = 'Completion_Confirmation' global static final List ALL_TYPES = new List global static final String MODE_MANAGED = 'Managed' global static final String MODE_FULL_HTML = 'Full_Html' global class RenderedEmail global String subject global String htmlBody global String plainBody global static RenderedEmail render(String type, Map tokens) global static RenderedEmail render(String type, Map tokens, String messageOverride) global static RenderedEmail render(String type, Map tokens, String messageOverride, Id brandId) global static String renderSubject(String subjectTemplate, Map tokens) ``` #### DocGenException Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenException.cls) ```apex global with sharing class DocGenException extends Exception ``` #### DocGenFieldWritebackService Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenFieldWritebackService.cls) ```apex global without sharing class DocGenFieldWritebackService global class WritebackRequest global String requestId global WritebackRequest() global static void writeBackFields(List requests) ``` #### DocGenFlowAction Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenFlowAction.cls) ```apex global with sharing class DocGenFlowAction global class Request global Id templateId global String templateApiName global Id recordId global Boolean saveToRecord global String documentTitle global String outputFormatOverride global String jsonData global class Response global Id contentDocumentId global Id contentVersionId global String errorMessage global Boolean success global static List generateDocument(List requests) ``` #### DocGenGiantQueryFlowAction Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenGiantQueryFlowAction.cls) ```apex global with sharing class DocGenGiantQueryFlowAction global class Request global Id templateId global Id recordId global Boolean saveToRecord global class Response global Id contentDocumentId global Id contentVersionId global Id jobId global Boolean isGiantQuery global String errorMessage global Boolean success global static List generateDocument(List requests) ``` #### DocGenMigrationRest Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenMigrationRest.cls) ```apex global with sharing class DocGenMigrationRest global static void readConfiguration() global static void createConfiguration() global static void discardStage() ``` #### DocGenPdfMergeFlowAction Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenPdfMergeFlowAction.cls) ```apex global with sharing class DocGenPdfMergeFlowAction global class Request global List contentVersionIds global String contentVersionIdsText global String documentTitle global Id relatedRecordId global Boolean padOddDocuments global class Response global Id contentVersionId global Id contentDocumentId global Boolean success global String errorMessage global static List mergePdfs(List requests) ``` #### DocGenPdfMerger Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenPdfMerger.cls) ```apex global with sharing class DocGenPdfMerger global class DocGenPdfMergeException extends Exception global static Blob mergePdfs(List pdfs, Boolean padOddDocuments) global static Blob mergePdfCvs(List partCvIds, Boolean padOddDocuments) global static Integer pageCount(Blob pdf) ``` #### DocGenService Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenService.cls) ```apex global with sharing class DocGenService global static Map generatePdfBlob(Id templateId, Id recordId) global static Id generateDocument(Id templateId, Id recordId) global static Id generateDocument(Id templateId, Id recordId, String outputFormatOverride) global static Id generateDocument(Id templateId, Id recordId, String outputFormatOverride, String documentTitle) global static Id generateDocument( Id templateId, Id recordId, String outputFormatOverride, String documentTitle, Id attachmentRecordId ) global static Id generateDocumentFromData(Id templateId, Id recordId, Map preloadedRecordData) global static Map generatePdfBlobFromData( Id templateId, Id recordId, Map preloadedRecordData ) global static Map generatePdfBlobFromData(Id templateId, Map dataMap) global static Id generateAndSaveFromData( Id templateId, Id attachmentRecordId, Map dataMap, String outputFormatOverride ) global static Id generateAndSaveFromData( Id templateId, Id attachmentRecordId, Map dataMap, String outputFormatOverride, String documentTitle ) global static Id generateAndSaveFromData( Id templateId, Id attachmentRecordId, Map dataMap, String outputFormatOverride, String documentTitle, Id fileAttachmentTarget ) ``` #### DocGenSignatureFinalizer Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenSignatureFinalizer.cls) ```apex global without sharing class DocGenSignatureFinalizer global class FinalizeRequest global String token global String base64Image global static void finalizeSignature(List requests) ``` #### DocGenSignatureFlowAction Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenSignatureFlowAction.cls) ```apex global with sharing class DocGenSignatureFlowAction global class Signer global Signer() global String name global String email global String role global Id contactId global class Request global Id templateId global String templateApiName global Id relatedRecordId global List signers global List signerRecords global List signerNames global List signerEmails global List signerRoles global List signerContactIds global Boolean sendEmails global String signingOrder global String emailMessage global String emailSubject global Boolean requireEmailVerification global Boolean prefillSignerEmail global Integer expirationDays global class Result global Id signatureRequestId global List signerUrls global List signerNames global List signerEmails global List signerRoles global String emailStatus global Boolean success global String errorMessage global static List generate(List requests) ``` #### DocGenSignaturePdfFlowAction Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenSignaturePdfFlowAction.cls) ```apex global with sharing class DocGenSignaturePdfFlowAction global class Request global Id templateId global Id contentVersionId global Id relatedRecordId global List signerRecords global String signingOrder global String documentTitleFormat global class Result global Id signatureRequestId global List signerUrls global List signerNames global List signerEmails global List signerRoles global Boolean success global String errorMessage global static List send(List requests) ``` #### DocGenSignaturePreparationController Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenSignaturePreparationController.cls) ```apex global with sharing class DocGenSignaturePreparationController global static List searchContacts(Id recordId, String search) global static Map getContext(Id recordId) global static Map uploadPdf(Id recordId, String fileName, String base64Pdf) global static Map selectPdf(Id recordId, Id contentVersionId) global static Map loadDraft(Id recordId, Id draftId) global static Integer saveDraft(Id recordId, Id draftId, Integer expectedRevision, String configJson) global static Map sendDraft(Id recordId, Id draftId, Integer expectedRevision, String configJson) ``` #### DocGenSignatureSubmitter Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenSignatureSubmitter.cls) ```apex global without sharing class DocGenSignatureSubmitter global class FlowInput global String token global String signatureData global class FlowOutput global Boolean isSuccess global String errorMessage global static List submitSignature(List inputs) ``` #### DocGenSignatureValidator Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenSignatureValidator.cls) ```apex global without sharing class DocGenSignatureValidator global class FlowInput global String token global class FlowOutput global Boolean isValid global String errorMessage global String signerName global String documentTitle global String documentUrl global static List validateToken(List inputs) ``` #### DocGenSigner Core · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/force-app/main/default/classes/DocGenSigner.cls) ```apex global class DocGenSigner global DocGenSigner() global String name global String email global String role global Id contactId ``` #### DocGenEinsteinProvider Optional Agentforce extension · [Source](https://github.com/Portwood-Global-Solutions/Portwood/blob/main/agentforce-ext/main/default/classes/DocGenEinsteinProvider.cls) ```apex global with sharing class DocGenEinsteinProvider implements DocGenAiProvider global String getName() global Boolean isAvailable() global String generateHtml(String prompt) global class DocGenAiException extends Exception ``` --- Related articles - [Generate documents from your own Apex](https://portwood.dev/knowledgebase/apex-generation.md) - [Build a custom Apex data provider](https://portwood.dev/knowledgebase/apex-data-provider.md) - [Call Flow actions and signing APIs from Apex](https://portwood.dev/knowledgebase/apex-actions.md) - [Use PDF, email, and cleanup helpers](https://portwood.dev/knowledgebase/apex-utilities.md) [Browse the article directory](https://portwood.dev/knowledgebase/)