2024-05-14 13:07:09 +00:00
|
|
|
package spec
|
|
|
|
|
|
|
|
import (
|
|
|
|
"embed"
|
|
|
|
"path"
|
|
|
|
)
|
|
|
|
|
|
|
|
//go:embed schemas/*.json schemas/*/*.json
|
2024-07-24 23:45:04 +00:00
|
|
|
|
2024-05-14 13:07:09 +00:00
|
|
|
var assets embed.FS
|
|
|
|
|
|
|
|
func jsonschemaDraft04JSONBytes() ([]byte, error) {
|
2024-07-24 23:45:04 +00:00
|
|
|
|
2024-05-14 13:07:09 +00:00
|
|
|
return assets.ReadFile(path.Join("schemas", "jsonschema-draft-04.json"))
|
2024-07-24 23:45:04 +00:00
|
|
|
|
2024-05-14 13:07:09 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
func v2SchemaJSONBytes() ([]byte, error) {
|
2024-07-24 23:45:04 +00:00
|
|
|
|
2024-05-14 13:07:09 +00:00
|
|
|
return assets.ReadFile(path.Join("schemas", "v2", "schema.json"))
|
2024-07-24 23:45:04 +00:00
|
|
|
|
2024-05-14 13:07:09 +00:00
|
|
|
}
|