Developer Forum [ All Topics | New Topic ]

Thread: Did not get supplier information

Hi,

I am using web service to get details of supplier(email). in some stones i am able to fetch information of suppliers but not for all.

now problem is that, with the same supplier i am able to fetch information for one stone and not for second one.

e.g. These both diamonds are from same supplier: 55476095 and 55476094.
in this case, I am getting information of supplier in 55476095 and not getting information for this stone id: 55476094. I have checked manually in rapnet and both stones are from same supplier.

I am using this webservice: GetSingleDiamond

why is this even with same supplier. can you please help me to sort it out.

Thanks,
Ketan


>> add a comment
ketan
09/10/2014 01:24


6 Replies:

Hi, can you please provide me solution. its urgent for me.

>> add a comment
ketan
9/11/2014 7:54:00 AM
Hi
I got   supplier details (email) , with webservice: GetSingleDiamond  in both stones (55476095 ,55476094 ).
If you have other examples with the problem send me and I'll check


>> add a comment
Reuven
9/11/2014 8:30:00 AM
Hi,
I am using GetSingleDiamond webservice in PHP using below code.. I am not getting information in Diamond id: 55476095
****************************
$auth_url = "https://technet.rapaport.com/HTTP/Authenticate.aspx";
$post_string = "username=MY_USERNAME&password=" . urlencode("MY_PASSWORD");

//create HTTP POST request with curl:
$request = curl_init($auth_url); // initiate curl object
curl_setopt($request, CURLOPT_HEADER, 0); // set to 0 to eliminate header info from response
curl_setopt($request, CURLOPT_RETURNTRANSFER, 1); // Returns response data instead of TRUE(1)
curl_setopt($request, CURLOPT_POSTFIELDS, $post_string); // use HTTP POST to send form data
curl_setopt($request, CURLOPT_SSL_VERIFYPEER, FALSE); // uncomment this line if you get no gateway response.
$auth_ticket = curl_exec($request); // execute curl post and store results in $auth_ticket
curl_close ($request);

$auth_url = "https://technet.rapaport.com/HTTP/JSON/RetailFeed/GetSingleDiamond.aspx";
$post_string = '{
"request": {
"header": {
"username": "MY_USERNAME",
"password": "MY_PASSWORD"

},
"body": {
"diamond_id": 55476095
}
}
}';
//create HTTP POST request with curl:
$request = curl_init($auth_url); // initiate curl object
curl_setopt($request, CURLOPT_HEADER, 0); // set to 0 to eliminate header info from response
curl_setopt($request, CURLOPT_RETURNTRANSFER, 1); // Returns response data instead of TRUE(1)
curl_setopt($request, CURLOPT_POSTFIELDS, $post_string); // use HTTP POST to send form data
curl_setopt($request, CURLOPT_SSL_VERIFYPEER, FALSE); // uncomment this line if you get no gateway response.
$response = curl_exec($request); // execute curl post and store results in $auth_ticket
echo "<pre>";
print_r($response);

*****************************
I am getting "error code: 4001" and "No Diamond was found" in above coding, but if I set Diamond id: 55476094, I am getting all information about diamond with supplier  information.
So, did I any mistake in my code? Please let me know so i can solve it.

Thanks,
Ketan

>> add a comment
ketan
9/12/2014 12:25:00 AM
In RapLink you get diamonds according to your settings,
http://www.rapnet.com/Rapnet/InventoryLink/FeedSelection/Diamonds.aspx
Check your settings ,if 55476095 compatible with your settings,
e.g. the price range


>> add a comment
Reuven
9/14/2014 3:48:00 AM
Hi, I think I use DLS service for diamonds.. and you gave me link to set my feed is in Inventory link. correct ? and DLS i have set all criteria..

or do I have to set all criteria in above link also you gave me ?

>> add a comment
ketan
9/15/2014 8:29:00 AM
There are two ways get diamonds from RapNet :
1. DLS :
   http://technet.rapaport.com/Info/Dls/
   and the diamonds settings:
   the http://www.rapnet.com/Rapnet/Dls/GeneralSettings.aspx
2. RapNet Inventory Link :
   http://technet.rapaport.com/Info/RapLink/RapNetInventoryLink.aspx
   and the diamonds settings:
   http://www.rapnet.com/RapNet/InventoryLink/GeneralSettings.aspx
the code you sent is use InventoryLink.


>> add a comment
Reuven
9/15/2014 9:37:00 AM