Surveillance station API: Unable to get the sid

This forum is for devlopers to discuss questions about apps/plug-ins/extension modules/API specifically developed for using with Synology DiskStations.
I'm New!
I'm New!
Posts: 1
Joined: Fri Aug 11, 2017 9:36 pm

Surveillance station API: Unable to get the sid

Postby domoos » Fri Aug 11, 2017 9:43 pm

Good evening,

First off, I do hope that I am posting this message in the correct forum. Please excuse me if not as I'm quite a newbie :)

I'm trying to use the API that Synology has kindly provided. I looked at the documentation and trying first off to login :

What I wrote so far is :

Code: Select all


$local_file = "test.txt";

$ch = curl_init();
$fp = fopen ($local_file, 'w+');
curl_setopt($ch, CURLOPT_COOKIEJAR, "/debug/SS-session_cookie");
curl_setopt($ch, CURLOPT_FILE, $fp);
curl_setopt($ch, CURLOPT_URL,"");
$resp = curl_exec ($ch);
curl_close ($ch);


However, if I look at the generated file (test.txt), I only get the following :


Same if I copy and paste the url : {"success":true}

Any idea what I'm missing and why I don't get the sid ? (I'm sure about my user/password ;-))

Many thanks for your help and best wishes.

Return to “Developer Discussion Room”

Who is online

Users browsing this forum: No registered users and 2 guests