Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Pulling a specific order by orderNumber via the REST API

 
Reply
   X-Cart forums > X-Cart 5 > Dev Questions (X-Cart 5)
 
Thread Tools Search this Thread
  #1  
Old 10-01-2015, 06:33 AM
 
cjipaygo cjipaygo is offline
 

Newbie
  
Join Date: Apr 2009
Posts: 7
 

Default Pulling a specific order by orderNumber via the REST API

Is it possible to pull / get a specific Order from the orders table using the orderNumber field instead of the order_id field?

I've tried:

https://mysite.com/xcart-5/xcart/admin.php?target=RESTAPI&_key=my-5-xcart-api&_path=order/0&_method=get&_schema=complex&model[orderNumber]=1

But it doesn't work.

If I do this, it will of course get the data I specify. But I need to use the orderNumber.

https://mysite.com/xcart-5/xcart/admin.php?target=RESTAPI&_key=my-5-xcart-api&_path=order/1&_method=get&_schema=complex

Thanks,

Chris
Reply With Quote
  #2  
Old 10-02-2015, 04:57 AM
  qualiteam's Avatar 
qualiteam qualiteam is offline
 

X-Guru
  
Join Date: Dec 2010
Posts: 6,373
 

Default Re: Pulling a specific order by orderNumber via the REST API

Hello Chris,

You can use the "_cnd" parameter to set conditions/restrictions on the data being retrieved by the API.

The parameter is not documented on the official http://kb.x-cart.com/ portal yet.
However, one of developers has created a small tutorial on using it.

The tutorial is in Russian, but Google Translate gives a somewhat correct translation:
http://dagdag-xcart5.blogspot.ru/2015/02/rest-api.html
__________________
Alex Solovev,
Qualiteam

---

User manual Video tutorials X-Cart FAQ

You are welcome to press "Thanks" button
if you find this post useful

Click here to learn how to apply patches

X-Cart Extensions
Reply With Quote
Reply
   X-Cart forums > X-Cart 5 > Dev Questions (X-Cart 5)



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 10:09 AM.

   

 
X-Cart forums © 2001-2020