GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — CurrentUser does not match the current Logon payload 'requriesTwoFactorAuth' · Issue #1 · vrchatapi/vrchatapi-java

CurrentUser does not match the current Logon payload 'requriesTwoFactorAuth'  #1

New issue
Copy link
New issue
Copy link
Open
Open
CurrentUser does not match the current Logon payload 'requriesTwoFactorAuth' #1
Copy link

Description

@jlong23
jlong23
opened on Nov 3, 2023
Issue body actions

Version 1.15.0

java.lang.IllegalArgumentException: The field requiresTwoFactorAuth in the JSON string is not defined in the CurrentUser properties. JSON: {"requiresTwoFactorAuth":["emailOtp"]}
at io.github.vrchatapi.model.CurrentUser.validateJsonObject(CurrentUser.java:1810) ~[vrchatapi-java-1.15.0.jar:na]
at io.github.vrchatapi.model.CurrentUser$CustomTypeAdapterFactory$1.read(CurrentUser.java:1970) ~[vrchatapi-java-1.15.0.jar:na]
at io.github.vrchatapi.model.CurrentUser$CustomTypeAdapterFactory$1.read(CurrentUser.java:1960) ~[vrchatapi-java-1.15.0.jar:na]
at com.google.gson.TypeAdapter$1.read(TypeAdapter.java:204) ~[gson-2.10.1.jar:na]
at com.google.gson.Gson.fromJson(Gson.java:1227) ~[gson-2.10.1.jar:na]
at com.google.gson.Gson.fromJson(Gson.java:1137) ~[gson-2.10.1.jar:na]
at com.google.gson.Gson.fromJson(Gson.java:1047) ~[gson-2.10.1.jar:na]
at com.google.gson.Gson.fromJson(Gson.java:1014) ~[gson-2.10.1.jar:na]
at io.github.vrchatapi.JSON.deserialize(JSON.java:244) ~[vrchatapi-java-1.15.0.jar:na]
at io.github.vrchatapi.ApiClient.deserialize(ApiClient.java:851) ~[vrchatapi-java-1.15.0.jar:na]
at io.github.vrchatapi.ApiClient.handleResponse(ApiClient.java:1061) ~[vrchatapi-java-1.15.0.jar:na]
at io.github.vrchatapi.ApiClient.execute(ApiClient.java:985) ~[vrchatapi-java-1.15.0.jar:na]
at io.github.vrchatapi.api.AuthenticationApi.getCurrentUserWithHttpInfo(AuthenticationApi.java:453) ~[vrchatapi-java-1.15.0.jar:na]
at io.github.vrchatapi.api.AuthenticationApi.getCurrentUser(AuthenticationApi.java:434) ~[vrchatapi-java-1.15.0.jar:na]
at org.tfs.vrchat.api.client.VRChatAPIClient.login(VRChatAPIClient.java:56) ~[classes/:na]

Suspect that it needs a secondary call too for final Token Generation.

Activity

  1. ariesclark commented on Nov 5, 2023

    @ariesclark
    ariesclark
    on Nov 5, 2023
    Member
    More actions

    We're aware of this issue, but it's difficult to solve since many of our generators don't support the pattern that VRChat returns for this, needing to use oneOf in JSON Schema. You'll need to catch the error and handle it manually.

  2. denis-hik commented on Jan 21, 2025

    @denis-hik
    denis-hik
    on Jan 21, 2025
    More actions

    use
    User.openapiFields.add("requiresTwoFactorAuthв ")

    Other fields
    error java.lang.IllegalArgumentException: The field <key> in the JSON string is not defined in the <T> properties. JSON =>
    <T>.openapiFields.add(<key>)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.