- Resource: Schema
- NodeType
- EdgeType
- LabelProperties
- Property
- StringValue
- IntValue
- BoolValue
- DoubleValue
- EdgeRule
- NodeGroup
- Methods
Resource: Schema
Schema is a collection of supported node & edge labels and properties for an overlay.
| JSON representation |
|---|
{ "name": string, "nodeTypes": [ { object ( |
| Fields | |
|---|---|
name |
Identifier. The resource name of the schema. Format: |
nodeTypes[] |
A list of |
edgeTypes[] |
A list of |
labelProperties[] |
A list of supported labels and corresponding properties. |
edgeRules[] |
Edge rules. These will indicate which node types can be connected and through what edge type. This is a list of (sourceNodeType, edgeType, destinationNodeType) tuples. |
NodeType
NodeType defines the schema of a node type in the graph.
| JSON representation |
|---|
{ "type": string, "labels": [ string ], "description": string, "optionalLabels": [ string ] } |
| Fields | |
|---|---|
type |
REQUIRED Name of the node type. This name is used to access the node type while defining the schema. |
labels[] |
Labels attached to the node. Composable, namespaced building blocks that define core attributes through associated properties. Multiple labels aggregate to fully specify the functional traits and property schema of the node type. |
description |
A human-readable description of the |
optionalLabels[] |
A node of this node type can have 0 or more of these labels. These node objects of this node type will have these labels alongside the required labels. |
EdgeType
EdgeType defines the schema of an edge type in the graph.
| JSON representation |
|---|
{ "type": string, "labels": [ string ], "description": string, "optionalLabels": [ string ] } |
| Fields | |
|---|---|
type |
REQUIRED Name of the edge type. This name is used to access the edge type while defining the schema. |
labels[] |
Labels attached to the edge. Composable, namespaced building blocks that define core attributes through associated properties. Multiple labels aggregate to fully specify the functional traits and property schema of the edge type. |
description |
A human-readable description of the |
optionalLabels[] |
An edge of this edge type can have 0 or more of these labels. These edge objects of this edge type will have these labels alongside the required labels. |
LabelProperties
Identifier for the label and corresponding properties.
| JSON representation |
|---|
{
"label": string,
"properties": [
{
object ( |
| Fields | |
|---|---|
label |
Full qualified name of the label. |
properties[] |
List of properties associated with the label. |
description |
A human-readable description of the label. |
Property
Property defines the schema of a property in the graph.
| JSON representation |
|---|
{ "name": string, "description": string, // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "stringValue": { object ( |
| Fields | |
|---|---|
name |
|
description |
A human-readable description of the |
| REQUIRED Value type of the property. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
stringValue |
StringValue represents a property that has a string value type. |
intValue |
IntValue represents a property that has an integer value type. |
boolValue |
BoolValue represents a property that has a boolean value type. |
doubleValue |
DoubleValue represents a property that has a double value type. |
| End of mutually exclusive fields. | |
StringValue
StringValue represents a property that has a string value type.
| JSON representation |
|---|
{ "repeated": boolean, "allowedValues": [ string ] } |
| Fields | |
|---|---|
repeated |
OPTIONAL Whether the property is repeated. |
allowedValues[] |
OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values. |
IntValue
IntValue represents a property that has an integer value type.
| JSON representation |
|---|
{ "repeated": boolean, "allowedValues": [ string ] } |
| Fields | |
|---|---|
repeated |
OPTIONAL Whether the property is repeated. |
allowedValues[] |
OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values. |
BoolValue
BoolValue represents a property that has a boolean value type.
| JSON representation |
|---|
{ "repeated": boolean, "allowedValues": [ boolean ] } |
| Fields | |
|---|---|
repeated |
OPTIONAL Whether the property is repeated. |
allowedValues[] |
OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values. |
DoubleValue
DoubleValue represents a property that has a double value type.
| JSON representation |
|---|
{ "repeated": boolean, "allowedValues": [ number ] } |
| Fields | |
|---|---|
repeated |
OPTIONAL Whether the property is repeated. |
allowedValues[] |
OPTIONAL Allowed values for the property. If provided, the property value must be one of the allowed values. |
EdgeRule
EdgeRule defines the connection rules for nodes in the graph.
| JSON representation |
|---|
{ "edgeType": string, // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "srcNodeType": string, "srcNodeGroup": { object ( |
| Fields | |
|---|---|
edgeType |
Optional. Name of the connected edge type. |
Specifies the source criteria for this edge rule. An edge rule must define its source either statically via a specific node type, or dynamically via a group of nodes that match given constraints. This takes precedence over the |
|
srcNodeType |
Optional. The specific node type name that acts as the source for this edge. |
srcNodeGroup |
Optional. A dynamic group of nodes, defined by label constraints, that can act as the source for this edge. |
| End of mutually exclusive fields. | |
Specifies the destination criteria for this edge rule. An edge rule must define its destination either statically via a specific node type, or dynamically via a group of nodes that match given constraints. This takes precedence over the |
|
destNodeType |
Optional. The specific node type name that acts as the destination for this edge. |
destNodeGroup |
Optional. A dynamic group of nodes, defined by label constraints, that can act as the destination for this edge. |
| End of mutually exclusive fields. | |
NodeGroup
NodeGroup represents a dynamic collection of nodes that satisfy specific criteria. A node is considered part of this group if it matches the defined constraints.
| JSON representation |
|---|
{ "anyLabels": [ string ] } |
| Fields | |
|---|---|
anyLabels[] |
Optional. A node must have at least one of these labels to be included in the group. If empty or unset, this constraint is not applied. |
Methods |
|
|---|---|
|
Explores the topology schema starting from given node types or label names up to a specified hop depth. |