328 lines
8.4 KiB
Markdown
328 lines
8.4 KiB
Markdown
# manager_api_new.api.ResourceApi
|
|
|
|
## Load the API package
|
|
```dart
|
|
import 'package:manager_api_new/api.dart';
|
|
```
|
|
|
|
All URIs are relative to *https://localhost:5001*
|
|
|
|
Method | HTTP request | Description
|
|
------------- | ------------- | -------------
|
|
[**resourceCreate**](ResourceApi.md#resourcecreate) | **POST** /api/Resource |
|
|
[**resourceDelete**](ResourceApi.md#resourcedelete) | **DELETE** /api/Resource/{id} |
|
|
[**resourceGet**](ResourceApi.md#resourceget) | **GET** /api/Resource |
|
|
[**resourceGetDetail**](ResourceApi.md#resourcegetdetail) | **GET** /api/Resource/{id}/detail |
|
|
[**resourceShow**](ResourceApi.md#resourceshow) | **GET** /api/Resource/{id} |
|
|
[**resourceUpdate**](ResourceApi.md#resourceupdate) | **PUT** /api/Resource |
|
|
[**resourceUpload**](ResourceApi.md#resourceupload) | **POST** /api/Resource/upload |
|
|
|
|
|
|
# **resourceCreate**
|
|
> ResourceDTO resourceCreate(resourceDTO)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:manager_api_new/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = ResourceApi();
|
|
final resourceDTO = ResourceDTO(); // ResourceDTO |
|
|
|
|
try {
|
|
final result = api_instance.resourceCreate(resourceDTO);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling ResourceApi->resourceCreate: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**resourceDTO** | [**ResourceDTO**](ResourceDTO.md)| |
|
|
|
|
### Return type
|
|
|
|
[**ResourceDTO**](ResourceDTO.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: application/json
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **resourceDelete**
|
|
> String resourceDelete(id)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:manager_api_new/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = ResourceApi();
|
|
final id = id_example; // String |
|
|
|
|
try {
|
|
final result = api_instance.resourceDelete(id);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling ResourceApi->resourceDelete: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**id** | **String**| |
|
|
|
|
### Return type
|
|
|
|
**String**
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: Not defined
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **resourceGet**
|
|
> List<ResourceDTO> resourceGet(instanceId, types)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:manager_api_new/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = ResourceApi();
|
|
final instanceId = instanceId_example; // String |
|
|
final types = []; // List<ResourceType> |
|
|
|
|
try {
|
|
final result = api_instance.resourceGet(instanceId, types);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling ResourceApi->resourceGet: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**instanceId** | **String**| | [optional]
|
|
**types** | [**List<ResourceType>**](ResourceType.md)| | [optional] [default to const []]
|
|
|
|
### Return type
|
|
|
|
[**List<ResourceDTO>**](ResourceDTO.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: Not defined
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **resourceGetDetail**
|
|
> ResourceDTO resourceGetDetail(id)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:manager_api_new/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = ResourceApi();
|
|
final id = id_example; // String |
|
|
|
|
try {
|
|
final result = api_instance.resourceGetDetail(id);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling ResourceApi->resourceGetDetail: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**id** | **String**| |
|
|
|
|
### Return type
|
|
|
|
[**ResourceDTO**](ResourceDTO.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: Not defined
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **resourceShow**
|
|
> MultipartFile resourceShow(id)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:manager_api_new/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = ResourceApi();
|
|
final id = id_example; // String |
|
|
|
|
try {
|
|
final result = api_instance.resourceShow(id);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling ResourceApi->resourceShow: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**id** | **String**| |
|
|
|
|
### Return type
|
|
|
|
[**MultipartFile**](MultipartFile.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: Not defined
|
|
- **Accept**: application/octet-stream, application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **resourceUpdate**
|
|
> ResourceDTO resourceUpdate(resourceDTO)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:manager_api_new/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = ResourceApi();
|
|
final resourceDTO = ResourceDTO(); // ResourceDTO |
|
|
|
|
try {
|
|
final result = api_instance.resourceUpdate(resourceDTO);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling ResourceApi->resourceUpdate: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**resourceDTO** | [**ResourceDTO**](ResourceDTO.md)| |
|
|
|
|
### Return type
|
|
|
|
[**ResourceDTO**](ResourceDTO.md)
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: application/json
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|
|
# **resourceUpload**
|
|
> String resourceUpload(label, type, instanceId)
|
|
|
|
|
|
|
|
### Example
|
|
```dart
|
|
import 'package:manager_api_new/api.dart';
|
|
// TODO Configure OAuth2 access token for authorization: bearer
|
|
//defaultApiClient.getAuthentication<OAuth>('bearer').accessToken = 'YOUR_ACCESS_TOKEN';
|
|
|
|
final api_instance = ResourceApi();
|
|
final label = label_example; // String |
|
|
final type = type_example; // String |
|
|
final instanceId = instanceId_example; // String |
|
|
|
|
try {
|
|
final result = api_instance.resourceUpload(label, type, instanceId);
|
|
print(result);
|
|
} catch (e) {
|
|
print('Exception when calling ResourceApi->resourceUpload: $e\n');
|
|
}
|
|
```
|
|
|
|
### Parameters
|
|
|
|
Name | Type | Description | Notes
|
|
------------- | ------------- | ------------- | -------------
|
|
**label** | **String**| | [optional]
|
|
**type** | **String**| | [optional]
|
|
**instanceId** | **String**| | [optional]
|
|
|
|
### Return type
|
|
|
|
**String**
|
|
|
|
### Authorization
|
|
|
|
[bearer](../README.md#bearer)
|
|
|
|
### HTTP request headers
|
|
|
|
- **Content-Type**: multipart/form-data
|
|
- **Accept**: application/json
|
|
|
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
|