mirror of
https://bitbucket.org/FransoletThomas/tablet-app.git
synced 2025-12-06 08:31:19 +00:00
230 lines
5.4 KiB
Markdown
230 lines
5.4 KiB
Markdown
# managerapi.api.UserApi
|
|
|
|
## Load the API package
|
|
```dart
|
|
import 'package:managerapi/api.dart';
|
|
```
|
|
|
|
All URIs are relative to *http://192.168.31.140*
|
|
|
|
Method | HTTP request | Description
|
|
------------- | ------------- | -------------
|
|
[**userCreateUser**](UserApi.md#usercreateuser) | **POST** /api/User |
|
|
[**userDeleteUser**](UserApi.md#userdeleteuser) | **DELETE** /api/User/{id} |
|
|
[**userGet**](UserApi.md#userget) | **GET** /api/User |
|
|
[**userGetDetail**](UserApi.md#usergetdetail) | **GET** /api/User/{id} |
|
|
[**userUpdateUser**](UserApi.md#userupdateuser) | **PUT** /api/User |
|
|
|
|
|
|
# **userCreateUser**
|
|
> UserDetailDTO userCreateUser(user)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:managerapi/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = UserApi();
|
|
final user = User(); // User |
|
|
|
|
try {
|
|
final result = api_instance.userCreateUser(user);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling UserApi->userCreateUser: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**user** | [**User**](User.md)| |
|
|
|
|
### Return type
|
|
|
|
[**UserDetailDTO**](UserDetailDTO.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: application/json
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **userDeleteUser**
|
|
> String userDeleteUser(id)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:managerapi/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = UserApi();
|
|
final id = id_example; // String |
|
|
|
|
try {
|
|
final result = api_instance.userDeleteUser(id);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling UserApi->userDeleteUser: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**id** | **String**| |
|
|
|
|
### Return type
|
|
|
|
**String**
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: Not defined
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **userGet**
|
|
> List<User> userGet()
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:managerapi/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = UserApi();
|
|
|
|
try {
|
|
final result = api_instance.userGet();
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling UserApi->userGet: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
This endpoint does not need any parameter.
|
|
|
|
### Return type
|
|
|
|
[**List<User>**](User.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: Not defined
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **userGetDetail**
|
|
> UserDetailDTO userGetDetail(id)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:managerapi/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = UserApi();
|
|
final id = id_example; // String |
|
|
|
|
try {
|
|
final result = api_instance.userGetDetail(id);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling UserApi->userGetDetail: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**id** | **String**| |
|
|
|
|
### Return type
|
|
|
|
[**UserDetailDTO**](UserDetailDTO.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: Not defined
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **userUpdateUser**
|
|
> UserDetailDTO userUpdateUser(user)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:managerapi/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = UserApi();
|
|
final user = User(); // User |
|
|
|
|
try {
|
|
final result = api_instance.userUpdateUser(user);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling UserApi->userUpdateUser: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**user** | [**User**](User.md)| |
|
|
|
|
### Return type
|
|
|
|
[**UserDetailDTO**](UserDetailDTO.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: application/json
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|