I am working on a project that uses a rust Netlify function and have enabled identity service on the project. I expected that using identity with functions would work similar in rust as it is in js and go (identity/user objects inside context.clientContext as described here, but it seems that the client_context passed to the rust handler function is empty even when “Authorization” header is set in the request.
In my http request to the function, I set the “Authorization” header with the jwt obtained from netlify identity widget.
When sending the same request to a function written in javascript, I am able to obtain the user from the context. So I believe the request is correct and the issue appears to be on the rust side.
This can be seen by creating the example/template rust netlify function (following guide here), logging the context passed to the handler, and making a request to the function with authorize header set with netlify identity widget jwt.
Any guidance as to how to use identity with a function in rust would be appreciated. I understand rust support is still experimental, so perhaps this is something that hasn’t been fully implemented yet?