folio

package
v0.2.37 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2026 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Overview

Package folio implements the core of span-folio: it talks to the FOLIO API to fetch metadata collections and renders them for inspection.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(cfg Config, client Client, w io.Writer) error

Run authenticates against the FOLIO API, fetches metadata collections and renders them to w.

Types

type Client

type Client interface {
	Authenticate(username, password string) error
	MetadataCollections(opts folio.MetadataCollectionsOpts) (*folio.MetadataCollectionsResponse, error)
}

Client is the subset of the FOLIO API used by this command. It is satisfied by *folio.API and can be stubbed in tests.

type Config

type Config struct {
	User     string
	Password string
	CQL      string
	Limit    int
	Raw      bool
}

Config holds the tunables for a folio run.

func DefaultConfig

func DefaultConfig() Config

DefaultConfig returns the default configuration.

Jump to

Keyboard shortcuts

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