Strange Behavior From Rest Services Suitetalk Query Endpoint

I’m trying to programmatically access the suitetalk rest api query endpoint (eg https://<account_id>.suitetalk.api.netsuite.com/services/rest/query/v1/suiteql?limit=10) for my Netsuite instance. I cloned the Netsuite postman collection, and queries seem to work perfectly within the postman UI. However, when I get the cURL code snippet from postman, the cURL seems to fail with a 401 unauthorized. Some advice on how to get the curl to work would be appreciated, but it’s less significant than the following issue:

When I query using javascript, the response is a 200, but the body of the response is XML stating “Incorrect data center requested! The data center you are requesting is not the data center where your account is hosted. To obtain the correct URL for your request, please use the SOAP getDataCenterUrls operation.” But, I’m not using the legacy data center url – as you can see above I’m using an account-id-based url, so I haven’t a clue why this error message is coming up. Has anyone seen this before? Why does it think I’m querying a SOAP endpoint (hence the xml response) on a specific data center?

Rookie Asked on April 20, 2022 in SuiteTalk.
Add Comment
0 Answer(s)

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.
  • This site made possible by our sponsors:   Tipalti   Celigo   Limebox   Become a Sponsor   Become a Sponsor