woocommerce / wc-api-python

A Python wrapper for the WooCommerce API.
https://pypi.org/project/WooCommerce/
MIT License
212 stars 112 forks source link

No route was found matching the URL and request method #15

Closed bsteph closed 8 years ago

bsteph commented 8 years ago

Very simple test doesn't seem to be working.

import sys from woocommerce import API

wcapi = API( url="https://", consumer_key="ck_blahblahblah", consumer_secret="cs_blahblahblah", wp_api=True, version="wc/v1" ) print(wcapi.get("products").json())

returns {u'message': u'No route was found matching the URL and request method', u'code': u'rest_no_route', u'data': {u'status': 404}}

However, when run the following command I get a good return: curl "https:///wc-api/v3/products?consumer_key=ck_blahblahblah&consumer_secret=cs_blahblahblah&wp_api=True&version=wc/v2&search=ATIGFX45GI"

claudiosanches commented 8 years ago

Are you using WooCommerce 2.6? Because only WooCommerce 2.6 have integration with WP REST API, like you are using in your settings wp_api=True, version="wc/v1" ;)