auth

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package auth provides authentication utilities including Firebase token management

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TokenManager

type TokenManager interface {
	GetToken() (string, error)
	Refresh() (string, error)
}

TokenManager handles Firebase custom token generation and caching. It automatically refreshes tokens before expiration and is safe for concurrent use.

func NewTokenManager

func NewTokenManager(serviceID string, credentialsFile ...string) (TokenManager, error)

NewTokenManager creates a TokenManager for service-to-service authentication. The serviceID parameter is used to identify your service in Firebase logs.

Jump to

Keyboard shortcuts

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