import 'package:mosquito_alert/api.dart';
All URIs are relative to https://api.mosquitoalert.com/v1
Method | HTTP request | Description |
---|---|---|
changePassword | POST /auth/password/change/ | |
obtainToken | POST /auth/token/ | |
refreshToken | POST /auth/token/refresh/ | |
signupGuest | POST /auth/signup/guest/ | |
verifyToken | POST /auth/token/verify/ |
changePassword(passwordChangeRequest)
import 'package:mosquito_alert/api.dart';
final api = MosquitoAlert().getAuthApi();
final PasswordChangeRequest passwordChangeRequest = ; // PasswordChangeRequest |
try {
api.changePassword(passwordChangeRequest);
} catch on DioException (e) {
print('Exception when calling AuthApi->changePassword: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
passwordChangeRequest | PasswordChangeRequest |
void (empty response body)
- Content-Type: application/json, application/x-www-form-urlencoded, multipart/form-data
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
AppUserTokenObtainPair obtainToken(appUserTokenObtainPairRequest)
Takes a set of user credentials and returns an access and refresh JSON web token pair to prove the authentication of those credentials.
import 'package:mosquito_alert/api.dart';
final api = MosquitoAlert().getAuthApi();
final AppUserTokenObtainPairRequest appUserTokenObtainPairRequest = ; // AppUserTokenObtainPairRequest |
try {
final response = api.obtainToken(appUserTokenObtainPairRequest);
print(response);
} catch on DioException (e) {
print('Exception when calling AuthApi->obtainToken: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
appUserTokenObtainPairRequest | AppUserTokenObtainPairRequest |
No authorization required
- Content-Type: application/json, application/x-www-form-urlencoded, multipart/form-data
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TokenRefresh refreshToken(tokenRefreshRequest)
Takes a refresh type JSON web token and returns an access type JSON web token if the refresh token is valid.
import 'package:mosquito_alert/api.dart';
final api = MosquitoAlert().getAuthApi();
final TokenRefreshRequest tokenRefreshRequest = ; // TokenRefreshRequest |
try {
final response = api.refreshToken(tokenRefreshRequest);
print(response);
} catch on DioException (e) {
print('Exception when calling AuthApi->refreshToken: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
tokenRefreshRequest | TokenRefreshRequest |
No authorization required
- Content-Type: application/json, application/x-www-form-urlencoded, multipart/form-data
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
GuestRegistration signupGuest(guestRegistrationRequest)
import 'package:mosquito_alert/api.dart';
final api = MosquitoAlert().getAuthApi();
final GuestRegistrationRequest guestRegistrationRequest = ; // GuestRegistrationRequest |
try {
final response = api.signupGuest(guestRegistrationRequest);
print(response);
} catch on DioException (e) {
print('Exception when calling AuthApi->signupGuest: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
guestRegistrationRequest | GuestRegistrationRequest |
No authorization required
- Content-Type: application/json, application/x-www-form-urlencoded, multipart/form-data
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
verifyToken(tokenVerifyRequest)
Takes a token and indicates if it is valid. This view provides no information about a token's fitness for a particular use.
import 'package:mosquito_alert/api.dart';
final api = MosquitoAlert().getAuthApi();
final TokenVerifyRequest tokenVerifyRequest = ; // TokenVerifyRequest |
try {
api.verifyToken(tokenVerifyRequest);
} catch on DioException (e) {
print('Exception when calling AuthApi->verifyToken: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
tokenVerifyRequest | TokenVerifyRequest |
void (empty response body)
No authorization required
- Content-Type: application/json, application/x-www-form-urlencoded, multipart/form-data
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]