All URIs are relative to http://localhost/nifi-api
Method | HTTP request | Description |
---|---|---|
deleteConnection | DELETE /connections/{id} | Deletes a connection |
getConnection | GET /connections/{id} | Gets a connection |
updateConnection | PUT /connections/{id} | Updates a connection |
ConnectionEntity deleteConnection(id, version, clientId)
Deletes a connection
// Import classes:
//import com.github.hermannpencole.nifi.swagger.ApiClient;
//import com.github.hermannpencole.nifi.swagger.ApiException;
//import com.github.hermannpencole.nifi.swagger.Configuration;
//import com.github.hermannpencole.nifi.swagger.auth.*;
//import com.github.hermannpencole.nifi.swagger.client.ConnectionsApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure OAuth2 access token for authorization: auth
OAuth auth = (OAuth) defaultClient.getAuthentication("auth");
auth.setAccessToken("YOUR ACCESS TOKEN");
ConnectionsApi apiInstance = new ConnectionsApi();
String id = "id_example"; // String | The connection id.
String version = "version_example"; // String | The revision is used to verify the client is working with the latest version of the flow.
String clientId = "clientId_example"; // String | If the client id is not specified, new one will be generated. This value (whether specified or generated) is included in the response.
try {
ConnectionEntity result = apiInstance.deleteConnection(id, version, clientId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling ConnectionsApi#deleteConnection");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | The connection id. | |
version | String | The revision is used to verify the client is working with the latest version of the flow. | [optional] |
clientId | String | If the client id is not specified, new one will be generated. This value (whether specified or generated) is included in the response. | [optional] |
- Content-Type: /
- Accept: application/json
ConnectionEntity getConnection(id)
Gets a connection
// Import classes:
//import com.github.hermannpencole.nifi.swagger.ApiClient;
//import com.github.hermannpencole.nifi.swagger.ApiException;
//import com.github.hermannpencole.nifi.swagger.Configuration;
//import com.github.hermannpencole.nifi.swagger.auth.*;
//import com.github.hermannpencole.nifi.swagger.client.ConnectionsApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure OAuth2 access token for authorization: auth
OAuth auth = (OAuth) defaultClient.getAuthentication("auth");
auth.setAccessToken("YOUR ACCESS TOKEN");
ConnectionsApi apiInstance = new ConnectionsApi();
String id = "id_example"; // String | The connection id.
try {
ConnectionEntity result = apiInstance.getConnection(id);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling ConnectionsApi#getConnection");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | The connection id. |
- Content-Type: /
- Accept: application/json
ConnectionEntity updateConnection(id, body)
Updates a connection
// Import classes:
//import com.github.hermannpencole.nifi.swagger.ApiClient;
//import com.github.hermannpencole.nifi.swagger.ApiException;
//import com.github.hermannpencole.nifi.swagger.Configuration;
//import com.github.hermannpencole.nifi.swagger.auth.*;
//import com.github.hermannpencole.nifi.swagger.client.ConnectionsApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure OAuth2 access token for authorization: auth
OAuth auth = (OAuth) defaultClient.getAuthentication("auth");
auth.setAccessToken("YOUR ACCESS TOKEN");
ConnectionsApi apiInstance = new ConnectionsApi();
String id = "id_example"; // String | The connection id.
ConnectionEntity body = new ConnectionEntity(); // ConnectionEntity | The connection configuration details.
try {
ConnectionEntity result = apiInstance.updateConnection(id, body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling ConnectionsApi#updateConnection");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | The connection id. | |
body | ConnectionEntity | The connection configuration details. |
- Content-Type: application/json
- Accept: application/json