2024-12-172024-12-172023Barakat, S., Sánchez Jerez, A.B. y Segura Rueda, S. (2023). IDLGen: Automated Code Generation for Inter-parameter Dependencies in Web APIs. En 21st International Conference, ICSOC 2023. Lecture Notes in Computer Science . Vol. 14419 LNCS (153-168), Roma, Italia: Springer.978-3-031-48420-90302-97431611-3349https://hdl.handle.net/11441/165860The generation of code templates from web API specifications is a common practice in industry. However, existing tools neglect the dependencies among input parameters (so-called inter-parameter dependencies), extremely common in practice and usually described in natural language. As a result, developers are responsible for implementing the corresponding validation logic manually, a tedious and errorprone process. In this paper, we present IDLGen, an approach for the automated generation of validation code for inter-parameter dependencies in web APIs. Specifically, we exploit the IDL4OAS extension for specifying inter-parameter dependencies as a part of OpenAPI Specification (OAS) files. To make our approach applicable in practice, we present an extension of the popular OpenAPI Generator tool ecosystem, automating the generation of Java and Python code for the management of inter-parameter dependencies in web APIs. Evaluation results show the effectiveness of the approach in accelerating the development of APIs, generating up to 9.4 times more lines of Java code than the current generator. This leads to average time savings ranging from 16 to 24 min when implementing API operations including between one and three dependencies, when compared to manual coding. More importantly, the generated code mitigates human errors, making web APIs significantly more reliable.application/pdf16 p.engWeb APIsOpen API and ScaffoldingCode generationIDLGen: Automated Code Generation for Inter-parameter Dependencies in Web APIsinfo:eu-repo/semantics/conferenceObjectinfo:eu-repo/semantics/openAccess10.1007/978-3-031-48421-6_11