Standard Errors

In this reference page, we explain how you should interpret error messages and what do they mean.

Endpoint specific

Many of our API endpoints have specific errors that will be displayed in the approved format. However, there are general errors that every api endpoint could produce in the cases where something in your call does not satisfy the requirements. To get better understanding of the requirements you need to read the detailed specification of each endpoint.

Standard errors

Bellow we are listing all possible standard errors that you can get from any script in the api services. We have showed examples in different response formats for more clarity. All error messages are available in all formats. The error format depends on what response format you have chosen. You can read more for choosing a response format in our request making reference page.

Missing API key

in order to verify you in our api endpoints we use the api key and api secret that you create in your profile within our website. In the case where you forget to provide it in the HTTP GET request as a url parameter you will get the following error message with the following http response code. This example is in XML format, but is available in all other formats as well.
HTTP: 400<xml>
<error>
<success>false</success>
<error>You must provide an API key. You must use a GET parameter "key"</error>
</error>
</xml>

Missing API secret

If you have provided your api key, bur for some reason you have not provided your api secret. You will get the following http error code with the following response in the format you have chosen. Notice that if you have provided your api secret but not your api key, you will get the previous error message. This example is in JSON format, but is available in all other formats as well.
HTTP: 400{
"success":false,
"error":"You must provide an API secret. You must use a GET parameter \"secret\""
}

Invalid API key and secret combination

You will receive this error if you have provided both of your api key and api secret, but their combination is not correct. We use the key and the secret together so a person having possession of only one of them cannot access our services and therefore steal from your hourly quota. This example is in CSV format, but is available in all other formats as well.
HTTP: 401success,error
false,The provided API key and secret pair are invalid. You can get them from your profile in http://livescore-api.com

No subscription

In order to use our api services, you have to subscribe. If you are a new user and you have never subscribed before this is the error message you are going to get from the response. This example is in XML format, but is available in all other formats as well.
HTTP: 402<xml>
<error>
<success>false</success>
<error>To use our services you must first subscribe. You can do that from your profile in http://livescore-api.com
</error>
</error>
</xml>

Expired subscription

In the case where you have been subscribed for our services before, but now you subscription has expired you will receive the error bellow. You can fix it by signing up once again for the next month. This example is in JSON format, but is available in all other formats as well.
HTTP: 402{
"success":false,
"error":"Your subscription has expired. You can renew it from your profile in http:\/\/livescore-api.com"
}

Wrong response format

With our services you can choose the format in which you can get the response from JSON, CSV, XML, and RSS. You choose it in the url that you are calling. You can find out more about this on our formats dedicated page. This error message is only available in JSON, as this is the default format that we have adopted. In the cases where the format chosen by you is not supported you will get messages in JSON.
HTTP: 500{
"success":false,
"error":"Invalid response format provided"
}

Missing api endpoint contoller or module

When you make a request to our services you provide a module and a controller. You can read more about making an API request here. If for some reason you have not provided a module or a controller you will get the error message bellow. This response is also only available in JSON, because if the request URL is bad we cannot parse it to find the format that you ask for.
HTTP: 400{
"success":false,
"error":"You must specify both module and controller"
}

Invalid module

If everything is good with the format of your request, but you have provided a bad module name. You can read more about request URL format here. Then you will receive the following error message. This example response is in CSV, but it is available in all other formats as well.
HTTP: 400success,error
false,Invalid module specified

Invalid controller

If everything is good with the format of your request and you have provided an existing module name, but you have provided a bad controller name. You can read more about request URL format here. Then you will receive the following error message. This example response is in XML, but it is available in all other formats as well.
HTTP: 400<xml>
<error>
<success>false</success>
<error>Invalid controller specified</error>
</error>
</xml>

Invalid module and or controller

If everything is good with the format of your request and you have provided both a valid module and controller names, but for some reason the combination of the two does not exists you will get the error message from bellow. You can read more on the request URL format here. This example response is in JSON, but it is available in all other formats as well.
HTTP: 400{
"success":false,
"error":"Invalid module/controller specified"
}

Invalid endpoint

In the case where the module and controller combination exists, but there has been some error on our side with configuring the endpoint, you will get the error message from bellow. If this occurs to you, we urge you to contact us immediately so we can fix this. This example response is in XML, but it is available in all other formats as well.
HTTP: 500<xml>
<error>
<success>false</success>
<error>
Path does not have configured method.
</error>
</error>
</xml>

Invalid HTTP method

All of our API endpoints accept HTTP GET calls, but in the future, we might start having available other methods as well. Therefore, in case you have made a request with the wrong HTTP method which is not supported by the endpoint you have chosen you will get the error message from bellow. You can read more on the making an API request here. If this happens to you the placeholder will be replaced by the method you used to make the request. For example, post. This example response is in CSV, but it is available in all other formats as well.
HTTP: 501success,error
false,Specified controller does not support <method>