Access lists basics

This commit is contained in:
Jamie Curnow committed 2023-01-13 15:03:28 +10:00
1 parent a239be993c
commit 6c76c041c4
17 files changed
+732 -2

No files matched your search

@@ -0,0 +1,21 @@
package schema
import (
"fmt"
)
// CreateAccessList is the schema for incoming data validation
func CreateAccessList() string {
return fmt.Sprintf(`
{
"type": "object",
"additionalProperties": false,
"required": [
"name"
],
"properties": {
"name": %s
}
}
`, stringMinMax(2, 100))
}
@@ -0,0 +1,17 @@
package schema
import "fmt"
// UpdateAccessList is the schema for incoming data validation
func UpdateAccessList() string {
return fmt.Sprintf(`
{
"type": "object",
"additionalProperties": false,
"minProperties": 1,
"properties": {
"name": %s
}
}
`, stringMinMax(2, 100))
}