Skip to Content
Technical Articles
Author's profile photo Lars Hvam

ABAP OpenAPI Client Generation in ABAP

The OpenAPI specification is a way to formally describe the services exposed by REST endpoints. To enforce design by contract(APIs), the specification is typically automatically turned into code in the client system, so the boring parts are hidden from the application developer, and the syntax checker can help to remind the developer when the contract is changed.

This client generation has long been a missing part in the ABAP ecosystem, and I’m happy to announce abap-openapi-client which is an open source OpenAPI client generator in ABAP 🙂



Both the code generation and the actual client code is ABAP. The code generation could have been in a different language, but to encourage ABAP developers to help with the ABAP generation, I find it important to have the generation in the same language.

Much of the code is just simple concatenation, which all(?) ABAP developers can help to evolve,

LOOP AT ms_specification-operations INTO ls_operation WHERE deprecated = abap_false.
  rv_abap = rv_abap &&
    |  METHOD { ms_input-interface_name }~{ ls_operation-abap_name }.\n| &&
    operation_implementation( ls_operation ) &&
    |  ENDMETHOD.\n\n|.


Another feature is to run the client generation in the browser! I.e. the client generation code does not require installation into an ABAP system to run,

This works by transpiling the ABAP code to JavaScript.


CI/CD Setup

The code is hosted on GitHub, and employs a full Continuous Integration setup, each change triggers static analysis via abaplint, and unit tests are run via the transpiler, this will help to make safe changes in the codebase.

As a Continous Delivery example, GitHub provides specifications for all its endpoints, and the generated ABAP client code is automatically updated daily at


Open Source

The code is open source under the MIT license. Expect bugs as multiple OpenAPI parts are not implemented yet, and ABAP is a funky language 🙂 With the CI setup, it can all be fixed, one bug at a time.

Bug reports/comments/feature requests welcome on

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Marco Hammel
      Marco Hammel

      Cool Stuff Lars Hvam !!

      Author's profile photo Philipp Dölker
      Philipp Dölker

      Nice One!

      Author's profile photo Christian Sasse
      Christian Sasse

      Hey Lars Hvam

      i just started work on the same while researching something, i stumbled over your post here. What an amazing and valuable contribution!

      Especially the Web Client is absolutely genius!


      Author's profile photo Lars Hvam
      Lars Hvam
      Blog Post Author

      still lots of work, but its a testable, easy to run setup