{"id":13655,"date":"2023-05-18T05:01:23","date_gmt":"2023-05-18T09:01:23","guid":{"rendered":"https:\/\/www.shinetechsoftware.com\/?p=13655"},"modified":"2023-06-01T05:35:04","modified_gmt":"2023-06-01T09:35:04","slug":"connecting-to-salesforce-with-soap-api","status":"publish","type":"post","link":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/","title":{"rendered":"Connecting to Salesforce with SOAP API in C#"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"13655\" class=\"elementor elementor-13655\" data-elementor-post-type=\"post\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-a8a9bc9 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"a8a9bc9\" data-element_type=\"section\" data-settings=\"{&quot;background_background&quot;:&quot;classic&quot;}\">\n\t\t\t\t\t\t\t<div class=\"elementor-background-overlay\"><\/div>\n\t\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-647237f6\" data-id=\"647237f6\" data-element_type=\"column\" data-settings=\"{&quot;background_background&quot;:&quot;classic&quot;}\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-3da7c944 elementor-widget elementor-widget-heading\" data-id=\"3da7c944\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h1 class=\"elementor-heading-title elementor-size-default\">Connecting to Salesforce with SOAP API in C#<\/h1>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-4f8505ad elementor-widget elementor-widget-text-editor\" data-id=\"4f8505ad\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\tSalesforce is a popular <strong><span class=\"font-red\">Customer Relationship Management (CRM)<\/span><\/strong> platform that provides a robust set of APIs for integrating and extending its functionality. One of the APIs available is the SOAP API, which allows developers to interact with Salesforce using the SOAP protocol. In this blog post, we will explore how to connect to Salesforce using the SOAP API in C# and perform basic operations.\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-931bc7d elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"931bc7d\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-41b60626\" data-id=\"41b60626\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-181cd61c elementor-widget elementor-widget-heading\" data-id=\"181cd61c\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Step 1:<span class=\"font-red\"> Set up a Salesforce Developer Account<\/span> <\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-7f8064 elementor-widget elementor-widget-text-editor\" data-id=\"7f8064\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<p>\u00a0<\/p><p>Before we dive into the code, make sure you have a <strong><span class=\"font-red\"> Salesforce Developer Account<\/span><\/strong>. If you don&#8217;t have one, you can sign up for free at https:\/\/developer.salesforce.com\/signup. This will provide you with the necessary credentials to authenticate and access Salesforce.<\/p><p>\u00a0<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-ea22317 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"ea22317\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-27d09888\" data-id=\"27d09888\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-1ccfdad0 elementor-widget elementor-widget-heading\" data-id=\"1ccfdad0\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Step 2: <span class=\"font-red\">Create a Salesforce Connected App <\/span> <\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-682da7dd elementor-widget elementor-widget-text-editor\" data-id=\"682da7dd\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<p>\u00a0<\/p><p>To connect to Salesforce using the SOAP API, we need to create a Connected App in Salesforce.<\/p><p><strong><span class=\"font-red\">Follow these steps:<\/span><\/strong><\/p><p>Log in to your Salesforce Developer Account.<br \/>Go to &#8220;Settings&#8221; &gt; &#8220;My Personal Information&#8221; &gt; &#8220;Rest My Security Token&#8221;<br \/>Click &#8220;Reset Security Token&#8221;, you will receive the security token via email<\/p><p>\u00a0<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-0caeccd elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"0caeccd\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-24f6f18\" data-id=\"24f6f18\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-2b70c326 elementor-widget elementor-widget-heading\" data-id=\"2b70c326\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Step 3: <span class=\"font-red\">Obtain the Salesforce WSDL<\/span> <\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-6807dd84 elementor-widget elementor-widget-text-editor\" data-id=\"6807dd84\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div><p>The Salesforce WSDL (Web Services Description Language) file describes the SOAP API operations and objects.<\/p><\/div><div><strong><span class=\"font-red\">Here&#8217;s how to obtain it:<\/span><\/strong><\/div><div><strong><span class=\"font-red\">\u00a0<\/span><\/strong><\/div><div>Log in to your Salesforce Developer Account.<\/div><div>Go to &#8220;Setup&#8221; &gt; &#8220;Inegrations&#8221; &gt; &#8220;API&#8221;<\/div><div>Click on &#8220;Generate Enterprise WSDL&#8221; and save the WSDL file to your local machine.<\/div><div>\u00a0<\/div><div>Tips: there are an issue in the WSDL file, please modify the below line as below:<\/div>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-204af34 elementor-widget elementor-widget-code-highlight\" data-id=\"204af34\" data-element_type=\"widget\" data-widget_type=\"code-highlight.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<div class=\"prismjs-default copy-to-clipboard word-wrap\">\n\t\t\t<pre data-line=\"\" class=\"highlight-height language-xml \">\n\t\t\t\t<code readonly=\"true\" class=\"language-xml\">\n\t\t\t\t\t<xmp><complexType name=\"ListViewRecord\">\r\n  <sequence>\r\n    <element name=\"columns\" type=\"tns:ListViewRecordColumn\" minOccurs=\"1\" maxOccurs=\"unbounded\"\/>\r\n  <\/sequence>\r\n  <xsd:attribute name=\"tmp\" type=\"xsd:string\" \/>\r\n<\/complexType><\/xmp>\n\t\t\t\t<\/code>\n\t\t\t<\/pre>\n\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-3b4a8a4 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"3b4a8a4\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-6d67ff28\" data-id=\"6d67ff28\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-353d373f elementor-widget elementor-widget-heading\" data-id=\"353d373f\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Step 4: <span class=\"font-red\">Add a Service Reference in Visual Studio <\/span> <\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-34f9d45d elementor-widget elementor-widget-text-editor\" data-id=\"34f9d45d\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<p>\u00a0<\/p><p>To interact with the Salesforce SOAP API in C#, we need to add a service reference in Visual Studio.<\/p><p><strong><span class=\"font-red\">Here&#8217;s how:<\/span><\/strong><\/p><p>Create a new C# project in Visual Studio or open an existing one. (Important: please use .net framework instead of .net core)<br \/>Right-click on &#8220;References&#8221; in the Solution Explorer and select &#8220;Add Service Reference.&#8221;<br \/>Click on &#8220;Advanced&#8221; and then on &#8220;Add Web Reference.&#8221;<br \/>Browse to the downloaded Salesforce WSDL file and add the reference to your project.<\/p><p>\u00a0<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-b27b45f elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"b27b45f\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-53d7a41b\" data-id=\"53d7a41b\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-70f8b05a elementor-widget elementor-widget-heading\" data-id=\"70f8b05a\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Step 5: <span class=\"font-red\">Write Code to Connect to Salesforce <\/span> <\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-8446e68 elementor-widget elementor-widget-text-editor\" data-id=\"8446e68\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<p><\/p>\n<p>With the Salesforce service reference added, we can now write code to connect to Salesforce and perform operations.<\/p>\n<p><strong><span class=\"font-red\">Here&#8217;s a sample code snippet:<\/span><\/strong><\/p>\n<p><\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-a150674 elementor-widget elementor-widget-code-highlight\" data-id=\"a150674\" data-element_type=\"widget\" data-widget_type=\"code-highlight.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<div class=\"prismjs-default copy-to-clipboard \">\n\t\t\t<pre data-line=\"\" class=\"highlight-height language-csharp \">\n\t\t\t\t<code readonly=\"true\" class=\"language-csharp\">\n\t\t\t\t\t<xmp>\/\/ Include necessary namespaces\r\nusing System;\r\nusing System.ServiceModel;\r\n\r\n\/\/ Create a new instance of the Salesforce API client\r\nSforceService client = new SforceService();\r\n\r\n\/\/ Set the Salesforce API session header (obtain session ID using authentication)\r\nLoginResult loginResult = client.login(\"YOUR_USERNAME\", \"YOUR_PASSWORD_AND_SECURITY_TOKEN\");\r\nclient.SessionHeaderValue = new SessionHeader\r\n{\r\nsessionValue = loginResult.sessionId\r\n};\r\n\r\n\/\/ Perform Salesforce API operations\r\n\/\/ Example: query the Salesforce Contact object\r\nQueryResult queryResult = client.query(\"SELECT Id, FirstName, LastName FROM Contact\");<\/xmp>\n\t\t\t\t<\/code>\n\t\t\t<\/pre>\n\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-7930f55 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"7930f55\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-18c1d1eb\" data-id=\"18c1d1eb\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-5b739e84 elementor-widget elementor-widget-text-editor\" data-id=\"5b739e84\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"explanation-text hire-image-text2\"><p class=\"fs-18\">Shinetech\u2019s scalable and dedicated development teams have a shared goal to help facilitate positive change within your business by building tailored software that will respond to your unique business problems in a timely and cost-effective manner.<\/p><p class=\"fs-18\">When you face problems that hinder your business\u2019 growth and development, it is always a challenge to find a reliable partner that can help you build software and sustain a long-term business relationship that can scale with your business needs. Shinetech offers end-to-end solutions, from concept and strategy, UX\/UI design, implementation, integration and support, helping you achieve your business goals and boost productivity within the shortest possible timeframe.<\/p><\/div>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-e1cd9a0 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"e1cd9a0\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-69ad287d\" data-id=\"69ad287d\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-5222ae9f elementor-widget elementor-widget-heading\" data-id=\"5222ae9f\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Contact us<\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-57550b48 elementor-widget elementor-widget-shinetech-form\" data-id=\"57550b48\" data-element_type=\"widget\" data-widget_type=\"shinetech-form.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t        \n<script>\n    window.onload = function() {\n        addGclid();\n    }\n\n    function addGclid() {\n        var gclidParam = getParam('gclid');\n        var gclidFormFields = ['gclid_field', 'foobar']; \/\/ \u6b64\u5904\u4e3a\u6240\u6709\u53ef\u80fd\u7684 GCLID \u8868\u5355\u5b57\u6bb5\n        var gclidRecord = null;\n        var currGclidFormField;\n\n        var gclsrcParam = getParam('gclsrc');\n        var isGclsrcValid = !gclsrcParam || gclsrcParam.indexOf('aw') !== -1;\n\n        gclidFormFields.forEach(function(field) {\n            if (document.getElementById(field)) {\n                currGclidFormField = document.getElementById(field);\n            }\n        });\n\n        if (gclidParam && isGclsrcValid) {\n            gclidRecord = getExpiryRecord(gclidParam);\n            localStorage.setItem('gclid', JSON.stringify(gclidRecord));\n        }\n\n        var gclid = gclidRecord || JSON.parse(localStorage.getItem('gclid'));\n        var isGclidValid = gclid && new Date().getTime() < gclid.expiryDate;\n\n        if (currGclidFormField && isGclidValid) {\n            currGclidFormField.value = gclid.value;\n        }\n    }\n\n    \/\/ google-Ads trace start\n    function getParam(p) {\n        var match = RegExp('[?&]' + p + '=([^&]*)').exec(window.location.search);\n        return match && decodeURIComponent(match[1].replace(\/\\+\/g, ' '));\n    }\n\n    function getExpiryRecord(value) {\n        var expiryPeriod = 90 * 24 * 60 * 60 * 1000; \/\/ \u4ee5\u6beb\u79d2\u8ba1\u7684 90 \u5929\u6709\u6548\u671f\n\n        var expiryDate = new Date().getTime() + expiryPeriod;\n        return {\n            value: value,\n            expiryDate: expiryDate\n        };\n    }\n<\/script>\n\n<div class=\"form-wrapper\">\n    <form class=\"contact-form needs-validation\" method=\"post\" novalidate>\n        <input type=\"hidden\" id=\"gclid_field\" name=\"gclid_field\" value=\"\">\n        <input type=\"hidden\" id=\"page-title\" name=\"page_title\" value=\"Connecting to Salesforce with SOAP API in C#\">\n        <input type=\"hidden\" id=\"_nounce\" name=\"_nounce\" value=\"8961ce790d\" \/><input type=\"hidden\" name=\"_wp_http_referer\" value=\"\/en\/wp-json\/wp\/v2\/posts\/13655\" \/>        <div class=\"container px-0\">\n            <div class=\"row\">\n                <div class=\"col-sm-6 col-md-6 col-lg-6\">\n                    <div class=\"form-material\">\n                        <input type=\"text\" class=\"form-material__control\" name=\"contact\" required id=\"contact_name\">\n                        <label class=\"form-material__label\" for=\"contact\">Name*<\/label>\n                        <div class=\"invalid-feedback\">\n                            Please fill require field.\n                        <\/div>\n                    <\/div>\n                <\/div>\n                <div class=\"col-sm-6 col-md-6 col-lg-6\">\n                    <div class=\"form-material\">\n                        <input class=\"form-material__control\" name=\"email\" type=\"email\" id=\"email\" required>\n                        <label class=\"form-material__label\" for=\"email\">Email*<\/label>\n                        <div class=\"invalid-feedback\">\n                            Please fill a valid Email.\n                        <\/div>\n                    <\/div>\n                <\/div>\n                <div class=\"col-sm-6 col-md-6 col-lg-6\">\n                    <div class=\"form-material\">\n                        <input type=\"text\" class=\"form-material__control\" name=\"telephone\" id=\"telephone\" required>\n                        <label class=\"form-material__label\" for=\"telephone\">Telephone* <\/label>\n                        <div class=\"invalid-feedback\">\n                            Please fill require field.\n                        <\/div>\n                    <\/div>\n                <\/div>\n                <div class=\"col-sm-6 col-md-6 col-lg-6\">\n                    <div class=\"form-material\">\n                        <input type=\"text\" class=\"form-material__control\" name=\"company\" id=\"company\">\n                        <label class=\"form-material__label\" for=\"company\">Company Name <\/label>\n                        <div class=\"invalid-feedback\">\n                            Please fill require field.\n                        <\/div>\n                    <\/div>\n                <\/div>\n                <div class=\"col-sm-12 col-md-12 col-lg-12\">\n                    <div class=\"form-material\">\n                        <textarea rows=\"8\" style=\"min-height: 130px;\" class=\"form-material__control\" name=\"description\" id=\"desc\" required><\/textarea>\n                        <label class=\"form-material__label\" for=\"description\">What do you need?*<\/label>\n                        <div class=\"invalid-feedback\">\n                            Please fill require field.\n                        <\/div>\n                    <\/div>\n                <\/div>\n            <\/div>\n            <div class=\"row contact-footer\">\n                <div class=\"col-sm-6 col-md-6 col-lg-6\">\n                    <button id=\"submit\" type=\"submit\" class=\"btn btn-primary\">\n                        Submit Request\n                    <\/button>\n                <\/div>\n                <div class=\"col-sm-6 col-md-6 col-lg-6 \">\n                    <div class=\"form-material form-check-group\">\n                        <input class=\"form-check-input contact-option\" id=\"freeTrial\" name=\"freetrial\" type=\"checkbox\" value=\"[FreeTrial]\">\n                        <label class=\"form-check-label\" for=\"freeTrial\">\n                            I would like a <a class=\"free-trial-link\" href=\"https:\/\/shinetechchina.com.cn\/en\/free-trial\/\">free trial<\/a>\n                        <\/label>\n                    <\/div>\n                <\/div>\n\n            <\/div>\n        <\/div>\n    <\/form>\n<\/div>        \t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>In this insight, we will discuss how to Connect to Salesforce with SOAP API in C#. We invited Leon Li from Shinetech Software to introduce his development experience to us.<\/p>\n","protected":false},"author":6,"featured_media":13666,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false,"footnotes":""},"categories":[19],"tags":[],"class_list":["post-13655","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-our-insight"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v23.9 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Connecting to Salesforce with SOAP API in C# | Shinetech Software<\/title>\n<meta name=\"description\" content=\"In this insight, we will discuss how to Connect to Salesforce with SOAP API in C#. We invited Leon Li from Shinetech Software to introduce his development experience to us.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Connecting to Salesforce with SOAP API in C# | Shinetech Software\" \/>\n<meta property=\"og:description\" content=\"In this insight, we will discuss how to Connect to Salesforce with SOAP API in C#. We invited Leon Li from Shinetech Software to introduce his development experience to us.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/\" \/>\n<meta property=\"og:site_name\" content=\"Shinetech Software\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/ShinetechSoftware\" \/>\n<meta property=\"article:published_time\" content=\"2023-05-18T09:01:23+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-06-01T09:35:04+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"2560\" \/>\n\t<meta property=\"og:image:height\" content=\"1707\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Shinetech Editorial Group\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@ShinetechUS\" \/>\n<meta name=\"twitter:site\" content=\"@ShinetechUS\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Shinetech Editorial Group\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/\"},\"author\":{\"name\":\"Shinetech Editorial Group\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#\/schema\/person\/bdf7ec41209ddf528d4fd8a5902baf90\"},\"headline\":\"Connecting to Salesforce with SOAP API in C#\",\"datePublished\":\"2023-05-18T09:01:23+00:00\",\"dateModified\":\"2023-06-01T09:35:04+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/\"},\"wordCount\":553,\"publisher\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#organization\"},\"image\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg\",\"articleSection\":[\"Our Insight\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/\",\"url\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/\",\"name\":\"Connecting to Salesforce with SOAP API in C# | Shinetech Software\",\"isPartOf\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg\",\"datePublished\":\"2023-05-18T09:01:23+00:00\",\"dateModified\":\"2023-06-01T09:35:04+00:00\",\"description\":\"In this insight, we will discuss how to Connect to Salesforce with SOAP API in C#. We invited Leon Li from Shinetech Software to introduce his development experience to us.\",\"breadcrumb\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#primaryimage\",\"url\":\"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg\",\"contentUrl\":\"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg\",\"width\":2560,\"height\":1707},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/shinetechchina.com.cn\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Connecting to Salesforce with SOAP API in C#\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#website\",\"url\":\"https:\/\/shinetechchina.com.cn\/en\/\",\"name\":\"Shinetech Software\",\"description\":\"Shinetech Software\",\"publisher\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/shinetechchina.com.cn\/en\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#organization\",\"name\":\"Shinetech Software\",\"url\":\"https:\/\/shinetechchina.com.cn\/en\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2021\/08\/Logo.svg\",\"contentUrl\":\"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2021\/08\/Logo.svg\",\"width\":170,\"height\":40,\"caption\":\"Shinetech Software\"},\"image\":{\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/ShinetechSoftware\",\"https:\/\/x.com\/ShinetechUS\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/shinetechchina.com.cn\/en\/#\/schema\/person\/bdf7ec41209ddf528d4fd8a5902baf90\",\"name\":\"Shinetech Editorial Group\",\"url\":\"https:\/\/shinetechchina.com.cn\/en\/author\/richard-liu\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Connecting to Salesforce with SOAP API in C# | Shinetech Software","description":"In this insight, we will discuss how to Connect to Salesforce with SOAP API in C#. We invited Leon Li from Shinetech Software to introduce his development experience to us.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"og_locale":"en_US","og_type":"article","og_title":"Connecting to Salesforce with SOAP API in C# | Shinetech Software","og_description":"In this insight, we will discuss how to Connect to Salesforce with SOAP API in C#. We invited Leon Li from Shinetech Software to introduce his development experience to us.","og_url":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/","og_site_name":"Shinetech Software","article_publisher":"https:\/\/www.facebook.com\/ShinetechSoftware","article_published_time":"2023-05-18T09:01:23+00:00","article_modified_time":"2023-06-01T09:35:04+00:00","og_image":[{"width":2560,"height":1707,"url":"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg","type":"image\/jpeg"}],"author":"Shinetech Editorial Group","twitter_card":"summary_large_image","twitter_creator":"@ShinetechUS","twitter_site":"@ShinetechUS","twitter_misc":{"Written by":"Shinetech Editorial Group","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#article","isPartOf":{"@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/"},"author":{"name":"Shinetech Editorial Group","@id":"https:\/\/shinetechchina.com.cn\/en\/#\/schema\/person\/bdf7ec41209ddf528d4fd8a5902baf90"},"headline":"Connecting to Salesforce with SOAP API in C#","datePublished":"2023-05-18T09:01:23+00:00","dateModified":"2023-06-01T09:35:04+00:00","mainEntityOfPage":{"@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/"},"wordCount":553,"publisher":{"@id":"https:\/\/shinetechchina.com.cn\/en\/#organization"},"image":{"@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#primaryimage"},"thumbnailUrl":"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg","articleSection":["Our Insight"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/","url":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/","name":"Connecting to Salesforce with SOAP API in C# | Shinetech Software","isPartOf":{"@id":"https:\/\/shinetechchina.com.cn\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#primaryimage"},"image":{"@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#primaryimage"},"thumbnailUrl":"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg","datePublished":"2023-05-18T09:01:23+00:00","dateModified":"2023-06-01T09:35:04+00:00","description":"In this insight, we will discuss how to Connect to Salesforce with SOAP API in C#. We invited Leon Li from Shinetech Software to introduce his development experience to us.","breadcrumb":{"@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#primaryimage","url":"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg","contentUrl":"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2023\/05\/IMG_4201-scaled.jpg","width":2560,"height":1707},{"@type":"BreadcrumbList","@id":"https:\/\/shinetechchina.com.cn\/en\/our-insight\/connecting-to-salesforce-with-soap-api\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/shinetechchina.com.cn\/en\/"},{"@type":"ListItem","position":2,"name":"Connecting to Salesforce with SOAP API in C#"}]},{"@type":"WebSite","@id":"https:\/\/shinetechchina.com.cn\/en\/#website","url":"https:\/\/shinetechchina.com.cn\/en\/","name":"Shinetech Software","description":"Shinetech Software","publisher":{"@id":"https:\/\/shinetechchina.com.cn\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/shinetechchina.com.cn\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/shinetechchina.com.cn\/en\/#organization","name":"Shinetech Software","url":"https:\/\/shinetechchina.com.cn\/en\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/shinetechchina.com.cn\/en\/#\/schema\/logo\/image\/","url":"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2021\/08\/Logo.svg","contentUrl":"https:\/\/shinetechchina.com.cn\/en\/wp-content\/uploads\/2021\/08\/Logo.svg","width":170,"height":40,"caption":"Shinetech Software"},"image":{"@id":"https:\/\/shinetechchina.com.cn\/en\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/ShinetechSoftware","https:\/\/x.com\/ShinetechUS"]},{"@type":"Person","@id":"https:\/\/shinetechchina.com.cn\/en\/#\/schema\/person\/bdf7ec41209ddf528d4fd8a5902baf90","name":"Shinetech Editorial Group","url":"https:\/\/shinetechchina.com.cn\/en\/author\/richard-liu\/"}]}},"_links":{"self":[{"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/posts\/13655","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/comments?post=13655"}],"version-history":[{"count":36,"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/posts\/13655\/revisions"}],"predecessor-version":[{"id":13778,"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/posts\/13655\/revisions\/13778"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/media\/13666"}],"wp:attachment":[{"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/media?parent=13655"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/categories?post=13655"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/shinetechchina.com.cn\/en\/wp-json\/wp\/v2\/tags?post=13655"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}