import 'package:openproject_dart_sdk/api.dart';
All URIs are relative to http://localhost
Method | HTTP request | Description |
---|---|---|
apiV3ProjectsAvailableParentProjectsGet | GET /api/v3/projects/available_parent_projects | list available parent project candidates |
apiV3ProjectsGet | GET /api/v3/projects | List projects |
apiV3ProjectsIdDelete | DELETE /api/v3/projects/{id} | delete project |
apiV3ProjectsIdGet | GET /api/v3/projects/{id} | View project |
apiV3ProjectsIdPatch | PATCH /api/v3/projects/{id} | update project |
apiV3ProjectsPost | POST /api/v3/projects | create project |
apiV3VersionsIdProjectsGet | GET /api/v3/versions/{id}/projects | List projects with version |
Projects apiV3ProjectsAvailableParentProjectsGet(filters, of_, sortBy)
list available parent project candidates
Lists projects which can become parent to another project. Only sound candidates are returned. For instance a project cannot become parent of itself or it’s children.
import 'package:openproject_dart_sdk/api.dart';
// TODO Configure HTTP basic authorization: basicAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').password = 'YOUR_PASSWORD';
// TODO Configure OAuth2 access token for authorization: oAuth
//defaultApiClient.getAuthentication<OAuth>('oAuth').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = ProjectsApi();
final filters = filters_example; // String | JSON specifying filter conditions.
final of_ = of__example; // String | The id or identifier of the project the parent candidate is determined for
final sortBy = sortBy_example; // String | JSON specifying sort criteria. Accepts the same format as returned by the queries endpoint and allows all the filters and sortBy supported by the project list end point.
try {
final result = api_instance.apiV3ProjectsAvailableParentProjectsGet(filters, of_, sortBy);
print(result);
} catch (e) {
print('Exception when calling ProjectsApi->apiV3ProjectsAvailableParentProjectsGet: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
filters | String | JSON specifying filter conditions. | [optional] |
of_ | String | The id or identifier of the project the parent candidate is determined for | [optional] |
sortBy | String | JSON specifying sort criteria. Accepts the same format as returned by the queries endpoint and allows all the filters and sortBy supported by the project list end point. | [optional] |
- Content-Type: Not defined
- Accept: application/json, application/hal+json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Projects apiV3ProjectsGet(filters, sortBy)
List projects
Returns a collection of projects. The collection can be filtered via query parameters similar to how work packages are filtered. In addition to the provided filter, the result set is always limited to only contain projects the client is allowed to see.
import 'package:openproject_dart_sdk/api.dart';
// TODO Configure HTTP basic authorization: basicAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').password = 'YOUR_PASSWORD';
// TODO Configure OAuth2 access token for authorization: oAuth
//defaultApiClient.getAuthentication<OAuth>('oAuth').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = ProjectsApi();
final filters = filters_example; // String | JSON specifying filter conditions. Accepts the same format as returned by the [queries](#queries) endpoint. Currently supported filters are: + ancestor: filters projects by their ancestor. A project is not considered to be it's own ancestor.
final sortBy = sortBy_example; // String | JSON specifying sort criteria. Currently supported orders are: + id + name + created_on + public + latest_activity_at + required_disk_space: There might also be additional orders based on the custom fields that have been configured.
try {
final result = api_instance.apiV3ProjectsGet(filters, sortBy);
print(result);
} catch (e) {
print('Exception when calling ProjectsApi->apiV3ProjectsGet: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
filters | String | JSON specifying filter conditions. Accepts the same format as returned by the queries endpoint. Currently supported filters are: + ancestor: filters projects by their ancestor. A project is not considered to be it's own ancestor. | [optional] |
sortBy | String | JSON specifying sort criteria. Currently supported orders are: + id + name + created_on + public + latest_activity_at + required_disk_space: There might also be additional orders based on the custom fields that have been configured. | [optional] |
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
apiV3ProjectsIdDelete(id)
delete project
Deletes the project permanently. As this is a lengthy process, the actual deletion is carried out asynchronously. So the project might exist well after the request has returned successfully. To prevent unwanted changes to the project scheduled for deletion, it is archived at once.
import 'package:openproject_dart_sdk/api.dart';
// TODO Configure HTTP basic authorization: basicAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').password = 'YOUR_PASSWORD';
// TODO Configure OAuth2 access token for authorization: oAuth
//defaultApiClient.getAuthentication<OAuth>('oAuth').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = ProjectsApi();
final id = 56; // int | Project id
try {
api_instance.apiV3ProjectsIdDelete(id);
} catch (e) {
print('Exception when calling ProjectsApi->apiV3ProjectsIdDelete: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
id | int | Project id |
void (empty response body)
- Content-Type: Not defined
- Accept: application/hal+json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Project apiV3ProjectsIdGet(id)
View project
import 'package:openproject_dart_sdk/api.dart';
// TODO Configure HTTP basic authorization: basicAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').password = 'YOUR_PASSWORD';
// TODO Configure OAuth2 access token for authorization: oAuth
//defaultApiClient.getAuthentication<OAuth>('oAuth').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = ProjectsApi();
final id = 56; // int | Project id
try {
final result = api_instance.apiV3ProjectsIdGet(id);
print(result);
} catch (e) {
print('Exception when calling ProjectsApi->apiV3ProjectsIdGet: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
id | int | Project id |
- Content-Type: Not defined
- Accept: application/hal+json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Project apiV3ProjectsIdPatch(id, project)
update project
Updates the given project by applying the attributes provided in the body.
import 'package:openproject_dart_sdk/api.dart';
// TODO Configure HTTP basic authorization: basicAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').password = 'YOUR_PASSWORD';
// TODO Configure OAuth2 access token for authorization: oAuth
//defaultApiClient.getAuthentication<OAuth>('oAuth').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = ProjectsApi();
final id = 56; // int | Project id
final project = Project(); // Project | Project changes
try {
final result = api_instance.apiV3ProjectsIdPatch(id, project);
print(result);
} catch (e) {
print('Exception when calling ProjectsApi->apiV3ProjectsIdPatch: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
id | int | Project id | |
project | Project | Project changes |
- Content-Type: application/json
- Accept: application/json, application/hal+json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Project apiV3ProjectsPost(project, filters, sortBy)
create project
Creates a new project, applying the attributes provided in the body. You can use the form and schema to be retrieve the valid attribute values and by that be guided towards successful creation.
import 'package:openproject_dart_sdk/api.dart';
// TODO Configure HTTP basic authorization: basicAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').password = 'YOUR_PASSWORD';
// TODO Configure OAuth2 access token for authorization: oAuth
//defaultApiClient.getAuthentication<OAuth>('oAuth').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = ProjectsApi();
final project = Project(); // Project | New project attributes
final filters = filters_example; // String | JSON specifying filter conditions. Accepts the same format as returned by the [queries](#queries) endpoint. Currently supported filters are: + ancestor: filters projects by their ancestor. A project is not considered to be it's own ancestor.
final sortBy = sortBy_example; // String | JSON specifying sort criteria. Currently supported orders are: + id + name + created_on + public + latest_activity_at + required_disk_space: There might also be additional orders based on the custom fields that have been configured.
try {
final result = api_instance.apiV3ProjectsPost(project, filters, sortBy);
print(result);
} catch (e) {
print('Exception when calling ProjectsApi->apiV3ProjectsPost: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
project | Project | New project attributes | |
filters | String | JSON specifying filter conditions. Accepts the same format as returned by the queries endpoint. Currently supported filters are: + ancestor: filters projects by their ancestor. A project is not considered to be it's own ancestor. | [optional] |
sortBy | String | JSON specifying sort criteria. Currently supported orders are: + id + name + created_on + public + latest_activity_at + required_disk_space: There might also be additional orders based on the custom fields that have been configured. | [optional] |
- Content-Type: application/json
- Accept: application/json, application/hal+json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
apiV3VersionsIdProjectsGet(id)
List projects with version
This endpoint lists the projects where the given version is available. The projects returned depend on the sharing settings of the given version, but are also limited to the projects that the current user is allowed to see.
import 'package:openproject_dart_sdk/api.dart';
// TODO Configure HTTP basic authorization: basicAuth
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').username = 'YOUR_USERNAME'
//defaultApiClient.getAuthentication<HttpBasicAuth>('basicAuth').password = 'YOUR_PASSWORD';
// TODO Configure OAuth2 access token for authorization: oAuth
//defaultApiClient.getAuthentication<OAuth>('oAuth').accessToken = 'YOUR_ACCESS_TOKEN';
final api_instance = ProjectsApi();
final id = 56; // int | Version id
try {
api_instance.apiV3VersionsIdProjectsGet(id);
} catch (e) {
print('Exception when calling ProjectsApi->apiV3VersionsIdProjectsGet: $e\n');
}
Name | Type | Description | Notes |
---|---|---|---|
id | int | Version id |
void (empty response body)
- Content-Type: Not defined
- Accept: application/hal+json
[Back to top] [Back to API list] [Back to Model list] [Back to README]