Add queues from script

Hi!
Trying to write a script that will create the queue. (send data to Freepbx need from another server) Nothing happens. I try to transfer data using method ‘post’. In short, should look like this:

Returns an error Forbidden
You don’t have permission to access /admin/modules/page.queues.php on this server.
What am I doing wrong?

Without knowing what you are doing it would be difficult to say what you are doing wrong. If I had to take a stab in the dark I would say you aren’t handling cookies.

Actually I just hard to write in English)

I’m trying to create a queue through the script and pass data with method=‘post’ script ‘page.queues.php’

And I can not understand what parameters I do not consider. I pass “account” and “name”. When you create a queue in FreePBX, these data are sufficient.

But in my case, the script returns an error ‘Forbidden
You don’t have permission to access /admin/modules/page.queues.php on this server.’

You say about handling cookies, can you tell details, please?

Thank you! You were right about handling cookies.