cursor

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package cursor is AuthKit's one page-cursor codec: a keyset position as opaque base64url JSON. Clients pass cursors back verbatim; nothing outside this package reads their contents.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decode

func Decode(c string, position any) error

Decode reads a cursor made by Encode into position. A cursor that is not one is 400 invalid_request on param cursor.

func Encode

func Encode(position any) string

Encode makes an opaque cursor from a keyset position.

func Invalid

func Invalid() error

Invalid is the error for a cursor this deployment did not issue.

func Keys

func Keys(c string, n int) ([]string, error)

Keys decodes a cursor of n non-empty string keys; "" is the first page, all keys empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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