apiv2/

directory
v1.7.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 18, 2026 License: MIT

README

GOCAST API V2

This API is designed to be a user-friendly and easy-to-use interface for third party services. It provides access to all non-administrative features of the GoCast platform via gRPC methods and exposes a REST API proxy for easy access.

In the future, this API might be extended to include more features and endpoints and replace the current REST API.

Documentation

You can find the docs for the new API here.

You can generate the code documentation using godoc and find it at http://localhost:6060/pkg/github.com/TUM-Dev/gocast.

File structure

All proto messages can be found in apiv2.proto. The actual endpoints are implemented in <./endpoint.go>.go, custom erros in ./errors and helper functions such as parsers, custom database queries, etc. in ./helpers.

Config

Install protobuf by running ./apiv2/installBuf.sh.

To generate the files in ./protobuf, run: ./apiv2/generate.sh.

Running the server

To build and start the new API, start GoCast as usual with: go run ./cmd/tumlive/tumlive.go.

The gRPC server will be running on port 12544 and the API proxy on localhost:8081/api/v2.
The docs can be found at http://localhost:8081/api/v2/docs.

Directories

Path Synopsis
Package errors provides helper functions for handling errors with specific HTTP status codes.
Package errors provides helper functions for handling errors with specific HTTP status codes.
Package helpers provides helper functions for parsing models to protobuf representations.
Package helpers provides helper functions for parsing models to protobuf representations.
protobuf
server
Package protobuf is a reverse proxy.
Package protobuf is a reverse proxy.
Package apiv2 provides API endpoints for the application.
Package apiv2 provides API endpoints for the application.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL