I have written a C# web service and it has a web method that gets last inserted Account object from Salesforce by using Salesforce Web Service API after that inserts these datas to an MSSQL database. I want to invoke this web service after an insert process of Account object from Salesforce. How can i invoke this web service inside of an Apex trigger(After Account insert) ? Any help would be appriciated.
Asked
Active
Viewed 572 times
0
-
2See Creating an Apex Class from a WSDL and HTTP Callout from Triggers. – Keith C Aug 01 '14 at 07:19
1 Answers
2
Since you are trying to transfer the Salesforce Account into your SQL database, you can make use of APEX Callouts and call your webservice from your trigger on Accounts.
Also, your don't need to call Salesforce API again from your webservice to get the Account details. you should just be passing the required fields from Account record to your webservice that you need to map in your SQL database
You can go through these Salesforce References to know more about making Apex Callouts ..
Vamsi Krishna Gosu
- 10,464
- 5
- 32
- 49