db

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package db provides shared database utilities.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeserializeClaims

func DeserializeClaims(data []byte) map[string]any

DeserializeClaims deserializes claims from JSON bytes to a map. Returns nil for empty/nil data or on unmarshal error.

func SerializeClaims

func SerializeClaims(claims map[string]any) []byte

SerializeClaims serializes a claims map to JSON bytes for database storage. Returns nil for empty/nil claims maps or on marshal error.

func ValidateClaimValues added in v1.0.1

func ValidateClaimValues(claims map[string]any) error

ValidateClaimValues checks that all claim values are strings or arrays of strings. This is the format required by the authorization system's JSONB containment queries.

Types

This section is empty.

Directories

Path Synopsis
Package pgtypes provides custom types for PostgreSQL database operations.
Package pgtypes provides custom types for PostgreSQL database operations.

Jump to

Keyboard shortcuts

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