HaProxy server timeout based on Relative path

Hey there,
How can i implement a ACL for a specific API path (/api-test) to have a server timeout value, so Global server timeout is 3s and i need to add backend timeout for 5 min only for a specific path. (all other request except /api-test should have the 3s server timeout ?



Maybe you can set an acl for this path to use a specific backend with specific timeout.

Something like (not tested) :

frontent web
  bind *:80
  acl api path_beg /api-test
  use_backend api_be if be
  default_backend web
backend web
  timeout server 5m
  server myserver
backend api_be
  timeout server 3s
  server myapiserver