Skip to main content
neela_balkaran
Jun 14, 2016 5:55 PM UTC
Solved

Error When Using Data Insertion API

Greetings!

I'm currently trying to utilize the Data Insertion API on my company site (using Ruby on Rails), but am getting an error when trying to post. I believe I am using the correct format/variables.
 

Below is the XML request:

"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<request>\n  <reportSuiteID>pluralsight-codeschool-dev</reportSuiteID>\n  <visitorID>146</visitorID>\n  <pageName>Testing Successful Payment</pageName>\n  <category>Individual</category>\n  <events>purchase</events>\n  <products>;Individual;1;55</products>\n  <purchaseID>137</purchaseID>\n</request>\n"

I'm using Faraday to send a post request to: "http://sc.omtrdc.net.112.2o7.net/b/ss//6"

And the response: 

<Faraday::Response:0x007fb4684d6ec0 @env= #<struct Faraday::Env method=:post, body="<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<status>FAILURE</status>\n<reason>NO account</reason>\n", #removed some info here status=200>, @on_complete_callbacks=[]>

Any thoughts on what could be wrong? The <reason>NO account</reason> implies that my report suite ID is missing, but it should be correct and was copied directly from my Omniture account.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
neela_balkaran
neela_balkaranAccepted solution
Jul 6, 2016 1:18 PM UTC

Yep - got the issue sorted out! Turns out it was more of a Faraday problem than an Adobe problem. Thank you all for your help!

6 replies

Gigazelle
Adobe Employee
Adobe Employee
Jun 14, 2016 6:14 PM UTC

Hi Neela, where are you sending the API request to?

Translate
neela_balkaran
Jun 14, 2016 6:19 PM UTC

Hi!

I am sending the data to the following URL: "http://sc.omtrdc.net.112.2o7.net/b/ss//6"

Translate
Gigazelle
Adobe Employee
Adobe Employee
Jun 15, 2016 5:36 PM UTC

Can you try sending it to "http://sc.omtrdc.net/b/ss//6"? The current URL you have there is a bunch of subdomains to 112.2o7.net.

Translate
neela_balkaran
Jun 15, 2016 6:00 PM UTC

Ah, good idea. But that didn't quite work.

That leads to an error of: 
Faraday::ConnectionFailed: getaddrinfo: nodename nor servname provided, or not known
from /Users/neela/.rbenv/versions/2.2.5/lib/ruby/2.2.0/net/http.rb:879:in `initialize'

Translate
TanmayMathur
Adobe Employee
Adobe Employee
Jun 30, 2016 12:28 PM UTC

Hi Neela, 

Have you been able to sort this issue out? Let us know if you need more help around this. If you have found the solution, please share it so it could benefit the community. Thanks!

Translate
neela_balkaran
neela_balkaranAuthorAccepted solution
Jul 6, 2016 1:18 PM UTC

Yep - got the issue sorted out! Turns out it was more of a Faraday problem than an Adobe problem. Thank you all for your help!

Translate