mockid

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package mockid checks the IDs of mocks, which name them in admin API paths, such as /mocks/{id}.

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalid = errors.New("an id holds only letters, digits, '.', '_', '~' and '-'")

ErrInvalid says what an ID may hold.

Functions

func Check

func Check(id string) error

Check accepts the IDs a mock can have: letters, digits, '.', '_', '~' and '-', the characters a URL path needs no escaping for. It returns ErrInvalid for any other, the empty one included.

Types

This section is empty.

Jump to

Keyboard shortcuts

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