callback

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DCRRedirectPorts = []int{8000, 8080, 8888, 9000}

DCRRedirectPorts are the specific ports to try for OAuth callbacks Must match TypeScript PR #84 and DCR registration

Functions

This section is empty.

Types

type CallbackResult

type CallbackResult struct {
	Code             string
	State            string
	Error            string
	ErrorDescription string
}

CallbackResult represents the result of the OAuth callback

type Server

type Server struct {
	// contains filtered or unexported fields
}

Server handles the OAuth callback

func NewServer

func NewServer() (*Server, error)

NewServer creates a new callback server Tries to bind to one of the pre-registered DCR ports (8000, 8080, 8888, 9000) Matches TypeScript PR #84 behavior for compatibility

func (*Server) Port

func (s *Server) Port() int

Port returns the server port

func (*Server) RedirectURI

func (s *Server) RedirectURI() string

RedirectURI returns the full redirect URI Uses /oauth/callback path to match TypeScript PR #84

func (*Server) Start

func (s *Server) Start() error

Start starts the callback server

func (*Server) Stop

func (s *Server) Stop() error

Stop stops the callback server

func (*Server) WaitForCallback

func (s *Server) WaitForCallback(timeout time.Duration) (*CallbackResult, error)

WaitForCallback waits for the OAuth callback

Jump to

Keyboard shortcuts

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