working on PDO implementation on API