Feature #8900


Restful Web service: generate WADL

Added by Nicolay Punin almost 13 years ago. Updated over 12 years ago.

Target version:
Start date:
Due date:
% Done:


Estimated time:


Redmine does not generate WADL for his Web Service

It helps to generate Java Rest clients automaticaly.


Some QA:

Actions #1

Updated by Jean-Baptiste Barth almost 13 years ago

Nicolay Punin wrote:

It helps to generate Java Rest clients automaticaly.

And it will probably be a bunch of work to maintain it ... manually, no ? Have you tried to generated such an XML description of the Redmine current API, and can you give us some points to convince us to introduce it ?

Maintaining it in a plugin could be a viable option too...

Actions #2

Updated by Nicolay Punin almost 13 years ago

1. No manaualy. Wadl generator library helps you. For example,
2. It will increase the attractiveness for java developers.
3. I do not want to use this( library.

  • It supports only 1.2.0. Not 1.3
  • It is a bike :(

4. I am work with redmine Rest API by means of Spring rest template (
At least 90% of my code can be automatically Generate by WADL parser. It is very convenient
5. This will be useful for the community.
6. This may be used in java IDE (Eclipse/RubyMine/Idea/Netbeans,etc.)

Maintaining it in a plugin could be a viable option too...

I writed already the plugin for me. It can show or modify project roles and status.
Maybe I'll write a WADL redmine plugin. If I will have a time :)

Something information:

Actions #3

Updated by Terence Mill almost 13 years ago


Actions #4

Updated by Siegfried Vogel over 12 years ago


Would be very helpful to detect and test Redmine RESTful API.

Actions #5

Updated by laurent sauvage over 12 years ago


Actions #6

Updated by Alex Last over 12 years ago

Redmine Java API supports Redmine 1.3.0

Actions #7

Updated by Alex Last over 12 years ago

Would be just great to generate the client code using some definition file. Until then, you're welcome to use (and improve!) the custom-made Redmine Java API.

Actions #8

Updated by Nicolay Punin over 12 years ago

Redmine Java API is not suitable for my case, because in my redmine installation I have plugins enhancing default REST functionality.
I wrote my own Java client using Sping Rest Template( link: and JAXB to write less code.

Here is the idea:
Describing entity, for example - a project

9 @XmlRootElement
10 @XmlType( propOrder={ "name", "identifier", "description", "homepage", "status", "public", "roles", "customFields" , "createdOn", "updatedOn"} )
11 public class Project {
13 final public static int STATUS_ACTIVE = 1;
14 final public static int STATUS_ARCHIVE = 9;
16 private String name;
17 private String homepage;
18 private String identifier;
19 private String description;
20 private boolean is_public;
21 private int status;
22 private List<Role> roles;
23 private List<CustomField> customFields;
24 private String createdOn;
25 private String updatedOn;
26 /// etc....

In the same way describing entities Role and CustomField.
Projects list is described simply:
9 @XmlRootElement
10 @XmlSeeAlso({Project.class})
11 public class Projects extends ArrayList<Project> {
13 @XmlElement(name = "project")
14 public List<Project> getProjects() {
15 return this;
16 }
17 }

Instead of standard Redmine API, in my case it is possible to manage project roles and project status (archive/active)

All other job is done by Spring Rest Template, for example this is how we can get projects list:
Map<String, String> vars = new HashMap<String, String>();
69 vars.put("offset", "0");
70 vars.put("limit", "10");
71 Projects projects = restTemplate.getForObject("{offset}&limit={limit}", Projects.class, vars);
72 return projects.getProjects();

Updating project:
String identifier = project.getIdentifier();
restTemplate.put("{identifier}.xml", project, identifier);

And so on for every redmine entity. Of course, this code is placed in separate class and covered with junit tests.

It would be great to generate this boilerplate code automatically.


Also available in: Atom PDF