API Response

Response codes

Every response included a response code. Possible response codes are:

200 OK The requests was succesfully completed. The response body includes the requested data
400 Bad Request The parameters were incorrect
404 Not Found The requested information was not found. For example when searching for a non-existent verse
500 Internal Server Error There's been a error on our side. Hopefully this error will not appear!

HTTP GET

Succesfull response

The basic syntax of a succesfull response is:

{
	success : true,
	status : 200,
	response : 
	{
		chapter : 1
		verse : 1
		text: "Na prinsipio Dios a krea e shelunan i tera."
	}
}

As you can see, the book and part (old/new) is not included. The next version of the API will include these two variables however

The encoding of the bible text is UTF-8

Unsuccesfull response

A response can fail for a variety of reasons. The syntax when a response is failed is:

{
	success : false,
	status : 404,
	error : 
	{
		description: "Bible text not found."
	}
}