Parse PandaDoc document JSON payload and provide simple API to access document data
-
static List<DocumentWrapper> parseFromJson(String jsonData)
: Used to fill in document data from JSON string.pandadoc.DocumentWrapper wrapper = pandadoc.DocumentWrapper.parseFromJson( newValue.pandadoc__InputJSON__c)[0];
global String event
: last event for this document. Possible values:document_state_changed
: document status was changed or new document was created. You get this event every time a document is sent\paid\approved\etcrecipient_completed
: a recipient filled all required input fieldsdocument_deleted
: document was deleted in PandaDoc applicationdocument_updated
: sent or completed document was edited (moved to draft status). New document version was generated.
global DocumentWrapper.DocumentData data
: document data wrapper. See DocumentData
Represents PandaDoc document data
global DocumentWrapper.DocumentPerson action_by
: available only forrecipient_completed
event. Represents a recipient who filled in document data. Equal tonull
otherwise. See DocumentPersonglobal DocumentWrapper.PandaDocUser created_by
: PandaDoc user who created the document. See PandaDocUserglobal Datetime date_created
: when document was createdglobal Datetime date_modified
: when document was editedglobal String id
: PandaDoc document Idglobal Map<String, String> metadata
: document metadataglobal SourceNode source_node
: link between PandaDoc document and Salesforce SObject. See: SourceNodeglobal String name
: document nameglobal List<DocumentWrapper.DocumentProducts> products
: list of document pricing items. See DocumentProductsglobal List<DocumentWrapper.DocumentRecipient> recipients
: list of document recipients. See DocumentRecipientglobal DocumentWrapper.PandaDocUser sent_by
: PandaDoc user who sent the document.global String status
: Document status on PandaDoc side. Possible values:document.draft
document.sent
document.completed
document.viewed
document.waiting_approval
document.rejected
document.approved
document.waiting_pay
document.paid
document.expired
document.declined
Base class for users\recipients
global String email
: emailglobal String first_name
: first nameglobal String last_name
: last nameglobal String id
: PandaDoc id
Extends from DocumentPerson and has all fields from parent.
global String avatar
: url to user avatar image
Extends from DocumentPerson and has all fields from parent.
global Boolean has_completed
:true
the recipient has completed the documentglobal String recipient_type
: possible values:signer
: the recipient has input field assigned to themCC
: the recipient has no input field assigned
global String role
: recipient role name
global String sku
: product skuglobal Map<String, Object> custom_fields
: here you will get all fields that were selected on theConfigure Tokens
page for this Product type. By default there is a selectedId
field forOpportunityLineItem
object. Please note that if the field value equals tonull
, this value won’t been added here, Dictionary won’t have this key.global Map<String, Object> custom_columns
: here you will get all custom columns that were added on PandaDoc UI.global String description
: product description.global DocumentWrapper.Discount discount
: product discount. Should be percent. Please see Discount.global String name
: product nameglobal String price
: string representation of product price per unitglobal Integer qty
: items quantityglobal String subtotal
: (price * qty) - discount
represents discount
global String type
: currently always equals topercent
global String value
: string representation of discount size