// Job ID: #367905
using AG.A1.Scheduler.Project.Contracts.Contracts;
var commitLeadToSFCommandHandler = Activate<ICommitLeadToSFCommandHandler>();
await commitLeadToSFCommandHandler.Handle(
FromJson<CommitLeadToSFRequest>("{\"RavingFanId\":43147,\"LastName\":\"Papadopoulos\",\"FirstName\":\"George\",\"Title\":null,\"Company\":\"NYM Group of NY, Inc and related entities\",\"Street\":\"3555 Veterans Memorial Highway, Suite J\",\"City\":\"Ronkonkoma\",\"State\":\"NY\",\"PostalCode\":\"11779\",\"Country\":\"United States\",\"Phone\":\"6318815350\",\"Email\":\"george@nymgroup.com\",\"Website\":null,\"LeadSource\":\"Employee Referral\",\"Fiscal_Year_End__c\":null,\"Entity_Type__c\":null,\"Source_Email__c\":\"Gabriel.Lombardo@alliantgroup.com\",\"Source_Name__c\":\"Gabriel Lombardo\",\"CPA_Email__c\":\"rrubman@alloysinternational.com\",\"CPA_Firm__c\":\"Rost & Co Cpas PC\",\"CPA_Name__c\":\"Russ Rubman\",\"CPA_Phone__c\":\"631-342-0043\",\"Service_Lines_Interested_In__c\":\"Client Account Services\",\"Existing_Client_Project_Manager__c\":\"Gabriel Lombardo\",\"Primary_Service_Line__c\":\"Client Account Services\",\"ASL__c\":true,\"Mattersphere_Referral_ID__c\":\"43147\",\"Matter_Number__c\":null,\"PM_ID__c\":\"3101\",\"CR_ID__c\":null,\"Submitted_By_ID__c\":3101,\"Submitted_By_Title__c\":null,\"Sub_Team_ID__c\":null,\"Team_ID__c\":null,\"CPA_Contact_Title__c\":\"Owner\",\"Additional_Notes__c\":\"George Papadopolous is the CFO. Cell: (516) 965-9640. 5 entities. Their CPA is only involved in general advice and tax form preparation. George was thrilled with the quality of work and the service we provided down the stretch for ERC, and is more than happy to see if Client Account Services can provide some value and keep the partnership between our companies going. He is expecting to be reached out to.\",\"Referring_Client_Consent__c\":\"Yes\",\"Existing_Client_Project_Number__c\":\"331335.0001\",\"Referred_By_Company__c\":\"NYM Group of NY, Inc and related entities\",\"Referred_By_Contact__c\":\"George Papadopoulos\",\"Referred_By_Title__c\":null,\"Referred_By_Contact_Phone__c\":\"6318815350\",\"Referred_By_Contact_Email__c\":\"george@nymgroup.com\",\"Current_Service_Lines__c\":\"ERC\",\"Existing_Client_Team_Director__c\":\"Reid McLaughlin\"}"),
null,
null);
| CurrentCulture | |
| CurrentUICulture | |
An exception occurred during performance of the job.
Cannot deserialize the current JSON array (e.g. [1,2,3]) into type 'AG.Integrations.RESTClients.SalesforceREST.Models.Lead' because the type requires a JSON object (e.g. {"name":"value"}) to deserialize correctly. To fix this error either change the JSON to a JSON object (e.g. {"name":"value"}) or change the deserialized type to an array or a type that implements a collection interface (e.g. ICollection, IList) like List<T> that can be deserialized from a JSON array. JsonArrayAttribute can also be added to the type to force it to deserialize from a JSON array. Path '', line 1, position 1.
Newtonsoft.Json.JsonSerializationException: Cannot deserialize the current JSON array (e.g. [1,2,3]) into type 'AG.Integrations.RESTClients.SalesforceREST.Models.Lead' because the type requires a JSON object (e.g. {"name":"value"}) to deserialize correctly.
To fix this error either change the JSON to a JSON object (e.g. {"name":"value"}) or change the deserialized type to an array or a type that implements a collection interface (e.g. ICollection, IList) like List<T> that can be deserialized from a JSON array. JsonArrayAttribute can also be added to the type to force it to deserialize from a JSON array.
Path '', line 1, position 1.
at AG.A1.Framework.Rest.RESTClient.HandleResponse[T](RestResponse restResponse) in C:\agent\_work\1\s\A1Solution\src-framework\AG.A1.Framework\Rest\RESTClient.cs:line 354
at AG.A1.Framework.Rest.RESTClient.ExecutePOSTAsync[T](IRESTEndpoint apiEndpoint, IDictionary`2 headers, IDictionary`2 bodyParameters, IDictionary`2 urlParameters) in C:\agent\_work\1\s\A1Solution\src-framework\AG.A1.Framework\Rest\RESTClient.cs:line 251
at AG.Integrations.RESTClients.SalesforceREST.SalesforceApiClientController.CreateLead(IDictionary`2 param, SalesforceToken token) in C:\agent\_work\1\s\A1Solution\src-integrations\AG.Integrations.RESTClients\SalesforceREST\SalesforceApiClientController.cs:line 295
at AG.A1.Scheduler.Project.Application.Helpers.SalesforceHelper.CreateLead(Lead lead, Boolean bypassTokenValidation) in C:\agent\_work\1\s\A1Solution\src-schedulers\AG.A1.Scheduler.Project.Application\Helpers\SalesforceHelper.cs:line 125
at AG.A1.Scheduler.Project.Application.Features.RavingFanReferralToSF.Commands.CommitLeadToSFCommandHandler.Handle(CommitLeadToSFRequest request, CancellationToken cancellationToken, PerformContext performContext) in C:\agent\_work\1\s\A1Solution\src-schedulers\AG.A1.Scheduler.Project.Application\Features\LeadToSF\Commands\CommitLeadToSFCommandHandler.cs:line 38
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)