ory / sdk

The place where ORY's SDKs are being auto-generated
Apache License 2.0
141 stars 85 forks source link

Ory Hydra Sdk for .Net throws 'subject' is null but the parameter has been provided (Accept login request) #212

Closed joearmonic closed 1 year ago

joearmonic commented 2 years ago

Preflight checklist

Describe the bug

I'm implementing a login page using Hydra for the OAuth process. This is the start of the method: public async Task<OAuthCompletedRequest> AcceptLoginRequestAsync(LoginAccept loginAccept) { var apiInstance = new AdminApi(_hydraConfiguration); var loginRequest = await apiInstance.AcceptLoginRequestAsync( loginAccept.LoginChallenge, new Ory.Hydra.Client.Model.HydraAcceptLoginRequest { Remember = loginAccept.RememberMe, Subject = loginAccept.UserId, RememberFor = 0 }, CancellationToken.None); (...)

I received this exception: image

The userId has content of course. We are using an email account in this case.

So I guess there may be a bug here. Any other library seem to not be as straighforward as this one, however, we have an MVP to acomplish and we are in a rush. Any help will be very well appreciated

B.R.

Reproducing the bug

After validated the credentials call 'AcceptLoginRequestAsync' and fullfilling all the parameters required by the method contract and there you have the error.

Relevant log output

No response

Relevant configuration

No response

Version

Latest

On which operating system are you observing this issue?

Windows

In which environment are you deploying?

No response

Additional Context

No response

vinckr commented 2 years ago

Hey, thanks for opening this report. I moved it to the ory/sdk repo, since that seems a better fit.