You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One option is to change the field to object, so the user can pass a string or an object. Another option is to provide separate functions for submitting(for both methods).
Environment
Client-Version: Java, v0.7.6-alpha.7
Server-Version: v0.7.6-alpha.1
Are we missing something?
The text was updated successfully, but these errors were encountered:
This is a known issue with OpenAPI Generator (OpenAPITools/openapi-generator#417). If possible, switching from GSON to Jackson should resolve this issue, as Jackson has better polymorphism support (SubmitSelfServiceLoginFlowWithPasswordMethodBody will be generated as a subclass of SubmitSelfServiceRegistrationFlowBody. You can then create an instance of SubmitSelfServiceLoginFlowWithPasswordMethodBody and pass it into V0alpha1Api.submitSelfServiceRegistrationFlowWithHttpInfo(String, SubmitSelfServiceRegistrationFlowBody)).
Describe the bug
The method
V0alpha1Api.submitSelfServiceRegistrationFlowWithHttpInfo
needsSubmitSelfServiceRegistrationFlowBody
as parameter. Thetraits
field is a string, though the API reference says it should be object (at least for password method). We tried to json encode our traits object to pass it to the constructor. But it results in false body encoding and 400 response code. Here is the debug log of the ApiClient:As you can see it looks like, the server fails to decode
email
trait:Property email is missing.
To Reproduce
Steps to reproduce the behavior:
SubmitSelfServiceRegistrationFlowBody
with"password"
method and pass the traits object with email to the constructor.Expected behavior
There is
SubmitSelfServiceRegistrationFlowWithPasswordMethodBody
class, which seems to have right fields, but it can't be passed to the submit function.One option is to change the field to object, so the user can pass a string or an object. Another option is to provide separate functions for submitting(for both methods).
Environment
Are we missing something?
The text was updated successfully, but these errors were encountered: