8.4 KiB
manager_api.api.ResourceApi
Load the API package
import 'package:manager_api/api.dart';
All URIs are relative to https://api.myinfomate.be
| Method | HTTP request | Description |
|---|---|---|
| resourceCreate | POST /api/Resource | |
| resourceDelete | DELETE /api/Resource/{id} | |
| resourceGet | GET /api/Resource | |
| resourceGetDetail | GET /api/Resource/{id}/detail | |
| resourceShow | GET /api/Resource/{id} | |
| resourceUpdate | PUT /api/Resource | |
| resourceUpload | POST /api/Resource/upload |
resourceCreate
ResourceDTO resourceCreate(resourceDTO)
Example
import 'package:manager_api/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 |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
resourceDelete
String resourceDelete(id)
Example
import 'package:manager_api/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
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
resourceGet
List resourceGet(instanceId, types)
Example
import 'package:manager_api/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 | [optional] [default to const []] |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
resourceGetDetail
ResourceDTO resourceGetDetail(id)
Example
import 'package:manager_api/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
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
resourceShow
MultipartFile resourceShow(id)
Example
import 'package:manager_api/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
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/octet-stream, application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
resourceUpdate
ResourceDTO resourceUpdate(resourceDTO)
Example
import 'package:manager_api/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 |
Return type
Authorization
HTTP request headers
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
resourceUpload
String resourceUpload(label, type, instanceId)
Example
import 'package:manager_api/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
HTTP request headers
- Content-Type: multipart/form-data
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]