feat(server): improve API specification (#1853)
This commit is contained in:
parent
da9b9c8c69
commit
9323cc76d9
41 changed files with 1690 additions and 396 deletions
16
mobile/openapi/README.md
generated
16
mobile/openapi/README.md
generated
|
@ -39,6 +39,16 @@ Please follow the [installation procedure](#installation--usage) and then run th
|
|||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = APIKeyApi();
|
||||
final aPIKeyCreateDto = APIKeyCreateDto(); // APIKeyCreateDto |
|
||||
|
@ -231,6 +241,12 @@ Class | Method | HTTP request | Description
|
|||
|
||||
- **Type**: HTTP Bearer authentication
|
||||
|
||||
## cookie
|
||||
|
||||
- **Type**: API key
|
||||
- **API key parameter name**: immich_access_token
|
||||
- **Location**:
|
||||
|
||||
|
||||
## Author
|
||||
|
||||
|
|
60
mobile/openapi/doc/APIKeyApi.md
generated
60
mobile/openapi/doc/APIKeyApi.md
generated
|
@ -26,6 +26,16 @@ Method | HTTP request | Description
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = APIKeyApi();
|
||||
final aPIKeyCreateDto = APIKeyCreateDto(); // APIKeyCreateDto |
|
||||
|
@ -50,7 +60,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -69,6 +79,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = APIKeyApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -92,7 +112,7 @@ void (empty response body)
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -111,6 +131,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = APIKeyApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -135,7 +165,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -154,6 +184,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = APIKeyApi();
|
||||
|
||||
|
@ -174,7 +214,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -193,6 +233,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = APIKeyApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -219,7 +269,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
94
mobile/openapi/doc/AlbumApi.md
generated
94
mobile/openapi/doc/AlbumApi.md
generated
|
@ -24,7 +24,7 @@ Method | HTTP request | Description
|
|||
|
||||
|
||||
# **addAssetsToAlbum**
|
||||
> AddAssetsResponseDto addAssetsToAlbum(albumId, addAssetsDto)
|
||||
> AddAssetsResponseDto addAssetsToAlbum(albumId, addAssetsDto, key)
|
||||
|
||||
|
||||
|
||||
|
@ -39,13 +39,18 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final albumId = albumId_example; // String |
|
||||
final addAssetsDto = AddAssetsDto(); // AddAssetsDto |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.addAssetsToAlbum(albumId, addAssetsDto);
|
||||
final result = api_instance.addAssetsToAlbum(albumId, addAssetsDto, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AlbumApi->addAssetsToAlbum: $e\n');
|
||||
|
@ -58,6 +63,7 @@ Name | Type | Description | Notes
|
|||
------------- | ------------- | ------------- | -------------
|
||||
**albumId** | **String**| |
|
||||
**addAssetsDto** | [**AddAssetsDto**](AddAssetsDto.md)| |
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
|
@ -65,7 +71,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -90,6 +96,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final albumId = albumId_example; // String |
|
||||
|
@ -116,7 +126,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -141,6 +151,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final createAlbumDto = CreateAlbumDto(); // CreateAlbumDto |
|
||||
|
@ -165,7 +179,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -190,6 +204,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final createAlbumShareLinkDto = CreateAlbumShareLinkDto(); // CreateAlbumShareLinkDto |
|
||||
|
@ -214,7 +232,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -239,6 +257,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final albumId = albumId_example; // String |
|
||||
|
@ -262,7 +284,7 @@ void (empty response body)
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -272,7 +294,7 @@ void (empty response body)
|
|||
[[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)
|
||||
|
||||
# **downloadArchive**
|
||||
> Object downloadArchive(albumId, skip)
|
||||
> MultipartFile downloadArchive(albumId, skip, key)
|
||||
|
||||
|
||||
|
||||
|
@ -287,13 +309,18 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final albumId = albumId_example; // String |
|
||||
final skip = 8.14; // num |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.downloadArchive(albumId, skip);
|
||||
final result = api_instance.downloadArchive(albumId, skip, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AlbumApi->downloadArchive: $e\n');
|
||||
|
@ -306,19 +333,20 @@ Name | Type | Description | Notes
|
|||
------------- | ------------- | ------------- | -------------
|
||||
**albumId** | **String**| |
|
||||
**skip** | **num**| | [optional]
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**Object**](Object.md)
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json
|
||||
- **Accept**: application/zip
|
||||
|
||||
[[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)
|
||||
|
||||
|
@ -338,6 +366,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
|
||||
|
@ -358,7 +390,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -368,7 +400,7 @@ 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)
|
||||
|
||||
# **getAlbumInfo**
|
||||
> AlbumResponseDto getAlbumInfo(albumId)
|
||||
> AlbumResponseDto getAlbumInfo(albumId, key)
|
||||
|
||||
|
||||
|
||||
|
@ -383,12 +415,17 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final albumId = albumId_example; // String |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.getAlbumInfo(albumId);
|
||||
final result = api_instance.getAlbumInfo(albumId, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AlbumApi->getAlbumInfo: $e\n');
|
||||
|
@ -400,6 +437,7 @@ try {
|
|||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**albumId** | **String**| |
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
|
@ -407,7 +445,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -432,6 +470,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final shared = true; // bool |
|
||||
|
@ -458,7 +500,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -483,6 +525,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final albumId = albumId_example; // String |
|
||||
|
@ -509,7 +555,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -534,6 +580,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final albumId = albumId_example; // String |
|
||||
|
@ -559,7 +609,7 @@ void (empty response body)
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -584,6 +634,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AlbumApi();
|
||||
final albumId = albumId_example; // String |
|
||||
|
@ -610,7 +664,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
218
mobile/openapi/doc/AssetApi.md
generated
218
mobile/openapi/doc/AssetApi.md
generated
|
@ -35,7 +35,7 @@ Method | HTTP request | Description
|
|||
|
||||
|
||||
# **addAssetsToSharedLink**
|
||||
> SharedLinkResponseDto addAssetsToSharedLink(addAssetsDto)
|
||||
> SharedLinkResponseDto addAssetsToSharedLink(addAssetsDto, key)
|
||||
|
||||
|
||||
|
||||
|
@ -50,12 +50,17 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final addAssetsDto = AddAssetsDto(); // AddAssetsDto |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.addAssetsToSharedLink(addAssetsDto);
|
||||
final result = api_instance.addAssetsToSharedLink(addAssetsDto, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->addAssetsToSharedLink: $e\n');
|
||||
|
@ -67,6 +72,7 @@ try {
|
|||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**addAssetsDto** | [**AddAssetsDto**](AddAssetsDto.md)| |
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
|
@ -74,7 +80,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -84,7 +90,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)
|
||||
|
||||
# **checkDuplicateAsset**
|
||||
> CheckDuplicateAssetResponseDto checkDuplicateAsset(checkDuplicateAssetDto)
|
||||
> CheckDuplicateAssetResponseDto checkDuplicateAsset(checkDuplicateAssetDto, key)
|
||||
|
||||
|
||||
|
||||
|
@ -99,12 +105,17 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final checkDuplicateAssetDto = CheckDuplicateAssetDto(); // CheckDuplicateAssetDto |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.checkDuplicateAsset(checkDuplicateAssetDto);
|
||||
final result = api_instance.checkDuplicateAsset(checkDuplicateAssetDto, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->checkDuplicateAsset: $e\n');
|
||||
|
@ -116,6 +127,7 @@ try {
|
|||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**checkDuplicateAssetDto** | [**CheckDuplicateAssetDto**](CheckDuplicateAssetDto.md)| |
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
|
@ -123,7 +135,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -148,6 +160,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final checkExistingAssetsDto = CheckExistingAssetsDto(); // CheckExistingAssetsDto |
|
||||
|
@ -172,7 +188,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -197,6 +213,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final createAssetsShareLinkDto = CreateAssetsShareLinkDto(); // CreateAssetsShareLinkDto |
|
||||
|
@ -221,7 +241,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -246,6 +266,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final deleteAssetDto = DeleteAssetDto(); // DeleteAssetDto |
|
||||
|
@ -270,7 +294,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -280,7 +304,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)
|
||||
|
||||
# **downloadFile**
|
||||
> Object downloadFile(assetId)
|
||||
> MultipartFile downloadFile(assetId, key)
|
||||
|
||||
|
||||
|
||||
|
@ -295,12 +319,17 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final assetId = assetId_example; // String |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.downloadFile(assetId);
|
||||
final result = api_instance.downloadFile(assetId, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->downloadFile: $e\n');
|
||||
|
@ -312,24 +341,25 @@ try {
|
|||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**assetId** | **String**| |
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**Object**](Object.md)
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
# **downloadFiles**
|
||||
> Object downloadFiles(downloadFilesDto)
|
||||
> MultipartFile downloadFiles(downloadFilesDto, key)
|
||||
|
||||
|
||||
|
||||
|
@ -344,12 +374,17 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final downloadFilesDto = DownloadFilesDto(); // DownloadFilesDto |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.downloadFiles(downloadFilesDto);
|
||||
final result = api_instance.downloadFiles(downloadFilesDto, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->downloadFiles: $e\n');
|
||||
|
@ -361,24 +396,25 @@ try {
|
|||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**downloadFilesDto** | [**DownloadFilesDto**](DownloadFilesDto.md)| |
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**Object**](Object.md)
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: 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)
|
||||
|
||||
# **downloadLibrary**
|
||||
> Object downloadLibrary(skip)
|
||||
> MultipartFile downloadLibrary(skip, key)
|
||||
|
||||
|
||||
|
||||
|
@ -393,12 +429,17 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final skip = 8.14; // num |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.downloadLibrary(skip);
|
||||
final result = api_instance.downloadLibrary(skip, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->downloadLibrary: $e\n');
|
||||
|
@ -410,19 +451,20 @@ try {
|
|||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**skip** | **num**| | [optional]
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**Object**](Object.md)
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
|
@ -442,6 +484,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final isFavorite = true; // bool |
|
||||
|
@ -470,7 +516,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -480,7 +526,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)
|
||||
|
||||
# **getAssetById**
|
||||
> AssetResponseDto getAssetById(assetId)
|
||||
> AssetResponseDto getAssetById(assetId, key)
|
||||
|
||||
|
||||
|
||||
|
@ -495,12 +541,17 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final assetId = assetId_example; // String |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.getAssetById(assetId);
|
||||
final result = api_instance.getAssetById(assetId, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->getAssetById: $e\n');
|
||||
|
@ -512,6 +563,7 @@ try {
|
|||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**assetId** | **String**| |
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
|
@ -519,7 +571,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -544,6 +596,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final getAssetByTimeBucketDto = GetAssetByTimeBucketDto(); // GetAssetByTimeBucketDto |
|
||||
|
@ -568,7 +624,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -593,6 +649,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final getAssetCountByTimeBucketDto = GetAssetCountByTimeBucketDto(); // GetAssetCountByTimeBucketDto |
|
||||
|
@ -617,7 +677,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -642,6 +702,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
|
||||
|
@ -662,7 +726,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -687,6 +751,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
|
||||
|
@ -707,7 +775,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -717,7 +785,7 @@ 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)
|
||||
|
||||
# **getAssetThumbnail**
|
||||
> Object getAssetThumbnail(assetId, format)
|
||||
> MultipartFile getAssetThumbnail(assetId, format, key)
|
||||
|
||||
|
||||
|
||||
|
@ -732,13 +800,18 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final assetId = assetId_example; // String |
|
||||
final format = ; // ThumbnailFormat |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.getAssetThumbnail(assetId, format);
|
||||
final result = api_instance.getAssetThumbnail(assetId, format, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->getAssetThumbnail: $e\n');
|
||||
|
@ -751,19 +824,20 @@ Name | Type | Description | Notes
|
|||
------------- | ------------- | ------------- | -------------
|
||||
**assetId** | **String**| |
|
||||
**format** | [**ThumbnailFormat**](.md)| | [optional]
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**Object**](Object.md)
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
|
@ -783,6 +857,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
|
||||
|
@ -803,7 +881,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -828,6 +906,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
|
||||
|
@ -848,7 +930,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -873,6 +955,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final deviceId = deviceId_example; // String |
|
||||
|
@ -897,7 +983,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -907,7 +993,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)
|
||||
|
||||
# **removeAssetsFromSharedLink**
|
||||
> SharedLinkResponseDto removeAssetsFromSharedLink(removeAssetsDto)
|
||||
> SharedLinkResponseDto removeAssetsFromSharedLink(removeAssetsDto, key)
|
||||
|
||||
|
||||
|
||||
|
@ -922,12 +1008,17 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final removeAssetsDto = RemoveAssetsDto(); // RemoveAssetsDto |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.removeAssetsFromSharedLink(removeAssetsDto);
|
||||
final result = api_instance.removeAssetsFromSharedLink(removeAssetsDto, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->removeAssetsFromSharedLink: $e\n');
|
||||
|
@ -939,6 +1030,7 @@ try {
|
|||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**removeAssetsDto** | [**RemoveAssetsDto**](RemoveAssetsDto.md)| |
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
|
@ -946,7 +1038,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -971,6 +1063,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final searchAssetDto = SearchAssetDto(); // SearchAssetDto |
|
||||
|
@ -995,7 +1091,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -1005,7 +1101,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)
|
||||
|
||||
# **serveFile**
|
||||
> Object serveFile(assetId, isThumb, isWeb)
|
||||
> MultipartFile serveFile(assetId, isThumb, isWeb, key)
|
||||
|
||||
|
||||
|
||||
|
@ -1020,14 +1116,19 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final assetId = assetId_example; // String |
|
||||
final isThumb = true; // bool |
|
||||
final isWeb = true; // bool |
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.serveFile(assetId, isThumb, isWeb);
|
||||
final result = api_instance.serveFile(assetId, isThumb, isWeb, key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->serveFile: $e\n');
|
||||
|
@ -1041,19 +1142,20 @@ Name | Type | Description | Notes
|
|||
**assetId** | **String**| |
|
||||
**isThumb** | **bool**| | [optional]
|
||||
**isWeb** | **bool**| | [optional]
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**Object**](Object.md)
|
||||
[**MultipartFile**](MultipartFile.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
|
@ -1073,6 +1175,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final assetId = assetId_example; // String |
|
||||
|
@ -1099,7 +1205,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -1109,7 +1215,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)
|
||||
|
||||
# **uploadFile**
|
||||
> AssetFileUploadResponseDto uploadFile(assetType, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, fileExtension, livePhotoData, isVisible, duration)
|
||||
> AssetFileUploadResponseDto uploadFile(assetType, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, fileExtension, key, livePhotoData, isVisible, duration)
|
||||
|
||||
|
||||
|
||||
|
@ -1124,6 +1230,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AssetApi();
|
||||
final assetType = ; // AssetTypeEnum |
|
||||
|
@ -1134,12 +1244,13 @@ final fileCreatedAt = fileCreatedAt_example; // String |
|
|||
final fileModifiedAt = fileModifiedAt_example; // String |
|
||||
final isFavorite = true; // bool |
|
||||
final fileExtension = fileExtension_example; // String |
|
||||
final key = key_example; // String |
|
||||
final livePhotoData = BINARY_DATA_HERE; // MultipartFile |
|
||||
final isVisible = true; // bool |
|
||||
final duration = duration_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.uploadFile(assetType, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, fileExtension, livePhotoData, isVisible, duration);
|
||||
final result = api_instance.uploadFile(assetType, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, fileExtension, key, livePhotoData, isVisible, duration);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling AssetApi->uploadFile: $e\n');
|
||||
|
@ -1158,6 +1269,7 @@ Name | Type | Description | Notes
|
|||
**fileModifiedAt** | **String**| |
|
||||
**isFavorite** | **bool**| |
|
||||
**fileExtension** | **String**| |
|
||||
**key** | **String**| | [optional]
|
||||
**livePhotoData** | **MultipartFile**| | [optional]
|
||||
**isVisible** | **bool**| | [optional]
|
||||
**duration** | **String**| | [optional]
|
||||
|
@ -1168,7 +1280,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
24
mobile/openapi/doc/AuthenticationApi.md
generated
24
mobile/openapi/doc/AuthenticationApi.md
generated
|
@ -75,6 +75,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AuthenticationApi();
|
||||
final changePasswordDto = ChangePasswordDto(); // ChangePasswordDto |
|
||||
|
@ -99,7 +103,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -161,6 +165,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AuthenticationApi();
|
||||
|
||||
|
@ -181,7 +195,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -206,6 +220,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = AuthenticationApi();
|
||||
|
||||
|
@ -226,7 +244,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
6
mobile/openapi/doc/DeviceInfoApi.md
generated
6
mobile/openapi/doc/DeviceInfoApi.md
generated
|
@ -28,6 +28,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = DeviceInfoApi();
|
||||
final upsertDeviceInfoDto = UpsertDeviceInfoDto(); // UpsertDeviceInfoDto |
|
||||
|
@ -52,7 +56,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
12
mobile/openapi/doc/JobApi.md
generated
12
mobile/openapi/doc/JobApi.md
generated
|
@ -29,6 +29,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = JobApi();
|
||||
|
||||
|
@ -49,7 +53,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -74,6 +78,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = JobApi();
|
||||
final jobId = ; // JobId |
|
||||
|
@ -100,7 +108,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
24
mobile/openapi/doc/OAuthApi.md
generated
24
mobile/openapi/doc/OAuthApi.md
generated
|
@ -112,6 +112,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = OAuthApi();
|
||||
final oAuthCallbackDto = OAuthCallbackDto(); // OAuthCallbackDto |
|
||||
|
@ -136,7 +146,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -193,6 +203,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = OAuthApi();
|
||||
|
||||
|
@ -213,7 +233,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
12
mobile/openapi/doc/ServerInfoApi.md
generated
12
mobile/openapi/doc/ServerInfoApi.md
generated
|
@ -103,6 +103,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = ServerInfoApi();
|
||||
|
||||
|
@ -123,7 +133,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
70
mobile/openapi/doc/ShareApi.md
generated
70
mobile/openapi/doc/ShareApi.md
generated
|
@ -26,6 +26,16 @@ Method | HTTP request | Description
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = ShareApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -52,7 +62,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -71,6 +81,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = ShareApi();
|
||||
|
||||
|
@ -91,7 +111,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -101,7 +121,7 @@ No authorization required
|
|||
[[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)
|
||||
|
||||
# **getMySharedLink**
|
||||
> SharedLinkResponseDto getMySharedLink()
|
||||
> SharedLinkResponseDto getMySharedLink(key)
|
||||
|
||||
|
||||
|
||||
|
@ -110,11 +130,22 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = ShareApi();
|
||||
final key = key_example; // String |
|
||||
|
||||
try {
|
||||
final result = api_instance.getMySharedLink();
|
||||
final result = api_instance.getMySharedLink(key);
|
||||
print(result);
|
||||
} catch (e) {
|
||||
print('Exception when calling ShareApi->getMySharedLink: $e\n');
|
||||
|
@ -122,7 +153,10 @@ try {
|
|||
```
|
||||
|
||||
### Parameters
|
||||
This endpoint does not need any parameter.
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**key** | **String**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
|
@ -130,7 +164,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -149,6 +183,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = ShareApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -173,7 +217,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -192,6 +236,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = ShareApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -215,7 +269,7 @@ void (empty response body)
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
24
mobile/openapi/doc/SystemConfigApi.md
generated
24
mobile/openapi/doc/SystemConfigApi.md
generated
|
@ -31,6 +31,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = SystemConfigApi();
|
||||
|
||||
|
@ -51,7 +55,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -76,6 +80,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = SystemConfigApi();
|
||||
|
||||
|
@ -96,7 +104,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -121,6 +129,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = SystemConfigApi();
|
||||
|
||||
|
@ -141,7 +153,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -166,6 +178,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = SystemConfigApi();
|
||||
final systemConfigDto = SystemConfigDto(); // SystemConfigDto |
|
||||
|
@ -190,7 +206,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
60
mobile/openapi/doc/TagApi.md
generated
60
mobile/openapi/doc/TagApi.md
generated
|
@ -26,6 +26,16 @@ Method | HTTP request | Description
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = TagApi();
|
||||
final createTagDto = CreateTagDto(); // CreateTagDto |
|
||||
|
@ -50,7 +60,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -69,6 +79,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = TagApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -92,7 +112,7 @@ void (empty response body)
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -111,6 +131,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = TagApi();
|
||||
|
||||
|
@ -131,7 +161,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -150,6 +180,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = TagApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -174,7 +214,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -193,6 +233,16 @@ No authorization required
|
|||
### Example
|
||||
```dart
|
||||
import 'package:openapi/api.dart';
|
||||
// TODO Configure HTTP Bearer authorization: bearer
|
||||
// Case 1. Use String Token
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken('YOUR_ACCESS_TOKEN');
|
||||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = TagApi();
|
||||
final id = id_example; // String |
|
||||
|
@ -219,7 +269,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
42
mobile/openapi/doc/UserApi.md
generated
42
mobile/openapi/doc/UserApi.md
generated
|
@ -37,6 +37,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = UserApi();
|
||||
final file = BINARY_DATA_HERE; // MultipartFile |
|
||||
|
@ -61,7 +65,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -86,6 +90,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = UserApi();
|
||||
final createUserDto = CreateUserDto(); // CreateUserDto |
|
||||
|
@ -110,7 +118,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -135,6 +143,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = UserApi();
|
||||
final userId = userId_example; // String |
|
||||
|
@ -159,7 +171,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -184,6 +196,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = UserApi();
|
||||
final isAll = true; // bool |
|
||||
|
@ -208,7 +224,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -233,6 +249,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = UserApi();
|
||||
|
||||
|
@ -253,7 +273,7 @@ This endpoint does not need any parameter.
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -407,6 +427,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = UserApi();
|
||||
final userId = userId_example; // String |
|
||||
|
@ -431,7 +455,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
@ -456,6 +480,10 @@ import 'package:openapi/api.dart';
|
|||
// Case 2. Use Function which generate token.
|
||||
// String yourTokenGeneratorFunction() { ... }
|
||||
//defaultApiClient.getAuthentication<HttpBearerAuth>('bearer').setAccessToken(yourTokenGeneratorFunction);
|
||||
// TODO Configure API key authorization: cookie
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKey = 'YOUR_API_KEY';
|
||||
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
//defaultApiClient.getAuthentication<ApiKeyAuth>('cookie').apiKeyPrefix = 'Bearer';
|
||||
|
||||
final api_instance = UserApi();
|
||||
final updateUserDto = UpdateUserDto(); // UpdateUserDto |
|
||||
|
@ -480,7 +508,7 @@ Name | Type | Description | Notes
|
|||
|
||||
### Authorization
|
||||
|
||||
[bearer](../README.md#bearer)
|
||||
[bearer](../README.md#bearer), [cookie](../README.md#cookie)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
|
|
43
mobile/openapi/lib/api/album_api.dart
generated
43
mobile/openapi/lib/api/album_api.dart
generated
|
@ -25,7 +25,9 @@ class AlbumApi {
|
|||
/// * [String] albumId (required):
|
||||
///
|
||||
/// * [AddAssetsDto] addAssetsDto (required):
|
||||
Future<Response> addAssetsToAlbumWithHttpInfo(String albumId, AddAssetsDto addAssetsDto,) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> addAssetsToAlbumWithHttpInfo(String albumId, AddAssetsDto addAssetsDto, { String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/album/{albumId}/assets'
|
||||
.replaceAll('{albumId}', albumId);
|
||||
|
@ -37,6 +39,10 @@ class AlbumApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
|
||||
|
@ -58,8 +64,10 @@ class AlbumApi {
|
|||
/// * [String] albumId (required):
|
||||
///
|
||||
/// * [AddAssetsDto] addAssetsDto (required):
|
||||
Future<AddAssetsResponseDto?> addAssetsToAlbum(String albumId, AddAssetsDto addAssetsDto,) async {
|
||||
final response = await addAssetsToAlbumWithHttpInfo(albumId, addAssetsDto,);
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<AddAssetsResponseDto?> addAssetsToAlbum(String albumId, AddAssetsDto addAssetsDto, { String? key, }) async {
|
||||
final response = await addAssetsToAlbumWithHttpInfo(albumId, addAssetsDto, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -288,7 +296,9 @@ class AlbumApi {
|
|||
/// * [String] albumId (required):
|
||||
///
|
||||
/// * [num] skip:
|
||||
Future<Response> downloadArchiveWithHttpInfo(String albumId, { num? skip, }) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> downloadArchiveWithHttpInfo(String albumId, { num? skip, String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/album/{albumId}/download'
|
||||
.replaceAll('{albumId}', albumId);
|
||||
|
@ -303,6 +313,9 @@ class AlbumApi {
|
|||
if (skip != null) {
|
||||
queryParams.addAll(_queryParams('', 'skip', skip));
|
||||
}
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
@ -325,8 +338,10 @@ class AlbumApi {
|
|||
/// * [String] albumId (required):
|
||||
///
|
||||
/// * [num] skip:
|
||||
Future<Object?> downloadArchive(String albumId, { num? skip, }) async {
|
||||
final response = await downloadArchiveWithHttpInfo(albumId, skip: skip, );
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> downloadArchive(String albumId, { num? skip, String? key, }) async {
|
||||
final response = await downloadArchiveWithHttpInfo(albumId, skip: skip, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -334,7 +349,7 @@ class AlbumApi {
|
|||
// 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 await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'MultipartFile',) as MultipartFile;
|
||||
|
||||
}
|
||||
return null;
|
||||
|
@ -391,7 +406,9 @@ class AlbumApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId (required):
|
||||
Future<Response> getAlbumInfoWithHttpInfo(String albumId,) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> getAlbumInfoWithHttpInfo(String albumId, { String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/album/{albumId}'
|
||||
.replaceAll('{albumId}', albumId);
|
||||
|
@ -403,6 +420,10 @@ class AlbumApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
|
@ -422,8 +443,10 @@ class AlbumApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [String] albumId (required):
|
||||
Future<AlbumResponseDto?> getAlbumInfo(String albumId,) async {
|
||||
final response = await getAlbumInfoWithHttpInfo(albumId,);
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<AlbumResponseDto?> getAlbumInfo(String albumId, { String? key, }) async {
|
||||
final response = await getAlbumInfoWithHttpInfo(albumId, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
|
147
mobile/openapi/lib/api/asset_api.dart
generated
147
mobile/openapi/lib/api/asset_api.dart
generated
|
@ -23,7 +23,9 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [AddAssetsDto] addAssetsDto (required):
|
||||
Future<Response> addAssetsToSharedLinkWithHttpInfo(AddAssetsDto addAssetsDto,) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> addAssetsToSharedLinkWithHttpInfo(AddAssetsDto addAssetsDto, { String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/shared-link/add';
|
||||
|
||||
|
@ -34,6 +36,10 @@ class AssetApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
|
||||
|
@ -53,8 +59,10 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [AddAssetsDto] addAssetsDto (required):
|
||||
Future<SharedLinkResponseDto?> addAssetsToSharedLink(AddAssetsDto addAssetsDto,) async {
|
||||
final response = await addAssetsToSharedLinkWithHttpInfo(addAssetsDto,);
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<SharedLinkResponseDto?> addAssetsToSharedLink(AddAssetsDto addAssetsDto, { String? key, }) async {
|
||||
final response = await addAssetsToSharedLinkWithHttpInfo(addAssetsDto, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -75,7 +83,9 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [CheckDuplicateAssetDto] checkDuplicateAssetDto (required):
|
||||
Future<Response> checkDuplicateAssetWithHttpInfo(CheckDuplicateAssetDto checkDuplicateAssetDto,) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> checkDuplicateAssetWithHttpInfo(CheckDuplicateAssetDto checkDuplicateAssetDto, { String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/check';
|
||||
|
||||
|
@ -86,6 +96,10 @@ class AssetApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
|
||||
|
@ -105,8 +119,10 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [CheckDuplicateAssetDto] checkDuplicateAssetDto (required):
|
||||
Future<CheckDuplicateAssetResponseDto?> checkDuplicateAsset(CheckDuplicateAssetDto checkDuplicateAssetDto,) async {
|
||||
final response = await checkDuplicateAssetWithHttpInfo(checkDuplicateAssetDto,);
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<CheckDuplicateAssetResponseDto?> checkDuplicateAsset(CheckDuplicateAssetDto checkDuplicateAssetDto, { String? key, }) async {
|
||||
final response = await checkDuplicateAssetWithHttpInfo(checkDuplicateAssetDto, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -286,7 +302,9 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [String] assetId (required):
|
||||
Future<Response> downloadFileWithHttpInfo(String assetId,) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> downloadFileWithHttpInfo(String assetId, { String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/download/{assetId}'
|
||||
.replaceAll('{assetId}', assetId);
|
||||
|
@ -298,6 +316,10 @@ class AssetApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
|
@ -317,8 +339,10 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [String] assetId (required):
|
||||
Future<Object?> downloadFile(String assetId,) async {
|
||||
final response = await downloadFileWithHttpInfo(assetId,);
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> downloadFile(String assetId, { String? key, }) async {
|
||||
final response = await downloadFileWithHttpInfo(assetId, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -326,7 +350,7 @@ class AssetApi {
|
|||
// 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 await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'MultipartFile',) as MultipartFile;
|
||||
|
||||
}
|
||||
return null;
|
||||
|
@ -339,7 +363,9 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [DownloadFilesDto] downloadFilesDto (required):
|
||||
Future<Response> downloadFilesWithHttpInfo(DownloadFilesDto downloadFilesDto,) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> downloadFilesWithHttpInfo(DownloadFilesDto downloadFilesDto, { String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/download-files';
|
||||
|
||||
|
@ -350,6 +376,10 @@ class AssetApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
|
||||
|
@ -369,8 +399,10 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [DownloadFilesDto] downloadFilesDto (required):
|
||||
Future<Object?> downloadFiles(DownloadFilesDto downloadFilesDto,) async {
|
||||
final response = await downloadFilesWithHttpInfo(downloadFilesDto,);
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> downloadFiles(DownloadFilesDto downloadFilesDto, { String? key, }) async {
|
||||
final response = await downloadFilesWithHttpInfo(downloadFilesDto, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -378,7 +410,7 @@ class AssetApi {
|
|||
// 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 await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'MultipartFile',) as MultipartFile;
|
||||
|
||||
}
|
||||
return null;
|
||||
|
@ -391,7 +423,9 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [num] skip:
|
||||
Future<Response> downloadLibraryWithHttpInfo({ num? skip, }) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> downloadLibraryWithHttpInfo({ num? skip, String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/download-library';
|
||||
|
||||
|
@ -405,6 +439,9 @@ class AssetApi {
|
|||
if (skip != null) {
|
||||
queryParams.addAll(_queryParams('', 'skip', skip));
|
||||
}
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
@ -425,8 +462,10 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [num] skip:
|
||||
Future<Object?> downloadLibrary({ num? skip, }) async {
|
||||
final response = await downloadLibraryWithHttpInfo( skip: skip, );
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> downloadLibrary({ num? skip, String? key, }) async {
|
||||
final response = await downloadLibraryWithHttpInfo( skip: skip, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -434,7 +473,7 @@ class AssetApi {
|
|||
// 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 await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'MultipartFile',) as MultipartFile;
|
||||
|
||||
}
|
||||
return null;
|
||||
|
@ -523,7 +562,9 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [String] assetId (required):
|
||||
Future<Response> getAssetByIdWithHttpInfo(String assetId,) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> getAssetByIdWithHttpInfo(String assetId, { String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/assetById/{assetId}'
|
||||
.replaceAll('{assetId}', assetId);
|
||||
|
@ -535,6 +576,10 @@ class AssetApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
|
@ -554,8 +599,10 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [String] assetId (required):
|
||||
Future<AssetResponseDto?> getAssetById(String assetId,) async {
|
||||
final response = await getAssetByIdWithHttpInfo(assetId,);
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<AssetResponseDto?> getAssetById(String assetId, { String? key, }) async {
|
||||
final response = await getAssetByIdWithHttpInfo(assetId, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -776,7 +823,9 @@ class AssetApi {
|
|||
/// * [String] assetId (required):
|
||||
///
|
||||
/// * [ThumbnailFormat] format:
|
||||
Future<Response> getAssetThumbnailWithHttpInfo(String assetId, { ThumbnailFormat? format, }) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> getAssetThumbnailWithHttpInfo(String assetId, { ThumbnailFormat? format, String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/thumbnail/{assetId}'
|
||||
.replaceAll('{assetId}', assetId);
|
||||
|
@ -791,6 +840,9 @@ class AssetApi {
|
|||
if (format != null) {
|
||||
queryParams.addAll(_queryParams('', 'format', format));
|
||||
}
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
@ -813,8 +865,10 @@ class AssetApi {
|
|||
/// * [String] assetId (required):
|
||||
///
|
||||
/// * [ThumbnailFormat] format:
|
||||
Future<Object?> getAssetThumbnail(String assetId, { ThumbnailFormat? format, }) async {
|
||||
final response = await getAssetThumbnailWithHttpInfo(assetId, format: format, );
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> getAssetThumbnail(String assetId, { ThumbnailFormat? format, String? key, }) async {
|
||||
final response = await getAssetThumbnailWithHttpInfo(assetId, format: format, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -822,7 +876,7 @@ class AssetApi {
|
|||
// 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 await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'MultipartFile',) as MultipartFile;
|
||||
|
||||
}
|
||||
return null;
|
||||
|
@ -985,7 +1039,9 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [RemoveAssetsDto] removeAssetsDto (required):
|
||||
Future<Response> removeAssetsFromSharedLinkWithHttpInfo(RemoveAssetsDto removeAssetsDto,) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> removeAssetsFromSharedLinkWithHttpInfo(RemoveAssetsDto removeAssetsDto, { String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/shared-link/remove';
|
||||
|
||||
|
@ -996,6 +1052,10 @@ class AssetApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['application/json'];
|
||||
|
||||
|
||||
|
@ -1015,8 +1075,10 @@ class AssetApi {
|
|||
/// Parameters:
|
||||
///
|
||||
/// * [RemoveAssetsDto] removeAssetsDto (required):
|
||||
Future<SharedLinkResponseDto?> removeAssetsFromSharedLink(RemoveAssetsDto removeAssetsDto,) async {
|
||||
final response = await removeAssetsFromSharedLinkWithHttpInfo(removeAssetsDto,);
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<SharedLinkResponseDto?> removeAssetsFromSharedLink(RemoveAssetsDto removeAssetsDto, { String? key, }) async {
|
||||
final response = await removeAssetsFromSharedLinkWithHttpInfo(removeAssetsDto, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -1096,7 +1158,9 @@ class AssetApi {
|
|||
/// * [bool] isThumb:
|
||||
///
|
||||
/// * [bool] isWeb:
|
||||
Future<Response> serveFileWithHttpInfo(String assetId, { bool? isThumb, bool? isWeb, }) async {
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> serveFileWithHttpInfo(String assetId, { bool? isThumb, bool? isWeb, String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/file/{assetId}'
|
||||
.replaceAll('{assetId}', assetId);
|
||||
|
@ -1114,6 +1178,9 @@ class AssetApi {
|
|||
if (isWeb != null) {
|
||||
queryParams.addAll(_queryParams('', 'isWeb', isWeb));
|
||||
}
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
@ -1138,8 +1205,10 @@ class AssetApi {
|
|||
/// * [bool] isThumb:
|
||||
///
|
||||
/// * [bool] isWeb:
|
||||
Future<Object?> serveFile(String assetId, { bool? isThumb, bool? isWeb, }) async {
|
||||
final response = await serveFileWithHttpInfo(assetId, isThumb: isThumb, isWeb: isWeb, );
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<MultipartFile?> serveFile(String assetId, { bool? isThumb, bool? isWeb, String? key, }) async {
|
||||
final response = await serveFileWithHttpInfo(assetId, isThumb: isThumb, isWeb: isWeb, key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
@ -1147,7 +1216,7 @@ class AssetApi {
|
|||
// 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 await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'MultipartFile',) as MultipartFile;
|
||||
|
||||
}
|
||||
return null;
|
||||
|
@ -1232,12 +1301,14 @@ class AssetApi {
|
|||
///
|
||||
/// * [String] fileExtension (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [MultipartFile] livePhotoData:
|
||||
///
|
||||
/// * [bool] isVisible:
|
||||
///
|
||||
/// * [String] duration:
|
||||
Future<Response> uploadFileWithHttpInfo(AssetTypeEnum assetType, MultipartFile assetData, String deviceAssetId, String deviceId, String fileCreatedAt, String fileModifiedAt, bool isFavorite, String fileExtension, { MultipartFile? livePhotoData, bool? isVisible, String? duration, }) async {
|
||||
Future<Response> uploadFileWithHttpInfo(AssetTypeEnum assetType, MultipartFile assetData, String deviceAssetId, String deviceId, String fileCreatedAt, String fileModifiedAt, bool isFavorite, String fileExtension, { String? key, MultipartFile? livePhotoData, bool? isVisible, String? duration, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/asset/upload';
|
||||
|
||||
|
@ -1248,6 +1319,10 @@ class AssetApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>['multipart/form-data'];
|
||||
|
||||
bool hasFields = false;
|
||||
|
@ -1333,13 +1408,15 @@ class AssetApi {
|
|||
///
|
||||
/// * [String] fileExtension (required):
|
||||
///
|
||||
/// * [String] key:
|
||||
///
|
||||
/// * [MultipartFile] livePhotoData:
|
||||
///
|
||||
/// * [bool] isVisible:
|
||||
///
|
||||
/// * [String] duration:
|
||||
Future<AssetFileUploadResponseDto?> uploadFile(AssetTypeEnum assetType, MultipartFile assetData, String deviceAssetId, String deviceId, String fileCreatedAt, String fileModifiedAt, bool isFavorite, String fileExtension, { MultipartFile? livePhotoData, bool? isVisible, String? duration, }) async {
|
||||
final response = await uploadFileWithHttpInfo(assetType, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, fileExtension, livePhotoData: livePhotoData, isVisible: isVisible, duration: duration, );
|
||||
Future<AssetFileUploadResponseDto?> uploadFile(AssetTypeEnum assetType, MultipartFile assetData, String deviceAssetId, String deviceId, String fileCreatedAt, String fileModifiedAt, bool isFavorite, String fileExtension, { String? key, MultipartFile? livePhotoData, bool? isVisible, String? duration, }) async {
|
||||
final response = await uploadFileWithHttpInfo(assetType, assetData, deviceAssetId, deviceId, fileCreatedAt, fileModifiedAt, isFavorite, fileExtension, key: key, livePhotoData: livePhotoData, isVisible: isVisible, duration: duration, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
|
18
mobile/openapi/lib/api/share_api.dart
generated
18
mobile/openapi/lib/api/share_api.dart
generated
|
@ -123,7 +123,11 @@ class ShareApi {
|
|||
///
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
Future<Response> getMySharedLinkWithHttpInfo() async {
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<Response> getMySharedLinkWithHttpInfo({ String? key, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final path = r'/share/me';
|
||||
|
||||
|
@ -134,6 +138,10 @@ class ShareApi {
|
|||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (key != null) {
|
||||
queryParams.addAll(_queryParams('', 'key', key));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
|
@ -149,8 +157,12 @@ class ShareApi {
|
|||
}
|
||||
|
||||
///
|
||||
Future<SharedLinkResponseDto?> getMySharedLink() async {
|
||||
final response = await getMySharedLinkWithHttpInfo();
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [String] key:
|
||||
Future<SharedLinkResponseDto?> getMySharedLink({ String? key, }) async {
|
||||
final response = await getMySharedLinkWithHttpInfo( key: key, );
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
|
|
6
mobile/openapi/test/album_api_test.dart
generated
6
mobile/openapi/test/album_api_test.dart
generated
|
@ -19,7 +19,7 @@ void main() {
|
|||
group('tests for AlbumApi', () {
|
||||
//
|
||||
//
|
||||
//Future<AddAssetsResponseDto> addAssetsToAlbum(String albumId, AddAssetsDto addAssetsDto) async
|
||||
//Future<AddAssetsResponseDto> addAssetsToAlbum(String albumId, AddAssetsDto addAssetsDto, { String key }) async
|
||||
test('test addAssetsToAlbum', () async {
|
||||
// TODO
|
||||
});
|
||||
|
@ -54,7 +54,7 @@ void main() {
|
|||
|
||||
//
|
||||
//
|
||||
//Future<Object> downloadArchive(String albumId, { num skip }) async
|
||||
//Future<MultipartFile> downloadArchive(String albumId, { num skip, String key }) async
|
||||
test('test downloadArchive', () async {
|
||||
// TODO
|
||||
});
|
||||
|
@ -68,7 +68,7 @@ void main() {
|
|||
|
||||
//
|
||||
//
|
||||
//Future<AlbumResponseDto> getAlbumInfo(String albumId) async
|
||||
//Future<AlbumResponseDto> getAlbumInfo(String albumId, { String key }) async
|
||||
test('test getAlbumInfo', () async {
|
||||
// TODO
|
||||
});
|
||||
|
|
20
mobile/openapi/test/asset_api_test.dart
generated
20
mobile/openapi/test/asset_api_test.dart
generated
|
@ -19,14 +19,14 @@ void main() {
|
|||
group('tests for AssetApi', () {
|
||||
//
|
||||
//
|
||||
//Future<SharedLinkResponseDto> addAssetsToSharedLink(AddAssetsDto addAssetsDto) async
|
||||
//Future<SharedLinkResponseDto> addAssetsToSharedLink(AddAssetsDto addAssetsDto, { String key }) async
|
||||
test('test addAssetsToSharedLink', () async {
|
||||
// TODO
|
||||
});
|
||||
|
||||
// Check duplicated asset before uploading - for Web upload used
|
||||
//
|
||||
//Future<CheckDuplicateAssetResponseDto> checkDuplicateAsset(CheckDuplicateAssetDto checkDuplicateAssetDto) async
|
||||
//Future<CheckDuplicateAssetResponseDto> checkDuplicateAsset(CheckDuplicateAssetDto checkDuplicateAssetDto, { String key }) async
|
||||
test('test checkDuplicateAsset', () async {
|
||||
// TODO
|
||||
});
|
||||
|
@ -54,21 +54,21 @@ void main() {
|
|||
|
||||
//
|
||||
//
|
||||
//Future<Object> downloadFile(String assetId) async
|
||||
//Future<MultipartFile> downloadFile(String assetId, { String key }) async
|
||||
test('test downloadFile', () async {
|
||||
// TODO
|
||||
});
|
||||
|
||||
//
|
||||
//
|
||||
//Future<Object> downloadFiles(DownloadFilesDto downloadFilesDto) async
|
||||
//Future<MultipartFile> downloadFiles(DownloadFilesDto downloadFilesDto, { String key }) async
|
||||
test('test downloadFiles', () async {
|
||||
// TODO
|
||||
});
|
||||
|
||||
// Current this is not used in any UI element
|
||||
//
|
||||
//Future<Object> downloadLibrary({ num skip }) async
|
||||
//Future<MultipartFile> downloadLibrary({ num skip, String key }) async
|
||||
test('test downloadLibrary', () async {
|
||||
// TODO
|
||||
});
|
||||
|
@ -82,7 +82,7 @@ void main() {
|
|||
|
||||
// Get a single asset's information
|
||||
//
|
||||
//Future<AssetResponseDto> getAssetById(String assetId) async
|
||||
//Future<AssetResponseDto> getAssetById(String assetId, { String key }) async
|
||||
test('test getAssetById', () async {
|
||||
// TODO
|
||||
});
|
||||
|
@ -117,7 +117,7 @@ void main() {
|
|||
|
||||
//
|
||||
//
|
||||
//Future<Object> getAssetThumbnail(String assetId, { ThumbnailFormat format }) async
|
||||
//Future<MultipartFile> getAssetThumbnail(String assetId, { ThumbnailFormat format, String key }) async
|
||||
test('test getAssetThumbnail', () async {
|
||||
// TODO
|
||||
});
|
||||
|
@ -145,7 +145,7 @@ void main() {
|
|||
|
||||
//
|
||||
//
|
||||
//Future<SharedLinkResponseDto> removeAssetsFromSharedLink(RemoveAssetsDto removeAssetsDto) async
|
||||
//Future<SharedLinkResponseDto> removeAssetsFromSharedLink(RemoveAssetsDto removeAssetsDto, { String key }) async
|
||||
test('test removeAssetsFromSharedLink', () async {
|
||||
// TODO
|
||||
});
|
||||
|
@ -159,7 +159,7 @@ void main() {
|
|||
|
||||
//
|
||||
//
|
||||
//Future<Object> serveFile(String assetId, { bool isThumb, bool isWeb }) async
|
||||
//Future<MultipartFile> serveFile(String assetId, { bool isThumb, bool isWeb, String key }) async
|
||||
test('test serveFile', () async {
|
||||
// TODO
|
||||
});
|
||||
|
@ -173,7 +173,7 @@ void main() {
|
|||
|
||||
//
|
||||
//
|
||||
//Future<AssetFileUploadResponseDto> uploadFile(AssetTypeEnum assetType, MultipartFile assetData, String deviceAssetId, String deviceId, String fileCreatedAt, String fileModifiedAt, bool isFavorite, String fileExtension, { MultipartFile livePhotoData, bool isVisible, String duration }) async
|
||||
//Future<AssetFileUploadResponseDto> uploadFile(AssetTypeEnum assetType, MultipartFile assetData, String deviceAssetId, String deviceId, String fileCreatedAt, String fileModifiedAt, bool isFavorite, String fileExtension, { String key, MultipartFile livePhotoData, bool isVisible, String duration }) async
|
||||
test('test uploadFile', () async {
|
||||
// TODO
|
||||
});
|
||||
|
|
2
mobile/openapi/test/share_api_test.dart
generated
2
mobile/openapi/test/share_api_test.dart
generated
|
@ -33,7 +33,7 @@ void main() {
|
|||
|
||||
//
|
||||
//
|
||||
//Future<SharedLinkResponseDto> getMySharedLink() async
|
||||
//Future<SharedLinkResponseDto> getMySharedLink({ String key }) async
|
||||
test('test getMySharedLink', () async {
|
||||
// TODO
|
||||
});
|
||||
|
|
|
@ -22,7 +22,7 @@ import { AddUsersDto } from './dto/add-users.dto';
|
|||
import { RemoveAssetsDto } from './dto/remove-assets.dto';
|
||||
import { UpdateAlbumDto } from './dto/update-album.dto';
|
||||
import { GetAlbumsDto } from './dto/get-albums.dto';
|
||||
import { ApiBearerAuth, ApiTags } from '@nestjs/swagger';
|
||||
import { ApiOkResponse, ApiTags } from '@nestjs/swagger';
|
||||
import { AlbumResponseDto } from '@app/domain';
|
||||
import { AlbumCountResponseDto } from './response-dto/album-count-response.dto';
|
||||
import { AddAssetsResponseDto } from './response-dto/add-assets-response.dto';
|
||||
|
@ -37,7 +37,6 @@ import { CreateAlbumShareLinkDto as CreateAlbumSharedLinkDto } from './dto/creat
|
|||
|
||||
// TODO might be worth creating a AlbumParamsDto that validates `albumId` instead of using the pipe.
|
||||
|
||||
@ApiBearerAuth()
|
||||
@ApiTags('Album')
|
||||
@Controller('album')
|
||||
export class AlbumController {
|
||||
|
@ -134,12 +133,13 @@ export class AlbumController {
|
|||
|
||||
@Authenticated({ isShared: true })
|
||||
@Get('/:albumId/download')
|
||||
@ApiOkResponse({ content: { 'application/zip': { schema: { type: 'string', format: 'binary' } } } })
|
||||
async downloadArchive(
|
||||
@GetAuthUser() authUser: AuthUserDto,
|
||||
@Param('albumId', new ParseUUIDPipe({ version: '4' })) albumId: string,
|
||||
@Query(new ValidationPipe({ transform: true })) dto: DownloadDto,
|
||||
@Response({ passthrough: true }) res: Res,
|
||||
): Promise<any> {
|
||||
) {
|
||||
this.albumService.checkDownloadAccess(authUser);
|
||||
|
||||
const { stream, fileName, fileSize, fileCount, complete } = await this.albumService.downloadArchive(
|
||||
|
|
|
@ -28,7 +28,7 @@ import { Response as Res } from 'express';
|
|||
import { DeleteAssetDto } from './dto/delete-asset.dto';
|
||||
import { SearchAssetDto } from './dto/search-asset.dto';
|
||||
import { CheckDuplicateAssetDto } from './dto/check-duplicate-asset.dto';
|
||||
import { ApiBearerAuth, ApiBody, ApiConsumes, ApiHeader, ApiTags } from '@nestjs/swagger';
|
||||
import { ApiBody, ApiConsumes, ApiHeader, ApiOkResponse, ApiTags } from '@nestjs/swagger';
|
||||
import { CuratedObjectsResponseDto } from './response-dto/curated-objects-response.dto';
|
||||
import { CuratedLocationsResponseDto } from './response-dto/curated-locations-response.dto';
|
||||
import { AssetResponseDto, ImmichReadStream } from '@app/domain';
|
||||
|
@ -62,7 +62,6 @@ function asStreamableFile({ stream, type, length }: ImmichReadStream) {
|
|||
return new StreamableFile(stream, { type, length });
|
||||
}
|
||||
|
||||
@ApiBearerAuth()
|
||||
@ApiTags('Asset')
|
||||
@Controller('asset')
|
||||
export class AssetController {
|
||||
|
@ -108,21 +107,23 @@ export class AssetController {
|
|||
|
||||
@Authenticated({ isShared: true })
|
||||
@Get('/download/:assetId')
|
||||
@ApiOkResponse({ content: { 'application/octet-stream': { schema: { type: 'string', format: 'binary' } } } })
|
||||
async downloadFile(
|
||||
@GetAuthUser() authUser: AuthUserDto,
|
||||
@Response({ passthrough: true }) res: Res,
|
||||
@Param('assetId') assetId: string,
|
||||
): Promise<any> {
|
||||
) {
|
||||
return this.assetService.downloadFile(authUser, assetId).then(asStreamableFile);
|
||||
}
|
||||
|
||||
@Authenticated({ isShared: true })
|
||||
@Post('/download-files')
|
||||
@ApiOkResponse({ content: { 'application/octet-stream': { schema: { type: 'string', format: 'binary' } } } })
|
||||
async downloadFiles(
|
||||
@GetAuthUser() authUser: AuthUserDto,
|
||||
@Response({ passthrough: true }) res: Res,
|
||||
@Body(new ValidationPipe()) dto: DownloadFilesDto,
|
||||
): Promise<any> {
|
||||
) {
|
||||
this.assetService.checkDownloadAccess(authUser);
|
||||
await this.assetService.checkAssetsAccess(authUser, [...dto.assetIds]);
|
||||
const { stream, fileName, fileSize, fileCount, complete } = await this.assetService.downloadFiles(dto);
|
||||
|
@ -138,11 +139,12 @@ export class AssetController {
|
|||
*/
|
||||
@Authenticated({ isShared: true })
|
||||
@Get('/download-library')
|
||||
@ApiOkResponse({ content: { 'application/octet-stream': { schema: { type: 'string', format: 'binary' } } } })
|
||||
async downloadLibrary(
|
||||
@GetAuthUser() authUser: AuthUserDto,
|
||||
@Query(new ValidationPipe({ transform: true })) dto: DownloadDto,
|
||||
@Response({ passthrough: true }) res: Res,
|
||||
): Promise<any> {
|
||||
) {
|
||||
this.assetService.checkDownloadAccess(authUser);
|
||||
const { stream, fileName, fileSize, fileCount, complete } = await this.assetService.downloadLibrary(authUser, dto);
|
||||
res.attachment(fileName);
|
||||
|
@ -155,13 +157,14 @@ export class AssetController {
|
|||
@Authenticated({ isShared: true })
|
||||
@Get('/file/:assetId')
|
||||
@Header('Cache-Control', 'max-age=31536000')
|
||||
@ApiOkResponse({ content: { 'application/octet-stream': { schema: { type: 'string', format: 'binary' } } } })
|
||||
async serveFile(
|
||||
@GetAuthUser() authUser: AuthUserDto,
|
||||
@Headers() headers: Record<string, string>,
|
||||
@Response({ passthrough: true }) res: Res,
|
||||
@Query(new ValidationPipe({ transform: true })) query: ServeFileDto,
|
||||
@Param('assetId') assetId: string,
|
||||
): Promise<any> {
|
||||
) {
|
||||
await this.assetService.checkAssetsAccess(authUser, [assetId]);
|
||||
return this.assetService.serveFile(authUser, assetId, query, res, headers);
|
||||
}
|
||||
|
@ -169,13 +172,14 @@ export class AssetController {
|
|||
@Authenticated({ isShared: true })
|
||||
@Get('/thumbnail/:assetId')
|
||||
@Header('Cache-Control', 'max-age=31536000')
|
||||
@ApiOkResponse({ content: { 'application/octet-stream': { schema: { type: 'string', format: 'binary' } } } })
|
||||
async getAssetThumbnail(
|
||||
@GetAuthUser() authUser: AuthUserDto,
|
||||
@Headers() headers: Record<string, string>,
|
||||
@Response({ passthrough: true }) res: Res,
|
||||
@Param('assetId') assetId: string,
|
||||
@Query(new ValidationPipe({ transform: true })) query: GetAssetThumbnailDto,
|
||||
): Promise<any> {
|
||||
) {
|
||||
await this.assetService.checkAssetsAccess(authUser, [assetId]);
|
||||
return this.assetService.getAssetThumbnail(assetId, query, res, headers);
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { Body, Controller, Get, Param, Put, ValidationPipe } from '@nestjs/common';
|
||||
import { ApiBearerAuth, ApiTags } from '@nestjs/swagger';
|
||||
import { ApiTags } from '@nestjs/swagger';
|
||||
import { Authenticated } from '../../decorators/authenticated.decorator';
|
||||
import { AllJobStatusResponseDto } from './response-dto/all-job-status-response.dto';
|
||||
import { GetJobDto } from './dto/get-job.dto';
|
||||
|
@ -8,7 +8,6 @@ import { JobCommandDto } from './dto/job-command.dto';
|
|||
|
||||
@Authenticated({ admin: true })
|
||||
@ApiTags('Job')
|
||||
@ApiBearerAuth()
|
||||
@Controller('jobs')
|
||||
export class JobController {
|
||||
constructor(private readonly jobService: JobService) {}
|
||||
|
|
|
@ -14,7 +14,7 @@ import {
|
|||
ValidateAccessTokenResponseDto,
|
||||
} from '@app/domain';
|
||||
import { Body, Controller, Ip, Post, Req, Res, ValidationPipe } from '@nestjs/common';
|
||||
import { ApiBadRequestResponse, ApiBearerAuth, ApiTags } from '@nestjs/swagger';
|
||||
import { ApiBadRequestResponse, ApiTags } from '@nestjs/swagger';
|
||||
import { Request, Response } from 'express';
|
||||
import { GetAuthUser } from '../decorators/auth-user.decorator';
|
||||
import { Authenticated } from '../decorators/authenticated.decorator';
|
||||
|
@ -45,7 +45,6 @@ export class AuthController {
|
|||
}
|
||||
|
||||
@Authenticated()
|
||||
@ApiBearerAuth()
|
||||
@Post('validateToken')
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
validateAccessToken(@GetAuthUser() authUser: AuthUserDto): ValidateAccessTokenResponseDto {
|
||||
|
@ -53,7 +52,6 @@ export class AuthController {
|
|||
}
|
||||
|
||||
@Authenticated()
|
||||
@ApiBearerAuth()
|
||||
@Post('change-password')
|
||||
async changePassword(@GetAuthUser() authUser: AuthUserDto, @Body() dto: ChangePasswordDto): Promise<UserResponseDto> {
|
||||
return this.authService.changePassword(authUser, dto);
|
||||
|
|
|
@ -5,12 +5,11 @@ import {
|
|||
UpsertDeviceInfoDto as UpsertDto,
|
||||
} from '@app/domain';
|
||||
import { Body, Controller, Put, ValidationPipe } from '@nestjs/common';
|
||||
import { ApiBearerAuth, ApiTags } from '@nestjs/swagger';
|
||||
import { ApiTags } from '@nestjs/swagger';
|
||||
import { GetAuthUser } from '../decorators/auth-user.decorator';
|
||||
import { Authenticated } from '../decorators/authenticated.decorator';
|
||||
|
||||
@Authenticated()
|
||||
@ApiBearerAuth()
|
||||
@ApiTags('Device Info')
|
||||
@Controller('device-info')
|
||||
export class DeviceInfoController {
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
import { SystemConfigDto, SystemConfigService, SystemConfigTemplateStorageOptionDto } from '@app/domain';
|
||||
import { Body, Controller, Get, Put, ValidationPipe } from '@nestjs/common';
|
||||
import { ApiBearerAuth, ApiTags } from '@nestjs/swagger';
|
||||
import { ApiTags } from '@nestjs/swagger';
|
||||
import { Authenticated } from '../decorators/authenticated.decorator';
|
||||
|
||||
@ApiTags('System Config')
|
||||
@ApiBearerAuth()
|
||||
@Authenticated({ admin: true })
|
||||
@Controller('system-config')
|
||||
export class SystemConfigController {
|
||||
|
|
|
@ -23,7 +23,7 @@ import { UpdateUserDto } from '@app/domain';
|
|||
import { FileInterceptor } from '@nestjs/platform-express';
|
||||
import { profileImageUploadOption } from '../config/profile-image-upload.config';
|
||||
import { Response as Res } from 'express';
|
||||
import { ApiBearerAuth, ApiBody, ApiConsumes, ApiTags } from '@nestjs/swagger';
|
||||
import { ApiBody, ApiConsumes, ApiTags } from '@nestjs/swagger';
|
||||
import { UserResponseDto } from '@app/domain';
|
||||
import { UserCountResponseDto } from '@app/domain';
|
||||
import { CreateProfileImageDto } from '@app/domain';
|
||||
|
@ -36,7 +36,6 @@ export class UserController {
|
|||
constructor(private readonly userService: UserService) {}
|
||||
|
||||
@Authenticated()
|
||||
@ApiBearerAuth()
|
||||
@Get()
|
||||
async getAllUsers(
|
||||
@GetAuthUser() authUser: AuthUserDto,
|
||||
|
@ -51,14 +50,12 @@ export class UserController {
|
|||
}
|
||||
|
||||
@Authenticated()
|
||||
@ApiBearerAuth()
|
||||
@Get('me')
|
||||
async getMyUserInfo(@GetAuthUser() authUser: AuthUserDto): Promise<UserResponseDto> {
|
||||
return await this.userService.getUserInfo(authUser);
|
||||
}
|
||||
|
||||
@Authenticated({ admin: true })
|
||||
@ApiBearerAuth()
|
||||
@Post()
|
||||
async createUser(
|
||||
@Body(new ValidationPipe({ transform: true })) createUserDto: CreateUserDto,
|
||||
|
@ -72,21 +69,18 @@ export class UserController {
|
|||
}
|
||||
|
||||
@Authenticated({ admin: true })
|
||||
@ApiBearerAuth()
|
||||
@Delete('/:userId')
|
||||
async deleteUser(@GetAuthUser() authUser: AuthUserDto, @Param('userId') userId: string): Promise<UserResponseDto> {
|
||||
return await this.userService.deleteUser(authUser, userId);
|
||||
}
|
||||
|
||||
@Authenticated({ admin: true })
|
||||
@ApiBearerAuth()
|
||||
@Post('/:userId/restore')
|
||||
async restoreUser(@GetAuthUser() authUser: AuthUserDto, @Param('userId') userId: string): Promise<UserResponseDto> {
|
||||
return await this.userService.restoreUser(authUser, userId);
|
||||
}
|
||||
|
||||
@Authenticated()
|
||||
@ApiBearerAuth()
|
||||
@Put()
|
||||
async updateUser(
|
||||
@GetAuthUser() authUser: AuthUserDto,
|
||||
|
@ -97,7 +91,6 @@ export class UserController {
|
|||
|
||||
@UseInterceptors(FileInterceptor('file', profileImageUploadOption))
|
||||
@Authenticated()
|
||||
@ApiBearerAuth()
|
||||
@ApiConsumes('multipart/form-data')
|
||||
@ApiBody({
|
||||
description: 'A new avatar for the user',
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import { applyDecorators, SetMetadata } from '@nestjs/common';
|
||||
import { ApiBearerAuth, ApiCookieAuth, ApiQuery } from '@nestjs/swagger';
|
||||
|
||||
interface AuthenticatedOptions {
|
||||
admin?: boolean;
|
||||
|
@ -12,7 +13,7 @@ export enum Metadata {
|
|||
}
|
||||
|
||||
export const Authenticated = (options?: AuthenticatedOptions) => {
|
||||
const decorators = [SetMetadata(Metadata.AUTH_ROUTE, true)];
|
||||
const decorators: MethodDecorator[] = [ApiBearerAuth(), ApiCookieAuth(), SetMetadata(Metadata.AUTH_ROUTE, true)];
|
||||
|
||||
options = options || {};
|
||||
|
||||
|
@ -22,6 +23,7 @@ export const Authenticated = (options?: AuthenticatedOptions) => {
|
|||
|
||||
if (options.isShared) {
|
||||
decorators.push(SetMetadata(Metadata.SHARED_ROUTE, true));
|
||||
decorators.push(ApiQuery({ name: 'key', type: String, required: false }));
|
||||
}
|
||||
|
||||
return applyDecorators(...decorators);
|
||||
|
|
|
@ -11,6 +11,7 @@ import { RedisIoAdapter } from './middlewares/redis-io.adapter.middleware';
|
|||
import { json } from 'body-parser';
|
||||
import { patchOpenAPI } from './utils/patch-open-api.util';
|
||||
import { getLogLevels, MACHINE_LEARNING_ENABLED } from '@app/common';
|
||||
import { IMMICH_ACCESS_COOKIE } from '@app/domain';
|
||||
|
||||
const logger = new Logger('ImmichServer');
|
||||
|
||||
|
@ -42,6 +43,7 @@ async function bootstrap() {
|
|||
scheme: 'Bearer',
|
||||
in: 'header',
|
||||
})
|
||||
.addCookieAuth(IMMICH_ACCESS_COOKIE)
|
||||
.addServer('/api')
|
||||
.build();
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load diff
524
web/src/api/open-api/api.ts
generated
524
web/src/api/open-api/api.ts
generated
File diff suppressed because it is too large
Load diff
|
@ -93,6 +93,7 @@ describe('AlbumCard component', () => {
|
|||
expect(apiMock.assetApi.getAssetThumbnail).toHaveBeenCalledWith(
|
||||
'thumbnailIdOne',
|
||||
ThumbnailFormat.Jpeg,
|
||||
undefined,
|
||||
{ responseType: 'blob' }
|
||||
);
|
||||
expect(createObjectURLMock).toHaveBeenCalledWith(thumbnailBlob);
|
||||
|
|
|
@ -34,9 +34,14 @@
|
|||
return;
|
||||
}
|
||||
|
||||
const { data } = await api.assetApi.getAssetThumbnail(thubmnailId, ThumbnailFormat.Jpeg, {
|
||||
responseType: 'blob'
|
||||
});
|
||||
const { data } = await api.assetApi.getAssetThumbnail(
|
||||
thubmnailId,
|
||||
ThumbnailFormat.Jpeg,
|
||||
undefined,
|
||||
{
|
||||
responseType: 'blob'
|
||||
}
|
||||
);
|
||||
|
||||
if (data instanceof Blob) {
|
||||
return URL.createObjectURL(data);
|
||||
|
|
|
@ -170,11 +170,7 @@
|
|||
{
|
||||
assetIds: assets.map((a) => a.id)
|
||||
},
|
||||
{
|
||||
params: {
|
||||
key: sharedLink?.key
|
||||
}
|
||||
}
|
||||
sharedLink?.key
|
||||
);
|
||||
|
||||
if (data.album) {
|
||||
|
@ -269,10 +265,8 @@
|
|||
const { data, status, headers } = await api.albumApi.downloadArchive(
|
||||
album.id,
|
||||
skip || undefined,
|
||||
sharedLink?.key,
|
||||
{
|
||||
params: {
|
||||
key: sharedLink?.key
|
||||
},
|
||||
responseType: 'blob',
|
||||
onDownloadProgress: function (progressEvent) {
|
||||
const request = this as XMLHttpRequest;
|
||||
|
|
|
@ -145,8 +145,7 @@
|
|||
|
||||
$downloadAssets[imageFileName] = 0;
|
||||
|
||||
const { data, status } = await api.assetApi.downloadFile(assetId, {
|
||||
params: { key },
|
||||
const { data, status } = await api.assetApi.downloadFile(assetId, key, {
|
||||
responseType: 'blob',
|
||||
onDownloadProgress: (progressEvent) => {
|
||||
if (progressEvent.lengthComputable) {
|
||||
|
|
|
@ -26,10 +26,7 @@
|
|||
|
||||
const loadAssetData = async () => {
|
||||
try {
|
||||
const { data } = await api.assetApi.serveFile(asset.id, false, true, {
|
||||
params: {
|
||||
key: publicSharedKey
|
||||
},
|
||||
const { data } = await api.assetApi.serveFile(asset.id, false, true, publicSharedKey, {
|
||||
responseType: 'blob'
|
||||
});
|
||||
|
||||
|
|
|
@ -54,11 +54,7 @@
|
|||
{
|
||||
assetIds
|
||||
},
|
||||
{
|
||||
params: {
|
||||
key: sharedLink?.key
|
||||
}
|
||||
}
|
||||
sharedLink?.key
|
||||
);
|
||||
|
||||
notificationController.show({
|
||||
|
@ -76,11 +72,7 @@
|
|||
{
|
||||
assetIds: assets.filter((a) => !selectedAssets.has(a)).map((a) => a.id)
|
||||
},
|
||||
{
|
||||
params: {
|
||||
key: sharedLink?.key
|
||||
}
|
||||
}
|
||||
sharedLink?.key
|
||||
);
|
||||
|
||||
assets = assets.filter((a) => !selectedAssets.has(a));
|
||||
|
|
|
@ -11,9 +11,14 @@
|
|||
return noThumbnailUrl;
|
||||
}
|
||||
|
||||
const { data } = await api.assetApi.getAssetThumbnail(thubmnailId, ThumbnailFormat.Webp, {
|
||||
responseType: 'blob'
|
||||
});
|
||||
const { data } = await api.assetApi.getAssetThumbnail(
|
||||
thubmnailId,
|
||||
ThumbnailFormat.Webp,
|
||||
undefined,
|
||||
{
|
||||
responseType: 'blob'
|
||||
}
|
||||
);
|
||||
if (data instanceof Blob) {
|
||||
return URL.createObjectURL(data);
|
||||
}
|
||||
|
|
|
@ -18,19 +18,17 @@ export const addAssetsToAlbum = async (
|
|||
assetIds: Array<string>,
|
||||
key: string | undefined = undefined
|
||||
): Promise<AddAssetsResponseDto> =>
|
||||
api.albumApi
|
||||
.addAssetsToAlbum(albumId, { assetIds }, { params: { key } })
|
||||
.then(({ data: dto }) => {
|
||||
if (dto.successfullyAdded > 0) {
|
||||
// This might be 0 if the user tries to add an asset that is already in the album
|
||||
notificationController.show({
|
||||
message: `Added ${dto.successfullyAdded} to ${dto.album?.albumName}`,
|
||||
type: NotificationType.Info
|
||||
});
|
||||
}
|
||||
api.albumApi.addAssetsToAlbum(albumId, { assetIds }, key).then(({ data: dto }) => {
|
||||
if (dto.successfullyAdded > 0) {
|
||||
// This might be 0 if the user tries to add an asset that is already in the album
|
||||
notificationController.show({
|
||||
message: `Added ${dto.successfullyAdded} to ${dto.album?.albumName}`,
|
||||
type: NotificationType.Info
|
||||
});
|
||||
}
|
||||
|
||||
return dto;
|
||||
});
|
||||
return dto;
|
||||
});
|
||||
|
||||
export async function bulkDownload(
|
||||
fileName: string,
|
||||
|
@ -53,24 +51,20 @@ export async function bulkDownload(
|
|||
|
||||
let total = 0;
|
||||
|
||||
const { data, status, headers } = await api.assetApi.downloadFiles(
|
||||
{ assetIds },
|
||||
{
|
||||
params: { key },
|
||||
responseType: 'blob',
|
||||
onDownloadProgress: function (progressEvent) {
|
||||
const request = this as XMLHttpRequest;
|
||||
if (!total) {
|
||||
total = Number(request.getResponseHeader('X-Immich-Content-Length-Hint')) || 0;
|
||||
}
|
||||
const { data, status, headers } = await api.assetApi.downloadFiles({ assetIds }, key, {
|
||||
responseType: 'blob',
|
||||
onDownloadProgress: function (progressEvent) {
|
||||
const request = this as XMLHttpRequest;
|
||||
if (!total) {
|
||||
total = Number(request.getResponseHeader('X-Immich-Content-Length-Hint')) || 0;
|
||||
}
|
||||
|
||||
if (total) {
|
||||
const current = progressEvent.loaded;
|
||||
downloadAssets.set({ [downloadFileName]: Math.floor((current / total) * 100) });
|
||||
}
|
||||
if (total) {
|
||||
const current = progressEvent.loaded;
|
||||
downloadAssets.set({ [downloadFileName]: Math.floor((current / total) * 100) });
|
||||
}
|
||||
}
|
||||
);
|
||||
});
|
||||
|
||||
const isNotComplete = headers['x-immich-archive-complete'] === 'false';
|
||||
const fileCount = Number(headers['x-immich-archive-file-count']) || 0;
|
||||
|
|
|
@ -108,11 +108,7 @@ async function fileUploader(
|
|||
deviceAssetId: String(deviceAssetId),
|
||||
deviceId: 'WEB'
|
||||
},
|
||||
{
|
||||
params: {
|
||||
key: sharedKey
|
||||
}
|
||||
}
|
||||
sharedKey
|
||||
);
|
||||
|
||||
if (status === 200 && data.isExist && data.id) {
|
||||
|
|
|
@ -12,7 +12,7 @@ export const load: PageServerLoad = async ({ params, parent }) => {
|
|||
const { key } = params;
|
||||
|
||||
try {
|
||||
const { data: sharedLink } = await api.shareApi.getMySharedLink({ params: { key } });
|
||||
const { data: sharedLink } = await api.shareApi.getMySharedLink(key);
|
||||
|
||||
const assetCount = sharedLink.assets.length;
|
||||
const assetId = sharedLink.album?.albumThumbnailAssetId || sharedLink.assets[0]?.id;
|
||||
|
|
|
@ -7,9 +7,7 @@ import type { PageServerLoad } from './$types';
|
|||
export const load: PageServerLoad = async ({ params }) => {
|
||||
try {
|
||||
const { key, assetId } = params;
|
||||
const { data: asset } = await api.assetApi.getAssetById(assetId, {
|
||||
params: { key }
|
||||
});
|
||||
const { data: asset } = await api.assetApi.getAssetById(assetId, key);
|
||||
|
||||
if (!asset) {
|
||||
return error(404, 'Asset not found');
|
||||
|
|
Loading…
Reference in a new issue