I have an existing application using Codeigniter Framework (MVC). I need to implement an integration in the software with the external cash register (e.g., making REST API calls). I need to either make a controller or a model (or both), but I don't fully understand which.
The functions within the class will be doing the various business logic of making calls to other model functions to retrieve appropriate data, format the JSON, send it and process the response from the API. This makes me think that I should be making a controller because it does no database calls itself. The thing that is making me doubt is that there is no need for an associated view and that while it's not doing IO operations with the database, it is doing IO operations with the API.
Should I make this a controller and only additionally create a model if there are database IO functions specific to this integration? Or should I also have a model and put specific API IO functions in it (e.g., sendData(), etc)?