openapifixture

package
v0.5.4 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterRoutes

func RegisterRoutes(mux *http.ServeMux)

RegisterRoutes mounts static routes for OpenAPI discovery (same package).

Types

type CreateUserRequest

type CreateUserRequest struct {
	// Name is the display name of the new user.
	Name string
	// Email is the contact address of the new user.
	Email string
	OrgID string `path:"org_id"` // OrgID owns the created user.
	Token string `header:"Authorization"`
}

CreateUserRequest exercises default input, path, and header for OpenAPI mapping.

type CreateUserResponse

type CreateUserResponse struct {
	ID    string `json:"id"`
	Name  string `json:"name"`
	Email string `json:"email"`
}

CreateUserResponse is the success body for create user.

type SearchRequest

type SearchRequest struct {
	Keyword string `query:"keyword"`
	Page    int    `query:"page"`
	Filter  string `payload:"filter"`
}

SearchRequest uses restricted query/payload sources.

type SearchResponse

type SearchResponse struct {
	Keyword string `json:"keyword"`
	Page    int    `json:"page"`
	Filter  string `json:"filter"`
}

SearchResponse is returned from search.

Jump to

Keyboard shortcuts

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