Codenia interview question

How to create api in php ?