Hi,
I've installed the OssnServices API v6.2 on my OSSN v5.2 (I intentionally use this version) and generated an API key. Afterwards, I'm trying to make a GET request via https://my.domain.net/community/api/1.0/user_friends?api_key_token=abcd1234&guid=4
but I'm always getting an empty response. Am I doing something wrong or did I forget something?
Thanks in advance.
That is: We can't use 'ü' in German translations. Good to know.
I finally found the error.
Apparently this is connected to a translation unit issue - probably because there is an ü
inside my ossnservices:success
translation. removing the German translation file and copying the English one to it solved the problem, which makes it quite clear that it must be an encoding problem.
Maybe someone else has this issue so this may help him as well.
That was too quick - it still doesn't work.
If I I miss out the &guid=
query parameter, I get a "user doesn't exist" message:
{
"merchant": "myCommunity",
"url": "https://my.net/work/",
"time_token": 1598556573,
"payload": false,
"code": "103",
"message": "Dieser Nutzer existiert nicht"
}
However, if I am adding the parameter e.g. &guid=4
to the URL, I am getting an empty response again.
WELL that was a really stupid error:
https://url.tld/api/1.0
should be https://url.tld/api/v1.0
.
it works.
Thanks a lot for your time and sorry for wasting it, Arsalan.
By the way, the code of the OssnServices class seems to be a bit faulty, at least inside the function genKey()
:
return hash('ripemd256', md5() . microtime() . rand(0, 2));
: the function md5()
doesn't return anything if it doesn't get any parameter parsed. that's a bit weird.
Arsalan,
I'm sorry, after some struggle setting up the OSSN installation (directory access right problems etc.) I didn't want to waste any more time setting up an installation I don't even need so I will have to go with the one I have now.
Just to make sure: does the OssnServices v6.2 work with OSSN v5.2?
Do I need to have private profiles turned off or do I need to have any special .htaccess or apache2.conf configuration set?
No worries. However, I don't really know what you mean by FTP or PHPMyAdmin details. I'm not using PHPMyAdmin for SQL and I don't really know what to send you for FTP details.
Tomorrow I want to try it with a fresh installation of OSSN to see if it works. maybe it's an issue with my apache2 config or htaccess?
I tried v6.2 and it worked fine for me.
Sorry i forgot to reply you. Maybe you can send ftp details and phpmyadmin details.
I didn't try it on a fresh install yet but I'll try it tomorrow.
what exactly do you need from the web hosting control panel? my web server is self-hosted. it's php-apache docker container running on an Ubuntu 20.04 server.
Due to the many requests in the past for additonal features and components we have decided to develope a premium version. Features like Hashtags, Videos, Polls, Events, Stories, Link Preview, etc included in it.
$199 (Life Time)