In creating my Github repositories to begin coding, I've realized I don't understand the distinction between the front-end back-end, and the API. Another way of phrasing my question is: where does the API come into this picture?
I'm going to list some more details and then questions I have - hopefully this gives you guys a better idea of what my actual question is, because I'm so confused that I don't know the specific question to ask.
Some more details:
- I'd like to try the Model-View-Controller pattern. I don't know if this changes the question/answer.
- The API will be RESTful
- I'd like my back-end to use my own API instead of allowing the back-end to cheat and call special queries. I think this style is more consistent.
- Does the front-end call the back-end which calls the API? Or does the front-end just call the API instead of calling the back-end?
- Does the back-end just execute an API and the API returns control to the back-end (where the back-end acts as the ultimate controller, delegating tasks)?
Long and detailed answers explaining the role of the API alongside the front-end back-end are encouraged. If the answer depends on the model of programming (models other than the Model-View-Controller pattern), please describe these other ways of thinking of the API. Thanks. I'm very confused.