I currently have two simple microservices one that returns a true or false and one that returns a string.
I need to be able to connect to the first microservice that returns a status of true or false in the header. If it returns false, then apigee needs to return an error and stop the execution. If it returns true, then it needs to send that response to the second microservice and allow the user to hit the second microservice.
I’ve looked online at the best solution for this and i’ve seen the ServiceCallout Policy is the best way of doing this task. But im not sure how i would implement this using this policy.
Setting your first microservice as a proxy target endpoint, and having your second microservice invoked by a service callout in the proxy post flow (ie after the target endpoint).
Otherwise, you could use two different Service Callout Policies - one for each microservice.
Not sure I quite understand your question. It shouldnt matter how many proxies need to hit your first microservice. But it sounds like it might be a reusable scenario that might be better suited to a service callout in a shared flow that’s reused across multiple proxies?