issue with the API?
matgargano opened this issue · 3 comments
i appreciate the effort with https://github.com/wp-api-libraries
I'm trying to use https://github.com/wp-api-libraries/wp-idxbroker-api and I've noticed that your GET API example is:
$idx_api = new IdxBrokerAPI( 'example_api_key');
$results = $idx_api->build_request( 'properties/featured' )->request();
I tried this using my API key and it returns false.
Digging deeper it appears that API request translates to...
a request to
https://api.idxbroker.com/properties/featured
with headers:
Content-Type
=> application/x-www-form-urlencoded
,
accesskey
=> my key
,
ancillarykey
=> null,
outputtype
=> json
,
apiversion
=> 1.4.0
a method of GET
and a body of ""
According to the IDX API https://middleware.idxbroker.com/docs/api/overview.php the URL structure is:
https://api.idxbroker.com/{component}/{method}/{primary request ID}/{secondary request ID}?{query string}
however also according to that link the Current components include: partners, clients, mls, and leads
-- properties isn't there.
am I doing something wrong?
thanks
"properties" is not a component of the IDX Broker API. I think this should be clients/featured This should have returned a 404. Maybe instead of returning false return a descriptive error?
@antonioortegajr thanks!
this has been fixed by ways of the updated README.md