add description information to params for modules

This commit is contained in:
Joel Wetzell
2026-06-01 17:39:00 -05:00
parent 81ae00c943
commit 5d1e6622cb
19 changed files with 172 additions and 128 deletions
+2
View File
@@ -22,6 +22,8 @@ func init() {
Type: "object", Type: "object",
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"dsn": { "dsn": {
Title: "Data Source Name",
Description: "the data source name (DSN) for the SQLite database",
Type: "string", Type: "string",
MinLength: new(1), MinLength: new(1),
}, },
+1
View File
@@ -25,6 +25,7 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port for the HTTP server to listen on",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1024), Minimum: jsonschema.Ptr[float64](1024),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
+1
View File
@@ -23,6 +23,7 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the name of the MIDI port to listen to",
Type: "string", Type: "string",
}, },
}, },
+1
View File
@@ -25,6 +25,7 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the name of the MIDI port to send messages to",
Type: "string", Type: "string",
}, },
}, },
+5
View File
@@ -23,18 +23,22 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"broker": { "broker": {
Title: "Broker URL", Title: "Broker URL",
Description: "the URL of the MQTT broker to connect to",
Type: "string", Type: "string",
}, },
"topic": { "topic": {
Title: "Topic", Title: "Topic",
Description: "an MQTT topic to subscribe to",
Type: "string", Type: "string",
}, },
"clientId": { "clientId": {
Title: "Client ID", Title: "Client ID",
Description: "the client ID to use when connecting to the MQTT broker",
Type: "string", Type: "string",
}, },
"qos": { "qos": {
Title: "QoS", Title: "QoS",
Description: "the QoS level to use when publishing messages",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](0), Minimum: jsonschema.Ptr[float64](0),
Maximum: jsonschema.Ptr[float64](2), Maximum: jsonschema.Ptr[float64](2),
@@ -42,6 +46,7 @@ func init() {
}, },
"retained": { "retained": {
Title: "Retained", Title: "Retained",
Description: "whether to set the retained flag when publishing messages",
Type: "boolean", Type: "boolean",
Default: json.RawMessage(`false`), Default: json.RawMessage(`false`),
}, },
+2
View File
@@ -21,10 +21,12 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"url": { "url": {
Title: "NATS Server URL", Title: "NATS Server URL",
Description: "the URL of the NATS server to connect to",
Type: "string", Type: "string",
}, },
"subject": { "subject": {
Title: "Subject", Title: "Subject",
Description: "the subject to subscribe to",
Type: "string", Type: "string",
}, },
}, },
+2
View File
@@ -25,11 +25,13 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"ip": { "ip": {
Title: "IP", Title: "IP",
Description: "the IP address to bind the NATS server to",
Type: "string", Type: "string",
Default: json.RawMessage(`"0.0.0.0"`), Default: json.RawMessage(`"0.0.0.0"`),
}, },
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port for the NATS server to listen on",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1024), Minimum: jsonschema.Ptr[float64](1024),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
+4
View File
@@ -21,9 +21,13 @@ func init() {
Type: "object", Type: "object",
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"host": { "host": {
Title: "Host",
Description: "the hostname or IP address of the Redis server to connect to",
Type: "string", Type: "string",
}, },
"port": { "port": {
Title: "Port",
Description: "the port to use when connecting to the Redis server",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1), Minimum: jsonschema.Ptr[float64](1),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
+3
View File
@@ -26,14 +26,17 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the name of the serial port to connect to",
Type: "string", Type: "string",
}, },
"baudRate": { "baudRate": {
Title: "Baud Rate", Title: "Baud Rate",
Description: "the baud rate to use when connecting to the serial port",
Type: "integer", Type: "integer",
}, },
"framing": { "framing": {
Title: "Framing Method", Title: "Framing Method",
Description: "the method to use for framing messages on the serial port",
Type: "string", Type: "string",
Enum: []any{"LF", "CR", "CRLF", "SLIP", "RAW"}, Enum: []any{"LF", "CR", "CRLF", "SLIP", "RAW"},
}, },
+4
View File
@@ -30,11 +30,13 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"ip": { "ip": {
Title: "IP", Title: "IP",
Description: "the IP address to bind the SIP server to",
Type: "string", Type: "string",
Default: json.RawMessage(`"0.0.0.0"`), Default: json.RawMessage(`"0.0.0.0"`),
}, },
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port for the SIP server to listen on",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1024), Minimum: jsonschema.Ptr[float64](1024),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
@@ -42,12 +44,14 @@ func init() {
}, },
"transport": { "transport": {
Title: "Transport", Title: "Transport",
Description: "the transport protocol to use for the SIP server",
Type: "string", Type: "string",
Enum: []any{"udp", "tcp", "ws", "udp4", "tcp4"}, Enum: []any{"udp", "tcp", "ws", "udp4", "tcp4"},
Default: json.RawMessage(`"udp"`), Default: json.RawMessage(`"udp"`),
}, },
"userAgent": { "userAgent": {
Title: "User Agent", Title: "User Agent",
Description: "the user agent string to use",
Type: "string", Type: "string",
Default: json.RawMessage(`"showbridge"`), Default: json.RawMessage(`"showbridge"`),
}, },
+5
View File
@@ -31,11 +31,13 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"ip": { "ip": {
Title: "IP", Title: "IP",
Description: "the IP address to bind the SIP server to",
Type: "string", Type: "string",
Default: json.RawMessage(`"0.0.0.0"`), Default: json.RawMessage(`"0.0.0.0"`),
}, },
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port for the SIP server to listen on",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1024), Minimum: jsonschema.Ptr[float64](1024),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
@@ -43,17 +45,20 @@ func init() {
}, },
"transport": { "transport": {
Title: "Transport", Title: "Transport",
Description: "the transport protocol to use for the SIP server",
Type: "string", Type: "string",
Enum: []any{"udp", "tcp", "ws", "udp4", "tcp4"}, Enum: []any{"udp", "tcp", "ws", "udp4", "tcp4"},
Default: json.RawMessage(`"udp"`), Default: json.RawMessage(`"udp"`),
}, },
"userAgent": { "userAgent": {
Title: "User Agent", Title: "User Agent",
Description: "the user agent string to use",
Type: "string", Type: "string",
Default: json.RawMessage(`"showbridge"`), Default: json.RawMessage(`"showbridge"`),
}, },
"separator": { "separator": {
Title: "DTMF Separator", Title: "DTMF Separator",
Description: "the DTMF character to use as a separator between DTMF digit groups",
Type: "string", Type: "string",
MinLength: new(1), MinLength: new(1),
MaxLength: new(1), MaxLength: new(1),
+3
View File
@@ -24,16 +24,19 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"host": { "host": {
Title: "Host", Title: "Host",
Description: "the hostname or IP address of the TCP server to connect to",
Type: "string", Type: "string",
}, },
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port of the TCP server to connect to",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1), Minimum: jsonschema.Ptr[float64](1),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
}, },
"framing": { "framing": {
Title: "Framing Method", Title: "Framing Method",
Description: "the method used to frame messages over the TCP connection",
Type: "string", Type: "string",
Enum: []any{"LF", "CR", "CRLF", "SLIP", "RAW"}, Enum: []any{"LF", "CR", "CRLF", "SLIP", "RAW"},
}, },
+3
View File
@@ -27,17 +27,20 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"ip": { "ip": {
Title: "IP", Title: "IP",
Description: "the IP address to bind the TCP server to",
Type: "string", Type: "string",
Default: json.RawMessage(`"0.0.0.0"`), Default: json.RawMessage(`"0.0.0.0"`),
}, },
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port for the TCP server to listen on",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1024), Minimum: jsonschema.Ptr[float64](1024),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
}, },
"framing": { "framing": {
Title: "Framing Method", Title: "Framing Method",
Description: "the method used to frame messages over the TCP connection",
Type: "string", Type: "string",
Enum: []any{"LF", "CR", "CRLF", "SLIP", "RAW"}, Enum: []any{"LF", "CR", "CRLF", "SLIP", "RAW"},
}, },
+1 -1
View File
@@ -20,8 +20,8 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"duration": { "duration": {
Title: "Duration", Title: "Duration",
Description: "time in milliseconds between emitted events",
Type: "integer", Type: "integer",
Description: "Interval duration in milliseconds",
}, },
}, },
Required: []string{"duration"}, Required: []string{"duration"},
+1 -1
View File
@@ -20,8 +20,8 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"duration": { "duration": {
Title: "Duration", Title: "Duration",
Description: "time in milliseconds before the timer fires",
Type: "integer", Type: "integer",
Description: "Interval duration in milliseconds",
}, },
}, },
Required: []string{"duration"}, Required: []string{"duration"},
+2
View File
@@ -22,10 +22,12 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"host": { "host": {
Title: "Host", Title: "Host",
Description: "the hostname or IP address of the UDP server to connect to",
Type: "string", Type: "string",
}, },
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port of the UDP server to connect to",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1), Minimum: jsonschema.Ptr[float64](1),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
+2
View File
@@ -23,10 +23,12 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"ip": { "ip": {
Title: "IP", Title: "IP",
Description: "the multicast address to listen on",
Type: "string", Type: "string",
}, },
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port to listen on",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1024), Minimum: jsonschema.Ptr[float64](1024),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
+3
View File
@@ -24,17 +24,20 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"ip": { "ip": {
Title: "IP", Title: "IP",
Description: "the IP address to bind the UDP server to",
Type: "string", Type: "string",
Default: json.RawMessage(`"0.0.0.0"`), Default: json.RawMessage(`"0.0.0.0"`),
}, },
"port": { "port": {
Title: "Port", Title: "Port",
Description: "the port for the UDP server to listen on",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1024), Minimum: jsonschema.Ptr[float64](1024),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
}, },
"bufferSize": { "bufferSize": {
Title: "Buffer Size", Title: "Buffer Size",
Description: "the size of the buffer for incoming UDP messages",
Type: "integer", Type: "integer",
Minimum: jsonschema.Ptr[float64](1), Minimum: jsonschema.Ptr[float64](1),
Maximum: jsonschema.Ptr[float64](65535), Maximum: jsonschema.Ptr[float64](65535),
+1
View File
@@ -24,6 +24,7 @@ func init() {
Properties: map[string]*jsonschema.Schema{ Properties: map[string]*jsonschema.Schema{
"url": { "url": {
Title: "URL", Title: "URL",
Description: "the URL of the WebSocket server to connect",
Type: "string", Type: "string",
}, },
}, },