If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

New PHP API for command line interface

Hi (my first post),

I have created a PHP API for the command line interface of the SqueezeCenter.

So if there are any budding PHP coders out there wanting to get their hands dirty and play around with their SqueezeCenter and Players, go check it out. It also would be really cool to get some feedback.

I hope you like it.

Oh link coming in second post.. it seems I am not allowed. makes sense.

I am not familiar with those tools, however I am guessing the PHP API is not going to work directly for you unless you create some sort of external interface to it. The PHP API is just working at the lowest level to the CLI. I can see it working as a proxy between the Squeezecenter/connected players and say a website. If you wanted to handle POST/GET requests say from a web browser you would need to code that. How you do that in PHP would be up to you. The SqueezePHPAPI just makes it easier for the PHP coder to not have to worry about dealing with CLI side of things.

..security related

oh..
and just while i think about it,
(this may be obvious for some)

On a security level, it should be generally noted that connecting to the CLI is generally NOT secure, unless it is in a separated trusted network, OR you use a secure tunnel to it somehow, say with SSH. So I would suggest if you wanted to work with remote (over the internet) SqueezeCenter servers via CLI and the PHP API, make sure you lock the connections down another way, do not rely on the SqueezeCenter authentication method. I sniffed my network and I saw my authentication password in the tubes!