add publish-request middleware