Commission Junction SOAP access Error

J

jatrojoomla

Hi!
Is there any one with knowledge of CJ [Commission Junction] API
development
I am getting error like:
http://fb.aafter.com/cj/testb/support.php
during Commission Junction SOAP access

Commission Junction:
http://cj.com/
http://webservices.cj.com/

Code is:
<body>
<center>
<h2>Commission Junction Demo Product Search</h2>
<form action="<?php echo $_SERVER['PHP_SELF'] ?>"
method="get">
<p><label for="keywords">Search for </label>
<input type="text" name="keywords" value="<?php echo
$_GET['keywords'] ?>" >
<input type="submit" value="Continue &rarr;" /></p>

</form>

</center>
<hr>

<?php

try {
$ini = ini_set("soap.wsdl_cache_enabled","0");
$client = new SoapClient('https://linksearch.api.cj.com/wsdl/version2/
productSearchServiceV2.wsdl', array('trace'=> true));
$results = $client->search(
$developerKey = 'developer_key /
developer_password',
$locale = 'EN'
);

} catch (Exception $e){

echo "<div id='error'><p>There was an error
with your request or the service is unavailable.</p></div>";

}

?>

</body>
</html>
 
J

Jon Spivey

Hi,
Can't help with php as I use asp.net but on first look it looks like you're
not passing in enough params to the product search. If you don't want to use
any param enter it as an empty string. Also you don't need a password just a
dev key you also need a web site id. It seams your url to the wsdl is wrong,
they've changed recently and now all start with http://product.ap1.cj.com eg
the productsearchservice is at
https://product.api.cj.com/wsdl/version2/productSearchServiceV2.wsdl

Just to show you this does actually work here's a 2 second page doing what I
think you want to do.
http://www.nisusnewmedia.com/cjproductsearchservice.aspx

Cheers,
Jon
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top