design

package
v0.0.0-...-84d5eb4 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Analytics = MediaType("application/vnd.analytics+json", func() {
	Description("Url analytics")
	Attributes(func() {
		Attribute("hits", Integer, func() {
			Example(1)
		})
	})

	View("default", func() {
		Attribute("hits")
	})
})
View Source
var CreateLinkPayload = Type("CreateLinkPayload", func() {
	Attribute("path", String, func() {
		MinLength(6)
		MaxLength(100)
		Example("path")
	})

	Attribute("url", String, func() {
		MinLength(8)
		MaxLength(2000)
		Example("path")
	})

	Required("path", "url")
})
View Source
var UpdateLinkPayload = Type("UpdateLinkPayload", func() {
	Attribute("path", String, func() {
		MinLength(6)
		MaxLength(100)
		Example("path")
	})

	Attribute("url", String, func() {
		MinLength(8)
		MaxLength(2000)
		Example("path")
	})
	Required("path", "url")
})
View Source
var Url = MediaType("application/vnd.url+json", func() {
	Description("A URL")
	Attributes(func() {
		Attribute("id", Integer, "URL ID", func() {
			Example(1)
		})

		Attribute("url", String, "External URL", func() {
			Example("example.com")
		})

		Attribute("path", String, "URL path key", func() {
			Example("path")
		})
	})

	View("default", func() {
		Attribute("id")
		Attribute("url")
		Attribute("path")
	})
})

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