Skip To Content
ArcGIS Developer
Dashboard

Hosted Knowledge Graph Service

Description

License:

At ArcGIS Enterprise 10.9.1, named users in the Enterprise portal must be licensed with the ArcGIS Knowledge user type extension to create, edit, and update Knowledge Graph Server services. At ArcGIS Enterprise 11.0, your account no longer requires the ArcGIS Knowledge user type extension, but you must be signed in to the Enterprise portal to create, edit, and update Knowledge Graph Server services.

A knowledge graph service is associated with several resources. One resource is a graph, which contains entities and relationships. Another resource is the data model that defines the types of entities and relationships that can be created in the graph. A knowledge graph service allows clients to query and edit both the graph and the data model.

Request parameters

ParameterDetails
f

The response format. The default response format is html.

Values: html | json | pjson

Example usage

Most requests made to and responses received from knowledge graph services will involve data encoded using protocol buffers. Protocol buffers are a language-neutral, platform-independent mechanism for serializing structured data that was designed by Google.

Sending a request to a knowledge graph service involves creating an http client in the programming language of your choice, and using it to create and send an http POST request. The POST request will include a protocol buffer defining the operation that will be performed. Similarly, the response will include a protocol buffer containing data returned by the service. The protocol buffers must be encoded and decoded. Protocol buffers are created using a *.proto file. Different requests and responses are associated with different .proto files. For details, refer to the complete Protocol Buffer Format (PBF) specification.

The following is a sample request URL for a knowledge graph service named SupplyChain:

https://machine.domain.com/webadaptor/rest/services/Hosted/SupplyChain/KnowledgeGraphServer?f=json

JSON Response syntax

When an JSON request is sent to the knowledge graph service, a JSON response is returned outlining the capabilities of the service. The following example represents the syntax for describing the capabilities of a knowledge graph service.

{
  "capabilities": "<comma-separated list of supported operations>",
  "supportedQueryFormats": "PBF",
  "allowGeometryUpdates": <boolean>,
  "searchMaxRecordCount": <integer>,
  "serviceCapabilities": {
    "indexCapabilities": {
      "supportsDescendingIndex": <boolean>,
      "supportsUniqueRelationshipConstraint": <boolean>,
      "supportsRelationshipIndex": <boolean>
    },
    "searchCapabilities": {
      "searchTypeFilterCapabilities": [
        "esriTypeEntity", "esriTypeRelationship", "esriTypeBoth"
      ],
      "allowLeadingWildcardQueries": <boolean>
    }
  },
  "maxRecordCount": <integer>,
  "description": "<string>",
  "copyrightText": "<string>",
  "units": "esriDecimalDegrees",
  "spatialReference": {"wkid": 4326},
  "currentVersion": <version number>,
  "dateFieldsTimeReference": {
    "respectsDaylightSaving": <boolean>,
    "timeZone": "UTC"
  },
  "serviceItemId": "<portal item ID>"
}

JSON Response example

This example illustrates the response to the example query shown above.

{
  "capabilities": "Delete,Query,Create,Editing,Update",
  "supportedQueryFormats": "PBF",
  "allowGeometryUpdates": false,
  "searchMaxRecordCount": 2000,
  "serviceCapabilities": {
    "indexCapabilities": {
      "supportsDescendingIndex": false,
      "supportsUniqueRelationshipConstraint": false,
      "supportsRelationshipIndex": true
    },
    "searchCapabilities": {
      "searchTypeFilterCapabilities": [
        "esriTypeEntity", "esriTypeRelationship", "esriTypeBoth"
      ],
      "allowLeadingWildcardQueries": true
    }
  },
  "maxRecordCount": 2000,
  "description": "",
  "copyrightText": "",
  "units": "esriDecimalDegrees",
  "spatialReference": {"wkid": 4326},
  "currentVersion": 10.91,
  "dateFieldsTimeReference": {
    "respectsDaylightSaving": false,
    "timeZone": "UTC"
  },
  "serviceItemId": "e69a705b47824987994122d6d78c795c"
}