com.diffbot:diffbot-enhance-client

OpenAPI Java


License
Unicode-TOU

Documentation

diffbot-enhance-client

Diffbot Enhance Service

  • API version: v3.0.0

Enhance is an API to find a person or organization in the Knowledge Graph using partial data

Automatically generated by the OpenAPI Generator

Requirements

Building the API client library requires:

  1. Java 1.8+
  2. Maven/Gradle

Installation

To install the API client library to your local Maven repository, simply execute:

mvn clean install

To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:

mvn clean deploy

Refer to the OSSRH Guide for more information.

Maven users

Add this dependency to your project's POM:

<dependency>
  <groupId>com.diffbot</groupId>
  <artifactId>diffbot-enhance-client</artifactId>
  <version>0.1.0</version>
  <scope>compile</scope>
</dependency>

Gradle users

Add this dependency to your project's build file:

compile "com.diffbot:diffbot-enhance-client:0.1.0"

Others

At first generate the JAR by executing:

mvn clean package

Then manually install the following JARs:

  • target/diffbot-enhance-client-0.1.0.jar
  • target/lib/*.jar

Getting Started

Please follow the installation instruction and execute the following Java code:

// Import classes:
import com.diffbot.kg.enhance.openapi.invoker.ApiClient;
import com.diffbot.kg.enhance.openapi.invoker.ApiException;
import com.diffbot.kg.enhance.openapi.invoker.Configuration;
import com.diffbot.kg.enhance.openapi.invoker.models.*;
import com.diffbot.kg.enhance.openapi.api.BulkEnhanceEndpointApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("https://kg.diffbot.com");

    BulkEnhanceEndpointApi apiInstance = new BulkEnhanceEndpointApi(defaultClient);
    String bulkjobId = "bulkjobId_example"; // String | Bulkjob Id
    String token = "token_example"; // String | Diffbot Token
    try {
      BulkjobStatusResponse result = apiInstance.bulkjobStatus(bulkjobId, token);
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling BulkEnhanceEndpointApi#bulkjobStatus");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Documentation for API Endpoints

All URIs are relative to https://kg.diffbot.com

Class Method HTTP request Description
BulkEnhanceEndpointApi bulkjobStatus GET /kg/enhance_endpoint/bulk/{bulkjobId}/status Bulk Enhance Status Endpoint
BulkEnhanceEndpointApi enhanceBulkjob POST /kg/enhance_endpoint/bulk Bulk Enhance Endpoint
BulkEnhanceEndpointApi pollBulkjob GET /kg/enhance_endpoint/bulk/{bulkjobId} Bulk Enhance Poll Endpoint
BulkEnhanceEndpointApi stopBulkjob GET /kg/enhance_endpoint/bulk/{bulkjobId}/stop Bulkjob stop
EnhanceLiveEndpointApi enhance GET /kg/enhance_endpoint Live Enhance Endpoint

Documentation for Models

Documentation for Authorization

All endpoints do not require authorization. Authentication schemes defined for the API:

Recommendation

It's recommended to create an instance of ApiClient per thread in a multithreaded environment to avoid any potential issues.

Author

support@diffbot.com