• burak sağman
  • NEWBIE
  • 0 Points
  • Member since 2023

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 2
    Replies
Hi everyone,
I would be very grateful if someone can help me.

I are trying to re use the selected value from a dynamic menu to use as an input to call other apex class.

I store values here (img 1), after I output this with success (img2).
I want to use the values as a input for call in next apex class(img3), but I get plain text "{!Matched_Order.OrderNumber}" on apex side and the Id is not passing.
Is it the correct way to pass the value or what am I missing?

Please help me finding the solution to make it work.
User-added imageUser-added imageUser-added image
Best regards,
Andre Chambel
Hi All,

I have a required where i need to create Account with Contact and attachment under the contact.
I also need to refer a look up value(Test_Rec_Type_Object__c) on Account with the help of external id and the same with contact as well. On contact i have a look up(Test_Object__c) which i need to refer with the external id.

Here is the snippet which i used from workbench REST API...
----------------------
/services/data/v37.0/composite/tree/Account

{
"records" :[{
    "attributes" : {"type" : "Account", "referenceId" : "ref1"},
    "name" : "Acc with Con with Att New",
    "phone" : "1234567890",
    "website" : "www.salesforce.com",
    "numberOfEmployees" : "100",
    "industry" : "Banking",
    "Test_Rec_Type_Object__c" : {
       "Text_External_Unique__c" : "12345" },

    "Contacts" : {
      "records" : [{
         "attributes" : {"type" : "Contact", "referenceId" : "ref2"},
         "lastname" : "Smith",
         "Title" : "President",
         "email" : "sample@salesforce.com",
         "Test_Object__c" : {
            "TO_External_Obj__c.Id" : "67890" },

    "Attachments" : {
      "records" : [{
         "attributes" : {"type" : "Attachment", "referenceId" : "ref3"},
         "Name": "TestPDF.pdf", 
         "body": "Attach with Rec Creation"
         }]
      }
         }]
      }
    }]
}

Here is the error i am getting... Could any one please help on this... There is some problem in referencing the external id(Highlighted bold)

Cannot deserialize instance of reference from START_OBJECT value { or request may be missing a required field at [line:8, column:27]