Skip to main content
Version: 2.0

gRPC APIs

Vectara implements a gRPC (Remote Procedure Call) API to all its core services. gRPC is a high-performance, open-source framework developed by Google that enables different services to communicate with each other.

Check out our API Overview for more information.

Protocol Buffer Definitions

You can download the proto files directly from GitHub below.

ProtobufDescription
services.protoDefines the core services within the platform.
serving.protoMessage definitions for running queries.
custom_dim.protoMessage definitions for custom dimensions.
indexing.protoMessage definitions for indexing content.
admin.protoMessage definitions for performing administrative tasks.
status.protoStatus return codes.
common.protoCommon message definitions.

Download the Auxiliary Protocol Buffers

The gRPC services also use Google's annotations.proto and http.proto. If you need these proto files, the following curl commands download these files into the ext subdirectory. You can then reference them in the protoc path using -I ext.

proto $ ls
admin.proto common.proto indexing.proto services.proto serving.proto status.proto
proto $ mkdir ext
proto $ curl -s -o ext/google/api/annotations.proto --create-dirs \
https://raw.githubusercontent.com/googleapis/googleapis/master/google/api/annotations.proto
proto $ curl -s -o ext/google/api/http.proto --create-dirs \
https://raw.githubusercontent.com/googleapis/googleapis/master/google/api/http.proto

Example Protocol Buffers

The Quickstart Examples GitHub repository has examples of connecting via gRPC in a variety of languages.

Generating Strongly Typed Clients

One of the advantages of using gRPC is that there is some tooling for generating strongly-typed clients/bindings in many programming languages. These work by converting the protobuf definitions to code.

The most up-to-date documentation on how to do this is in the "quick start" sections of https://grpc.io/docs/languages/ following the "Generate gRPC code" section in the language of your choosing. For example, check out the official documentation for getting started with gRPC in Python.