Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

exception handled by API. message: "" #4

Open
soffi opened this issue Oct 19, 2012 · 2 comments
Open

exception handled by API. message: "" #4

soffi opened this issue Oct 19, 2012 · 2 comments

Comments

@soffi
Copy link

soffi commented Oct 19, 2012

Hi, I'm having trouble talking to the API with curl (both commandline and in php) and with wget

Every request I make throws this into my error_log

exception handled by API. message: ""

but using a browser works just great! :)

any idea how I should form my requests with curl?

@supine
Copy link

supine commented Nov 8, 2012

Can you give an example of the curl command you are running, in particular the headers you are setting in the request?

@biffhero
Copy link

I cannot use this via the command line with wget / curl, or via firefox or chrome.

Here is the URL that I am using:

http://racktables/racktables/api.php?method=get_status

Here are the messages in my *_log files:

==> /var/log/httpd/access_log <==
a.b.c.d - - [25/Nov/2012:06:29:11 +0000] "GET /racktables/api.php?method=get_status HTTP/1.1" 500 - "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_4) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11"

==> /var/log/httpd/error_log <==
[Sun Nov 25 06:29:11 2012] [error] [client a.b.c.d] exception handled by API. message: "" request URI: /racktables/api.php?method=get_status
[Sun Nov 25 06:29:11 2012] [error] [client a.b.c.d] PHP Notice: Use of undefined constant JSON_FORCE_OBJECT - assumed 'JSON_FORCE_OBJECT' in /var/www/html/racktables/api.php on line 924
[Sun Nov 25 06:29:11 2012] [error] [client a.b.c.d] PHP Warning: json_encode() expects exactly 1 parameter, 2 given in /var/www/html/racktables/api.php on line 924

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants