ummobile_sdk 0.0.3 copy "ummobile_sdk: ^0.0.3" to clipboard
ummobile_sdk: ^0.0.3 copied to clipboard

outdated

The SDK package used in the UMMobile App to connect with the server.

SDK to connect to the UMMobile API

Test codecov

Getting Started #

This package was made for the UMMobile app.

Initialization #

To initialize a new instance a token is needed.

UMMobileSDK sdk = UMMobileSDK(token: 'YOUR_TOKEN');

Auth #

To get a token you can use the static function UMMobileSDK.auth() that returns the API section for the authentication.

// Get token
Token token = await UMMobileSDK
  .auth()
  .getToken(username: 1234567, password: 'YOUR_PASSWORD');

// Initialize using the access token
UMMobileSDK sdk = UMMobileSDK(token: token.accessToken);

Sections #

The UMMobileSDK contains an attribute for each API section.

  • user: contains the functions to get the user information.
  • academic: contains the functions to get the academic information.
  • financial: contains the functions to get the financial information.
  • notifications: contains the functions to get the notifications information.
  • questionnaire: contains the functions to get the questionnaire information.
    • covid: contains the functions to get the COVID questionnaire information.
  • catalogue: contains the functions to get the general information.
  • communication: contains the functions to get the information from Conéctate.

Individual vs Main class #

Each section can be found in an attribute of the main class, but can also be used individually.

// Individual class
UMMobileUser user = UMMobileUser(token: 'YOUT_TOKEN');
await user.getInformation();

// Main class
UMMobileSDK sdk = UMMobileSDK(token: 'YOUR_TOKEN');
await sdk.user.getInformation();
1
likes
0
pub points
0%
popularity

Publisher

unverified uploader

The SDK package used in the UMMobile App to connect with the server.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, ummobile_custom_http

More

Packages that depend on ummobile_sdk