oauth

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package oauth implements the OAuth 2.1 authorization server that MCP clients use to obtain bearer tokens: RFC 8414 / RFC 9728 metadata, RFC 7591 dynamic client registration, PKCE authorization code and refresh token grants, and RFC 7009 revocation.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

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

Server serves the OAuth endpoints.

func New

func New(svc *core.Service, log *slog.Logger, requireSession func(http.Handler) http.Handler) *Server

New builds the server. requireSession guards the consent screen with the dashboard login (provided by the web package).

func (*Server) Register

func (s *Server) Register(mux *http.ServeMux)

Register mounts the endpoints on mux.

Jump to

Keyboard shortcuts

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