Answer the question
In order to leave comments, you need to log in
How to work with third party api?
I use symfony, and when writing another connection to the X service api, the question arose whether I was doing it right. Are there any rules for organizing an application working through the api side? Now I am writing requests to the api in the controller..
Answer the question
In order to leave comments, you need to log in
Make a service. In it, refer to this api or to your stub for the duration of testing. In the same place you can transform the data if they are clumsy. Error handling can be both taken out above and extinguished in place by sending a message to the logs and an empty object to call
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question