I need to create an API so an external client can perform actions on my custom extensions database table.
What would be the right approach?
- Should I use https://api.joomla.org/cms-3/ for this? How?! I did not find any examples.
- Put the API in a separate directory (for example /api/) and include the Joomla framework into my php?
- Or create a MVC extension, for example com_myapi?
- Should I use REST or any other method?
- Would com_api be a good start? (https://github.com/techjoomla/com_api) Did not find any documentation however…
The external client should be able to:
PUT - Modify an existing object on the server
POST - Create a new object on the server
DELETE - Remove an object on the server
I should then return a response (ok, or a specific error). JSON?
OR…. Am I overlooking some obvious other great solution?
Any suggestion is welcome!