SuiteTalk URLs Demystified

I’ve been dinged by NetSuite’s SuiteTalk URLs either changing or breaking on more than one occasion. Today, I believe I’ve been given the “secret handshake” to connect my SuiteTalk app in a datacenter-agnostic fashion. Hopefully, going forward, this will help us all to get it right.

The short version of my story is this. There are 2 things you need to set when connecting your SuiteTalk app to NetSuite. When you bind your web service, you need to bind to the WSDL. And then when you set your entry/binding point, it’s not the same URL. This is not normal behavior for Microsoft developers. Let me explain the steps and then hopefully you Microsoft developers will understand.

Below, I’m showing you my web reference. Notice the following:

  1. It points to netsuite.wsdl.
  2. What’s whited out is my account number.
  3. It’s a web reference, not a service reference.
    • Right click on Service References
    • Click Add a Service Reference
    • In the lower lefthand corner of the newly opened window, click Advanced
    • In the lower lefthand corder of the next window, click Add Web Reference
    • Paste into the URL field, your URL, with your account number
    • In my case, I renamed the “Web reference name” to nsWS (way shorter!)
    • Click Add Reference

SolutionExplorer

And here, I’m showing my entry/binding point. This is in my app.config file. The applicationSettings section will be added to your app.config file after you bind to the WSDL above. Notice the following:

  1. The value (or entry point) is not the same as the WSDL.
  2. I’ve whited out the account number. A leading account number is the new and correct format for my URL.
  3. Your app.config must be edited using Visual Studio (or any text editor) after you bind to the WSDL.

AppConfig

This is the basics of binding a SuiteTalk application to NetSuite. I’m told that if you follow these conventions, your SuiteTalk app will NOT experience any of the following symptoms:

  1. Failure to compile.
  2. Will log in successfully, but can’t run any services.
  3. Will display a “Connection timeout error.”

One more thing… If you have a sandbox, there is a new way to swap your connection from your production copy of NetSuite to your sandbox. The easiest way to do this is to click on your web reference. In my case, this is nsWS. Hit F4 to open the properties. Change the URL to be your account number, plus “_SB”. That denotes your sandbox. Then change your app config to do the same. Then change your Passport (passed in a call to NetSuite at login) to do the same.

Here’s another tidbit that I learned when moving to the datacenter-agnostic URLs. My production provision of NetSuite may not necessarily be hosted in the same datacenter as my sandbox provision of NetSuite. This might help you troubleshoot datacenter specific problems, which I’ve seen from time to time.

I hope this helps.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s