Basic API call doesn't seem to work?

Kevin B Posted in Technical Support 3 years ago

Hi guys,

I've enabled OSSNServices and generated an API Key. I then run a simple GET on the browser address bar:

 http://10.48.1.28/api/v1.0/message_list?api_key_token={token}&guid=1

I am getting the following error:

{
    "merchant": "mysite",
    "url": "http:\/\/10.48.1.28\/",
    "time_token": 1604069637,
    "payload": false,
    "code": "200",
    "message": "No such a user exists"
}

The guid of 1 is definitely correct, but I also tried 0 and 2 with the same results.

According to the API page, invalid user should return an error 103, so 200 makes me think perhaps it could be a red herring?

I also get the same response if I perform a POST using curl.

Any thoughts?

Many thanks
Kev

Replies
gb Kevin B Replied 3 years ago

Just figured it out!!

The reference page for the "Recent list" shows the wrong endpoint!

It should be message_recent not message_list.

https://www.opensource-socialnetwork.org/webservices/view/3614/recent-messages-list