38

I have a web application providing more than 30 REST services (using Jersey) to clients. Is it possible to automatically create a WADL document for my application?

I need this, so that I can have it configured in SoapUI for testing various scenarios and save it for later use.

Vasil Lukach
  • 3,658
  • 3
  • 31
  • 40
basiljames
  • 4,777
  • 4
  • 24
  • 41

3 Answers3

25

If you are using Jersey then url to wadl would be something like

http://localhost:8080/applicationname/application.wadl

You may need to add the resource base into the url e.g.

http://localhost:8080/applicationname/resources/application.wadl

BillRobertson42
  • 12,602
  • 4
  • 40
  • 57
  • 6
    In jersy who will create this WADL, if it is automatically generated then what environment and API needed for this ? – Atul Kumar Sep 21 '15 at 05:23
  • I think it needs to be specified as a parameter to your build system (e.g. in the pom.xml file for Maven). https://stackoverflow.com/a/14742322/714112 – Sridhar Sarnobat Jul 12 '17 at 21:30
9
http://{host}:{port}/{context_root}/{resource}/application.wadl 

substitute values for host, port, context root and resource.

dur
  • 15,689
  • 25
  • 79
  • 125
user991802
  • 351
  • 3
  • 3
7

In the past I've used Enunciate (GitHub repository).

It's a build-time tool that generates Interface Definition Documents (WADL, WSDL, etc) automatically for you. It's really easy to integrate it in your Maven build.

Steffen Opel
  • 63,899
  • 11
  • 192
  • 211
Manuel Palacio
  • 306
  • 3
  • 6
  • Yes, and it also integrates with Spring which separate well the processing layer (@Service) from the exposition layer (REST, SOAP). The enunciate documentation of the service is very well generated. – рüффп Aug 30 '13 at 12:44
  • 4
    The codehaus link is dead. The code is on GitHub https://github.com/stoicflame/enunciate and it links to the site http://enunciate.webcohesion.com/ – Gonfi den Tschal Nov 09 '15 at 14:19