How Can We Help?
Searching leads, contacts, opportunities and accounts containing a specific text
search = 'sncf'
call = sf_api_call('/services/data/v59.0/search/', parameters={
'q': "FIND { %s } IN ALL FIELDS RETURNING Account (Id, Name), Contact (Id, Name), Opportunity (Id, Name), Lead (Id, Name) WITH METADATA='LABELS' " % search
})
print(json.dumps(call, indent=2))