This article will automatically build a full REST WS client from a OpenAPI (former swagger) spec file.
There are 2 sub pages depending on the Maven plugin being used for generating the Java code:
openapi-generator-maven-plugin
swagger-codegen-maven-plugin