Flowable and Swagger

How come I can’t see Swagger’s controllers in swagger UI ?
I’ve created a simple spring-boot 2.0.2 app. These are the relevant parts in my pom.xml :

	<relativePath/> <!-- lookup parent from repository -->


	<!-- Spring Boot -->

           <!-- Flowable -->

	<!-- Swagger -->		

And I have the following class:
public class SwaggerConfig {



Sorry for the late reply.

The Flowable REST API is not registered as part of the root context. Each engine registers a custom servlet with a custom configuration. Have a look at RestApiAutoConfiguration. I suppose that you somehow need to extend those configurations and hook in the swagger config.

Have you had a look at the flowable-rest application? We also have a static swagger documentation that can be used.



As I know springfox will only pick the controllers that are registered components.
So you have to add
@ComponentScan(basePackages = “org.flowable.rest.service.api”)

and sample code:

@ComponentScan(basePackages = "org.flowable.rest.service.api")
public class SwaggerConfig extends WebMvcConfigurationSupport {

public Docket processApi() {
    return new Docket(DocumentationType.SWAGGER_2)

protected void addResourceHandlers(ResourceHandlerRegistry registry) {



The only drawback I see is that it will register Flowable REST APIs as part of the root context and also under /process-api, /app-api, etc. (all from RestApiAutoConfiguration)
But you can also exclude this autoconfiguration:
@SpringBootApplication(exclude = { RestApiAutoConfiguration.class })

I try something similar like @eran. But I use spring-boot-starter-parent in version 2.0.0.M3 and flowable 6.4.0 but I think its no difference to your configuration. I use nearly the same swagger configuration of @rgorzkowski post. But if I start my application I run into following error.
Field restResponseFactory in org.flowable.rest.service.api.history.HistoricActivityInstanceBaseResource required a bean of type ‘org.flowable.rest.service.api.RestResponseFactory’ that could not be found.
Consider defining a bean of type ‘org.flowable.rest.service.api.RestResponseFactory’ in your configuration.
For me it sounds like a problem in flowable-rest package. Or do you have a special hint for me.

Another question to @rgorzkowski. Is the extends of WebMvcConfigurationSupport necessary and what should it do.

@tanzmann - did you manage to get past this?

I’m getting the same error after configuring Swagger to scan for APIs in flowable code…
Same Spring boot with flowable-rest spring starter.


No, but I haven’t try it again.

Thanks for the reply.
Eventually we decided to run Flowable separate from the Spring Boot, and use the REST Api to control it.

Have a great day! :slight_smile:

Here is what I did to get the swagger ui working:

package io.avalia.experiments.flowable.simpleapp.config;

import com.fasterxml.jackson.databind.ObjectMapper;
import org.flowable.rest.service.api.RestResponseFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import springfox.documentation.builders.ApiInfoBuilder;
import springfox.documentation.service.ApiInfo;
import springfox.documentation.swagger2.annotations.EnableSwagger2;

@ComponentScan(basePackages = "org.flowable.rest.service.api")

public class SwaggerDocumentationConfig {

    protected ObjectMapper objectMapper;
    public RestResponseFactory restResponseFactory() {
        RestResponseFactory restResponseFactory = new RestResponseFactory(objectMapper);
        return restResponseFactory;

    ApiInfo apiInfo() {
        return new ApiInfoBuilder()
            .title("Flowable APIs")


refer to this code, it work.
think you!