Artículo: Toward Dependency-Aware API Gateways
Fecha
Editor
Publicado en
Licencia Creative Commons
Resumen
Web APIs often include inter-parameter dependencies that constrain how input parameters can be combined to form valid calls to the service. API requests violating one or more of these dependencies result in an unnecessary exchange of messages, causing a waste of time and user quota. Also, dependencies are often not correctly checked by the servers, resulting in critical failures or uninformative error responses. In this paper, we propose extending API gateways to support the detection and explanation of inter-parameter dependencies violations. To achieve this goal, we leveraged IDL4OAS, an OAS extension for describing the dependencies among input parameters in web APIs, and IDLReasoner, a constraint-based IDL reasoner. Both were integrated into a prototype tool using Spring Cloud Gateway. Preliminary evaluation results on five industrial API operations show that our approach can successfully detect and explain all invalid requests, reducing the response time by around 80.31% and minimizing potential input validation failures.