Can we set timeout on lock creation/acquisition?

Scenario: I need to acquire locks for a session. Currently I do this and I set a timeout in curl of 5s.
There is an issue with this as Consul will still acquire the lock eventually e.g. after 6s, and I then have a disjointed view of which keys I have acquired.

I see in the CLI there is a -timeout option, that cancels acquisition after the specified timeout. How can I achieve this behaviour through the HTTP API?

Bumping this. Is this possible?