Skip to content

Latest commit

 

History

History
176 lines (124 loc) · 5.13 KB

FunnelApi.md

File metadata and controls

176 lines (124 loc) · 5.13 KB

FunnelApi

All URIs are relative to http://localhost/nifi-api

Method HTTP request Description
getFunnel GET /funnels/{id} Gets a funnel
removeFunnel DELETE /funnels/{id} Deletes a funnel
updateFunnel PUT /funnels/{id} Updates a funnel

getFunnel

FunnelEntity getFunnel(id)

Gets a funnel

Example

// 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.FunnelApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure OAuth2 access token for authorization: auth
OAuth auth = (OAuth) defaultClient.getAuthentication("auth");
auth.setAccessToken("YOUR ACCESS TOKEN");

FunnelApi apiInstance = new FunnelApi();
String id = "id_example"; // String | The funnel id.
try {
    FunnelEntity result = apiInstance.getFunnel(id);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling FunnelApi#getFunnel");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id String The funnel id.

Return type

FunnelEntity

Authorization

auth

HTTP request headers

  • Content-Type: /
  • Accept: application/json

removeFunnel

FunnelEntity removeFunnel(id, version, clientId)

Deletes a funnel

Example

// 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.FunnelApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure OAuth2 access token for authorization: auth
OAuth auth = (OAuth) defaultClient.getAuthentication("auth");
auth.setAccessToken("YOUR ACCESS TOKEN");

FunnelApi apiInstance = new FunnelApi();
String id = "id_example"; // String | The funnel 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 {
    FunnelEntity result = apiInstance.removeFunnel(id, version, clientId);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling FunnelApi#removeFunnel");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id String The funnel 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]

Return type

FunnelEntity

Authorization

auth

HTTP request headers

  • Content-Type: /
  • Accept: application/json

updateFunnel

FunnelEntity updateFunnel(id, body)

Updates a funnel

Example

// 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.FunnelApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure OAuth2 access token for authorization: auth
OAuth auth = (OAuth) defaultClient.getAuthentication("auth");
auth.setAccessToken("YOUR ACCESS TOKEN");

FunnelApi apiInstance = new FunnelApi();
String id = "id_example"; // String | The funnel id.
FunnelEntity body = new FunnelEntity(); // FunnelEntity | The funnel configuration details.
try {
    FunnelEntity result = apiInstance.updateFunnel(id, body);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling FunnelApi#updateFunnel");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
id String The funnel id.
body FunnelEntity The funnel configuration details.

Return type

FunnelEntity

Authorization

auth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json