Trying to get a 'count' but Backendless encountered an error while handling the request.

I am getting a count on the number of occurances a licence key appears in my leaderboard database. It seemed to work for a while, but now when I run the count I get an error…


"message": "Backendless encountered an error while handling the request. An internal trouble ticket with ID F10845E0-E512-9A7E-FFE9-D5AFDA044100 has been created and we will be investigating the issue."

Previosuly this correctly returned an interger value (number of entries) so I’m not quite sure what started to happen.

The same error happens both in my app and in the REST console. The code i use to get these entries is as follows:

https://api.backendless.com/'.$APP_ID.'/'.$SECRET_KEY.'/data/Leaderboard_'.$GAME_ID.'/count?where=licenseKey%3D'.$USER_LICENSE

As I said, previously this just returned an int which was great but now I dont know whats going on…

Help.
Thanks

Hi Simon,

Could you please provide a complete sample REST request?

Here it is:

https://api.backendless.com/6FB0797D-AFB7-3B57-FFAB-BCEABA9E4500/E9F61682-4EC7-77CD-FFB6-89023DED4B00/data/Leaderboard_Game01/count?where=licenseKey%3DD18A2108-CF8A4C44-939E68DD-70E5E1A0

You should enclose string values into single quotes like ‘value’.

Here is the proper request:
https://api.backendless.com/6FB0797D-AFB7-3B57-FFAB-BCEABA9E4500/E9F61682-4EC7-77CD-FFB6-89023DED4B00/data/Leaderboard_Game01/count?where=licenseKey%3D'D18A2108-CF8A4C44-939E68DD-70E5E1A0'

Thanks. This seems to work in the REST console but in my php request I get: The server does not support the HTTP protocol version used in the request.

Any idea?

Ah…looks like there is a space in my license key when my app submits it. That’s the issue. Will need to make sure its trimmed. Many Thanks!!