api

package
v0.98.0 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2026 License: GPL-3.0 Imports: 1 Imported by: 0

README

API Documentation

This directory contains OpenAPI/Swagger artifacts for Flowbot.

Contract boundary (honest scope)

  • Source of truth for routes and behavior: Go handlers under internal/server/, internal/modules/, and user docs under docs/user-guide/.
  • Swagger (swagger.yaml / /swagger/) is an auxiliary surface. It currently covers a small subset of routes (primarily the example module plus generated stubs). It is not a complete API contract.
  • There is no strict /api/v1 versioning guarantee. Breaking HTTP/config changes are called out in CHANGELOG.md.

Primary HTTP surfaces:

Prefix Purpose
/service/{module}/* Module business routes (often aligned with capability IDs)
/hub/* Hub management (apps, capabilities, health) — requires scopes
/chatagent/* Chat agent HTTP API
/livez, /readyz, /startupz Probes (/readyz checks PostgreSQL + Redis)
/metrics Prometheus scrape (authenticated)
/swagger/* Swagger UI (when built with -tags swagger)

File Descriptions

swagger.json & swagger.yaml
  • OpenAPI specification files (partial)
  • Auto-generated by swaggo/swag from annotations
docs.go
  • Generated Go package embedding Swagger definitions
api.http
  • HTTP request examples for REST clients

Usage

After starting the server (swagger tag build): http://localhost:6060/swagger/index.html

go tool task swagger

Auth

Use X-AccessToken or Authorization: Bearer with a scoped token. Do not pass tokens in query strings.

Documentation

Overview

Package api Code generated by swaggo/swag. DO NOT EDIT

Index

Constants

This section is empty.

Variables

View Source
var SwaggerInfo = &swag.Spec{
	Version:          "1.0",
	Host:             "localhost:6060",
	BasePath:         "/service",
	Schemes:          []string{"http"},
	Title:            "Flowbot API",
	Description:      "Flowbot Homelab Data Hub HTTP API (partial OpenAPI; see docs/api/README.md)",
	InfoInstanceName: "swagger",
	SwaggerTemplate:  docTemplate,
	LeftDelim:        "{{",
	RightDelim:       "}}",
}

SwaggerInfo holds exported Swagger Info so clients can modify it

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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