API-KEY is working (stripping for whitespace \n), API reworked to MYSQLI

Signed-off-by: goal101 <mark.kuhre@gmail.com>