Pega Sales Automation API
Pega Sales Automation™ includes a variety of work objects, for example, accounts, contacts, and so on. Use the Pega Sales Automation API to create or edit work objects from any external application and to enhance the flexibility of the application to communicate with other systems.
- Generating the authentication token
- Prerequisites
- Data formats
- Contact API
- Account API
- Organization API
- Opportunity API
- Leads API
- Codes
For more information, see Integration-Services category.
Generating the authentication token
The authentication token verifies if the credentials provided in the authorization header by using *Basic* authentication are valid or not.
URL format - GET https://[hostname:port]/prweb/api/v1/authenticate
.
Sample response - headers
{ "date": "Tue, 04 Aug 2019 09:55:49 GMT", "cache-control": "max-age=0", "server": "Apache-Coyote/1.1", "content-length": "0", "content-type": "text/plain;charset=UTF-8" }
Prerequisites
- Ensure that the operator whose credentials are provided for authorization has the PegaRULES:PegaAPI role in the section on the access group rule form.
- Ensure that the operator performing API operations is the Sales Automation application user and has all of the required permissions.
- Optional: If you use http instead of https, ensure that you clear the check box in the Service Package: api under the section.
Data formats
When a work object has an embedded page, the data of the page is inserted in the table along with an index. When you update the work object, pass the pzIndexes parameter. Review the following example:
{ "content":{ "LastName":"Modified" "Address": {"pxObjClass": "Data-Address-Postal","pyCity": "ABCD3","pyState": "Telangana3","pzIndexOwnerKey": "PEGACRM-ENTITY-CONTACT CON-6","pzIndexes": {"Index_Address": "0"}}} } }
If you do not pass the pzIndexes parameter, the system creates a new entry in the table instead of updating the required entry.
Ensure that the date time property is always in the YYYYMMDDThhmmss.SS GMT
format, for example, 20190914T094514.187 GMT.
Contact API
Get contact
Implementation notes - Gets the details of a contact given its ID.
URL - GET https://[hostname:port]/prweb/api/v1/cases/ID.
Request parameter - ID - pzInsKey of the contact to be fetched.
Sample response - header
{ "date": "Tue, 23 Apr 2019 10:28:31 GMT", "content-encoding": "gzip", "etag": "\"20190416T102444.324 GMT\"", "vary": "Accept-Encoding", "content-type": "application/json;charset=UTF-8", "cache-control": "no-cache", "connection": "Keep-Alive", "content-length": "3138" }
Sample response - body
{ "caseTypeID": "UPlus-SAPlus-Work-Contact", "createdBy": "SASysAdmin.SAPlus", "createTime": "2017-10-27T06:44:01.241Z", "ID": "UPLUS-SAPLUS-WORK-CONTACT SAMPLECON-20", "lastUpdatedBy": "[email protected]", "lastUpdateTime": "2019-04-16T10:24:44.324Z", "name": "Kiley Amigon", "pxObjClass": "Pega-API-CaseManagement-Case", "status": "Open-Active", "urgency": "10", "actions": { "ID": "pyUpdateCaseDetails", "name": "Edit details", "pxObjClass": "Pega-API-CaseManagement-Action" }, { "ID": "crmEdit", "name": "Edit", "pxObjClass": "Pega-API-CaseManagement-Action" } ], "content": { "AccountID": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-36", "BirthDate": "1978-04-21", "CampaignID": "PEGAMKT-WORK CMP-151", "CampaignName": "test1234", "CLV_VALUE": "235", "crmAddress": " 25 E 75th St #69\nLos Angeles\nCA\n90034\nUSA", "CrmCurrentTime": "2018-12-19T11:44:04.387Z", "crmSearchOrg": "Org not found", "crmSearchRelatedAccount": "Account not found", "crmTerritorySearch": "West", "DontCall": "false", "DontEmail": "false", "EmailDecision": "[email protected]", "FavorabilityRating": "2-Passive", "FilterDateShowAll": "True", "FirstName": "Kiley", "Gender": "M", "googleMapLink": "http://maps.google.com/maps?q=25 E 75th St #69,Los Angeles,CA,USA,United States,90034&", "HomeEmail": "[email protected]", "HomePhone": "410-655-8723", "InfluenceRating": "3-Low", "IsCustomer": "false", "IsTarget": "false", "LastName": "Amigon", "MapAddressForDisplay": "Los Angeles, CA, USA", "MaritalStatus": "Married", "MobilePhone": "7889898821", "Name": "Kiley Amigon", "OfficePhone": "8878765541", "OldHomeEmail": "[email protected]", "OldHomePhone": "410-655-8723", "OldMobilePhone": "7889898821", "OldOfficePhone": "8878765541", "OldTerritoryID": "SampleBT2", "OldWorkEmail": "[email protected]", "OrganizationID": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-6", "OrgInitEmpty": "false", "pxApplication": "SAPlus", "pxApplicationVersion": "01.01.01", "pxCommitDateTime": "2019-04-16T10:24:44.328Z", "pxCoveredCount": "0", "pxCoveredCountOpen": "0", "pxCoveredCountUnsatisfied": "0", "pxCreateDateTime": "2017-10-27T06:44:01.241Z", "pxCreateOperator": "SASysAdmin.SAPlus", "pxCreateOpName": "SASysAdmin.SAPlus", "pxCreateSystemID": "pega", "pxExternalSystemUpdateCount": "7", "pxGeolocationAddress": " 25 E 75th St #69,Los Angeles,CA,90034,USA", "pxInsName": "SAMPLECON-20", "pxLatitude": "33.9722523", "pxLatLong": "33.9722523 , -118.2737948", "pxLockHandle": "UPLUS-SAPLUS-WORK-CONTACT SAMPLECON-20", "pxLongitude": "-118.2737948", "pxMoveImportDateTime": "2019-02-04T08:28:32.690Z", "pxMoveImportOperId": "sfasysadmin", "pxMoveImportOperName": "Administrator", "pxObjClass": "UPlus-SAPlus-Work-Contact", "pxSaveDateTime": "2019-04-16T10:24:44.324Z", "pxUpdateCounter": "27", "pxUpdateDateTime": "2019-04-16T10:24:44.323Z", "pxUpdateOperator": "[email protected]", "pxUpdateOpName": "Narasimham Nallamalli", "pxUpdateOrgUnit": "Sales", "pxUpdateSystemID": "pega", "pxUrgencyWork": "10", "pxUrgencyWorkClass": "10", "pyAgeFromDate": "2017-10-27T06:43:47.144Z", "pyConfirmationNote": "Thank you for your input", "pyElapsedCustomerUnsatisfied": "0.0", "pyElapsedStatusNew": "0", "pyElapsedStatusOpen": "0.0", "pyElapsedStatusPending": "0", "pyID": "SampleCON-20", "pyLabel": "Kiley Amigon", "pyLabelOld": "Kiley Amigon", "pyNextEmailThreadID": "1", "pyNotifyQuickStream": "QuestionAboutItem", "pyOrigDivision": "SMB", "pyOrigOrg": "UPlus", "pyOrigOrgUnit": "Sales", "pyOrigUserDivision": "SMB", "pyOrigUserID": "SASysAdmin.SAPlus", "pyOrigUserWorkgroup": "default@UPlus", "pyOwnerDivision": "SMB", "pyOwnerOrg": "UPlus", "pyOwnerOrgUnit": "Sales", "pyProcessInBackground": "false", "pyPushNotificationsEnabled": "false", "pySatisfactionChangeTimestamp": "2017-10-27T06:44:01.267Z", "pyStatusCustomerSat": "New", "pyStatusWork": "Open-Active", "pyStatusWorkOld": "Open-Active", "pyStatusWorkTimestamp": "2017-10-27T06:44:01.268Z", "pyWorkIDPrefix": "Con-", "pzIndexCount": "7", "pzInsKey": "UPLUS-SAPLUS-WORK-CONTACT SAMPLECON-20", "ResponsibilityDescription": "Monitoring revenue margins and worker productivity as well as implementing new directives for growth", "Salutation": "Mr.", "SearchOn": "Email", "ShowCancelButton": "true", "TerritoryID": "SamplePT2", "TerritoryName": "West", "Title": "Director of Operations", "WinScore": "500", "WorkEmail": "[email protected]", "WorkType": "Contact", "Address": { "pxObjClass": "Data-Address-Postal" }, "Addresses": [ { "AddressType": "Business Address", "IsPrimary": "true", "PrimaryLabel": "(Primary)", "pxObjClass": "Data-Address-Postal", "pyCity": "Los Angeles", "pyCountry": "USA", "pyPostalCode": "90034", "pyState": "CA", "pyStreet": "25 E 75th St #69", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-CONTACT SAMPLECON-20", "pzIndexes": { "Index_Addresses": "6" } } ], "CampaignsList": [ { "CampaignID": "PEGAMKT-WORK CMP-134", "CampaignName": "test1234", "pxObjClass": "PegaCRM-Work-", "ContactsList": [ "" ] } ], "Domains": [], "EngagementStatuses": [], "NewTerritory": { "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory" }, "pxFlow": { "pzInternalCaseFlow": { "pxAssignActivity": "pzCreateInternalAssignment", "pxAssignClass": "Assign-Internal", "pxAssignIsVirtual": "true", "pxAssignmentKey": "ASSIGN-INTERNAL UPLUS-SAPLUS-WORK-CONTACT SAMPLECON-20!PZINTERNALCASEFLOW", "pxFlowInsKey": "RULE-OBJ-FLOW WORK- PZINTERNALCASEFLOW #20191105T160214.591 GMT", "pxIsInvestigative": "false", "pxLastActivityStatus": "false", "pxLastUpdateBy": "SASysAdmin.SAPlus", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@uplus", "pxSubscript": "pzInternalCaseFlow", "pxSystemFlow": "true", "pxTimeFlowStarted": "20171027T064401.243 GMT", "pyCategory": "FlowStandard", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Contact", "pyFlowType": "pzInternalCaseFlow", "pyFlowTypeLabel": "Internal flow", "pyLastFlowStep": "ASSIGNMENT63", "pyLastFlowStepLabel": "Perform action", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@uplus", "flowName": "pzInternalCaseFlow", "isNewCase": "true", "ReferencePageName": "tempWorkPage" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "false", "pyFAProcessOnJump": "false", "pyFlowStep": "ASSIGNMENT63", "pyStepLabel": "Perform action", "pyStepType": "ASSIGNMENT" } ] } }, "pxSystemUpdateDetailsList": [], "pyAttachmentCategories": [] } }
Create contact
Implementation notes - Creates a new contact work object provided with the required parameters.
URL - POST https://[hostname:port]/prweb/api/v1/cases.
Request parameter
Parameter | Description |
---|---|
LastName | Last name of the contact to be created. |
TerritoryID | Identifier of the territory where the current account is included. |
Sample request
"caseTypeID": "PegaCRM-Entity-Contact", "processID": "pyStartCase", "parentCaseID": "", "content": {"LastName":"API Contact", "TerritoryID":"BT1" } }
Sample response - header
{ "location": "https://lab5087.lab.pega.com/prweb/api/v1/cases/PEGACRM-ENTITY-CONTACT+CON-3", "date": "Tue, 23 Apr 2019 10:44:50 GMT", "etag": "\"20190423T104450.609 GMT\"", "content-length": "109", "content-type": "application/json;charset=UTF-8" }
Sample response - body
{ "ID": "PEGACRM-ENTITY-CONTACT CON-3", "nextPageID": "Confirm", "pxObjClass": "Pega-API-CaseManagement-Case" }
Update contact
Implementation notes - Performs an action given a contact ID and an optional content in the request body.
URL - PUT https://sfa-dev.pega.com:443/prweb/api/v1/cases/[ID].
Request parameter
Parameter | Description |
---|---|
ID | pzInsKey of the contact to be updated. |
If-Match | etag from Get or Create contact. |
ActionID | Related to crmEdit. |
Sample request - body
{ "content": {"LastName":"Modified"}, "pageInstructions": [ { "instruction": "APPEND", "target": ".myPageList", "listIndex": "3", "listMoveToIndex": "5", "content": {} } ] }
Search contact
Implementation notes - Searches the contact work object provided with the required parameters.
URL - GET https://[hostname:port]/prweb/api/v1/data/[ID].
Request parameter - ID – D_Search[SearchParam,ClassName] data page with parameters passed to fetch the contact.
Sample URL - GET/https:[hostname:port]/prweb/api/v1/data/D_crmContactList?ContFilter=test&ClassName=PegaCRM-Entity-Contact.
Sample response - header
set-cookie:JSESSIONID=154C2CDF084578867CDEA176171DA05F; Path=/prweb; Secure; HttpOnlycache-control:no-cachecontent-type:application/json;charset=UTF-8content-length:128637date:Mon, 29 Apr 2019 13:00:18 GMTvary:Accept-Encoding
Sample response - body
{ "pxMore":"false" ,"pxObjClass":"Code-Pega-List" ,"pxPageCount":"0" ,"pxQueryTimeStamp":"2019-04-29T13:00:18.677Z" ,"pxResultCount":"1" ,"pxSQLStatementPost":"SELECT \"PC0\".\"name\" AS \"Name\" , \"PC0\".\"title\" AS \"Title\" , \"PC0\".\"workemail\" AS \"WorkEmail\" , \"PC0\".\"officephone\" AS \"OfficePhone\" , \"PC0\".\"favorabilityrating\" AS \"FavorabilityRating\" , \"PC0\".\"maritalstatus\" AS \"MaritalStatus\" , \"PC0\".\"gender\" AS \"Gender\" , \"BT\".\"name\" AS \"Name\" , \"Org\".\"name\" AS \"Name\" , \"PC0\".\"pyid\" AS \"pyID\" , \"PC0\".\"firstname\" AS \"FirstName\" , \"PC0\".\"lastname\" AS \"LastName\" , \"PC0\".\"homeemail\" AS \"HomeEmail\" , \"PC0\".\"iscustomer\" AS \"IsCustomer\" , \"PC0\".\"territoryid\" AS \"TerritoryID\" , \"PC0\".\"organizationid\" AS \"OrganizationID\" , \"PC0\".\"accountid\" AS \"AccountID\" , \"PC0\".\"pxcreatedatetime\" AS \"pxCreateDateTime\" , \"PC0\".\"pxcreateopname\" AS \"pxCreateOpName\" , \"PC0\".\"pxupdatedatetime\" AS \"pxUpdateDateTime\" , \"PC0\".\"pxupdateopname\" AS \"pxUpdateOpName\" , \"Acc\".\"territoryid\" AS \"TerritoryID\" , \"Org\".\"territoryid\" AS \"TerritoryID\" , \"PC0\".\"pystatuswork\" AS \"pyStatusWork\" , \"PC0\".\"pyselected\" AS \"pySelected\" , \"PC0\".\"homephone\" AS \"HomePhone\" , \"Acc\".\"name\" AS \"Name\" , \"PC0\".\"mobilephone\" AS \"MobilePhone\" , \"PC0\".\"pxlatitude\" AS \"pxLatitude\" , \"PC0\".\"pxlongitude\" AS \"pxLongitude\" , \"PC0\".\"pxlatlong\" AS \"pxLatLong\" , \"PC0\".\"googlemaplink\" AS \"googleMapLink\" , \"PC0\".\"mapaddressfordisplay\" AS \"MapAddressForDisplay\" , \"Org\".\"pyid\" AS \"pyID\" , \"PC0\".\"birthdate\" AS \"BirthDate\" , \"PC0\".\"pzinskey\" AS \"pzInsKey\" , \"PC0\".\"assistantname\" AS \"AssistantName\" , \"PC0\".\"assistantphone\" AS \"AssistantPhone\" , \"PC0\".\"faxnumber\" AS \"FaxNumber\" , \"PC0\".\"assistantemail\" AS \"AssistantEmail\" , \"Org\".\"iscustomer\" AS \"IsCustomer\" , \"Org\".\"pzinskey\" AS \"pzInsKey\" , \"PC0\".\"dontcall\" AS \"DontCall\" , \"PC0\".\"dontemail\" AS \"DontEmail\" , \"Shared\".\"srcol1\" AS \"pxLinkedRefFrom\" , \"PC0\".\"dontcontactviaemail\" AS \"DontContactViaEmail\" , \"PC0\".\"dontcontactviaphone\" AS \"DontContactViaPhone\" FROM pegadata.crm_entity_contact \"PC0\" LEFT OUTER JOIN pegadata.crm_entity_account \"Acc\" ON ( ( \"PC0\".\"accountid\" = \"Acc\".\"pzinskey\" ) AND ( ( \"Acc\".\"pxobjclass\" IN (? , ? ) ) ) AND ( ( \"PC0\".\"pxobjclass\" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.crm_entity_org \"Org\" ON ( ( \"PC0\".\"organizationid\" = \"Org\".\"pzinskey\" ) AND ( ( \"Org\".\"pxobjclass\" = ? ) ) AND ( ( \"PC0\".\"pxobjclass\" IN (? , ? ) ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY \"BT\" ON ( ( \"PC0\".\"territoryid\" = \"BT\".\"territoryid\" ) AND ( ( \"BT\".\"pxobjclass\" = ? ) ) AND ( ( \"PC0\".\"pxobjclass\" IN (? , ? ) ) ) ) LEFT OUTER JOIN ( SELECT \"Shared\".\"pxlinkedreffrom\" AS \"srcol1\" , \"Shared\".\"pzinskey\" AS \"pzinskey\" FROM pegadata.crm_link_sharedwork \"Shared\" WHERE \"Shared\".\"pxobjclass\" = ? ) \"Shared\" ON ( ( \"Shared\".\"srcol1\" = \"PC0\".\"pzinskey\" ) AND ( ( \"PC0\".\"pxobjclass\" IN (? , ? ) ) ) ) WHERE ( \"PC0\".\"pystatuswork\" IN (? , ? ) AND ( UPPER(\"Org\".\"name\") LIKE ? OR UPPER(\"PC0\".\"name\") LIKE ? OR \"PC0\".\"pyid\" = ? OR \"PC0\".\"workemail\" = ? ) ) ORDER BY 12 ASC" ,"pxSQLStatementPre":"SELECT \"PC0\".\"name\" AS \"Name\" , \"PC0\".\"title\" AS \"Title\" , \"PC0\".\"workemail\" AS \"WorkEmail\" , \"PC0\".\"officephone\" AS \"OfficePhone\" , \"PC0\".\"favorabilityrating\" AS \"FavorabilityRating\" , \"PC0\".\"maritalstatus\" AS \"MaritalStatus\" , \"PC0\".\"gender\" AS \"Gender\" , \"BT\".\"name\" AS \"Name\" , \"Org\".\"name\" AS \"Name\" , \"PC0\".\"pyid\" AS \"pyID\" , \"PC0\".\"firstname\" AS \"FirstName\" , \"PC0\".\"lastname\" AS \"LastName\" , \"PC0\".\"homeemail\" AS \"HomeEmail\" , \"PC0\".\"iscustomer\" AS \"IsCustomer\" , \"PC0\".\"territoryid\" AS \"TerritoryID\" , \"PC0\".\"organizationid\" AS \"OrganizationID\" , \"PC0\".\"accountid\" AS \"AccountID\" , \"PC0\".\"pxcreatedatetime\" AS \"pxCreateDateTime\" , \"PC0\".\"pxcreateopname\" AS \"pxCreateOpName\" , \"PC0\".\"pxupdatedatetime\" AS \"pxUpdateDateTime\" , \"PC0\".\"pxupdateopname\" AS \"pxUpdateOpName\" , \"Acc\".\"territoryid\" AS \"TerritoryID\" , \"Org\".\"territoryid\" AS \"TerritoryID\" , \"PC0\".\"pystatuswork\" AS \"pyStatusWork\" , \"PC0\".\"pyselected\" AS \"pySelected\" , \"PC0\".\"homephone\" AS \"HomePhone\" , \"Acc\".\"name\" AS \"Name\" , \"PC0\".\"mobilephone\" AS \"MobilePhone\" , \"PC0\".\"pxlatitude\" AS \"pxLatitude\" , \"PC0\".\"pxlongitude\" AS \"pxLongitude\" , \"PC0\".\"pxlatlong\" AS \"pxLatLong\" , \"PC0\".\"googlemaplink\" AS \"googleMapLink\" , \"PC0\".\"mapaddressfordisplay\" AS \"MapAddressForDisplay\" , \"Org\".\"pyid\" AS \"pyID\" , \"PC0\".\"birthdate\" AS \"BirthDate\" , \"PC0\".\"pzinskey\" AS \"pzInsKey\" , \"PC0\".\"assistantname\" AS \"AssistantName\" , \"PC0\".\"assistantphone\" AS \"AssistantPhone\" , \"PC0\".\"faxnumber\" AS \"FaxNumber\" , \"PC0\".\"assistantemail\" AS \"AssistantEmail\" , \"Org\".\"iscustomer\" AS \"IsCustomer\" , \"Org\".\"pzinskey\" AS \"pzInsKey\" , \"PC0\".\"dontcall\" AS \"DontCall\" , \"PC0\".\"dontemail\" AS \"DontEmail\" , \"Shared\".\"srcol1\" AS \"pxLinkedRefFrom\" , \"PC0\".\"dontcontactviaemail\" AS \"DontContactViaEmail\" , \"PC0\".\"dontcontactviaphone\" AS \"DontContactViaPhone\" FROM pegadata.crm_entity_contact \"PC0\" LEFT OUTER JOIN pegadata.crm_entity_account \"Acc\" ON ( ( \"PC0\".\"accountid\" = \"Acc\".\"pzinskey\" ) AND ( ( \"Acc\".\"pxobjclass\" IN (? , ? ) ) ) AND ( ( \"PC0\".\"pxobjclass\" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.crm_entity_org \"Org\" ON ( ( \"PC0\".\"organizationid\" = \"Org\".\"pzinskey\" ) AND ( ( \"Org\".\"pxobjclass\" = ? ) ) AND ( ( \"PC0\".\"pxobjclass\" IN (? , ? ) ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY \"BT\" ON ( ( \"PC0\".\"territoryid\" = \"BT\".\"territoryid\" ) AND ( ( \"BT\".\"pxobjclass\" = ? ) ) AND ( ( \"PC0\".\"pxobjclass\" IN (? , ? ) ) ) ) LEFT OUTER JOIN ( SELECT \"Shared\".\"pxlinkedreffrom\" AS \"srcol1\" , \"Shared\".\"pzinskey\" AS \"pzinskey\" FROM pegadata.crm_link_sharedwork \"Shared\" WHERE \"Shared\".\"pxobjclass\" = ? ) \"Shared\" ON ( ( \"Shared\".\"srcol1\" = \"PC0\".\"pzinskey\" ) AND ( ( \"PC0\".\"pxobjclass\" IN (? , ? ) ) ) ) WHERE ( \"PC0\".\"pystatuswork\" IN (? , ? ) AND ( UPPER(\"Org\".\"name\") LIKE ? OR UPPER(\"PC0\".\"name\") LIKE ? OR \"PC0\".\"pyid\" = ? OR \"PC0\".\"workemail\" = ? ) ) ORDER BY 12 ASC" ,"pxTotalResultCount":"0" ,"pyForceDBName":"" ,"pyForceUseStandardDB":"false" ,"pyMaxRecords":"0" ,"pyObjClass":"PegaCRM-Entity-Contact" ,"pyQueryTimeoutInterval":"0" ,"pyRowCount":"0" ,"pyStartIndex":"0" ,"pyUseReportsDatabase":"false" ,"pzLoadTime":"April 29, 2019 9:00:18 AM EDT" ,"pzPageNameHash":"_pa7380641120526830pz" ,"pxResults":[ { "DontCall":"false" ,"DontEmail":"false" ,"IsCustomer":"false" ,"LastName":"test" ,"Name":"test" ,"pxCreateDateTime":"2019-04-23T10:37:34.582Z" ,"pxCreateOpName":"Narasimham Nallamalli" ,"pxObjClass":"PegaCRM-Entity-Contact" ,"pxUpdateDateTime":"2019-04-23T10:37:54.902Z" ,"pxUpdateOpName":"Narasimham Nallamalli" ,"pyID":"Con-1" ,"pyStatusWork":"Open-Active" ,"pzInsKey":"PEGACRM-ENTITY-CONTACT CON-1" ,"TerritoryID":"BT1" ,"pxPages": { "Acc":{ "pxObjClass":"PegaCRM-Entity-Account" ,"pxSubscript":"Acc" } ,"BT":{ "Name":"Global" ,"pxObjClass":"PegaCRM-Data-SFA-BusinessTerritory" ,"pxSubscript":"BT" } ,"Org":{ "pxObjClass":"PegaCRM-Entity-Org" ,"pxSubscript":"Org" } ,"Shared":{ "pxObjClass":"Link-Association-SharedWork" ,"pxSubscript":"Shared" } } } ]}
Account API
Get account
Implementation notes - Gets the details of an account given its ID.
URL - GET https://[hostname:port]/prweb/api/v1/cases/ID.
Request parameter - ID - pzInsKey of the account to be fetched.
Sample response - header
{ "date": "Tue, 23 Apr 2019 11:08:55 GMT", "content-encoding": "gzip", "etag": "\"20190219T142131.754 GMT\"", "vary": "Accept-Encoding", "content-type": "application/json;charset=UTF-8", "cache-control": "no-cache", "connection": "Keep-Alive", "content-length": "3985" }
Sample response - body
{ "caseTypeID": "UPlus-SAPlus-Work-Account", "createdBy": "SASalesOps.SAPlus", "createTime": "2017-10-17T11:33:45.376Z", "description": "Acme is a software product company. They have software products Acme Insight Software for Retails, Wholesalers, Distributors.", "ID": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-1", "lastUpdatedBy": "jking", "lastUpdateTime": "2019-02-19T14:21:31.754Z", "name": "Acme Software", "pxObjClass": "Pega-API-CaseManagement-Case", "status": "Open-Active", "urgency": "10", "content": { "AccountOwnerNames": "Terry Mason", "AccountOwnerUserIDs": "tmason", "crmAddress": " 3801 East Frank Phillips Blvd\nBartlesville\nOK\n74006\nUSA", "crmSearchOrg": "Acme Software", "crmSearchOwner": "SASalesOps.SAPlus", "crmTerritorySearch": "North East", "EmployeeCount": "1200", "googleMapLink": "http://maps.google.com/maps?q=3801 East Frank Phillips Blvd,Bartlesville,OK,USA,United States,74006&", "Industry": "Services", "IsTarget": "false", "MapAddressForDisplay": "Bartlesville, OK, USA", "Name": "Acme Software", "OldOwnerID": "tmason", "OldPhoneNumber": "2136968004", "OldTerritoryID": "SampleBT2", "OldWebsite": "www.acmesoft.com", "OrganizationID": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-1", "OrgInitEmpty": "false", "PhoneNumber": "213-696-8004", "pxApplication": "SAPlus", "pxApplicationVersion": "01.01.01", "pxCommitDateTime": "2019-02-19T14:21:33.731Z", "pxCoveredCount": "0", "pxCoveredCountOpen": "0", "pxCoveredCountUnsatisfied": "0", "pxCreateDateTime": "2017-10-17T11:33:45.376Z", "pxCreateOperator": "SASalesOps.SAPlus", "pxCreateOpName": "SASalesOps.SAPlus", "pxCreateSystemID": "pega", "pxGeolocationAddress": " 3801 East Frank Phillips Blvd,Bartlesville,OK,74006,USA", "pxInsName": "ACC-1", "pxLatitude": "36.7502276", "pxLatLong": "36.7502630 , -95.9347448", "pxLockHandle": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-1", "pxLongitude": "-95.9347379", "pxMoveImportDateTime": "2019-02-04T08:28:32.484Z", "pxMoveImportOperId": "sfasysadmin", "pxMoveImportOperName": "Administrator", "pxObjClass": "UPlus-SAPlus-Work-Account", "pxSaveDateTime": "2019-02-19T14:21:31.754Z", "pxUpdateCounter": "12", "pxUpdateDateTime": "2019-02-05T09:57:02.544Z", "pxUpdateOperator": "jking", "pxUpdateOpName": "Joel King", "pxUpdateOrgUnit": "Sales", "pxUpdateSystemID": "pega", "pxUrgencyPartyTotal": "0", "pxUrgencyWork": "10", "pxUrgencyWorkClass": "10", "pyAgeFromDate": "2017-10-17T11:33:45.378Z", "pyConfirmationNote": "Assigned to manager to fix correspondence problem", "pyDescription": "Acme is a software product company. They have software products Acme Insight Software for Retails, Wholesalers, Distributors.", "pyElapsedCustomerUnsatisfied": "3.0", "pyElapsedStatusNew": "7.0", "pyElapsedStatusOpen": "0", "pyElapsedStatusPending": "0", "pyFlowKey": "RULE-OBJ-FLOW PEGACRM-ENTITY-ACCOUNT CRMCREATE #20170911T111927.682 GMT", "pyFlowName": "crmCreate", "pyFolderType": "pyDefault", "pyHasAttachments": "true", "pyID": "Acc-1", "pyLabel": "Acme Software", "pyLabelOld": "Acme Software", "pyNextEmailThreadID": "1", "pyNotifyQuickStream": "QuestionAboutItem", "pyOrigDivision": "SMB", "pyOrigOrg": "pega.com", "pyOrigOrgUnit": "Sales", "pyOrigUserDivision": "SMB", "pyOrigUserID": "SASalesOps.SAPlus", "pyOrigUserWorkgroup": "default@UPlus", "pyOwnerDivision": "SMB", "pyOwnerOrg": "pega.com", "pyOwnerOrgUnit": "Sales", "pyOwnerUserID": "tmason", "pyProcessInBackground": "false", "pyPushNotificationsEnabled": "false", "pySatisfactionChangeTimestamp": "2017-10-17T11:33:48.470Z", "pySelectAll": "true", "pyStatusCustomerSat": "New", "pyStatusWork": "Open-Active", "pyStatusWorkOld": "Open-Active", "pyStatusWorkTimestamp": "2017-10-17T11:33:53.068Z", "pyTemporaryObject": "false", "pyWorkIDPrefix": "Acc-", "pyWorkPartiesRule": "Default", "pzIndexCount": "16", "pzInsKey": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-1", "Revenue": "50000", "SellingMode": "B2B", "ShortName": "Acme Software", "ShowCancelButton": "true", "TerritoryID": "SampleBT2", "TerritoryName": "North East", "Website": "www.acmesoft.com", "WorkType": "Account", "Address": { "pxObjClass": "Data-Address-Postal", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-1", "pzIndexes": {} }, "Addresses": [ { "AddressType": "Business Address", "IsPrimary": "true", "PrimaryLabel": "(Primary)", "pxObjClass": "Data-Address-Postal", "pyCity": "Bartlesville", "pyCountry": "USA", "pyPostalCode": "74006", "pyState": "OK", "pyStreet": "3801 East Frank Phillips Blvd", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-1", "pzIndexes": { "Index_Addresses": "13" } } ], "EngagementStatuses": [ { "FamilyCategoryName": "Security", "GroupFamilyName": "Commercial Security", "ProductGroupName": "Surveillance Cameras", "ProductID": "PRSampleProd13", "ProductName": "Network Video Recorder with PoE", "pxObjClass": "PegaCRM-Embed-EngagementStatus", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-1", "Status": "Blocked", "pzIndexes": { "Index_EngagementStatuses": "15" } } ] "NewTerritory": { "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory" }, "pxCorrSummary": [ { "pxCorrHandle": "DATA-CORR-EMAIL UPLUS-SAPLUS-WORK-ACCOUNT ACC-1!20171017T113346.347 GMT", "pxCorrName": "crmAccountCreated", "pxCorrType": "Email", "pxObjClass": "Embed-CorrSummary" } ], "pxFlow": { "FixCorrespondence": { "pxAssignActivity": "WorkList", "pxAssignClass": "Assign-Worklist", "pxAssignmentKey": "ASSIGN-WORKLIST UPLUS-SAPLUS-WORK-ACCOUNT ACC-1!FIXCORRESPONDENCE", "pxAssignStatus": "Open-Active", "pxFlowInsKey": "RULE-OBJ-FLOW WORK- FIXCORRESPONDENCE #20191124T094252.831 GMT", "pxIsInvestigative": "true", "pxLastUpdateBy": "System", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "SFASysAdmin", "pxRouteToUserName": "SFA Administrator", "pxSubscript": "FixCorrespondence", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171017T113556.221 GMT", "pyCategory": "ProcessFlow", "pyConfirmationNote": "Assigned to manager to fix correspondence problem", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Account", "pyFlowType": "FixCorrespondence", "pyFlowTypeLabel": "Fix and send correspondences", "pyInstructions": "Fix Correspondence", "pyLastFlowStep": "ASSIGNMENT6", "pyLastFlowStepLabel": "FixCorrespondence", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "SFASysAdmin", "CorrHandle": "DATA-CORR-EMAIL UPLUS-SAPLUS-WORK-ACCOUNT ACC-1!20171017T113346.347 GMT", "CorrList": "crmAccountCreated", "CorrPartyRole": "Owner", "CorrProblem": "** Caught com.sun.mail.util.MailConnectException: Couldn't connect to host, port: sample.com, 25; timeout 60000", "ErrorMessage": "** Caught com.sun.mail.util.MailConnectException: Couldn't connect to host, port: sample.com, 25; timeout 60000", "flowName": "FixCorrespondence", "pyTempPlaceHolder": "TempPlaceHolder", "ReferencePageName": "pyWorkPage" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "false", "pyFAProcessOnJump": "false", "pyFlowStep": "ASSIGNMENT6", "pyStepLabel": "FixCorrespondence", "pyStepType": "ASSIGNMENT" } ] }, "pzInternalCaseFlow": { "pxAssignActivity": "pzCreateInternalAssignment", "pxAssignClass": "Assign-Internal", "pxAssignIsVirtual": "true", "pxAssignmentKey": "ASSIGN-INTERNAL UPLUS-SAPLUS-WORK-ACCOUNT ACC-1!PZINTERNALCASEFLOW", "pxFlowInsKey": "RULE-OBJ-FLOW WORK- PZINTERNALCASEFLOW #20191105T160214.591 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "SASalesOps.SAPlus", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@uplus", "pxSubscript": "pzInternalCaseFlow", "pxSystemFlow": "true", "pxTimeFlowStarted": "20171017T113346.238 GMT", "pyCategory": "FlowStandard", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Account", "pyFlowType": "pzInternalCaseFlow", "pyFlowTypeLabel": "Internal flow", "pyLastFlowStep": "ASSIGNMENT63", "pyLastFlowStepLabel": "Perform action", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@uplus", "flowName": "pzInternalCaseFlow", "isNewCase": "true", "ReferencePageName": "AccountPage" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "false", "pyFAProcessOnJump": "false", "pyFlowStep": "ASSIGNMENT63", "pyStepLabel": "Perform action", "pyStepType": "ASSIGNMENT" } ] } }, "pxSystemUpdateDetailsList": [], "pyAttachmentCategories": [], "pyWorkParty": {}, "TeamMembers": [ { "crmSearchTerm": "Terry Mason", "IsAccountOwner": "true", "pxObjClass": "PegaCRM-Party-TeamMember", "pxPartyRole": "TeamMember", "pyEmail1": "[email protected]", "pyFullName": "Terry Mason", "pyHomePhoneTimes": "Anytime", "pyMobilePhoneTimes": "Anytime", "pyOtherPhoneTimes": "Anytime", "pyPartyNotified": "false", "pyResponseMode1": "Email1", "pyWorkPartyUri": "tmason", "pyWorkPhone": "347592469", "pyWorkPhoneTimes": "Anytime", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-1", "TeamMemberRole": "Owner", "pzIndexes": { "crmIndexTeamMembers": "14" } } ] } }
Create account
Implementation notes - Creates a new account work object provided with the required parameters.
URL - POST https://[hostname:port]/prweb/api/v1/cases.
Request parameter
Parameter | Description |
---|---|
Name | Name of an account to be created. |
TerritoryID | Identifier of the territory where the current account is included. |
OrganizationID | Identifier of the organization where the current account is included. |
Sample request
{ "caseTypeID": "PegaCRM-Entity-Account", "processID": "pyStartCase", "parentCaseID": "", "content": {"Name":"API Account", "OrganizationID":"PEGACRM-ENTITY-ORG ORG-3", "TerritoryID":"BT1"} }
Sample response - header
{ "location": "https://lab5087.lab.pega.com/prweb/api/v1/cases/PEGACRM-ENTITY-ACCOUNT+ACC-3", "date": "Tue, 23 Apr 2019 10:44:50 GMT", "etag": "\"20190423T104450.609 GMT\"", "content-length": "109", "content-type": "application/json;charset=UTF-8" }
Sample response - body
{ "ID": "PEGACRM-ENTITY- ACCOUNT ACC-3", "nextPageID": "Confirm", "pxObjClass": "Pega-API-CaseManagement-Case" }
Update account
Implementation notes - Performs an action given an account ID and an optional content in the request body.
URL - PUT https://sfa-dev.pega.com:443/prweb/api/v1/cases/[ID].
Request parameter
Parameter | Description |
---|---|
ID | pzInsKey of the contact to be updated. |
If-Match | etag from Get or Create account. |
ActionID | Related to crmEdit |
Sample request - body
{ "content": {"Name":"Modified"}, "pageInstructions": [ { "instruction": "APPEND", "target": ".myPageList", "listIndex": "3", "listMoveToIndex": "5", "content": {} } ] }
Search account
Implementation notes - Searches the account work object provided with the required parameters.
URL - GET https://[hostname:port]/prweb/api/v1/data/[ID]
.
Request parameter - ID – D_Search[SearchParam,ClassName] data page with parameters passed to fetch the account.
Sample URL - GET/https:[hostname:port]/prweb/api/v1/data/D_crmAccountsList? AccFilter=Oliver&ClassName=PegaCRM-Entity-Account.
Sample response - header
{ set-cookie:JSESSIONID=1545E3617CE391B335C6B772947E468C; Path=/prweb; Secure; HttpOnly cache-control:no-cache content-type:application/json;charset=UTF-8 content-length:104895 date:Mon, 29 Apr 2019 13:20:01 GMT vary:Accept-Encoding }
Sample response - body
{ "pxMore": "false", "pxObjClass": "Code-Pega-List", "pxPageCount": "0", "pxQueryTimeStamp": "2019-04-29T13:20:01.073Z", "pxResultCount": "1", "pxSQLStatementPost": "SELECT "PC0"."name" AS "Name" , "Org"."name" AS "Name" , "PC0"."industry" AS "Industry" , "OppTotalAmtRep"."srcol3" AS "pySummaryCount(1)" , "OppTotalAmtRep"."srcol1" AS "pySummaryValue(1)" , "PC0"."istarget" AS "IsTarget" , "Oper"."pyusername" AS "pyUserName" , "BT"."name" AS "Name" , "PC0"."pyid" AS "pyID" , "PC0"."sellingmode" AS "SellingMode" , "Org"."territoryid" AS "TerritoryID" , "Org"."pzinskey" AS "pzInsKey" , "PC0"."pzinskey" AS "pzInsKey" , "PC0"."googlemaplink" AS "googleMapLink" , "PC0"."pxlatitude" AS "pxLatitude" , "PC0"."pxlongitude" AS "pxLongitude" , "PC0"."pxlatlong" AS "pxLatLong" , "PC0"."mapaddressfordisplay" AS "MapAddressForDisplay" , "PC0"."organizationid" AS "OrganizationID" , "PC0"."pydescription" AS "pyDescription" , "PC0"."pyowneruserid" AS "pyOwnerUserID" , "PC0"."territoryid" AS "TerritoryID" , "PC0"."contactid" AS "ContactID" , "PC0"."crmaddress" AS "crmAddress" , "PC0"."website" AS "Website" , "PC0"."phonenumber" AS "PhoneNumber" , "PC0"."employeecount" AS "EmployeeCount" , "PC0"."revenue" AS "Revenue" , "Shared"."srcol1" AS "pxLinkedRefFrom" FROM pegadata.crm_entity_account "PC0" LEFT OUTER JOIN pegadata.crm_entity_org "Org" ON ( ( "PC0"."organizationid" = "Org"."pzinskey" ) AND ( ( "Org"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.pr_operators "Oper" ON ( ( "Oper"."pyuseridentifier" = "PC0"."pyowneruserid" ) AND ( ( "Oper"."pxobjclass" IN (? , ? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY "BT" ON ( ( "PC0"."territoryid" = "BT"."territoryid" ) AND ( ( "BT"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN ( SELECT "OppTotalAmtRep"."accountid" AS "srcol2" , SUM("OppTotalAmtRep"."opportunityamount") AS "srcol1" , COUNT("OppTotalAmtRep"."pyid") AS "srcol3" FROM pegadata.crm_work_opportunity "OppTotalAmtRep" WHERE ( "OppTotalAmtRep"."pystatuswork" IN (? , ? ) ) AND ( ( ( "OppTotalAmtRep"."pxobjclass" IN (? , ? ) ) ) ) GROUP BY "OppTotalAmtRep"."accountid" ) "OppTotalAmtRep" ON ( ( "OppTotalAmtRep"."srcol2" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN ( SELECT "Shared"."pxlinkedreffrom" AS "srcol1" , "Shared"."pzinskey" AS "pzinskey" FROM pegadata.crm_link_sharedwork "Shared" WHERE "Shared"."pxobjclass" = ? ) "Shared" ON ( ( "Shared"."srcol1" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) WHERE ( ( "PC0"."pystatuswork" IN (? , ? ) AND ( UPPER("PC0"."name") LIKE ? OR UPPER("Oper"."pyusername") LIKE ? OR UPPER("Org"."name") LIKE ? OR "PC0"."pyid" = ? ) ) ) ORDER BY 1 ASC", "pxSQLStatementPre": "SELECT "PC0"."name" AS "Name" , "Org"."name" AS "Name" , "PC0"."industry" AS "Industry" , "OppTotalAmtRep"."srcol3" AS "pySummaryCount(1)" , "OppTotalAmtRep"."srcol1" AS "pySummaryValue(1)" , "PC0"."istarget" AS "IsTarget" , "Oper"."pyusername" AS "pyUserName" , "BT"."name" AS "Name" , "PC0"."pyid" AS "pyID" , "PC0"."sellingmode" AS "SellingMode" , "Org"."territoryid" AS "TerritoryID" , "Org"."pzinskey" AS "pzInsKey" , "PC0"."pzinskey" AS "pzInsKey" , "PC0"."googlemaplink" AS "googleMapLink" , "PC0"."pxlatitude" AS "pxLatitude" , "PC0"."pxlongitude" AS "pxLongitude" , "PC0"."pxlatlong" AS "pxLatLong" , "PC0"."mapaddressfordisplay" AS "MapAddressForDisplay" , "PC0"."organizationid" AS "OrganizationID" , "PC0"."pydescription" AS "pyDescription" , "PC0"."pyowneruserid" AS "pyOwnerUserID" , "PC0"."territoryid" AS "TerritoryID" , "PC0"."contactid" AS "ContactID" , "PC0"."crmaddress" AS "crmAddress" , "PC0"."website" AS "Website" , "PC0"."phonenumber" AS "PhoneNumber" , "PC0"."employeecount" AS "EmployeeCount" , "PC0"."revenue" AS "Revenue" , "Shared"."srcol1" AS "pxLinkedRefFrom" FROM pegadata.crm_entity_account "PC0" LEFT OUTER JOIN pegadata.crm_entity_org "Org" ON ( ( "PC0"."organizationid" = "Org"."pzinskey" ) AND ( ( "Org"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.pr_operators "Oper" ON ( ( "Oper"."pyuseridentifier" = "PC0"."pyowneruserid" ) AND ( ( "Oper"."pxobjclass" IN (? , ? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY "BT" ON ( ( "PC0"."territoryid" = "BT"."territoryid" ) AND ( ( "BT"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN ( SELECT "OppTotalAmtRep"."accountid" AS "srcol2" , SUM("OppTotalAmtRep"."opportunityamount") AS "srcol1" , COUNT("OppTotalAmtRep"."pyid") AS "srcol3" FROM pegadata.crm_work_opportunity "OppTotalAmtRep" WHERE ( "OppTotalAmtRep"."pystatuswork" IN (? , ? ) ) AND ( ( ( "OppTotalAmtRep"."pxobjclass" IN (? , ? ) ) ) ) GROUP BY "OppTotalAmtRep"."accountid" ) "OppTotalAmtRep" ON ( ( "OppTotalAmtRep"."srcol2" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN ( SELECT "Shared"."pxlinkedreffrom" AS "srcol1" , "Shared"."pzinskey" AS "pzinskey" FROM pegadata.crm_link_sharedwork "Shared" WHERE "Shared"."pxobjclass" = ? ) "Shared" ON ( ( "Shared"."srcol1" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) WHERE ( ( "PC0"."pystatuswork" IN (? , ? ) AND ( UPPER("PC0"."name") LIKE ? OR UPPER("Oper"."pyusername") LIKE ? OR UPPER("Org"."name") LIKE ? OR "PC0"."pyid" = ? ) ) ) ORDER BY 1 ASC", "pxTotalResultCount": "0", "pyForceDBName": "", "pyForceUseStandardDB": "false", "pyMaxRecords": "0", "pyObjClass": "PegaCRM-Entity-Account", "pyQueryTimeoutInterval": "0", "pyRowCount": "0", "pyStartIndex": "0", "pyUseReportsDatabase": "false", "pzLoadTime": "April 29, 2019 9:20:01 AM EDT", "pzPageNameHash": "_pa7381823524608663pz", "pxResults":[ { "Industry": "Public Administration", "IsTarget": "false", "Name": "Test Corp", "OrganizationID": "PEGACRM-ENTITY-ORG ORG-1", "pxObjClass": "PegaCRM-Entity-Account", "pyID": "Acc-101", "pyOwnerUserID": "[email protected]", "pzInsKey": "PEGACRM-ENTITY-ACCOUNT ACC-101", "SellingMode": "B2B", "TerritoryID": "BT1", "Website": "www.test.com", "pxPages": { "BT": { "Name": "Global", "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory", "pxSubscript": "BT" }, "Oper": { "pxObjClass": "Data-Admin-Operator-ID", "pxSubscript": "Oper", "pyUserName": "Narasimham Nallamalli" }, "OppTotalAmtRep": { "pxObjClass": "PegaCRM-Work-SFA-Opportunity", "pxSubscript": "OppTotalAmtRep", "pySummaryCount":[ "" ], "pySummaryValue":[ "" ], }, "Org": { "Name": "Test Corp", "pxObjClass": "PegaCRM-Entity-Org", "pxSubscript": "Org", "pzInsKey": "PEGACRM-ENTITY-ORG ORG-1", "TerritoryID": "BT1" }, "Shared": { "pxObjClass": "Link-Association-SharedWork", "pxSubscript": "Shared" } } } ] }
Organization API
Get organization
Implementation notes - Gets the details of an organization given its ID.
URL - GET https://[hostname:port]/prweb/api/v1/cases/ID
.
Request parameter - ID - pzInsKey of the organization to be fetched.
Sample response - header
{ "date": "Tue, 23 Apr 2019 11:55:47 GMT", "content-encoding": "gzip", "etag": "\"20190415T102443.016 GMT\"", "vary": "Accept-Encoding", "content-type": "application/json;charset=UTF-8", "cache-control": "no-cache", "connection": "Keep-Alive", "content-length": "3451" }
Sample response - body
{ "caseTypeID": "UPlus-SAPlus-Work-Org", "createdBy": "SASalesOps.SAPlus", "createTime": "2017-10-17T11:33:53.247Z", "description": "Acadia's world-class research facilities rival the largest institutions. With our unique location and small campus, Acadia fosters collaboration across disciplines", "ID": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2", "lastUpdatedBy": "SFASampleSysAdmin", "lastUpdateTime": "2019-04-15T10:24:43.016Z", "name": "Acadia Research Corp", "pxObjClass": "Pega-API-CaseManagement-Case", "status": "Open-Active", "urgency": "10", "content": { "crmAddress": " 116 Kanawha Boulevard East\nCharleston\nWV\n25301\nUSA", "crmSearchOwner": "Terry Mason", "crmTerritorySearch": "North East", "EmployeeCount": "3000", "googleMapLink": "http://maps.google.com/maps?q=116 Kanawha Boulevard East,Charleston,WV,USA,United States,25301&", "Industry": "Services", "IsCustomer": "true", "IsTarget": "false", "MapAddressForDisplay": "Charleston, WV, USA", "Name": "Acadia Research Corp", "OldPhoneNumber": "608-382-4541", "OldTerritoryID": "SampleBT2", "OldWebsite": "www.Acadiacorp.com", "OrgInitEmpty": "true", "PhoneNumber": "608-382-4541", "pxApplication": "SAPlus", "pxApplicationVersion": "01.01.01", "pxCommitDateTime": "2019-04-15T10:24:43.023Z", "pxCoveredCount": "0", "pxCoveredCountOpen": "0", "pxCoveredCountUnsatisfied": "0", "pxCreateDateTime": "2017-10-17T11:33:53.247Z", "pxCreateOperator": "SASalesOps.SAPlus", "pxCreateOpName": "SASalesOps.SAPlus", "pxCreateSystemID": "pega", "pxGeolocationAddress": " 116 Kanawha Boulevard East,Charleston,WV,25301,USA", "pxInsName": "SAMPLEORG-2", "pxLatitude": "38.3538630", "pxLockHandle": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2", "pxLongitude": "-81.6426405", "pxMoveImportDateTime": "2019-02-04T08:28:33.243Z", "pxMoveImportOperId": "sfasysadmin", "pxMoveImportOperName": "Administrator", "pxObjClass": "UPlus-SAPlus-Work-Org", "pxSaveDateTime": "2019-04-15T10:24:43.016Z", "pxUpdateCounter": "19", "pxUpdateDateTime": "2019-04-15T10:24:43.012Z", "pxUpdateOperator": "SFASampleSysAdmin", "pxUpdateOpName": "SFA Sample Sys Admin", "pxUpdateOrgUnit": "Sales", "pxUpdateSystemID": "pega", "pxUrgencyPartyTotal": "0", "pxUrgencyWork": "10", "pxUrgencyWorkClass": "10", "pyAgeFromDate": "2017-10-17T11:33:28.840Z", "pyConfirmationNote": "Assigned to manager to fix correspondence problem", "pyDescription": "Acadia's world-class research facilities rival the largest institutions. With our unique location and small campus, Acadia fosters collaboration across disciplines", "pyElapsedCustomerUnsatisfied": "0.0", "pyElapsedStatusNew": "1.0", "pyElapsedStatusOpen": "0", "pyElapsedStatusPending": "0", "pyHasAttachments": "true", "pyID": "SampleOrg-2", "pyLabel": "Acadia Research Corp", "pyLabelOld": "Acadia Research Corp", "pyNextEmailThreadID": "1", "pyNotifyQuickStream": "QuestionAboutItem", "pyOrigDivision": "SMB", "pyOrigOrg": "UPlus", "pyOrigOrgUnit": "Sales", "pyOrigUserDivision": "SMB", "pyOrigUserID": "SASalesOps.SAPlus", "pyOrigUserWorkgroup": "default@UPlus", "pyOwnerDivision": "SMB", "pyOwnerOrg": "UPlus", "pyOwnerOrgUnit": "Sales", "pyOwnerUserID": "tmason", "pyPartyClassPrompt": "Follower", "pyPushNotificationsEnabled": "false", "pySatisfactionChangeTimestamp": "2017-10-17T11:33:53.364Z", "pySelectAll": "true", "pyStatusCustomerSat": "New", "pyStatusWork": "Open-Active", "pyStatusWorkOld": "Open-Active", "pyStatusWorkTimestamp": "2017-10-17T11:33:54.429Z", "pyWorkIDPrefix": "Org-", "pzIndexCount": "12", "pzInsKey": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2", "Revenue": "150000", "ShortName": "Acadia Research Corp", "ShowCancelButton": "true", "TerritoryID": "SampleBT2", "TerritoryName": "North East", "Website": "www.Acadiacorp.com", "WorkType": "Organization", "Address": { "pxObjClass": "Data-Address-Postal", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2", "pzIndexes": { "Index_Address": "5" } }, "Addresses": [ { "AddressType": "Business Address", "IsPrimary": "true", "PrimaryLabel": "(Primary)", "pxObjClass": "Data-Address-Postal", "pyCity": "Charleston", "pyCountry": "USA", "pyPostalCode": "25301", "pyState": "WV", "pyStreet": "116 Kanawha Boulevard East", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2", "pzIndexes": { "Index_Addresses": "11" } } ], "Domains": [], "NewTerritory": { "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory" }, "pxCorrSummary": [ { "pxCorrHandle": "DATA-CORR-EMAIL UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2!20171017T113353.273 GMT", "pxCorrName": "crmOrgCreated", "pxCorrType": "Email", "pxObjClass": "Embed-CorrSummary" } ], "pxFlow": { "FixCorrespondence": { "pxAssignActivity": "WorkList", "pxAssignClass": "Assign-Worklist", "pxAssignmentKey": "ASSIGN-WORKLIST UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2!FIXCORRESPONDENCE", "pxAssignStatus": "Open-Active", "pxFlowInsKey": "RULE-OBJ-FLOW WORK- FIXCORRESPONDENCE #20191124T094252.831 GMT", "pxIsInvestigative": "true", "pxLastUpdateBy": "System", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "SFASysAdmin", "pxRouteToUserName": "SFA Administrator", "pxSubscript": "FixCorrespondence", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171017T113656.351 GMT", "pyCategory": "ProcessFlow", "pyConfirmationNote": "Assigned to manager to fix correspondence problem", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Org", "pyFlowType": "FixCorrespondence", "pyFlowTypeLabel": "Fix and send correspondences", "pyInstructions": "Fix Correspondence", "pyLastFlowStep": "ASSIGNMENT6", "pyLastFlowStepLabel": "FixCorrespondence", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "SFASysAdmin", "CorrHandle": "DATA-CORR-EMAIL UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2!20171017T113353.273 GMT", "CorrList": "crmOrgCreated", "CorrPartyRole": "Owner", "CorrProblem": "** Caught com.sun.mail.util.MailConnectException: Couldn't connect to host, port: sample.com, 25; timeout 60000", "ErrorMessage": "** Caught com.sun.mail.util.MailConnectException: Couldn't connect to host, port: sample.com, 25; timeout 60000", "flowName": "FixCorrespondence", "pyTempPlaceHolder": "TempPlaceHolder", "ReferencePageName": "pyWorkPage" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "false", "pyFAProcessOnJump": "false", "pyFlowStep": "ASSIGNMENT6", "pyStepLabel": "FixCorrespondence", "pyStepType": "ASSIGNMENT" } ] }, "pzInternalCaseFlow": { "pxAssignActivity": "pzCreateInternalAssignment", "pxAssignClass": "Assign-Internal", "pxAssignIsVirtual": "true", "pxAssignmentKey": "ASSIGN-INTERNAL UPLUS-SAPLUS-WORK-ORG SAMPLEORG-2!PZINTERNALCASEFLOW", "pxFlowInsKey": "RULE-OBJ-FLOW WORK- PZINTERNALCASEFLOW #20191105T160214.591 GMT", "pxIsInvestigative": "false", "pxLastActivityStatus": "VerificationNotRequired", "pxLastUpdateBy": "SASalesOps.SAPlus", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@uplus", "pxSubscript": "pzInternalCaseFlow", "pxSystemFlow": "true", "pxTimeFlowStarted": "20171017T113353.250 GMT", "pyCategory": "FlowStandard", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Org", "pyFlowType": "pzInternalCaseFlow", "pyFlowTypeLabel": "Internal flow", "pyLastFlowStep": "ASSIGNMENT63", "pyLastFlowStepLabel": "Perform action", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@uplus", "flowName": "pzInternalCaseFlow", "isNewCase": "true", "ReferencePageName": "tempWorkPage" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "false", "pyFAProcessOnJump": "false", "pyFlowStep": "ASSIGNMENT63", "pyStepLabel": "Perform action", "pyStepType": "ASSIGNMENT" } ] } }, "pxSystemUpdateDetailsList": [], "pyAttachmentCategories": [], "pyWorkParty": {} } }
Create organization
Implementation notes - Creates a new organization work object provided with the required parameters.
URL - POST https://[hostname:port]/prweb/api/v1/cases
.
Request parameter
Parameter | Description |
---|---|
Name | Name of an organization to be created. |
TerritoryID | Identifier of the territory where the current account is included. |
Sample request
{ "caseTypeID": "PegaCRM-Entity-ORG", "processID": "pyStartCase", "parentCaseID": "", "content": {"Name":"API Organization", "TerritoryID":"BT1"} }
Sample response - header
{ "location": "https://lab5087.lab.pega.com/prweb/api/v1/cases/PEGACRM-ENTITY-ORG+ORG-2", "date": "Tue, 23 Apr 2019 11:57:55 GMT", "etag": "\"20190423T115755.753 GMT\"", "content-length": "105", "content-type": "application/json;charset=UTF-8" }
Sample response - body
{ "ID": "PEGACRM-ENTITY-ORG ORG-2", "nextPageID": "Confirm", "pxObjClass": "Pega-API-CaseManagement-Case" }
Update organization
Implementation notes - Performs an action given an organization ID and an optional content in the request body.
URL - PUT https://sfa-dev.pega.com:443/prweb/api/v1/cases/[ID]
.
Request parameter
Parameter | Description |
---|---|
ID | pzInsKey of the contact to be updated. |
If-Match | etag from Get or Create Organization. |
ActionID | Related to crmEdit. |
Sample request - body
{ "content": {"Name":"Modified"}, "pageInstructions": [ { "instruction": "APPEND", "target": ".myPageList", "listIndex": "3", "listMoveToIndex": "5", "content": {} } ] }
Search organization
Implementation notes - Searches the opportunity work object provided with the required parameters.
URL - GET https://[hostname:port]/prweb/api/v1/data/[ID]
.
Request parameter - ID – D_Search[SearchParam,ClassName] data page with parameters passed to fetch the organization.
Sample URL - GET/https:[hostname:port]/prweb/api/v1/data/D_crmOrgList?OrgParam=Alliance&ClassName=PegaCRM-Entity-Org.
Sample response - header
{ set-cookie:JSESSIONID=77CE7FF894BF74DDDB6D6F2714C9AD02; Path=/prweb; Secure; HttpOnly cache-control:no-cache content-type:application/json;charset=UTF-8 content-length:102182 date:Mon, 29 Apr 2019 13:26:49 GMT vary:Accept-Encoding }
Sample response - body
{ "pxMore": "false", "pxObjClass": "Code-Pega-List", "pxPageCount": "0", "pxQueryTimeStamp": "2019-04-29T13:26:49.286Z", "pxResultCount": "1", "pxSQLStatementPost": "SELECT "PC0"."name" AS "Name" , "PC0"."parentname" AS "ParentName" , "PC0"."industry" AS "Industry" , "PC0"."employeecount" AS "EmployeeCount" , "PC0"."revenue" AS "Revenue" , "Sub1"."srcol2" AS "pySummaryCount(1)" , "PC0"."istarget" AS "IsTarget" , "PC0"."iscustomer" AS "IsCustomer" , "Oper"."pyusername" AS "pyUserName" , "BT"."name" AS "Name" , "PC0"."pyid" AS "pyID" , "PC0"."pxcreatedatetime" AS "pxCreateDateTime" , "PC0"."pxcreateopname" AS "pxCreateOpName" , "PC0"."pxupdatedatetime" AS "pxUpdateDateTime" , "PC0"."pxupdateopname" AS "pxUpdateOpName" , "PC0"."pystatuswork" AS "pyStatusWork" , "PC0"."pzinskey" AS "pzInsKey" , "PC0"."crmaddress" AS "crmAddress" , "PC0"."phonenumber" AS "PhoneNumber" , "PC0"."googlemaplink" AS "googleMapLink" , "PC0"."pxlatitude" AS "pxLatitude" , "PC0"."pxlongitude" AS "pxLongitude" , "PC0"."pxlatlong" AS "pxLatLong" , "PC0"."mapaddressfordisplay" AS "MapAddressForDisplay" , "PC0"."website" AS "Website" , "PC0"."territoryid" AS "TerritoryID" , "PC0"."pyowneruserid" AS "pyOwnerUserID" , "PC0"."pydescription" AS "pyDescription" , "PC0"."activeoppcount" AS "ActiveOppCount" , "PC0"."activeopptotalamt" AS "ActiveOppTotalAmt" , "PC0"."ticker" AS "Ticker" , "Shared"."srcol1" AS "pxLinkedRefFrom" FROM pegadata.crm_entity_org "PC0" INNER JOIN pegadata.pr_operators "Oper" ON ( ( "Oper"."pyuseridentifier" = "PC0"."pyowneruserid" ) AND ( ( "Oper"."pxobjclass" IN (? , ? , ? ) ) ) AND ( ( "PC0"."pxobjclass" = ? ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY "BT" ON ( ( "PC0"."territoryid" = "BT"."territoryid" ) AND ( ( "BT"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" = ? ) ) ) LEFT OUTER JOIN ( SELECT "Sub1"."organizationid" AS "srcol1" , COUNT("Sub1"."pyid") AS "srcol2" FROM pegadata.crm_entity_account "Sub1" WHERE ( "Sub1"."pystatuswork" IN (? , ? ) ) AND ( ( ( "Sub1"."pxobjclass" IN (? , ? ) ) ) ) GROUP BY "Sub1"."organizationid" ) "Sub1" ON ( ( "Sub1"."srcol1" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" = ? ) ) ) LEFT OUTER JOIN ( SELECT "Shared"."pxlinkedreffrom" AS "srcol1" , "Shared"."pzinskey" AS "pzinskey" FROM pegadata.crm_link_sharedwork "Shared" WHERE "Shared"."pxobjclass" = ? ) "Shared" ON ( ( "Shared"."srcol1" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" = ? ) ) ) WHERE ( "PC0"."pystatuswork" IN (? , ? ) AND ( UPPER("PC0"."name") LIKE ? OR UPPER("Oper"."pyusername") LIKE ? OR "PC0"."pyid" = ? ) ) ORDER BY 1 ASC", "pxSQLStatementPre": "SELECT "PC0"."name" AS "Name" , "PC0"."parentname" AS "ParentName" , "PC0"."industry" AS "Industry" , "PC0"."employeecount" AS "EmployeeCount" , "PC0"."revenue" AS "Revenue" , "Sub1"."srcol2" AS "pySummaryCount(1)" , "PC0"."istarget" AS "IsTarget" , "PC0"."iscustomer" AS "IsCustomer" , "Oper"."pyusername" AS "pyUserName" , "BT"."name" AS "Name" , "PC0"."pyid" AS "pyID" , "PC0"."pxcreatedatetime" AS "pxCreateDateTime" , "PC0"."pxcreateopname" AS "pxCreateOpName" , "PC0"."pxupdatedatetime" AS "pxUpdateDateTime" , "PC0"."pxupdateopname" AS "pxUpdateOpName" , "PC0"."pystatuswork" AS "pyStatusWork" , "PC0"."pzinskey" AS "pzInsKey" , "PC0"."crmaddress" AS "crmAddress" , "PC0"."phonenumber" AS "PhoneNumber" , "PC0"."googlemaplink" AS "googleMapLink" , "PC0"."pxlatitude" AS "pxLatitude" , "PC0"."pxlongitude" AS "pxLongitude" , "PC0"."pxlatlong" AS "pxLatLong" , "PC0"."mapaddressfordisplay" AS "MapAddressForDisplay" , "PC0"."website" AS "Website" , "PC0"."territoryid" AS "TerritoryID" , "PC0"."pyowneruserid" AS "pyOwnerUserID" , "PC0"."pydescription" AS "pyDescription" , "PC0"."activeoppcount" AS "ActiveOppCount" , "PC0"."activeopptotalamt" AS "ActiveOppTotalAmt" , "PC0"."ticker" AS "Ticker" , "Shared"."srcol1" AS "pxLinkedRefFrom" FROM pegadata.crm_entity_org "PC0" INNER JOIN pegadata.pr_operators "Oper" ON ( ( "Oper"."pyuseridentifier" = "PC0"."pyowneruserid" ) AND ( ( "Oper"."pxobjclass" IN (? , ? , ? ) ) ) AND ( ( "PC0"."pxobjclass" = ? ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY "BT" ON ( ( "PC0"."territoryid" = "BT"."territoryid" ) AND ( ( "BT"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" = ? ) ) ) LEFT OUTER JOIN ( SELECT "Sub1"."organizationid" AS "srcol1" , COUNT("Sub1"."pyid") AS "srcol2" FROM pegadata.crm_entity_account "Sub1" WHERE ( "Sub1"."pystatuswork" IN (? , ? ) ) AND ( ( ( "Sub1"."pxobjclass" IN (? , ? ) ) ) ) GROUP BY "Sub1"."organizationid" ) "Sub1" ON ( ( "Sub1"."srcol1" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" = ? ) ) ) LEFT OUTER JOIN ( SELECT "Shared"."pxlinkedreffrom" AS "srcol1" , "Shared"."pzinskey" AS "pzinskey" FROM pegadata.crm_link_sharedwork "Shared" WHERE "Shared"."pxobjclass" = ? ) "Shared" ON ( ( "Shared"."srcol1" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" = ? ) ) ) WHERE ( "PC0"."pystatuswork" IN (? , ? ) AND ( UPPER("PC0"."name") LIKE ? OR UPPER("Oper"."pyusername") LIKE ? OR "PC0"."pyid" = ? ) ) ORDER BY 1 ASC", "pxTotalResultCount": "0", "pyForceDBName": "", "pyForceUseStandardDB": "false", "pyMaxRecords": "0", "pyObjClass": "PegaCRM-Entity-Org", "pyQueryTimeoutInterval": "0", "pyRowCount": "0", "pyStartIndex": "0", "pyUseReportsDatabase": "false", "pzLoadTime": "April 29, 2019 9:26:49 AM EDT", "pzPageNameHash": "_pa7382231738134380pz", "pxResults":[ { "Industry": "Public Administration", "IsTarget": "false", "Name": "Test Corp", "pxCreateDateTime": "2019-04-23T11:11:44.159Z", "pxCreateOpName": "Narasimham Nallamalli", "pxObjClass": "PegaCRM-Entity-Org", "pxUpdateDateTime": "2019-04-23T11:12:20.173Z", "pxUpdateOpName": "Narasimham Nallamalli", "pyID": "Org-1", "pyOwnerUserID": "[email protected]", "pyStatusWork": "Open-Active", "pzInsKey": "PEGACRM-ENTITY-ORG ORG-1", "TerritoryID": "BT1", "Website": "www.test.com", "pxPages": { "BT": { "Name": "Global", "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory", "pxSubscript": "BT" }, "Oper": { "pxObjClass": "Data-Admin-Operator-ID", "pxSubscript": "Oper", "pyUserName": "Narasimham Nallamalli" }, "Shared": { "pxObjClass": "Link-Association-SharedWork", "pxSubscript": "Shared" }, "Sub1": { "pxObjClass": "PegaCRM-Entity-Account", "pxSubscript": "Sub1", "pySummaryCount":[ "1" ], } } } ]}
Opportunity API
Get opportunity
Implementation notes - Gets the details of an opportunity given its ID.
URL - GET https://[hostname:port]/prweb/api/v1/cases/ID
.
Request parameter - ID - pzInsKey of the opportunity to be fetched.
Sample response - header
{ "date": "Tue, 23 Apr 2019 12:05:08 GMT", "content-encoding": "gzip", "etag": "\"20190219T142241.556 GMT\"", "vary": "Accept-Encoding", "content-type": "application/json;charset=UTF-8", "cache-control": "no-cache", "connection": "Keep-Alive", "content-length": "3121" }
Sample response - body
{ "caseTypeID": "UPlus-SAPlus-Work-Opportunity", "createdBy": "jking", "createTime": "2019-02-05T11:19:31.744Z", "ID": "UPLUS-SAPLUS-WORK-OPPORTUNITY SAMPLEOPP-85", "lastUpdatedBy": "jking", "lastUpdateTime": "2019-02-19T14:22:41.556Z", "name": "steve john", "pxObjClass": "Pega-API-CaseManagement-Case", "stage": "PRIM1", "status": "Open-Active", "urgency": "10", "content": { "AccountID": "UPLUS-SAPLUS-WORK-ACCOUNT SAMPLEACC-534", "CloseDate": "2019-02-28T05:00:00.000Z", "ContactID": "UPLUS-SAPLUS-WORK-CONTACT SAMPLECON-122", "ContactRelation": "true", "crmFirstStage": "Qualification", "crmSearchOwner": "Joel King", "crmTerritorySearch": "North America", "ForecastCategory": "NotForecasted", "ForecastLastCalculated": "2019-02-05T11:19:32.011Z", "googleMapLink": "http://maps.google.com/maps?q=,&", "IsPartnerSourced": "true", "Name": "steve john", "OldOwnerUserID": "jking", "OpportunityAmount": "54345345", "OpportunityClosePeriod": "20191", "OpportunityCloseQtr": "1", "OpportunityCloseYear": "2019", "OpportunityStage": "Qualification", "OpportunityStageOld": "Qualification", "OrganizationID": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-24", "PartnerID": "UPLUS-SAPLUS-WORK-ORG-PARTNER PRN-20012", "pxApplication": "SAPlus", "pxApplicationVersion": "8", "pxCommitDateTime": "2019-02-19T14:22:42.465Z", "pxCoveredCount": "0", "pxCoveredCountOpen": "0", "pxCoveredCountUnsatisfied": "0", "pxCreateDateTime": "2019-02-05T11:19:31.744Z", "pxCreateOperator": "jking", "pxCreateOpName": "Joel King", "pxCreateSystemID": "pega", "pxCurrentStage": "PRIM1", "pxCurrentStageLabel": "Qualification", "pxCurrentStageSubscript": "PRIM1_1", "pxExternalSystemUpdateCount": "0", "pxInsName": "SAMPLEOPP-85", "pxObjClass": "UPlus-SAPlus-Work-Opportunity", "pxSaveDateTime": "2019-02-19T14:22:41.556Z", "pxUpdateCounter": "2", "pxUpdateDateTime": "2019-02-05T11:19:31.921Z", "pxUpdateOperator": "jking", "pxUpdateOpName": "Joel King", "pxUpdateOrgUnit": "Sales", "pxUpdateSystemID": "pega", "pxUrgencyWork": "10", "pxUrgencyWorkClass": "10", "pxUrgencyWorkStageSLA": "0", "pyAgeFromDate": "2019-02-05T11:19:31.744Z", "pyConfirmationNote": "Thank you for your input", "pyElapsedCustomerUnsatisfied": "0.0", "pyElapsedStatusNew": "0.0", "pyElapsedStatusOpen": "0", "pyElapsedStatusPending": "0", "pyFlowKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-OPPORTUNITY CRMCREATE #20190128T081840.426 GMT", "pyFlowName": "crmCreate", "pyFolderType": "DefaultOpportunityWorkPage", "pyGotoStage": "Qualification", "pyID": "SampleOpp-85", "pyLabel": "steve john", "pyLabelOld": "steve john", "pyNextEmailThreadID": "1", "pyNotifyQuickStream": "QuestionAboutItem", "pyOrigDivision": "SMB", "pyOrigOrg": "pega.com", "pyOrigOrgUnit": "Sales", "pyOrigUserDivision": "SMB", "pyOrigUserID": "jking", "pyOrigUserWorkgroup": "default@UPlus", "pyOwnerDivision": "SMB", "pyOwnerOrg": "pega.com", "pyOwnerOrgUnit": "Sales", "pyOwnerUserID": "jking", "pyPushNotificationsEnabled": "false", "pySatisfactionChangeTimestamp": "2019-02-05T11:19:31.896Z", "pyStatusCustomerSat": "New", "pyStatusWork": "Open-Active", "pyStatusWorkOld": "Open-Active", "pyStatusWorkTimestamp": "2019-02-05T11:19:32.011Z", "pyTemporaryObject": "false", "pyTempText": "desktop", "pyWorkIDPrefix": "SampleOpp-", "pyWorkPartiesRule": "Default", "pzIndexCount": "4", "pzInsKey": "UPLUS-SAPLUS-WORK-OPPORTUNITY SAMPLEOPP-85", "SellingMode": "B2B", "StageLastChanged": "2019-02-05T11:19:31.769Z", "TerritoryID": "SamplePT3", "TerritoryName": "East", "WinProbability": "10", "Address": { "pxObjClass": "Data-Address-Postal" }, "Addresses": [], "Competitors": [], "Contacts": [ { "ContactID": "UPLUS-SAPLUS-WORK-CONTACT SAMPLECON-122", "IsPrimaryContact": "false", "pxCreateDateTime": "2019-02-05T11:19:31.920Z", "pxObjClass": "PegaCRM-Embed-SFA-OppContacts", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-OPPORTUNITY SAMPLEOPP-85", "Role": "Decision Maker", "pzIndexes": { "Index_OppContacts": "3" } } ], "Forecast": [ { "ForecastAmount": "54345345", "ForecastCategory": "NotForecasted", "ForecastCloseDate": "2019-02-28", "ForecastClosePeriod": "20191", "ForecastCloseQtr": "1", "ForecastCloseYear": "2019", "pxObjClass": "PegaCRM-Embed-SFA-Forecast", "TerritoryID": "OPP" }, { "ForecastAmount": "54345345", "ForecastCategory": "NotForecasted", "ForecastCloseDate": "2019-02-28", "ForecastClosePeriod": "20191", "ForecastCloseQtr": "1", "ForecastCloseYear": "2019", "pxObjClass": "PegaCRM-Embed-SFA-Forecast", "TerritoryID": "SamplePT3" }, { "ForecastAmount": "54345345", "ForecastCategory": "NotForecasted", "ForecastCloseDate": "2019-02-28", "ForecastClosePeriod": "20191", "ForecastCloseQtr": "1", "ForecastCloseYear": "2019", "pxObjClass": "PegaCRM-Embed-SFA-Forecast", "TerritoryID": "SampleBT1" }, { "ForecastAmount": "54345345", "ForecastCategory": "NotForecasted", "ForecastCloseDate": "2019-02-28", "ForecastClosePeriod": "20191", "ForecastCloseQtr": "1", "ForecastCloseYear": "2019", "pxObjClass": "PegaCRM-Embed-SFA-Forecast", "TerritoryID": "BT1" } ], "Products": [], "pxFlow": { "pzInternalCaseFlow": { "pxAssignActivity": "pzCreateInternalAssignment", "pxAssignClass": "Assign-Internal", "pxAssignIsVirtual": "true", "pxAssignmentKey": "ASSIGN-INTERNAL UPLUS-SAPLUS-WORK-OPPORTUNITY SAMPLEOPP-85!PZINTERNALCASEFLOW", "pxFlowInsKey": "RULE-OBJ-FLOW WORK- PZINTERNALCASEFLOW #20180713T133112.404 GMT", "pxIsInvestigative": "false", "pxLastActivityStatus": "false", "pxLastUpdateBy": "jking", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "[email protected]", "pxSubscript": "pzInternalCaseFlow", "pxSystemFlow": "true", "pxTimeFlowStarted": "20190205T111931.759 GMT", "pyCategory": "FlowStandard", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Opportunity", "pyFlowType": "pzInternalCaseFlow", "pyFlowTypeLabel": "Internal flow", "pyLastFlowStep": "ASSIGNMENT63", "pyLastFlowStepLabel": "Perform action", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "[email protected]", "flowName": "pzInternalCaseFlow", "isNewCase": "true", "ReferencePageName": "OpportunityWorkPage" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "false", "pyFAProcessOnJump": "false", "ASSIGNMENT63", "pyStepLabel": "Perform action", "pyStepType": "ASSIGNMENT" } ] } }, "pxStageHistory": [ { "pxEnterStageTime": "2019-02-05T11:19:31.763Z", "pxObjClass": "Embed-StageHistory", "pxStageID": "PRIM1", "pxStageName": "Qualification", "pxStageType": "Primary", "pxSubscript": "PRIM1_1", "pxProcesses": [] } ], "pxSystemUpdateDetailsList": [], "pyAttachmentCategories": [], "TeamMembers": [ { "crmSearchTerm": "Joel King", "IsOpportunityOwner": "true", "pxObjClass": "PegaCRM-Party-TeamMember", "pxPartyRole": "TeamMember", "pyEmail1": "[email protected]", "pyFullName": "Joel King", "pyHomePhoneTimes": "Anytime", "pyMobilePhoneTimes": "Anytime", "pyOtherPhoneTimes": "Anytime", "pyPartyNotified": "false", "pyResponseMode1": "Email1", "pyWorkPartyUri": "jking", "pyWorkPhone": "789921323", "pyWorkPhoneTimes": "Anytime", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-OPPORTUNITY SAMPLEOPP-85", "TeamMemberRole": "Owner", "pzIndexes": { "crmIndexTeamMembers": "2" } } ] }, "stages": [ { "ID": "PRIM1", "name": "Qualification", "pxObjClass": "Pega-API-CaseManagement-Stage" }, { "ID": "PRIM2", "name": "Analysis", "pxObjClass": "Pega-API-CaseManagement-Stage" }, { "ID": "PRIM3", "name": "Proposal", "pxObjClass": "Pega-API-CaseManagement-Stage" }, { "ID": "PRIM4", "name": "Decision", "pxObjClass": "Pega-API-CaseManagement-Stage" }, { "ID": "PRIM5", "name": "Negotiation", "pxObjClass": "Pega-API-CaseManagement-Stage" }, { "ID": "PRIM6", "name": "Closed", "pxObjClass": "Pega-API-CaseManagement-Stage" } ] }
Create opportunity
Implementation notes - Creates a new opportunity work object provided with the required parameters.
URL - POST https://[hostname:port]/prweb/api/v1/cases
.
Request parameter
Parameter | Description |
---|---|
Name | Name of the opportunity to be created. |
TerritoryID | Identifier of the territory where the current opportunity is included. |
CloseDate | Opportunity close date. |
OpportunityAmount | Amount generated from the opportunity. |
ContactID | Contact associated with the opportunity. |
AccountID | Account associated with the opportunity. |
ForecastCategory | Forecast category of the opportunity. |
OpportunityStage | Stage of the opportunity. |
Sample request
{ "caseTypeID": "PegaCRM-Work-SFA-Opportunity", "processID": "pyStartCase", "parentCaseID": "", "content": { "OpportunityAmount":"89000", "CloseDate":"20200914T094514.187 GMT", "Name":"Test API Oppty", "TerritoryID":"BT1", "OpportunityStage":"Proposal", "ForecastCategory":"Upside", "AccountID":"PegaCRM-Entity-Account ACC-109", } } }
Sample response - header
{ "status": "201", "date": "Mon, 29 Apr 2019 13:46:45 GMT", "server": "server", "etag": "\"20190429T134645.565 GMT\"", "content-length": "117" "location": "https://crmdev83.pegacloud.net/prweb/api/v1/cases/PEGACRM-WORK-SFA-OPPORTUNITY+OPP-109", "content-type": "application/json;charset=UTF-8" }
Sample response - body
{ "PEGACRM-WORK-SFA-OPPORTUNITY OPP-109", "nextPageID”:"Confirm", "pxObjClass": “Pega-API-CaseManagement-Case" }
Update opportunity
Implementation notes - Performs an action given an opportunity ID and an optional content in the request body.
URL - PUT https://sfa-dev.pega.com:443/prweb/api/v1/cases/[ID]
.
Request parameter
Parameter | Description |
---|---|
ID | pzInsKey of the opportunity to be updated |
If-Match | etag from Get or Create Opportunity. |
ActionID | Related to crmEdit. |
Sample request - body
{ "content": { "ForecastCategory":"Strech"}, "pageInstructions": [ { "instruction": "APPEND", "target": ".myPageList", "listIndex": "3", "listMoveToIndex": "5", "content": {} } ] }
Search opportunity
Implementation notes - Searches the opportunity work object provided with the required parameters.
URL - GET https://[hostname:port]/prweb/api/v1/data/[ID]
.
Request parameter - ID – D_Search[SearchParam,ClassName] data page with parameters passed to fetch the opportunity.
Sample URL - GET/https:[hostname:port]/prweb/api/v1/data/ D_crmOpportunitiesList? OppFilter=Amazon&ClassName=PegaCRM-Work-SFA-Opportunity.
Sample response - header
{ date:Tue, 30 Apr 2019 11:09:57 GMT content-type:application/json;charset=UTF-8 content-length:95096 connection:keep-alive set-cookie:AWSALB=pMRTRQRcrk1jP3Y9nPhrWMOsHu3dOoJjjdv2NbWxCtsgBFAkWHpTXhGC2n6lF03y29OcBUpi40Z3jTPToz1nT9ZLA+clV6ERfDDpuAynlNpa51rXptUsGfGYaCBY; Expires=Tue, 07 May 2019 11:09:56 GMT; Path=/; JSESSIONID=E440177F7424714DC9FF44A9355B427E; Path=/prweb; Secure; HttpOnly cache-control:no-cache server:server }
Sample response - body
{ "pxMore": "false", "pxObjClass": "Code-Pega-List", "pxPageCount": "0", "pxQueryTimeStamp": "2019-04-30T11:09:57.191Z", "pxResultCount": "1", "pxSQLStatementPost": "SELECT "PC0"."name" AS "Name" , "Acc"."name" AS "Name" , "PC0"."opportunitystage" AS "OpportunityStage" , "Oper"."pyusername" AS "pyUserName" , "PC0"."opportunityamount" AS "OpportunityAmount" , "PC0"."closedate" AS "CloseDate" , "PC0"."opportunitymustwin" AS "OpportunityMustWin" , "BT"."name" AS "Name" , "PC0"."opportunitysource" AS "OpportunitySource" , "Org"."name" AS "Name" , "PC0"."pzinskey" AS "pzInsKey" , "PC0"."accountid" AS "AccountID" , "PC0"."territoryid" AS "TerritoryID" , "PC0"."campaigndescription" AS "CampaignDescription" , "PC0"."campaignid" AS "CampaignID" , "PC0"."pyowneruserid" AS "pyOwnerUserID" , "PC0"."pyid" AS "pyID" , "PC0"."pxobjclass" AS "pxObjClass" , "Partner"."name" AS "Name" , "PC0"."winprobability" AS "WinProbability" FROM pegadata.crm_work_opportunity "PC0" LEFT OUTER JOIN pegadata.crm_entity_account "Acc" ON ( ( "PC0"."accountid" = "Acc"."pzinskey" ) AND ( ( "Acc"."pxobjclass" IN (? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.crm_entity_org "Org" ON ( ( "Acc"."organizationid" = "Org"."pzinskey" ) AND "Acc"."pxobjclass" LIKE ? AND ( ( "Org"."pxobjclass" IN (? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.pr_operators "Oper" ON ( ( "Oper"."pyuseridentifier" = "PC0"."pyowneruserid" ) AND ( ( "Oper"."pxobjclass" IN (? , ? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY "BT" ON ( ( "PC0"."territoryid" = "BT"."territoryid" ) AND ( ( "BT"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.crm_entity_partner "Partner" ON ( ( "Partner"."pzinskey" = "Oper"."organizationid" ) AND "Oper"."pxobjclass" = ? AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) AND ( ( "Partner"."pxobjclass" = ? ) ) ) WHERE ( ( "PC0"."pystatuswork" IN (? , ? ) AND ( UPPER("PC0"."name") LIKE ? OR UPPER("Acc"."name") LIKE ? OR UPPER("Oper"."pyusername") LIKE ? OR "PC0"."pyid" = ? ) ) AND ( ( 'true' = ? AND ( "PC0"."ispartnersourced" = ? OR "PC0"."partnerid" IS NOT NULL ) ) OR 'true' <> ? ) ) ORDER BY 6 ASC", "pxSQLStatementPre": "SELECT "PC0"."name" AS "Name" , "Acc"."name" AS "Name" , "PC0"."opportunitystage" AS "OpportunityStage" , "Oper"."pyusername" AS "pyUserName" , "PC0"."opportunityamount" AS "OpportunityAmount" , "PC0"."closedate" AS "CloseDate" , "PC0"."opportunitymustwin" AS "OpportunityMustWin" , "BT"."name" AS "Name" , "PC0"."opportunitysource" AS "OpportunitySource" , "Org"."name" AS "Name" , "PC0"."pzinskey" AS "pzInsKey" , "PC0"."accountid" AS "AccountID" , "PC0"."territoryid" AS "TerritoryID" , "PC0"."campaigndescription" AS "CampaignDescription" , "PC0"."campaignid" AS "CampaignID" , "PC0"."pyowneruserid" AS "pyOwnerUserID" , "PC0"."pyid" AS "pyID" , "PC0"."pxobjclass" AS "pxObjClass" , "Partner"."name" AS "Name" , "PC0"."winprobability" AS "WinProbability" FROM pegadata.crm_work_opportunity "PC0" LEFT OUTER JOIN pegadata.crm_entity_account "Acc" ON ( ( "PC0"."accountid" = "Acc"."pzinskey" ) AND ( ( "Acc"."pxobjclass" IN (? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.crm_entity_org "Org" ON ( ( "Acc"."organizationid" = "Org"."pzinskey" ) AND "Acc"."pxobjclass" LIKE ? AND ( ( "Org"."pxobjclass" IN (? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.pr_operators "Oper" ON ( ( "Oper"."pyuseridentifier" = "PC0"."pyowneruserid" ) AND ( ( "Oper"."pxobjclass" IN (? , ? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY "BT" ON ( ( "PC0"."territoryid" = "BT"."territoryid" ) AND ( ( "BT"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.crm_entity_partner "Partner" ON ( ( "Partner"."pzinskey" = "Oper"."organizationid" ) AND "Oper"."pxobjclass" = ? AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) AND ( ( "Partner"."pxobjclass" = ? ) ) ) WHERE ( ( "PC0"."pystatuswork" IN (? , ? ) AND ( UPPER("PC0"."name") LIKE ? OR UPPER("Acc"."name") LIKE ? OR UPPER("Oper"."pyusername") LIKE ? OR "PC0"."pyid" = ? ) ) AND ( ( 'true' = ? AND ( "PC0"."ispartnersourced" = ? OR "PC0"."partnerid" IS NOT NULL ) ) OR 'true' <> ? ) ) ORDER BY 6 ASC", "pxTotalResultCount": "0", "pyForceDBName": "", "pyForceUseStandardDB": "false", "pyMaxRecords": "0", "pyObjClass": "PegaCRM-Work-SFA-Opportunity", "pyQueryTimeoutInterval": "0", "pyRowCount": "0", "pyStartIndex": "0", "pyUseReportsDatabase": "false", "pzLoadTime": "April 30, 2019 11:09:57 AM UTC", "pzPageNameHash": "_pa425317473821051pz", "pxResults":[ { "AccountID": "PEGACRM-ENTITY-ACCOUNT ACC-107", "CloseDate": "2019-04-18T04:00:00.000Z", "Name": "Ralph Lauren LLC", "OpportunityAmount": "90000", "OpportunityMustWin": "false", "OpportunityStage": "Qualification", "pxObjClass": "PegaCRM-Work-SFA-Opportunity", "pyID": "Opp-107", "pyOwnerUserID": "[email protected]", "pzInsKey": "PEGACRM-WORK-SFA-OPPORTUNITY OPP-107", "TerritoryID": "BT10", "WinProbability": "10", "pxPages": { "Acc": { "Name": "G J R Minigs", "pxObjClass": "PegaCRM-Entity-Account" }, "BT": { "Name": "India", "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory" }, "Oper": { "pxObjClass": "Data-Admin-Operator-ID", "pyUserName": "Omarp" }, "Org": { "Name": "G J R Minigs", "pxObjClass": "PegaCRM-Entity-Org" }, "Partner": { "pxObjClass": "PegaCRM-Entity-Org-Partner" } } } ]}
Leads API
Get leads
Implementation notes - Gets the details of a lead given its ID.
URL - GET https://[hostname:port]/prweb/api/v1/cases/ID
.
Request parameter - ID - pzInsKey of the lead to be fetched.
Sample response - header
{ "date": "Tue, 23 Apr 2019 12:21:24 GMT", "content-encoding": "gzip", "etag": "\"20190205T073053.144 GMT\"", "vary": "Accept-Encoding", "content-type": "application/json;charset=UTF-8", "cache-control": "no-cache", "connection": "Keep-Alive", "content-length": "9414" }
Sample response - body
{ "caseTypeID": "UPlus-SAPlus-Work-Lead", "createdBy": "SASalesOps.SAPlus", "createTime": "2019-01-30T11:32:23.920Z", "description": "Offer a variety of value-added products and services through technology partnerships. Our partners include GDCM, Avocent, Unite Technologies", "ID": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3", "lastUpdatedBy": "System", "lastUpdateTime": "2019-02-05T07:30:53.144Z", "name": "Annabelle Boord", "pxObjClass": "Pega-API-CaseManagement-Case", "status": "Pending-Submission", "urgency": "10", "content": { "AccountID": "UPLUS-SAPLUS-WORK-ACCOUNT ACC-3", "ChangeReason": "Assigning a partner to follow-up with the lead", "ContactID": "UPLUS-SAPLUS-WORK-CONTACT SAMPLECON-3", "crmAddress": " 13 Gunnison St\nPlano\nTX\n75075\nUSA", "crmsample": "true", "crmSearchOrg": "Org not found", "crmSearchOwner": "Jani Biddy", "crmSearchRelatedAccount": "Account not found", "crmTerritorySearch": "North East", "CSLeadNameforBU": "Offer a variety of value-added products and services through technology partnerships. Our partners include GDCM, Avocent, Unite Technologies for Annabelle Boord", "DefaultRoutingText": "Automatic routing", "EmployeeCount": "500890", "FirstName": "Annabelle", "googleMapLink": "http://maps.google.com/maps?q=13 Gunnison St,Plano,TX,USA,United States,75075&", "Industry": "Retail Trade", "IsAutomaticRouting": "false", "IsPartnerSourced": "true", "LastName": "Boord", "LeadCompanyName": "APW Technologies Corp", "LeadEmail": "[email protected]", "LeadMobile": "872-558-1665", "LeadPhone": "972-961-4968", "LeadRating": "1-Hot", "LeadRevenue": "2345", "LeadsContactOutEmailCount": "3", "LeadSource": "Direct Mail", "LeadStage": "Marketing Qualified", "LeadStageOld": "Assigned", "MapAddressForDisplay": "Plano, TX, USA", "Name": "Annabelle Boord", "OldOwnerID": "tmason", "OldTerritoryID": "SampleBT2", "OldWebsite": "www.apwtech.com", "OrganizationID": "UPLUS-SAPLUS-WORK-ORG SAMPLEORG-3", "OrgInitEmpty": "false", "OrgSubscribeCount": "6", "PartnerID": "UPLUS-SAPLUS-WORK-ORG-PARTNER PRN-20013", "pxApplication": "SAPlus", "pxApplicationVersion": "01.01.01", "pxCommitDateTime": "2019-02-05T07:30:53.160Z", "pxCoveredCount": "0", "pxCoveredCountOpen": "0", "pxCoveredCountUnsatisfied": "0", "pxCreateDateTime": "2019-01-30T11:32:23.920Z", "pxCreateOperator": "SASalesOps.SAPlus", "pxCreateOpName": "SASalesOps.SAPlus", "pxCreateSystemID": "pega", "pxGeolocationAddress": " 13 Gunnison St,Plano,TX,75075,USA", "pxInsName": "SAMPLELEAD-3", "pxLatitude": "33.0778989", "pxLatLong": "33.0778989 , -96.7260530", "pxLockHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3", "pxLongitude": "-96.7260530", "pxMoveImportDateTime": "2019-02-04T08:28:32.852Z", "pxMoveImportOperId": "sfasysadmin", "pxMoveImportOperName": "Administrator", "pxObjClass": "UPlus-SAPlus-Work-Lead", "pxSaveDateTime": "2019-02-05T07:30:53.144Z", "pxUpdateCounter": "97", "pxUpdateDateTime": "2019-01-25T11:13:04.692Z", "pxUpdateOperator": "System", "pxUpdateOpName": "Agent(System-Queue-ServiceLevel.ProcessEvent)", "pxUpdateSystemID": "pega", "pxUrgencyPartyTotal": "0", "pxUrgencyWork": "10", "pxUrgencyWorkClass": "10", "pyAgeFromDate": "2017-10-17T13:04:04.189Z", "pyConfirmationNote": "Assigned to manager to fix correspondence problem", "pyDescription": "Offer a variety of value-added products and services through technology partnerships. Our partners include GDCM, Avocent, Unite Technologies", "pyElapsedCustomerUnsatisfied": "0.0", "pyElapsedStatusNew": "1.0", "pyElapsedStatusOpen": "40165805", "pyElapsedStatusPending": "0", "pyFlowName": "crmEdit", "pyHasAttachments": "true", "pyID": "SampleLEAD-3", "pyLabel": "Annabelle Boord", "pyLabelOld": "Annabelle Boord", "pyNextEmailThreadID": "1", "pyNotifyQuickStream": "QuestionAboutItem", "pyOrigDivision": "SMB", "pyOrigOrg": "UPlus", "pyOrigOrgUnit": "Sales", "pyOrigUserDivision": "SMB", "pyOrigUserID": "SASalesOps.SAPlus", "pyOrigUserWorkgroup": "default@UPlus", "pyOwnerDivision": "SMB", "pyOwnerOrg": "UPlus", "pyOwnerOrgUnit": "Sales", "pyOwnerUserID": "jbiddy", "pyPushNotificationsEnabled": "false", "pySatisfactionChangeTimestamp": "2017-10-17T13:04:15.088Z", "pySelectAll": "true", "pyStatusCustomerSat": "New", "pyStatusWork": "Pending-Submission", "pyStatusWorkOld": "Pending-Submission", "pyStatusWorkTimestamp": "2019-01-25T10:14:21.342Z", "pyUserName": "Jani Biddy", "pyWorkIDPrefix": "Lead-", "pzIndexCount": "4", "pzInsKey": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3", "SellingMode": "B2B" "ShowCancelButton": "true", "StageLastChanged": "2019-01-25T10:14:21.340Z", "TerritoryID": "SampleBT2", "TerritoryName": "North East", "Website": "www.apwtech.com", "WorkType": "Lead", "Address": { "pxObjClass": "Data-Address-Postal", "pyCity": "Plano", "pyCountry": "USA", "pyPostalCode": "75075", "pyState": "TX", "pyStreet": "13 Gunnison St", "pzIndexOwnerKey": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3", "pzIndexes": { "Index_Address": "3" } }, "DealDetails": { "pxObjClass": "PegaCRM-Embed-SFA-Deal" }, "LeadScore": { "PredictionType": "Adaptive", "pxDecisionReference": "SampleLEAD-3 -6185449242499482350", "pxDecisionTime": "2017-10-25T13:57:43.584Z", "pxIdentifier": "/Lead Ranking/Lead Ranking/", "pxInteractionID": "-6185449242499482350", "pxObjClass": "SA-SR", "pxRank": "1", "pyApplication": "SAPlus", "pyApplicationVersion": "01.01.01", "pyComponent": "LeadRanking", "pyDivision": "SMB", "pyGroup": "Lead Ranking", "pyIssue": "Lead Ranking", "pyOperator": "tmason", "pyOrganization": "UPlus", "pyPreviousComponent": "LeadRanking", "pyPropensity": "0.9074074074074074", "pyStrategy": "EvaluateLeadRanking", "pySubjectID": "SampleLEAD-3", "pyTempInteger": "91", "pyUnit": "Sales", "pzIsReusable": "false" }, "NewTerritory": { "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory" }, "pxCorrSummary": [ { "pxCorrHandle": "DATA-CORR-EMAIL UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!20171017T130415.060 GMT", "pxCorrName": "crmLeadCreated", "pxCorrType": "Email", "pxObjClass": "Embed-CorrSummary" } ], "pxFlow": { "ConvertLead": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CONVERTLEAD", "pxAssignStatus": "Open-Active", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CONVERTLEAD #20171023T000044.838 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "SASysAdmin.SAPlus", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "ConvertLead", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171025T085427.879 GMT", "pyCategory": "FlowStandard", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "ConvertLead", "pyFlowTypeLabel": "ConvertLead", "pyLastFlowStep": "ASSIGNMENT63", "pyLastFlowStepLabel": "Display lead conversion screen", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "ConvertLead", "flowType": "ConvertLead", "HarnessPurpose": "Review", "pyActivity": "Work-.StartNewFlow", "pyStatus": "success", "pzHarnessID": "HID2807D2219332C9A75DE1D373469D184D", "pzPrimaryPageName": "pyWorkPage", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "ASSIGNMENT63", “pyStepLabel": "Display lead conversion screen", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171018T103545.416 GMT", "pxAssignGoalTime": "20171018T093545.415 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20170904T071854.101 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "tmason", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171018T083545.413 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzFromFrame": "pyWorkPage", "pzHarnessID": "HID844796460D63141B1D47FC2D3F808FDF", "pzPrimaryPageName": "pyWorkPage", "pzTransactionId": "dd1fcac53032fc6dc2cba325db7c4a39", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit_1": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171020T133057.893 GMT", "pxAssignGoalTime": "20171020T123057.892 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT_1", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20170904T071854.101 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "tmason", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit_1", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171020T113057.887 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit_1", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzFromFrame": "pyWorkPage", "pzHarnessID": "HIDC4CA111C327FB82D278BC9F9DE081BCE", "pzPrimaryPageName": "pyWorkPage", "pzTransactionId": "605ad068a5932305f8c5143e8ec65795", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit_2": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171020T135713.768 GMT", "pxAssignGoalTime": "20171020T125713.768 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT_2", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20170904T071854.101 GMT", "pxIsInvestigative": "false", "pxLastActivityStatus": "crmEdit", "pxLastUpdateBy": "tmason", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit_2", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171020T115713.765 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit_2", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzFromFrame": "pyWorkPage", "pzHarnessID": "HIDCF8D21FC282CAF7A0F7D879FAA90AE17", "pzPrimaryPageName": "pyWorkPage", "pzTransactionId": "0bb2aed4592d8ea36d3c5dc9398c3720", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit_3": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171020T135946.915 GMT", "pxAssignGoalTime": "20171020T125946.914 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT_3", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20170904T071854.101 GMT", "pxIsInvestigative": "false", "pxLastActivityStatus": "crmEdit", "pxLastUpdateBy": "tmason", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit_3", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171020T115946.912 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit_3", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzFromFrame": "pyWorkPage", "pzHarnessID": "HID17056BEA40A3A29185EEC0B248378D85", "pzPrimaryPageName": "pyWorkPage", "pzTransactionId": "26860ce3223d3130338db7bfb0d1b407", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit_4": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171020T140740.358 GMT", "pxAssignGoalTime": "20171020T130740.358 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT_4", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20170904T071854.101 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "tmason", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit_4", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171020T120740.355 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit_4", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzFromFrame": "pyWorkPage", "pzHarnessID": "HIDED83F974DE585B2A09F1A2C3C8762452", "pzPrimaryPageName": "pyWorkPage", "pzTransactionId": "aa57d73f2f9668583bf1b51647dcd311", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit_5": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171024T144901.688 GMT", "pxAssignGoalTime": "20171024T134901.688 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT_5", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20171023T000047.452 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "SASysAdmin.SAPlus", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit_5", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171024T124901.683 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit_5", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzFromFrame": "pyWorkPage", "pzHarnessID": "HIDF3579D47388E2755E18E010CAC4E85D8", "pzPrimaryPageName": "pyWorkPage", "pzTransactionId": "2a08096e178d8912d2557a7ef718d118", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit_6": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171024T145209.590 GMT", "pxAssignGoalTime": "20171024T135209.590 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT_6", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20171023T000047.452 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "SASysAdmin.SAPlus", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit_6", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171024T125209.589 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit_6", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzHarnessID": "HID959C2F349115EF959B71EA264259CD67", "pzPrimaryPageName": "pyWorkPage" "pzTransactionId": "7c0513a5c4b52986021b1a660ac3fe69", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit_7": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171024T150420.828 GMT", "pxAssignGoalTime": "20171024T140420.827 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT_7", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20171023T000047.452 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "tmason", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit_7", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171024T130420.826 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit_7", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzFromFrame": "pyWorkPage", "pzHarnessID": "HID1F98B5F37CC52320FF7DC3AC652CE116", "pzPrimaryPageName": "pyWorkPage", "pzTransactionId": "d7b47b63ef2baa4d7a9336026f87cb52", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "crmEdit_8": { "pxAssignActivity": "WorkBasket", "pxAssignClass": "Assign-WorkBasket", "pxAssignDeadTime": "20171025T084247.044 GMT", "pxAssignGoalTime": "20171025T074247.044 GMT", "pxAssignmentKey": "ASSIGN-WORKBASKET UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!CRMEDIT_8", "pxAssignStatus": "Open-Active", "pxAssignSvcLevel": "crmClearDefaultWB", "pxFlowInsKey": "RULE-OBJ-FLOW PEGACRM-WORK-SFA-LEAD CRMEDIT #20171023T000047.452 GMT", "pxIsInvestigative": "false", "pxLastUpdateBy": "SASysAdmin.SAPlus", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@UPlus", "pxSubscript": "crmEdit_8", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171025T064247.039 GMT", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "crmEdit", "pyFlowTypeLabel": "Edit", "pyInstructions": "Edit Lead", "pyLastFlowStep": "Assignment1", "pyLastFlowStepLabel": "Edit", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@UPlus", "coverPage": "pyWorkCover", "DisplayLockInfo": "true", "flowClass": "UPlus-SAPlus-Work-Lead", "flowName": "crmEdit_8", "flowType": "crmEdit", "HarnessPurpose": "Review", "pxObjClass": "@baseclass", "pyActivity": "Work-.StartNewFlow", "pyManualSupportingFlow": "true", "pyStatus": "success", "pzFromFrame": "pyWorkPage", "pzHarnessID": "HID4C413031D74E7B780C955AD425B6C185", "pzPrimaryPageName": "pyWorkPage", "pzTransactionId": "16daca2807920c34080cf879be11645a", "ReferencePageName": "pyWorkPage", "SuccessIndicator": "0", "workHandle": "UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "true", "pyFAProcessOnJump": "false", "pyFlowStep": "Assignment1", "pyStepLabel": "Edit", "pyStepType": "ASSIGNMENT" } ] }, "FixCorrespondence": { "pxAssignActivity": "WorkList", "pxAssignClass": "Assign-Worklist", "pxAssignmentKey": "ASSIGN-WORKLIST UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!FIXCORRESPONDENCE", "pxAssignStatus": "Open-Active", "pxFlowInsKey": "RULE-OBJ-FLOW WORK- FIXCORRESPONDENCE #20191124T094252.831 GMT", "pxIsInvestigative": "true", "pxLastUpdateBy": "System", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "SFASysAdmin", "pxRouteToUserName": "SFA Administrator", "pxSubscript": "FixCorrespondence", "pxSystemFlow": "false", "pxTimeFlowStarted": "20171017T130800.769 GMT", "pyCategory": "ProcessFlow", "pyConfirmationNote": "Assigned to manager to fix correspondence problem", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "FixCorrespondence", "pyFlowTypeLabel": "Fix and send correspondences", "pyInstructions": "Fix Correspondence", "pyLastFlowStep": "ASSIGNMENT6", "pyLastFlowStepLabel": "FixCorrespondence", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "SFASysAdmin", "CorrHandle": "DATA-CORR-EMAIL UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!20171017T130415.060 GMT", "CorrList": "crmLeadCreated", "CorrPartyRole": "Owner", "CorrProblem": "** Caught com.sun.mail.util.MailConnectException: Couldn't connect to host, port: sample.com, 25; timeout 60000", "ErrorMessage": "** Caught com.sun.mail.util.MailConnectException: Couldn't connect to host, port: sample.com, 25; timeout 60000", "flowName": "FixCorrespondence", "pyTempPlaceHolder": "TempPlaceHolder", "ReferencePageName": "pyWorkPage" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "false", "pyFAProcessOnJump": "false", "pyFlowStep": "ASSIGNMENT6", "pyStepLabel": "FixCorrespondence", "pyStepType": "ASSIGNMENT" } ] }, "pzInternalCaseFlow": { "pxAssignActivity": "pzCreateInternalAssignment", "pxAssignClass": "Assign-Internal", "pxAssignIsVirtual": "true", "pxAssignmentKey": "ASSIGN-INTERNAL UPLUS-SAPLUS-WORK-LEAD SAMPLELEAD-3!PZINTERNALCASEFLOW", "pxFlowInsKey": "RULE-OBJ-FLOW WORK- PZINTERNALCASEFLOW #20191105T160214.591 GMT", "pxIsInvestigative": "false", "pxLastActivityStatus": "true", "pxLastUpdateBy": "SASalesOps.SAPlus", "pxObjClass": "Embed-PegaEPRO-FlowPage", "pxRouteTo": "default@uplus", "pxSubscript": "pzInternalCaseFlow", "pxSystemFlow": "true", "pxTimeFlowStarted": "20171017T130415.045 GMT", "pyCategory": "FlowStandard", "pyDeferCommit": "false", "pyDeferErrors": "false", "pyDraftMode": "false", "pyFirstRun": "false", "pyFlowCalledCount": "1", "pyFlowInterestPageClass": "UPlus-SAPlus-Work-Lead", "pyFlowType": "pzInternalCaseFlow", "pyFlowTypeLabel": "Internal flow", "pyLastFlowStep": "ASSIGNMENT63", "pyLastFlowStepLabel": "Perform action", "pyContexts": {}, "pyFlowParameters": { "AssignTo": "default@uplus", "flowName": "pzInternalCaseFlow", "isNewCase": "true", "ReferencePageName": "tempWorkPage" }, "pyFlowPath": [ { "pxObjClass": "Embed-PegaEPRO-FlowPath", "pyDisplay": "false", "pyFAProcessOnJump": "false", "pyFlowStep": "ASSIGNMENT63", "pyStepLabel": "Perform action", "pyStepType": "ASSIGNMENT" } ] } }, "pxSystemUpdateDetailsList": [], "pyAttachmentCategories": [], "pyWorkParty": {} } }
Create leads
Implementation notes - Creates a new lead work object provided with the required parameters.
URL - POST https://[hostname:port]/prweb/api/v1/cases
.
Request parameter
Parameter | Description |
---|---|
LastName | LastName of the lead to be created. |
TerritoryID | Identifier of the territory where the current lead is included. |
Industry | Name of the industry in which the lead is present. |
LeadCompanyName | Company name in which the lead is present. |
LeadStage | Stage of the lead. |
Sample request
{ "caseTypeID": "PegaCRM-Work-SFA-Lead", "processID": "pyStartCase", "parentCaseID": "", "content": {"LastName":"Test API", "Industry":"Construction", "LeadCompanyName":"Maruti", "TerritoryID":"BT1", "LeadStage":"Assigned" }
Sample response - header
{ "status": "201", "date": "Tue, 30 Apr 2019 11:37:54 GMT", "server": "server", "etag": "\"20190430T113754.838 GMT\"", "content-length": "203", "location": "https://crmdev83.pegacloud.net/prweb/api/v1/cases/PEGACRM-WORK-SFA-LEAD+LEAD-1057", "content-type": "application/json;charset=UTF-8" }
Sample response - body
{ "ID":"PEGACRM-WORK-SFA-LEAD LEAD-1057", "nextAssignmentID":”ASSIGN-WORKLIST PEGACRM-WORK-SFA-LEAD LEAD-1057!PZINTERNALACTIONSTUB", "nextPageID":"Perform", "pxObjClass": "Pega-API-CaseManagement-Case" }
Update leads
Implementation notes - Performs an action given a lead ID and an optional content in the request body.
URL - PUT https://sfa-dev.pega.com:443/prweb/api/v1/cases/[ID]
.
Request parameter
Parameter | Description |
---|---|
ID | pzInsKey of the contact to be updated. |
If-Match | etag from Get or Create contact. |
ActionID | Related to crmEdit. |
Sample request - body
{ "content": {"Name":"Modified123456"}, "pageInstructions": [ { "instruction": "APPEND", "target": ".myPageList", "listIndex": "3", "listMoveToIndex": "5", "content": {} } ] }
Search leads
Implementation notes - Searches the lead work object provided with the required parameters.
URL - GET https://[hostname:port]/prweb/api/v1/data/[ID]
.
Request parameter - ID – D_Search[SearchParam,ClassName] data page with parameters passed to fetch the lead.
Sample URL - GET/https:[hostname:port]/prweb/api/v1/data/ D_crmLeadsList? LeadFilter=Laura&ClassName=PegaCRM-Work-SFA-Lead.
Sample response - header
{ date:Tue, 30 Apr 2019 11:13:55 GMT content-type:application/json;charset=UTF-8 content-length:103835connection:keep-alive set-cookie:AWSALB=xtOgwMHMzcwLdX3RwX1gxOqIdPcuWf+UlZ6ebHUS1CkodWWIiVP01n3HPSfbOCVtNDMybR5/5pq7YYyRfNfoQid0/9cBbj7r8rI6KNWE8b+/5R1/71Hb+XPjkClS; Expires=Tue, 07 May 2019 11:13:55 GMT; Path=/; JSESSIONID=588AB013994A510151CE270DEA6BFB4B; Path=/prweb; Secure; HttpOnly cache-control:no-cache server:server }
Sample response - body
{ "pxMore": "false", "pxObjClass": "Code-Pega-List", "pxPageCount": "0", "pxQueryTimeStamp": "2019-04-30T11:13:55.611Z", "pxResultCount": "2", "pxSQLStatementPost": "SELECT "PC0"."name" AS "Name" , "PC0"."leadcompanyname" AS "LeadCompanyName" , "PC0"."leadstage" AS "LeadStage" , "PC0"."pxcreatedatetime" AS "pxCreateDateTime" , "Operator"."pyusername" AS "pyUserName" , "BT"."name" AS "Name" , "PC0"."leadsource" AS "LeadSource" , "PC0"."campaigndescription" AS "CampaignDescription" , "PC0"."leademail" AS "LeadEmail" , "PC0"."leadphone" AS "LeadPhone" , "PC0"."firstname" AS "FirstName" , "PC0"."lastname" AS "LastName" , "PC0"."pyowneruserid" AS "pyOwnerUserID" , "PC0"."territoryid" AS "TerritoryID" , "PC0"."campaignid" AS "CampaignID" , "PC0"."pyid" AS "pyID" , "PC0"."pzinskey" AS "pzInsKey" , "PC0"."sellingmode" AS "SellingMode" , "LastActDate"."srcol2" AS "pySummaryDateTime(1)" , "LeadPredictor"."crmpropensity" AS "crmPropensity" , "Partner"."name" AS "Name" , "PC0"."ispartnersourced" AS "IsPartnerSourced" , "PC0"."pystatuswork" AS "pyStatusWork" , "PC0"."routedworkqueuename" AS "RoutedWorkQueueName" FROM pegadata.crm_work_lead "PC0" LEFT OUTER JOIN pegadata.pr_operators "Operator" ON ( ( "Operator"."pyuseridentifier" = "PC0"."pyowneruserid" ) AND ( ( "Operator"."pxobjclass" IN (? , ? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY "BT" ON ( ( "PC0"."territoryid" = "BT"."territoryid" ) AND ( ( "BT"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.lead_ranking_predictors_history "LeadPredictor" ON ( ( "PC0"."pzinskey" = "LeadPredictor"."lead_id" ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.crm_entity_partner "Partner" ON ( ( "Partner"."pzinskey" = "Operator"."organizationid" ) AND "Operator"."pxobjclass" = ? AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) AND ( ( "Partner"."pxobjclass" = ? ) ) ) LEFT OUTER JOIN ( SELECT "LastActDate"."relatedto" AS "srcol1" , MAX("LastActDate"."completeddate") AS "srcol2" FROM pegadata.crm_work_task "LastActDate" WHERE ( UPPER("LastActDate"."listrelatedto") = ? AND "LastActDate"."pxobjclass" = ? ) GROUP BY "LastActDate"."relatedto" ) "LastActDate" ON ( ( "LastActDate"."srcol1" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) WHERE ( ( "PC0"."pystatuswork" IN (? , ? , ? , ? ) AND ( UPPER("PC0"."leadcompanyname") LIKE ? OR UPPER("PC0"."pyowneruserid") LIKE ? OR UPPER("Operator"."pyusername") LIKE ? OR UPPER("PC0"."name") LIKE ? OR "PC0"."pyid" = ? ) AND "PC0"."leadstage" NOT LIKE ? ) AND ( ( 'true' = ? AND ( "PC0"."ispartnersourced" = ? OR "PC0"."partnerid" IS NOT NULL ) ) OR 'true' <> ? ) ) ORDER BY 22 ASC, 23 ASC, 1 ASC", "pxSQLStatementPre": "SELECT "PC0"."name" AS "Name" , "PC0"."leadcompanyname" AS "LeadCompanyName" , "PC0"."leadstage" AS "LeadStage" , "PC0"."pxcreatedatetime" AS "pxCreateDateTime" , "Operator"."pyusername" AS "pyUserName" , "BT"."name" AS "Name" , "PC0"."leadsource" AS "LeadSource" , "PC0"."campaigndescription" AS "CampaignDescription" , "PC0"."leademail" AS "LeadEmail" , "PC0"."leadphone" AS "LeadPhone" , "PC0"."firstname" AS "FirstName" , "PC0"."lastname" AS "LastName" , "PC0"."pyowneruserid" AS "pyOwnerUserID" , "PC0"."territoryid" AS "TerritoryID" , "PC0"."campaignid" AS "CampaignID" , "PC0"."pyid" AS "pyID" , "PC0"."pzinskey" AS "pzInsKey" , "PC0"."sellingmode" AS "SellingMode" , "LastActDate"."srcol2" AS "pySummaryDateTime(1)" , "LeadPredictor"."crmpropensity" AS "crmPropensity" , "Partner"."name" AS "Name" , "PC0"."ispartnersourced" AS "IsPartnerSourced" , "PC0"."pystatuswork" AS "pyStatusWork" , "PC0"."routedworkqueuename" AS "RoutedWorkQueueName" FROM pegadata.crm_work_lead "PC0" LEFT OUTER JOIN pegadata.pr_operators "Operator" ON ( ( "Operator"."pyuseridentifier" = "PC0"."pyowneruserid" ) AND ( ( "Operator"."pxobjclass" IN (? , ? , ? ) ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) INNER JOIN pegadata.CRM_DATA_BUSINESSTERRITORY "BT" ON ( ( "PC0"."territoryid" = "BT"."territoryid" ) AND ( ( "BT"."pxobjclass" = ? ) ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.lead_ranking_predictors_history "LeadPredictor" ON ( ( "PC0"."pzinskey" = "LeadPredictor"."lead_id" ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) LEFT OUTER JOIN pegadata.crm_entity_partner "Partner" ON ( ( "Partner"."pzinskey" = "Operator"."organizationid" ) AND "Operator"."pxobjclass" = ? AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) AND ( ( "Partner"."pxobjclass" = ? ) ) ) LEFT OUTER JOIN ( SELECT "LastActDate"."relatedto" AS "srcol1" , MAX("LastActDate"."completeddate") AS "srcol2" FROM pegadata.crm_work_task "LastActDate" WHERE ( UPPER("LastActDate"."listrelatedto") = ? AND "LastActDate"."pxobjclass" = ? ) GROUP BY "LastActDate"."relatedto" ) "LastActDate" ON ( ( "LastActDate"."srcol1" = "PC0"."pzinskey" ) AND ( ( "PC0"."pxobjclass" IN (? , ? ) ) ) ) WHERE ( ( "PC0"."pystatuswork" IN (? , ? , ? , ? ) AND ( UPPER("PC0"."leadcompanyname") LIKE ? OR UPPER("PC0"."pyowneruserid") LIKE ? OR UPPER("Operator"."pyusername") LIKE ? OR UPPER("PC0"."name") LIKE ? OR "PC0"."pyid" = ? ) AND "PC0"."leadstage" NOT LIKE ? ) AND ( ( 'true' = ? AND ( "PC0"."ispartnersourced" = ? OR "PC0"."partnerid" IS NOT NULL ) ) OR 'true' <> ? ) ) ORDER BY 22 ASC, 23 ASC, 1 ASC", "pxTotalResultCount": "0", "pyForceDBName": "", "pyForceUseStandardDB": "false", "pyMaxRecords": "0", "pyObjClass": "PegaCRM-Work-SFA-Lead", "pyQueryTimeoutInterval": "0", "pyRowCount": "0", "pyStartIndex": "0", "pyUseReportsDatabase": "true", "pzLoadTime": "April 30, 2019 11:13:55 AM UTC", "pzPageNameHash": "_pa425555882935075pz", "pxResults"[ { "DaysInactive": "20", "FirstName": "Arya", "LastName": "Stark", "LeadCompanyName": "GOT", "LeadEmail": "[email protected]", "LeadPhone": "8985541376", "LeadRank": "59", "LeadStage": "Assigned", "Name": "Arya Stark", "pxCreateDateTime": "2019-04-09T13:14:41.070Z", "pxObjClass": "PegaCRM-Work-SFA-Lead", "pyID": "Lead-5", "pyOwnerUserID": "[email protected]", "pyStatusWork": "Open-Active", "pzInsKey": "PEGACRM-WORK-SFA-LEAD LEAD-5", "SellingMode": "B2B", "TerritoryID": "BT1", "pxPages": { "BT": { "Name": "Global", "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory" }, "LastActDate": { "pxObjClass": "PegaCRM-Work-Task-CustAct", "pySummaryDateTime":[ "1970-01-01T00:00:00.000Z" ], }, "LeadPredictor": { "crmPropensity": "0.591346154", "pxObjClass": "PegaCRM-Data-SFA-LeadPredictors" }, "Operator": { "pxObjClass": "Data-Admin-Operator-ID", "pyUserName": "Mohith Reddy" }, "Partner": { "pxObjClass": "PegaCRM-Entity-Org-Partner" } } }, { "DaysInactive": "1", "FirstName": "Arya", "LastName": "Stark", "LeadCompanyName": "GOT", "LeadEmail": "[email protected]", "LeadPhone": "8985541376", "LeadRank": "47", "LeadStage": "Assigned", "Name": "Arya Stark", "pxCreateDateTime": "2019-04-29T10:38:33.817Z", "pxObjClass": "PegaCRM-Work-SFA-Lead", "pyID": "Lead-57", "pyOwnerUserID": "[email protected]", "pyStatusWork": "Open-Active", "pzInsKey": "PEGACRM-WORK-SFA-LEAD LEAD-57", "SellingMode": "B2B", "TerritoryID": "BT10", "pxPages": { "BT": { "Name": "India", "pxObjClass": "PegaCRM-Data-SFA-BusinessTerritory" }, "LastActDate": { "pxObjClass": "PegaCRM-Work-Task-CustAct", "pySummaryDateTime":[ "1970-01-01T00:00:00.000Z" ], }, "LeadPredictor": { "crmPropensity": "0.472222222", "pxObjClass": "PegaCRM-Data-SFA-LeadPredictors" }, "Operator": { "pxObjClass": "Data-Admin-Operator-ID", "pyUserName": "Aditya" }, "Partner": { "pxObjClass": "PegaCRM-Entity-Org-Partner" } } } ] }
Codes
Success codes
HTTP status code | Description |
---|---|
200 | Success(OK) |
201 | Created |
204 | No content |
Error codes
HTTP status code | Description |
---|---|
400 | Bad request |
401 | Unauthorized |
403 | Forbidden |
404 | Not found |
412 | Precondition failed |
500 | Internal error |
Previous topic Pega Sales Automation Next topic Pega Sales Automation design patterns