Openfire UserService plugin redirects me to admin login

When I make a request from an HTTP client or from my browser directly, exactly like the instructions for adding a user show:

http://example.com:9090/plugins/userService/userservice?type=add&secret=bigsecre t&username=kafka&password=drowssap&name=franz&email=franz@kafka.com

I am just redirected to the admin login page. I have the sercret key enabled and include it in my request. If I log in to the admin console and get a session, then from a web browser I can make the request. How do I overcome this?