title | topic | type | typeOrder | roles | ||
---|---|---|---|---|---|---|
API structure and libraries |
intro |
reference |
2 |
|
We use gRPC as our messaging protocol for all our APIs, except the Subscription API
and
Provision API
.
Our .proto
files can be found at github.com/working-group-two/wgtwoapis
under the wgtwo
folder.
The Subscription API
and Provision API
has a REST-like API.
Our OpenAPI specification can be found at github.com/working-group-two/wgtwoapis-openapi
under the openapi
folder.
Using our .proto
files and OpenAPI specification, you may generate code for most languages.
In addition, we offer generated code for Go and Java.
Add import for the API you would like to use. Path is the same as its .proto
file:
import (
wgtwoEvents "github.com/working-group-two/wgtwoapis/wgtwo/events/v0"
)
To add the dependencies, first you need to add the https://jitpack.io repository:
Then you can add the dependencies:
The specific package to include is included in the documentation of each API.
The version used is the commit SHA from our repository.
Latest version should match the output of:
git ls-remote https://github.com/working-group-two/wgtwoapis master | cut -f1