Update service generation after security (roles + apikey)
This commit is contained in:
parent
b9ab5238ba
commit
e8d899310e
@ -1,4 +1,4 @@
|
||||
// Openapi Generator last run: : 2026-03-13T12:04:24.358808
|
||||
// Openapi Generator last run: : 2026-03-13T16:08:54.634997
|
||||
import 'package:openapi_generator_annotations/openapi_generator_annotations.dart';
|
||||
|
||||
@Openapi(
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
"info": {
|
||||
"title": "Manager Service",
|
||||
"description": "API Manager Service",
|
||||
"version": "Version Alpha 5.0"
|
||||
"version": "Version Alpha 2.0"
|
||||
},
|
||||
"servers": [
|
||||
{
|
||||
@ -183,7 +183,112 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"/api/ApiKey": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"ApiKey"
|
||||
],
|
||||
"operationId": "ApiKey_GetApiKeys",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"content": {
|
||||
"application/octet-stream": {
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"format": "binary"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
}
|
||||
]
|
||||
},
|
||||
"post": {
|
||||
"tags": [
|
||||
"ApiKey"
|
||||
],
|
||||
"operationId": "ApiKey_CreateApiKey",
|
||||
"requestBody": {
|
||||
"x-name": "request",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/CreateApiKeyRequest"
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": true,
|
||||
"x-position": 1
|
||||
},
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"content": {
|
||||
"application/octet-stream": {
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"format": "binary"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"/api/ApiKey/{id}": {
|
||||
"delete": {
|
||||
"tags": [
|
||||
"ApiKey"
|
||||
],
|
||||
"operationId": "ApiKey_RevokeApiKey",
|
||||
"parameters": [
|
||||
{
|
||||
"name": "id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"x-position": 1
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"content": {
|
||||
"application/octet-stream": {
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"format": "binary"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"/api/ApplicationInstance": {
|
||||
@ -807,7 +912,12 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
}
|
||||
]
|
||||
},
|
||||
"post": {
|
||||
"tags": [
|
||||
@ -991,7 +1101,12 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"/api/Configuration/{id}": {
|
||||
@ -1043,7 +1158,12 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
}
|
||||
]
|
||||
},
|
||||
"delete": {
|
||||
"tags": [
|
||||
@ -1180,7 +1300,12 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"/api/Configuration/import": {
|
||||
@ -1971,6 +2096,64 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/Instance/app-key": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"Instance"
|
||||
],
|
||||
"operationId": "Instance_GetAppKeyByPin",
|
||||
"parameters": [
|
||||
{
|
||||
"name": "pinCode",
|
||||
"in": "query",
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"x-position": 1
|
||||
},
|
||||
{
|
||||
"name": "appType",
|
||||
"in": "query",
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"x-position": 2
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {}
|
||||
}
|
||||
}
|
||||
},
|
||||
"404": {
|
||||
"description": "",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"500": {
|
||||
"description": "",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/Resource": {
|
||||
"get": {
|
||||
"tags": [
|
||||
@ -5385,7 +5568,7 @@
|
||||
"schema": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/components/schemas/User"
|
||||
"$ref": "#/components/schemas/UserDetailDTO"
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -5699,9 +5882,28 @@
|
||||
"pinCode": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"role": {
|
||||
"$ref": "#/components/schemas/UserRole"
|
||||
}
|
||||
}
|
||||
},
|
||||
"UserRole": {
|
||||
"type": "integer",
|
||||
"description": "0 = SuperAdmin\n1 = InstanceAdmin\n2 = ContentEditor\n3 = Viewer",
|
||||
"x-enumNames": [
|
||||
"SuperAdmin",
|
||||
"InstanceAdmin",
|
||||
"ContentEditor",
|
||||
"Viewer"
|
||||
],
|
||||
"enum": [
|
||||
0,
|
||||
1,
|
||||
2,
|
||||
3
|
||||
]
|
||||
},
|
||||
"LoginDTO": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
@ -5872,6 +6074,33 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"CreateApiKeyRequest": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"appType": {
|
||||
"$ref": "#/components/schemas/ApiKeyAppType"
|
||||
}
|
||||
}
|
||||
},
|
||||
"ApiKeyAppType": {
|
||||
"type": "integer",
|
||||
"description": "0 = VisitApp\n1 = TabletApp\n2 = Other",
|
||||
"x-enumNames": [
|
||||
"VisitApp",
|
||||
"TabletApp",
|
||||
"Other"
|
||||
],
|
||||
"enum": [
|
||||
0,
|
||||
1,
|
||||
2
|
||||
]
|
||||
},
|
||||
"ApplicationInstanceDTO": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
@ -9761,52 +9990,6 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"User": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"id",
|
||||
"email",
|
||||
"password",
|
||||
"lastName",
|
||||
"token",
|
||||
"instanceId"
|
||||
],
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
"email": {
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
"password": {
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
"firstName": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"lastName": {
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
"token": {
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
"dateCreation": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
},
|
||||
"instanceId": {
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
}
|
||||
}
|
||||
},
|
||||
"UserDetailDTO": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
@ -9830,6 +10013,18 @@
|
||||
"instanceId": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
},
|
||||
"role": {
|
||||
"nullable": true,
|
||||
"oneOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/UserRole"
|
||||
}
|
||||
]
|
||||
},
|
||||
"password": {
|
||||
"type": "string",
|
||||
"nullable": true
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -9847,12 +10042,21 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"apikey": {
|
||||
"type": "apiKey",
|
||||
"description": "API Key for mobile apps",
|
||||
"name": "X-Api-Key",
|
||||
"in": "header"
|
||||
}
|
||||
}
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
"bearer": []
|
||||
},
|
||||
{
|
||||
"apikey": []
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
@ -9864,6 +10068,10 @@
|
||||
"name": "AI",
|
||||
"description": "Assistant IA"
|
||||
},
|
||||
{
|
||||
"name": "ApiKey",
|
||||
"description": "API Key management for mobile apps"
|
||||
},
|
||||
{
|
||||
"name": "ApplicationInstance",
|
||||
"description": "Application instance management"
|
||||
|
||||
@ -11,6 +11,8 @@ doc/AiChatMessage.md
|
||||
doc/AiChatRequest.md
|
||||
doc/AiChatResponse.md
|
||||
doc/AiChatResponseNavigation.md
|
||||
doc/ApiKeyApi.md
|
||||
doc/ApiKeyAppType.md
|
||||
doc/AppConfigurationLink.md
|
||||
doc/AppConfigurationLinkApplicationInstance.md
|
||||
doc/AppConfigurationLinkConfiguration.md
|
||||
@ -35,6 +37,7 @@ doc/Coordinate.md
|
||||
doc/CoordinateEqualityComparer.md
|
||||
doc/CoordinateSequence.md
|
||||
doc/CoordinateSequenceFactory.md
|
||||
doc/CreateApiKeyRequest.md
|
||||
doc/DayStatDTO.md
|
||||
doc/Device.md
|
||||
doc/DeviceApi.md
|
||||
@ -146,9 +149,10 @@ doc/StatsSummaryDTO.md
|
||||
doc/TokenDTO.md
|
||||
doc/TranslationAndResourceDTO.md
|
||||
doc/TranslationDTO.md
|
||||
doc/User.md
|
||||
doc/UserApi.md
|
||||
doc/UserDetailDTO.md
|
||||
doc/UserDetailDTORole.md
|
||||
doc/UserRole.md
|
||||
doc/VideoDTO.md
|
||||
doc/VisitEventDTO.md
|
||||
doc/WeatherDTO.md
|
||||
@ -156,6 +160,7 @@ doc/WebDTO.md
|
||||
git_push.sh
|
||||
lib/api.dart
|
||||
lib/api/ai_api.dart
|
||||
lib/api/api_key_api.dart
|
||||
lib/api/application_instance_api.dart
|
||||
lib/api/authentication_api.dart
|
||||
lib/api/configuration_api.dart
|
||||
@ -185,6 +190,7 @@ lib/model/ai_chat_message.dart
|
||||
lib/model/ai_chat_request.dart
|
||||
lib/model/ai_chat_response.dart
|
||||
lib/model/ai_chat_response_navigation.dart
|
||||
lib/model/api_key_app_type.dart
|
||||
lib/model/app_configuration_link.dart
|
||||
lib/model/app_configuration_link_application_instance.dart
|
||||
lib/model/app_configuration_link_configuration.dart
|
||||
@ -206,6 +212,7 @@ lib/model/coordinate.dart
|
||||
lib/model/coordinate_equality_comparer.dart
|
||||
lib/model/coordinate_sequence.dart
|
||||
lib/model/coordinate_sequence_factory.dart
|
||||
lib/model/create_api_key_request.dart
|
||||
lib/model/day_stat_dto.dart
|
||||
lib/model/device.dart
|
||||
lib/model/device_detail_dto.dart
|
||||
@ -308,27 +315,16 @@ lib/model/stats_summary_dto.dart
|
||||
lib/model/token_dto.dart
|
||||
lib/model/translation_and_resource_dto.dart
|
||||
lib/model/translation_dto.dart
|
||||
lib/model/user.dart
|
||||
lib/model/user_detail_dto.dart
|
||||
lib/model/user_detail_dto_role.dart
|
||||
lib/model/user_role.dart
|
||||
lib/model/video_dto.dart
|
||||
lib/model/visit_event_dto.dart
|
||||
lib/model/weather_dto.dart
|
||||
lib/model/web_dto.dart
|
||||
pubspec.yaml
|
||||
test/agenda_event_stat_dto_test.dart
|
||||
test/ai_api_test.dart
|
||||
test/ai_card_dto_test.dart
|
||||
test/ai_chat_message_test.dart
|
||||
test/ai_chat_request_test.dart
|
||||
test/ai_chat_response_navigation_test.dart
|
||||
test/ai_chat_response_test.dart
|
||||
test/day_stat_dto_test.dart
|
||||
test/game_stat_dto_test.dart
|
||||
test/navigation_action_dto_test.dart
|
||||
test/poi_stat_dto_test.dart
|
||||
test/problem_details_test.dart
|
||||
test/quiz_stat_dto_test.dart
|
||||
test/section_stat_dto_test.dart
|
||||
test/stats_api_test.dart
|
||||
test/stats_summary_dto_test.dart
|
||||
test/visit_event_dto_test.dart
|
||||
test/api_key_api_test.dart
|
||||
test/api_key_app_type_test.dart
|
||||
test/create_api_key_request_test.dart
|
||||
test/user_detail_dto_role_test.dart
|
||||
test/user_role_test.dart
|
||||
|
||||
@ -3,7 +3,7 @@ API Manager Service
|
||||
|
||||
This Dart package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
||||
|
||||
- API version: Version Alpha 5.0
|
||||
- API version: Version Alpha 2.0
|
||||
- Generator version: 7.9.0
|
||||
- Build package: org.openapitools.codegen.languages.DartClientCodegen
|
||||
|
||||
@ -62,6 +62,9 @@ All URIs are relative to *https://localhost:5001*
|
||||
Class | Method | HTTP request | Description
|
||||
------------ | ------------- | ------------- | -------------
|
||||
*AIApi* | [**aiChat**](doc//AIApi.md#aichat) | **POST** /api/Ai/chat |
|
||||
*ApiKeyApi* | [**apiKeyCreateApiKey**](doc//ApiKeyApi.md#apikeycreateapikey) | **POST** /api/ApiKey |
|
||||
*ApiKeyApi* | [**apiKeyGetApiKeys**](doc//ApiKeyApi.md#apikeygetapikeys) | **GET** /api/ApiKey |
|
||||
*ApiKeyApi* | [**apiKeyRevokeApiKey**](doc//ApiKeyApi.md#apikeyrevokeapikey) | **DELETE** /api/ApiKey/{id} |
|
||||
*ApplicationInstanceApi* | [**applicationInstanceAddConfigurationToApplicationInstance**](doc//ApplicationInstanceApi.md#applicationinstanceaddconfigurationtoapplicationinstance) | **POST** /api/ApplicationInstance/{applicationInstanceId}/application-link |
|
||||
*ApplicationInstanceApi* | [**applicationInstanceCreate**](doc//ApplicationInstanceApi.md#applicationinstancecreate) | **POST** /api/ApplicationInstance |
|
||||
*ApplicationInstanceApi* | [**applicationInstanceDelete**](doc//ApplicationInstanceApi.md#applicationinstancedelete) | **DELETE** /api/ApplicationInstance/{id} |
|
||||
@ -90,6 +93,7 @@ Class | Method | HTTP request | Description
|
||||
*InstanceApi* | [**instanceCreateInstance**](doc//InstanceApi.md#instancecreateinstance) | **POST** /api/Instance |
|
||||
*InstanceApi* | [**instanceDeleteInstance**](doc//InstanceApi.md#instancedeleteinstance) | **DELETE** /api/Instance/{id} |
|
||||
*InstanceApi* | [**instanceGet**](doc//InstanceApi.md#instanceget) | **GET** /api/Instance |
|
||||
*InstanceApi* | [**instanceGetAppKeyByPin**](doc//InstanceApi.md#instancegetappkeybypin) | **GET** /api/Instance/app-key |
|
||||
*InstanceApi* | [**instanceGetDetail**](doc//InstanceApi.md#instancegetdetail) | **GET** /api/Instance/{id} |
|
||||
*InstanceApi* | [**instanceGetInstanceByPinCode**](doc//InstanceApi.md#instancegetinstancebypincode) | **GET** /api/Instance/byPin |
|
||||
*InstanceApi* | [**instanceUpdateinstance**](doc//InstanceApi.md#instanceupdateinstance) | **PUT** /api/Instance |
|
||||
@ -173,6 +177,7 @@ Class | Method | HTTP request | Description
|
||||
- [AiChatRequest](doc//AiChatRequest.md)
|
||||
- [AiChatResponse](doc//AiChatResponse.md)
|
||||
- [AiChatResponseNavigation](doc//AiChatResponseNavigation.md)
|
||||
- [ApiKeyAppType](doc//ApiKeyAppType.md)
|
||||
- [AppConfigurationLink](doc//AppConfigurationLink.md)
|
||||
- [AppConfigurationLinkApplicationInstance](doc//AppConfigurationLinkApplicationInstance.md)
|
||||
- [AppConfigurationLinkConfiguration](doc//AppConfigurationLinkConfiguration.md)
|
||||
@ -194,6 +199,7 @@ Class | Method | HTTP request | Description
|
||||
- [CoordinateEqualityComparer](doc//CoordinateEqualityComparer.md)
|
||||
- [CoordinateSequence](doc//CoordinateSequence.md)
|
||||
- [CoordinateSequenceFactory](doc//CoordinateSequenceFactory.md)
|
||||
- [CreateApiKeyRequest](doc//CreateApiKeyRequest.md)
|
||||
- [DayStatDTO](doc//DayStatDTO.md)
|
||||
- [Device](doc//Device.md)
|
||||
- [DeviceDTO](doc//DeviceDTO.md)
|
||||
@ -296,8 +302,9 @@ Class | Method | HTTP request | Description
|
||||
- [TokenDTO](doc//TokenDTO.md)
|
||||
- [TranslationAndResourceDTO](doc//TranslationAndResourceDTO.md)
|
||||
- [TranslationDTO](doc//TranslationDTO.md)
|
||||
- [User](doc//User.md)
|
||||
- [UserDetailDTO](doc//UserDetailDTO.md)
|
||||
- [UserDetailDTORole](doc//UserDetailDTORole.md)
|
||||
- [UserRole](doc//UserRole.md)
|
||||
- [VideoDTO](doc//VideoDTO.md)
|
||||
- [VisitEventDTO](doc//VisitEventDTO.md)
|
||||
- [WeatherDTO](doc//WeatherDTO.md)
|
||||
@ -316,6 +323,12 @@ Authentication schemes defined for the API:
|
||||
- **Scopes**:
|
||||
- **Manager-api**: Manager WebAPI
|
||||
|
||||
### apikey
|
||||
|
||||
- **Type**: API key
|
||||
- **API key parameter name**: X-Api-Key
|
||||
- **Location**: HTTP header
|
||||
|
||||
|
||||
## Author
|
||||
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
import 'package:manager_api_new/api.dart';
|
||||
```
|
||||
|
||||
All URIs are relative to *http://192.168.31.228:5000*
|
||||
All URIs are relative to *https://localhost:5001*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
|
||||
141
manager_api_new/doc/ApiKeyApi.md
Normal file
141
manager_api_new/doc/ApiKeyApi.md
Normal file
@ -0,0 +1,141 @@
|
||||
# manager_api_new.api.ApiKeyApi
|
||||
|
||||
## Load the API package
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
```
|
||||
|
||||
All URIs are relative to *https://localhost:5001*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**apiKeyCreateApiKey**](ApiKeyApi.md#apikeycreateapikey) | **POST** /api/ApiKey |
|
||||
[**apiKeyGetApiKeys**](ApiKeyApi.md#apikeygetapikeys) | **GET** /api/ApiKey |
|
||||
[**apiKeyRevokeApiKey**](ApiKeyApi.md#apikeyrevokeapikey) | **DELETE** /api/ApiKey/{id} |
|
||||
|
||||
|
||||
# **apiKeyCreateApiKey**
|
||||
> MultipartFile apiKeyCreateApiKey(createApiKeyRequest)
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
final api_instance = ApiKeyApi();
|
||||
final createApiKeyRequest = CreateApiKeyRequest(); // CreateApiKeyRequest |
|
||||
|
||||
try {
|
||||
final result = api_instance.apiKeyCreateApiKey(createApiKeyRequest);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling ApiKeyApi->apiKeyCreateApiKey: $e\n');
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**createApiKeyRequest** | [**CreateApiKeyRequest**](CreateApiKeyRequest.md)| |
|
||||
|
||||
### Return type
|
||||
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/octet-stream
|
||||
|
||||
[[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)
|
||||
|
||||
# **apiKeyGetApiKeys**
|
||||
> MultipartFile apiKeyGetApiKeys()
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
final api_instance = ApiKeyApi();
|
||||
|
||||
try {
|
||||
final result = api_instance.apiKeyGetApiKeys();
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling ApiKeyApi->apiKeyGetApiKeys: $e\n');
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
This endpoint does not need any parameter.
|
||||
|
||||
### Return type
|
||||
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/octet-stream
|
||||
|
||||
[[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)
|
||||
|
||||
# **apiKeyRevokeApiKey**
|
||||
> MultipartFile apiKeyRevokeApiKey(id)
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
final api_instance = ApiKeyApi();
|
||||
final id = id_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.apiKeyRevokeApiKey(id);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling ApiKeyApi->apiKeyRevokeApiKey: $e\n');
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**id** | **String**| |
|
||||
|
||||
### Return type
|
||||
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/octet-stream
|
||||
|
||||
[[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)
|
||||
|
||||
14
manager_api_new/doc/ApiKeyAppType.md
Normal file
14
manager_api_new/doc/ApiKeyAppType.md
Normal file
@ -0,0 +1,14 @@
|
||||
# manager_api_new.model.ApiKeyAppType
|
||||
|
||||
## Load the model package
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
```
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@ -204,6 +204,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -230,7 +234,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -247,6 +251,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -273,7 +281,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -21,6 +21,10 @@ Method | HTTP request | Description
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -55,7 +59,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -72,6 +76,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -98,7 +106,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
16
manager_api_new/doc/CreateApiKeyRequest.md
Normal file
16
manager_api_new/doc/CreateApiKeyRequest.md
Normal file
@ -0,0 +1,16 @@
|
||||
# manager_api_new.model.CreateApiKeyRequest
|
||||
|
||||
## Load the model package
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
```
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**name** | **String** | | [optional]
|
||||
**appType** | [**ApiKeyAppType**](ApiKeyAppType.md) | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@ -25,6 +25,10 @@ Method | HTTP request | Description
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -51,7 +55,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -154,6 +158,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -180,7 +188,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -12,6 +12,7 @@ Method | HTTP request | Description
|
||||
[**instanceCreateInstance**](InstanceApi.md#instancecreateinstance) | **POST** /api/Instance |
|
||||
[**instanceDeleteInstance**](InstanceApi.md#instancedeleteinstance) | **DELETE** /api/Instance/{id} |
|
||||
[**instanceGet**](InstanceApi.md#instanceget) | **GET** /api/Instance |
|
||||
[**instanceGetAppKeyByPin**](InstanceApi.md#instancegetappkeybypin) | **GET** /api/Instance/app-key |
|
||||
[**instanceGetDetail**](InstanceApi.md#instancegetdetail) | **GET** /api/Instance/{id} |
|
||||
[**instanceGetInstanceByPinCode**](InstanceApi.md#instancegetinstancebypincode) | **GET** /api/Instance/byPin |
|
||||
[**instanceUpdateinstance**](InstanceApi.md#instanceupdateinstance) | **PUT** /api/Instance |
|
||||
@ -142,6 +143,55 @@ This endpoint does not need any parameter.
|
||||
|
||||
[[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)
|
||||
|
||||
# **instanceGetAppKeyByPin**
|
||||
> Object instanceGetAppKeyByPin(pinCode, appType)
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
final api_instance = InstanceApi();
|
||||
final pinCode = pinCode_example; // String |
|
||||
final appType = appType_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.instanceGetAppKeyByPin(pinCode, appType);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling InstanceApi->instanceGetAppKeyByPin: $e\n');
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pinCode** | **String**| | [optional]
|
||||
**appType** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**Object**](Object.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[apikey](../README.md#apikey), [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)
|
||||
|
||||
# **instanceGetDetail**
|
||||
> InstanceDTO instanceGetDetail(id)
|
||||
|
||||
@ -193,6 +243,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -219,7 +273,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -157,6 +157,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -183,7 +187,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -200,6 +204,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -226,7 +234,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -111,6 +111,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -137,7 +141,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -256,6 +256,10 @@ This endpoint does not need any parameter.
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -282,7 +286,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -426,6 +430,10 @@ This endpoint does not need any parameter.
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -452,7 +460,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -469,6 +477,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -495,7 +507,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -512,6 +524,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -538,7 +554,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -203,6 +203,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -229,7 +233,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -246,6 +250,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -272,7 +280,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -295,6 +295,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -321,7 +325,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -338,6 +342,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -364,7 +372,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
@ -381,6 +389,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -407,7 +419,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -111,6 +111,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -137,7 +141,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
import 'package:manager_api_new/api.dart';
|
||||
```
|
||||
|
||||
All URIs are relative to *http://192.168.31.228:5000*
|
||||
All URIs are relative to *https://localhost:5001*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
@ -70,6 +70,10 @@ Name | Type | Description | Notes
|
||||
### Example
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
// TODO Configure API key authorization: apikey
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('apikey').apiKeyPrefix = 'Bearer';
|
||||
// TODO Configure OAuth2 access token for authorization: bearer
|
||||
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
||||
|
||||
@ -95,7 +99,7 @@ void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[apikey](../README.md#apikey), [bearer](../README.md#bearer)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
||||
@ -16,6 +16,7 @@ Name | Type | Description | Notes
|
||||
**expiration** | [**DateTime**](DateTime.md) | | [optional]
|
||||
**instanceId** | **String** | | [optional]
|
||||
**pinCode** | **String** | | [optional]
|
||||
**role** | [**UserRole**](UserRole.md) | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@ -103,7 +103,7 @@ Name | Type | Description | Notes
|
||||
[[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()
|
||||
> List<UserDetailDTO> userGet()
|
||||
|
||||
|
||||
|
||||
@ -128,7 +128,7 @@ This endpoint does not need any parameter.
|
||||
|
||||
### Return type
|
||||
|
||||
[**List<User>**](User.md)
|
||||
[**List<UserDetailDTO>**](UserDetailDTO.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
|
||||
@ -13,6 +13,8 @@ Name | Type | Description | Notes
|
||||
**firstName** | **String** | | [optional]
|
||||
**lastName** | **String** | | [optional]
|
||||
**instanceId** | **String** | | [optional]
|
||||
**role** | [**UserDetailDTORole**](UserDetailDTORole.md) | | [optional]
|
||||
**password** | **String** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
14
manager_api_new/doc/UserDetailDTORole.md
Normal file
14
manager_api_new/doc/UserDetailDTORole.md
Normal file
@ -0,0 +1,14 @@
|
||||
# manager_api_new.model.UserDetailDTORole
|
||||
|
||||
## Load the model package
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
```
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
14
manager_api_new/doc/UserRole.md
Normal file
14
manager_api_new/doc/UserRole.md
Normal file
@ -0,0 +1,14 @@
|
||||
# manager_api_new.model.UserRole
|
||||
|
||||
## Load the model package
|
||||
```dart
|
||||
import 'package:manager_api_new/api.dart';
|
||||
```
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@ -29,6 +29,7 @@ part 'auth/http_basic_auth.dart';
|
||||
part 'auth/http_bearer_auth.dart';
|
||||
|
||||
part 'api/ai_api.dart';
|
||||
part 'api/api_key_api.dart';
|
||||
part 'api/application_instance_api.dart';
|
||||
part 'api/authentication_api.dart';
|
||||
part 'api/configuration_api.dart';
|
||||
@ -50,6 +51,7 @@ part 'model/ai_chat_message.dart';
|
||||
part 'model/ai_chat_request.dart';
|
||||
part 'model/ai_chat_response.dart';
|
||||
part 'model/ai_chat_response_navigation.dart';
|
||||
part 'model/api_key_app_type.dart';
|
||||
part 'model/app_configuration_link.dart';
|
||||
part 'model/app_configuration_link_application_instance.dart';
|
||||
part 'model/app_configuration_link_configuration.dart';
|
||||
@ -72,6 +74,7 @@ part 'model/coordinate.dart';
|
||||
part 'model/coordinate_equality_comparer.dart';
|
||||
part 'model/coordinate_sequence.dart';
|
||||
part 'model/coordinate_sequence_factory.dart';
|
||||
part 'model/create_api_key_request.dart';
|
||||
part 'model/device.dart';
|
||||
part 'model/device_dto.dart';
|
||||
part 'model/device_detail_dto.dart';
|
||||
@ -169,8 +172,10 @@ part 'model/stats_summary_dto.dart';
|
||||
part 'model/token_dto.dart';
|
||||
part 'model/translation_and_resource_dto.dart';
|
||||
part 'model/translation_dto.dart';
|
||||
part 'model/user.dart';
|
||||
part 'model/user_detail_dto.dart';
|
||||
part 'model/user_detail_dto_role.dart';
|
||||
part 'model/user_role.dart';
|
||||
part 'model/user_role_extensions.dart';
|
||||
part 'model/video_dto.dart';
|
||||
part 'model/visit_event_dto.dart';
|
||||
part 'model/weather_dto.dart';
|
||||
|
||||
170
manager_api_new/lib/api/api_key_api.dart
Normal file
170
manager_api_new/lib/api/api_key_api.dart
Normal file
@ -0,0 +1,170 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class ApiKeyApi {
|
||||
ApiKeyApi([ApiClient? apiClient]) : apiClient = apiClient ?? defaultApiClient;
|
||||
|
||||
final ApiClient apiClient;
|
||||
|
||||
/// Performs an HTTP 'POST /api/ApiKey' operation and returns the [Response].
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [CreateApiKeyRequest] createApiKeyRequest (required):
|
||||
Future<Response> apiKeyCreateApiKeyWithHttpInfo(
|
||||
CreateApiKeyRequest createApiKeyRequest,
|
||||
) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/api/ApiKey';
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody = createApiKeyRequest;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
path,
|
||||
'POST',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [CreateApiKeyRequest] createApiKeyRequest (required):
|
||||
Future<MultipartFile?> apiKeyCreateApiKey(
|
||||
CreateApiKeyRequest createApiKeyRequest,
|
||||
) async {
|
||||
final response = await apiKeyCreateApiKeyWithHttpInfo(
|
||||
createApiKeyRequest,
|
||||
);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty &&
|
||||
response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(
|
||||
await _decodeBodyBytes(response),
|
||||
'MultipartFile',
|
||||
) as MultipartFile;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /api/ApiKey' operation and returns the [Response].
|
||||
Future<Response> apiKeyGetApiKeysWithHttpInfo() async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/api/ApiKey';
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
path,
|
||||
'GET',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
Future<MultipartFile?> apiKeyGetApiKeys() async {
|
||||
final response = await apiKeyGetApiKeysWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty &&
|
||||
response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(
|
||||
await _decodeBodyBytes(response),
|
||||
'MultipartFile',
|
||||
) as MultipartFile;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'DELETE /api/ApiKey/{id}' operation and returns the [Response].
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<Response> apiKeyRevokeApiKeyWithHttpInfo(
|
||||
String id,
|
||||
) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/api/ApiKey/{id}'.replaceAll('{id}', id);
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
path,
|
||||
'DELETE',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] id (required):
|
||||
Future<MultipartFile?> apiKeyRevokeApiKey(
|
||||
String id,
|
||||
) async {
|
||||
final response = await apiKeyRevokeApiKeyWithHttpInfo(
|
||||
id,
|
||||
);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty &&
|
||||
response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(
|
||||
await _decodeBodyBytes(response),
|
||||
'MultipartFile',
|
||||
) as MultipartFile;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@ -170,6 +170,75 @@ class InstanceApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /api/Instance/app-key' operation and returns the [Response].
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] pinCode:
|
||||
///
|
||||
/// * [String] appType:
|
||||
Future<Response> instanceGetAppKeyByPinWithHttpInfo({
|
||||
String? pinCode,
|
||||
String? appType,
|
||||
}) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/api/Instance/app-key';
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (pinCode != null) {
|
||||
queryParams.addAll(_queryParams('', 'pinCode', pinCode));
|
||||
}
|
||||
if (appType != null) {
|
||||
queryParams.addAll(_queryParams('', 'appType', appType));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
path,
|
||||
'GET',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
);
|
||||
}
|
||||
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] pinCode:
|
||||
///
|
||||
/// * [String] appType:
|
||||
Future<Object?> instanceGetAppKeyByPin({
|
||||
String? pinCode,
|
||||
String? appType,
|
||||
}) async {
|
||||
final response = await instanceGetAppKeyByPinWithHttpInfo(
|
||||
pinCode: pinCode,
|
||||
appType: appType,
|
||||
);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty &&
|
||||
response.statusCode != HttpStatus.noContent) {
|
||||
return await apiClient.deserializeAsync(
|
||||
await _decodeBodyBytes(response),
|
||||
'Object',
|
||||
) as Object;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Performs an HTTP 'GET /api/Instance/{id}' operation and returns the [Response].
|
||||
/// Parameters:
|
||||
///
|
||||
|
||||
@ -150,7 +150,7 @@ class UserApi {
|
||||
);
|
||||
}
|
||||
|
||||
Future<List<User>?> userGet() async {
|
||||
Future<List<UserDetailDTO>?> userGet() async {
|
||||
final response = await userGetWithHttpInfo();
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
@ -161,9 +161,9 @@ class UserApi {
|
||||
if (response.body.isNotEmpty &&
|
||||
response.statusCode != HttpStatus.noContent) {
|
||||
final responseBody = await _decodeBodyBytes(response);
|
||||
return (await apiClient.deserializeAsync(responseBody, 'List<User>')
|
||||
as List)
|
||||
.cast<User>()
|
||||
return (await apiClient.deserializeAsync(
|
||||
responseBody, 'List<UserDetailDTO>') as List)
|
||||
.cast<UserDetailDTO>()
|
||||
.toList(growable: false);
|
||||
}
|
||||
return null;
|
||||
|
||||
@ -491,8 +491,6 @@ class ApiClient {
|
||||
return TranslationAndResourceDTO.fromJson(value);
|
||||
case 'TranslationDTO':
|
||||
return TranslationDTO.fromJson(value);
|
||||
case 'User':
|
||||
return User.fromJson(value);
|
||||
case 'UserDetailDTO':
|
||||
return UserDetailDTO.fromJson(value);
|
||||
case 'VideoDTO':
|
||||
|
||||
@ -65,6 +65,9 @@ String parameterToString(dynamic value) {
|
||||
if (value is DateTime) {
|
||||
return value.toUtc().toIso8601String();
|
||||
}
|
||||
if (value is ApiKeyAppType) {
|
||||
return ApiKeyAppTypeTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is AppType) {
|
||||
return AppTypeTypeTransformer().encode(value).toString();
|
||||
}
|
||||
@ -107,6 +110,9 @@ String parameterToString(dynamic value) {
|
||||
if (value is SectionType) {
|
||||
return SectionTypeTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is UserRole) {
|
||||
return UserRoleTypeTransformer().encode(value).toString();
|
||||
}
|
||||
return value.toString();
|
||||
}
|
||||
|
||||
|
||||
152
manager_api_new/lib/model/agenda_event_stat_dto.dart
Normal file
152
manager_api_new/lib/model/agenda_event_stat_dto.dart
Normal file
@ -0,0 +1,152 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class AgendaEventStatDTO {
|
||||
/// Returns a new [AgendaEventStatDTO] instance.
|
||||
AgendaEventStatDTO({
|
||||
this.eventId,
|
||||
this.eventTitle,
|
||||
this.taps,
|
||||
});
|
||||
|
||||
String? eventId;
|
||||
|
||||
String? eventTitle;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
int? taps;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) =>
|
||||
identical(this, other) ||
|
||||
other is AgendaEventStatDTO &&
|
||||
other.eventId == eventId &&
|
||||
other.eventTitle == eventTitle &&
|
||||
other.taps == taps;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eventId == null ? 0 : eventId!.hashCode) +
|
||||
(eventTitle == null ? 0 : eventTitle!.hashCode) +
|
||||
(taps == null ? 0 : taps!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() =>
|
||||
'AgendaEventStatDTO[eventId=$eventId, eventTitle=$eventTitle, taps=$taps]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eventId != null) {
|
||||
json[r'eventId'] = this.eventId;
|
||||
} else {
|
||||
json[r'eventId'] = null;
|
||||
}
|
||||
if (this.eventTitle != null) {
|
||||
json[r'eventTitle'] = this.eventTitle;
|
||||
} else {
|
||||
json[r'eventTitle'] = null;
|
||||
}
|
||||
if (this.taps != null) {
|
||||
json[r'taps'] = this.taps;
|
||||
} else {
|
||||
json[r'taps'] = null;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [AgendaEventStatDTO] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static AgendaEventStatDTO? fromJson(dynamic value) {
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
// Ensure that the map contains the required keys.
|
||||
// Note 1: the values aren't checked for validity beyond being non-null.
|
||||
// Note 2: this code is stripped in release mode!
|
||||
assert(() {
|
||||
requiredKeys.forEach((key) {
|
||||
assert(json.containsKey(key),
|
||||
'Required key "AgendaEventStatDTO[$key]" is missing from JSON.');
|
||||
assert(json[key] != null,
|
||||
'Required key "AgendaEventStatDTO[$key]" has a null value in JSON.');
|
||||
});
|
||||
return true;
|
||||
}());
|
||||
|
||||
return AgendaEventStatDTO(
|
||||
eventId: mapValueOfType<String>(json, r'eventId'),
|
||||
eventTitle: mapValueOfType<String>(json, r'eventTitle'),
|
||||
taps: mapValueOfType<int>(json, r'taps'),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<AgendaEventStatDTO> listFromJson(
|
||||
dynamic json, {
|
||||
bool growable = false,
|
||||
}) {
|
||||
final result = <AgendaEventStatDTO>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = AgendaEventStatDTO.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, AgendaEventStatDTO> mapFromJson(dynamic json) {
|
||||
final map = <String, AgendaEventStatDTO>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = AgendaEventStatDTO.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of AgendaEventStatDTO-objects as value to a dart map
|
||||
static Map<String, List<AgendaEventStatDTO>> mapListFromJson(
|
||||
dynamic json, {
|
||||
bool growable = false,
|
||||
}) {
|
||||
final map = <String, List<AgendaEventStatDTO>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = AgendaEventStatDTO.listFromJson(
|
||||
entry.value,
|
||||
growable: growable,
|
||||
);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{};
|
||||
}
|
||||
95
manager_api_new/lib/model/api_key_app_type.dart
Normal file
95
manager_api_new/lib/model/api_key_app_type.dart
Normal file
@ -0,0 +1,95 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
/// 0 = VisitApp 1 = TabletApp 2 = Other
|
||||
class ApiKeyAppType {
|
||||
/// Instantiate a new enum with the provided [value].
|
||||
const ApiKeyAppType._(this.value);
|
||||
|
||||
/// The underlying value of this enum member.
|
||||
final int value;
|
||||
|
||||
@override
|
||||
String toString() => value.toString();
|
||||
|
||||
int toJson() => value;
|
||||
|
||||
static const number0 = ApiKeyAppType._(0);
|
||||
static const number1 = ApiKeyAppType._(1);
|
||||
static const number2 = ApiKeyAppType._(2);
|
||||
|
||||
/// List of all possible values in this [enum][ApiKeyAppType].
|
||||
static const values = <ApiKeyAppType>[
|
||||
number0,
|
||||
number1,
|
||||
number2,
|
||||
];
|
||||
|
||||
static ApiKeyAppType? fromJson(dynamic value) =>
|
||||
ApiKeyAppTypeTypeTransformer().decode(value);
|
||||
|
||||
static List<ApiKeyAppType> listFromJson(
|
||||
dynamic json, {
|
||||
bool growable = false,
|
||||
}) {
|
||||
final result = <ApiKeyAppType>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = ApiKeyAppType.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
}
|
||||
|
||||
/// Transformation class that can [encode] an instance of [ApiKeyAppType] to int,
|
||||
/// and [decode] dynamic data back to [ApiKeyAppType].
|
||||
class ApiKeyAppTypeTypeTransformer {
|
||||
factory ApiKeyAppTypeTypeTransformer() =>
|
||||
_instance ??= const ApiKeyAppTypeTypeTransformer._();
|
||||
|
||||
const ApiKeyAppTypeTypeTransformer._();
|
||||
|
||||
int encode(ApiKeyAppType data) => data.value;
|
||||
|
||||
/// Decodes a [dynamic value][data] to a ApiKeyAppType.
|
||||
///
|
||||
/// If [allowNull] is true and the [dynamic value][data] cannot be decoded successfully,
|
||||
/// then null is returned. However, if [allowNull] is false and the [dynamic value][data]
|
||||
/// cannot be decoded successfully, then an [UnimplementedError] is thrown.
|
||||
///
|
||||
/// The [allowNull] is very handy when an API changes and a new enum value is added or removed,
|
||||
/// and users are still using an old app with the old code.
|
||||
ApiKeyAppType? decode(dynamic data, {bool allowNull = true}) {
|
||||
if (data != null) {
|
||||
switch (data) {
|
||||
case 0:
|
||||
return ApiKeyAppType.number0;
|
||||
case 1:
|
||||
return ApiKeyAppType.number1;
|
||||
case 2:
|
||||
return ApiKeyAppType.number2;
|
||||
default:
|
||||
if (!allowNull) {
|
||||
throw ArgumentError('Unknown enum value to decode: $data');
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Singleton [ApiKeyAppTypeTypeTransformer] instance.
|
||||
static ApiKeyAppTypeTypeTransformer? _instance;
|
||||
}
|
||||
@ -27,6 +27,7 @@ class AppConfigurationLinkApplicationInstance {
|
||||
this.languages = const [],
|
||||
this.sectionEventId,
|
||||
this.sectionEvent,
|
||||
this.isAssistant,
|
||||
});
|
||||
|
||||
String instanceId;
|
||||
@ -63,6 +64,14 @@ class AppConfigurationLinkApplicationInstance {
|
||||
|
||||
ApplicationInstanceSectionEvent? sectionEvent;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
bool? isAssistant;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) =>
|
||||
identical(this, other) ||
|
||||
@ -80,7 +89,8 @@ class AppConfigurationLinkApplicationInstance {
|
||||
other.layoutMainPage == layoutMainPage &&
|
||||
_deepEquality.equals(other.languages, languages) &&
|
||||
other.sectionEventId == sectionEventId &&
|
||||
other.sectionEvent == sectionEvent;
|
||||
other.sectionEvent == sectionEvent &&
|
||||
other.isAssistant == isAssistant;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
@ -98,11 +108,12 @@ class AppConfigurationLinkApplicationInstance {
|
||||
(layoutMainPage == null ? 0 : layoutMainPage!.hashCode) +
|
||||
(languages == null ? 0 : languages!.hashCode) +
|
||||
(sectionEventId == null ? 0 : sectionEventId!.hashCode) +
|
||||
(sectionEvent == null ? 0 : sectionEvent!.hashCode);
|
||||
(sectionEvent == null ? 0 : sectionEvent!.hashCode) +
|
||||
(isAssistant == null ? 0 : isAssistant!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() =>
|
||||
'AppConfigurationLinkApplicationInstance[instanceId=$instanceId, appType=$appType, id=$id, configurations=$configurations, mainImageId=$mainImageId, mainImageUrl=$mainImageUrl, loaderImageId=$loaderImageId, loaderImageUrl=$loaderImageUrl, primaryColor=$primaryColor, secondaryColor=$secondaryColor, layoutMainPage=$layoutMainPage, languages=$languages, sectionEventId=$sectionEventId, sectionEvent=$sectionEvent]';
|
||||
'AppConfigurationLinkApplicationInstance[instanceId=$instanceId, appType=$appType, id=$id, configurations=$configurations, mainImageId=$mainImageId, mainImageUrl=$mainImageUrl, loaderImageId=$loaderImageId, loaderImageUrl=$loaderImageUrl, primaryColor=$primaryColor, secondaryColor=$secondaryColor, layoutMainPage=$layoutMainPage, languages=$languages, sectionEventId=$sectionEventId, sectionEvent=$sectionEvent, isAssistant=$isAssistant]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@ -168,6 +179,11 @@ class AppConfigurationLinkApplicationInstance {
|
||||
} else {
|
||||
json[r'sectionEvent'] = null;
|
||||
}
|
||||
if (this.isAssistant != null) {
|
||||
json[r'isAssistant'] = this.isAssistant;
|
||||
} else {
|
||||
json[r'isAssistant'] = null;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@ -212,6 +228,7 @@ class AppConfigurationLinkApplicationInstance {
|
||||
sectionEventId: mapValueOfType<String>(json, r'sectionEventId'),
|
||||
sectionEvent:
|
||||
ApplicationInstanceSectionEvent.fromJson(json[r'sectionEvent']),
|
||||
isAssistant: mapValueOfType<bool>(json, r'isAssistant'),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
|
||||
140
manager_api_new/lib/model/create_api_key_request.dart
Normal file
140
manager_api_new/lib/model/create_api_key_request.dart
Normal file
@ -0,0 +1,140 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class CreateApiKeyRequest {
|
||||
/// Returns a new [CreateApiKeyRequest] instance.
|
||||
CreateApiKeyRequest({
|
||||
this.name,
|
||||
this.appType,
|
||||
});
|
||||
|
||||
String? name;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
ApiKeyAppType? appType;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) =>
|
||||
identical(this, other) ||
|
||||
other is CreateApiKeyRequest &&
|
||||
other.name == name &&
|
||||
other.appType == appType;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(name == null ? 0 : name!.hashCode) +
|
||||
(appType == null ? 0 : appType!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'CreateApiKeyRequest[name=$name, appType=$appType]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.name != null) {
|
||||
json[r'name'] = this.name;
|
||||
} else {
|
||||
json[r'name'] = null;
|
||||
}
|
||||
if (this.appType != null) {
|
||||
json[r'appType'] = this.appType;
|
||||
} else {
|
||||
json[r'appType'] = null;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [CreateApiKeyRequest] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static CreateApiKeyRequest? fromJson(dynamic value) {
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
// Ensure that the map contains the required keys.
|
||||
// Note 1: the values aren't checked for validity beyond being non-null.
|
||||
// Note 2: this code is stripped in release mode!
|
||||
assert(() {
|
||||
requiredKeys.forEach((key) {
|
||||
assert(json.containsKey(key),
|
||||
'Required key "CreateApiKeyRequest[$key]" is missing from JSON.');
|
||||
assert(json[key] != null,
|
||||
'Required key "CreateApiKeyRequest[$key]" has a null value in JSON.');
|
||||
});
|
||||
return true;
|
||||
}());
|
||||
|
||||
return CreateApiKeyRequest(
|
||||
name: mapValueOfType<String>(json, r'name'),
|
||||
appType: ApiKeyAppType.fromJson(json[r'appType']),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<CreateApiKeyRequest> listFromJson(
|
||||
dynamic json, {
|
||||
bool growable = false,
|
||||
}) {
|
||||
final result = <CreateApiKeyRequest>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = CreateApiKeyRequest.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, CreateApiKeyRequest> mapFromJson(dynamic json) {
|
||||
final map = <String, CreateApiKeyRequest>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = CreateApiKeyRequest.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of CreateApiKeyRequest-objects as value to a dart map
|
||||
static Map<String, List<CreateApiKeyRequest>> mapListFromJson(
|
||||
dynamic json, {
|
||||
bool growable = false,
|
||||
}) {
|
||||
final map = <String, List<CreateApiKeyRequest>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = CreateApiKeyRequest.listFromJson(
|
||||
entry.value,
|
||||
growable: growable,
|
||||
);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{};
|
||||
}
|
||||
@ -21,6 +21,7 @@ class TokenDTO {
|
||||
this.expiration,
|
||||
this.instanceId,
|
||||
this.pinCode,
|
||||
this.role,
|
||||
});
|
||||
|
||||
String? accessToken;
|
||||
@ -51,6 +52,14 @@ class TokenDTO {
|
||||
|
||||
String? pinCode;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
UserRole? role;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) =>
|
||||
identical(this, other) ||
|
||||
@ -62,7 +71,8 @@ class TokenDTO {
|
||||
other.expiresIn == expiresIn &&
|
||||
other.expiration == expiration &&
|
||||
other.instanceId == instanceId &&
|
||||
other.pinCode == pinCode;
|
||||
other.pinCode == pinCode &&
|
||||
other.role == role;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
@ -74,11 +84,12 @@ class TokenDTO {
|
||||
(expiresIn == null ? 0 : expiresIn!.hashCode) +
|
||||
(expiration == null ? 0 : expiration!.hashCode) +
|
||||
(instanceId == null ? 0 : instanceId!.hashCode) +
|
||||
(pinCode == null ? 0 : pinCode!.hashCode);
|
||||
(pinCode == null ? 0 : pinCode!.hashCode) +
|
||||
(role == null ? 0 : role!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() =>
|
||||
'TokenDTO[accessToken=$accessToken, refreshToken=$refreshToken, scope=$scope, tokenType=$tokenType, expiresIn=$expiresIn, expiration=$expiration, instanceId=$instanceId, pinCode=$pinCode]';
|
||||
'TokenDTO[accessToken=$accessToken, refreshToken=$refreshToken, scope=$scope, tokenType=$tokenType, expiresIn=$expiresIn, expiration=$expiration, instanceId=$instanceId, pinCode=$pinCode, role=$role]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@ -122,6 +133,11 @@ class TokenDTO {
|
||||
} else {
|
||||
json[r'pinCode'] = null;
|
||||
}
|
||||
if (this.role != null) {
|
||||
json[r'role'] = this.role;
|
||||
} else {
|
||||
json[r'role'] = null;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@ -154,6 +170,7 @@ class TokenDTO {
|
||||
expiration: mapDateTime(json, r'expiration', r''),
|
||||
instanceId: mapValueOfType<String>(json, r'instanceId'),
|
||||
pinCode: mapValueOfType<String>(json, r'pinCode'),
|
||||
role: UserRole.fromJson(json[r'role']),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
|
||||
@ -18,6 +18,8 @@ class UserDetailDTO {
|
||||
this.firstName,
|
||||
this.lastName,
|
||||
this.instanceId,
|
||||
this.role,
|
||||
this.password,
|
||||
});
|
||||
|
||||
String? id;
|
||||
@ -30,6 +32,10 @@ class UserDetailDTO {
|
||||
|
||||
String? instanceId;
|
||||
|
||||
UserDetailDTORole? role;
|
||||
|
||||
String? password;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) =>
|
||||
identical(this, other) ||
|
||||
@ -38,7 +44,9 @@ class UserDetailDTO {
|
||||
other.email == email &&
|
||||
other.firstName == firstName &&
|
||||
other.lastName == lastName &&
|
||||
other.instanceId == instanceId;
|
||||
other.instanceId == instanceId &&
|
||||
other.role == role &&
|
||||
other.password == password;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
@ -47,11 +55,13 @@ class UserDetailDTO {
|
||||
(email == null ? 0 : email!.hashCode) +
|
||||
(firstName == null ? 0 : firstName!.hashCode) +
|
||||
(lastName == null ? 0 : lastName!.hashCode) +
|
||||
(instanceId == null ? 0 : instanceId!.hashCode);
|
||||
(instanceId == null ? 0 : instanceId!.hashCode) +
|
||||
(role == null ? 0 : role!.hashCode) +
|
||||
(password == null ? 0 : password!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() =>
|
||||
'UserDetailDTO[id=$id, email=$email, firstName=$firstName, lastName=$lastName, instanceId=$instanceId]';
|
||||
'UserDetailDTO[id=$id, email=$email, firstName=$firstName, lastName=$lastName, instanceId=$instanceId, role=$role, password=$password]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@ -80,6 +90,16 @@ class UserDetailDTO {
|
||||
} else {
|
||||
json[r'instanceId'] = null;
|
||||
}
|
||||
if (this.role != null) {
|
||||
json[r'role'] = this.role;
|
||||
} else {
|
||||
json[r'role'] = null;
|
||||
}
|
||||
if (this.password != null) {
|
||||
json[r'password'] = this.password;
|
||||
} else {
|
||||
json[r'password'] = null;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
@ -109,6 +129,8 @@ class UserDetailDTO {
|
||||
firstName: mapValueOfType<String>(json, r'firstName'),
|
||||
lastName: mapValueOfType<String>(json, r'lastName'),
|
||||
instanceId: mapValueOfType<String>(json, r'instanceId'),
|
||||
role: UserDetailDTORole.fromJson(json[r'role']),
|
||||
password: mapValueOfType<String>(json, r'password'),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
|
||||
100
manager_api_new/lib/model/user_detail_dto_role.dart
Normal file
100
manager_api_new/lib/model/user_detail_dto_role.dart
Normal file
@ -0,0 +1,100 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
class UserDetailDTORole {
|
||||
/// Returns a new [UserDetailDTORole] instance.
|
||||
UserDetailDTORole();
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is UserDetailDTORole;
|
||||
|
||||
/*@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
|
||||
@override
|
||||
String toString() => 'UserDetailDTORole[]';*/
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [UserDetailDTORole] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static UserDetailDTORole? fromJson(dynamic value) {
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
// Ensure that the map contains the required keys.
|
||||
// Note 1: the values aren't checked for validity beyond being non-null.
|
||||
// Note 2: this code is stripped in release mode!
|
||||
assert(() {
|
||||
requiredKeys.forEach((key) {
|
||||
assert(json.containsKey(key), 'Required key "UserDetailDTORole[$key]" is missing from JSON.');
|
||||
assert(json[key] != null, 'Required key "UserDetailDTORole[$key]" has a null value in JSON.');
|
||||
});
|
||||
return true;
|
||||
}());
|
||||
|
||||
return UserDetailDTORole(
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<UserDetailDTORole> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <UserDetailDTORole>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = UserDetailDTORole.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, UserDetailDTORole> mapFromJson(dynamic json) {
|
||||
final map = <String, UserDetailDTORole>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = UserDetailDTORole.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of UserDetailDTORole-objects as value to a dart map
|
||||
static Map<String, List<UserDetailDTORole>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<UserDetailDTORole>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = UserDetailDTORole.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
99
manager_api_new/lib/model/user_role.dart
Normal file
99
manager_api_new/lib/model/user_role.dart
Normal file
@ -0,0 +1,99 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
/// 0 = SuperAdmin 1 = InstanceAdmin 2 = ContentEditor 3 = Viewer
|
||||
class UserRole {
|
||||
/// Instantiate a new enum with the provided [value].
|
||||
const UserRole._(this.value);
|
||||
|
||||
/// The underlying value of this enum member.
|
||||
final int value;
|
||||
|
||||
@override
|
||||
String toString() => value.toString();
|
||||
|
||||
int toJson() => value;
|
||||
|
||||
static const number0 = UserRole._(0);
|
||||
static const number1 = UserRole._(1);
|
||||
static const number2 = UserRole._(2);
|
||||
static const number3 = UserRole._(3);
|
||||
|
||||
/// List of all possible values in this [enum][UserRole].
|
||||
static const values = <UserRole>[
|
||||
number0,
|
||||
number1,
|
||||
number2,
|
||||
number3,
|
||||
];
|
||||
|
||||
static UserRole? fromJson(dynamic value) =>
|
||||
UserRoleTypeTransformer().decode(value);
|
||||
|
||||
static List<UserRole> listFromJson(
|
||||
dynamic json, {
|
||||
bool growable = false,
|
||||
}) {
|
||||
final result = <UserRole>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = UserRole.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
}
|
||||
|
||||
/// Transformation class that can [encode] an instance of [UserRole] to int,
|
||||
/// and [decode] dynamic data back to [UserRole].
|
||||
class UserRoleTypeTransformer {
|
||||
factory UserRoleTypeTransformer() =>
|
||||
_instance ??= const UserRoleTypeTransformer._();
|
||||
|
||||
const UserRoleTypeTransformer._();
|
||||
|
||||
int encode(UserRole data) => data.value;
|
||||
|
||||
/// Decodes a [dynamic value][data] to a UserRole.
|
||||
///
|
||||
/// If [allowNull] is true and the [dynamic value][data] cannot be decoded successfully,
|
||||
/// then null is returned. However, if [allowNull] is false and the [dynamic value][data]
|
||||
/// cannot be decoded successfully, then an [UnimplementedError] is thrown.
|
||||
///
|
||||
/// The [allowNull] is very handy when an API changes and a new enum value is added or removed,
|
||||
/// and users are still using an old app with the old code.
|
||||
UserRole? decode(dynamic data, {bool allowNull = true}) {
|
||||
if (data != null) {
|
||||
switch (data) {
|
||||
case 0:
|
||||
return UserRole.number0;
|
||||
case 1:
|
||||
return UserRole.number1;
|
||||
case 2:
|
||||
return UserRole.number2;
|
||||
case 3:
|
||||
return UserRole.number3;
|
||||
default:
|
||||
if (!allowNull) {
|
||||
throw ArgumentError('Unknown enum value to decode: $data');
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Singleton [UserRoleTypeTransformer] instance.
|
||||
static UserRoleTypeTransformer? _instance;
|
||||
}
|
||||
16
manager_api_new/lib/model/user_role_extensions.dart
Normal file
16
manager_api_new/lib/model/user_role_extensions.dart
Normal file
@ -0,0 +1,16 @@
|
||||
// @dart=2.18
|
||||
|
||||
part of openapi.api;
|
||||
|
||||
/// Extension ajoutant le nom string à [UserRole], synchronisé avec l'enum C# backend.
|
||||
extension UserRoleName on UserRole {
|
||||
String get name {
|
||||
switch (value) {
|
||||
case 0: return 'SuperAdmin';
|
||||
case 1: return 'InstanceAdmin';
|
||||
case 2: return 'ContentEditor';
|
||||
case 3: return 'Viewer';
|
||||
default: return value.toString();
|
||||
}
|
||||
}
|
||||
}
|
||||
34
manager_api_new/test/api_key_api_test.dart
Normal file
34
manager_api_new/test/api_key_api_test.dart
Normal file
@ -0,0 +1,34 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
import 'package:manager_api_new/api.dart';
|
||||
import 'package:test/test.dart';
|
||||
|
||||
/// tests for ApiKeyApi
|
||||
void main() {
|
||||
// final instance = ApiKeyApi();
|
||||
|
||||
group('tests for ApiKeyApi', () {
|
||||
//Future<MultipartFile> apiKeyCreateApiKey(CreateApiKeyRequest createApiKeyRequest) async
|
||||
test('test apiKeyCreateApiKey', () async {
|
||||
// TODO
|
||||
});
|
||||
|
||||
//Future<MultipartFile> apiKeyGetApiKeys() async
|
||||
test('test apiKeyGetApiKeys', () async {
|
||||
// TODO
|
||||
});
|
||||
|
||||
//Future<MultipartFile> apiKeyRevokeApiKey(String id) async
|
||||
test('test apiKeyRevokeApiKey', () async {
|
||||
// TODO
|
||||
});
|
||||
});
|
||||
}
|
||||
17
manager_api_new/test/api_key_app_type_test.dart
Normal file
17
manager_api_new/test/api_key_app_type_test.dart
Normal file
@ -0,0 +1,17 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
import 'package:manager_api_new/api.dart';
|
||||
import 'package:test/test.dart';
|
||||
|
||||
// tests for ApiKeyAppType
|
||||
void main() {
|
||||
group('test ApiKeyAppType', () {});
|
||||
}
|
||||
29
manager_api_new/test/create_api_key_request_test.dart
Normal file
29
manager_api_new/test/create_api_key_request_test.dart
Normal file
@ -0,0 +1,29 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
import 'package:manager_api_new/api.dart';
|
||||
import 'package:test/test.dart';
|
||||
|
||||
// tests for CreateApiKeyRequest
|
||||
void main() {
|
||||
// final instance = CreateApiKeyRequest();
|
||||
|
||||
group('test CreateApiKeyRequest', () {
|
||||
// String name
|
||||
test('to test the property `name`', () async {
|
||||
// TODO
|
||||
});
|
||||
|
||||
// ApiKeyAppType appType
|
||||
test('to test the property `appType`', () async {
|
||||
// TODO
|
||||
});
|
||||
});
|
||||
}
|
||||
19
manager_api_new/test/user_detail_dto_role_test.dart
Normal file
19
manager_api_new/test/user_detail_dto_role_test.dart
Normal file
@ -0,0 +1,19 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
import 'package:manager_api_new/api.dart';
|
||||
import 'package:test/test.dart';
|
||||
|
||||
// tests for UserDetailDTORole
|
||||
void main() {
|
||||
// final instance = UserDetailDTORole();
|
||||
|
||||
group('test UserDetailDTORole', () {});
|
||||
}
|
||||
17
manager_api_new/test/user_role_test.dart
Normal file
17
manager_api_new/test/user_role_test.dart
Normal file
@ -0,0 +1,17 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// ignore_for_file: unused_element, unused_import
|
||||
// ignore_for_file: always_put_required_named_parameters_first
|
||||
// ignore_for_file: constant_identifier_names
|
||||
// ignore_for_file: lines_longer_than_80_chars
|
||||
|
||||
import 'package:manager_api_new/api.dart';
|
||||
import 'package:test/test.dart';
|
||||
|
||||
// tests for UserRole
|
||||
void main() {
|
||||
group('test UserRole', () {});
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user