• Alex Olinger
  • NEWBIE
  • 10 Points
  • Member since 2021

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 1
    Replies
/services/data/v53.0/sobjects/Account?name=...
I was trying to filter down the accounts call from the requests itself. 
My use case is to call accounts and find the Account ID from the given Account Name.
 
Using the following call and JSON data I have been trying to Create a new opportunity attached to an account. Headers/Call are correct as I've been able to create Leads/Accounts. Something with the JSON is wrong but i'm not sure what it is. 

/services/data/v53.0/sobjects/Opportunity

data={
'Name': "Test opportunity",
'Accountid': "XXXXXXXXXXXXX",
'closedate': "1/12/2021",
'stagename':"Needs Analysis",
'Probability': "10"
}
Using the following call and JSON data I have been trying to Create a new opportunity attached to an account. Headers/Call are correct as I've been able to create Leads/Accounts. Something with the JSON is wrong but i'm not sure what it is. 

/services/data/v53.0/sobjects/Opportunity

data={
'Name': "Test opportunity",
'Accountid': "XXXXXXXXXXXXX",
'closedate': "1/12/2021",
'stagename':"Needs Analysis",
'Probability': "10"
}