I'm busy getting my software to talk to the webservice of JasperServer. I would like to run a simple report, but it does not work, and I tried a lot!
Using the default user/password on a test install of JasperServer 5.2 (Cummunity Edition) on a Windows 2008 Server using the default setting of a 64 bit Windows installer
Here is wat I do:
1. I log in with a GET request on http://22.214.171.124:8080/jasperserver/rest/login?j_username=jasperadmin...
I got a 200 result with a cookie in the headers and I remember that for future use.
2. I ask for a list of reports with a GET request (with the previously received cookie in the headers) on http://126.96.36.199:8080/jasperserver/rest/resources/reports?type=repor...
I got a 200 result with a wonderfull xml in the body, containing a list of resourceDescriptors with reports. I fill a list with the name, label, description and uriString, so I can select one to run.
3. I select a very simple report. This reports contains only 3 fields. No parameters, vars, images or anything like that. When I log in to JasperServer with my browser (with the same credentials), the reports runs fine. Its one page which contains about 20 records. according to the previously received xml, the uriString of this report is /reports/Kassas.
4. The easiest way to get a pdf of that report using the webservice should be a rest_v2 call. So I do a GET request (with the cookie set in the headers) on http://188.8.131.52:8080/jasperserver/rest_v2/report/reports/Kassas.pdf
Now I get a 404 Not Found reponse. And that is where I need some help.
I played with the extension (for format selection), an alternative resource path, which gave me a 'resource not found' error.
The user has an admin role.
I am out of options. Please tell me what I do wrong. I got two days left before my manager wants to decide if we continue with JasperServer.
Thank you for your valuable time!
Hi. I hope you still use Jasper?
Well, I did not try it since we do not need the server but what I can think of is that the v2 url is a separate webapp and therefore needs it's own login? Maybe you solve it by using all your url's in the v2 style.