I work as a developer on a few different APIs that make calls to each other.
Let's take two and call them API-USER
and API-BUSINESS
.
A user application makes calls to API-USER
, which in turn makes calls to API-BUSINESS
Right now, when API-BUSINESS
returns an error the API-USER
receives it as a generic error and passes it through to the user.
The concern is that this approach could lead to issues when breaking changes are introduced to the errors in API-BUSINESS
.
Are there some API patterns or practices that can lead to a more durable approach to passing errors between APIs?
Is there a better vocabulary to use when talking about this type of error passing?