All URIs are relative to http://localhost/nifi-api
Method | HTTP request | Description |
---|---|---|
exportTemplate | GET /templates/{id}/download | Exports a template |
removeTemplate | DELETE /templates/{id} | Deletes a template |
String exportTemplate(id)
Exports a template
// 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.TemplatesApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure OAuth2 access token for authorization: auth
OAuth auth = (OAuth) defaultClient.getAuthentication("auth");
auth.setAccessToken("YOUR ACCESS TOKEN");
TemplatesApi apiInstance = new TemplatesApi();
String id = "id_example"; // String | The template id.
try {
String result = apiInstance.exportTemplate(id);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling TemplatesApi#exportTemplate");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | The template id. |
String
- Content-Type: /
- Accept: application/xml
TemplateEntity removeTemplate(id)
Deletes a template
// 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.TemplatesApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure OAuth2 access token for authorization: auth
OAuth auth = (OAuth) defaultClient.getAuthentication("auth");
auth.setAccessToken("YOUR ACCESS TOKEN");
TemplatesApi apiInstance = new TemplatesApi();
String id = "id_example"; // String | The template id.
try {
TemplateEntity result = apiInstance.removeTemplate(id);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling TemplatesApi#removeTemplate");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | The template id. |
- Content-Type: /
- Accept: application/json