Skip to content

eh_GJUsersAuthRequest

Daniel Queiroz Porto edited this page Sep 17, 2020 · 1 revision

Inherits: eh_GJBaseRequest > HTTPRequest > Node > Object

Description

This class decribes the Auth api endpoint. It's response is modeled in the custom resource of eh_GJUsersAuthData.

It's a simple class to help with login in the user, but should be the first thing the game does or check for.

If the request fails, the signal gj_request_failed will be emitted with an error dict as its parameter.

Methods

return type method signature
int auth_user_credentials(String p_username, String p_user_token)

Signals

  • gj_auth_data_received(eh_gj_users_auth_data)

Signal sent with Auth Data response. Sends the eh_GJUsersAuthData resource as paremeter.


Constants

  • URL_ENDPOINT = /users/auth/ --- Address for this endpoint.

Method Descriptions

auth_user_credentials

Builds url and send request to the auth Endpoint. Return an int which is the request error code.