endpoints

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2026 License: MIT Imports: 3 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package endpoints is a knowledgebase.Extractor that classifies a crawled request as an API endpoint (REST, GraphQL, SOAP, AJAX/XHR) by inspecting method, URL, headers, and content types. Emits per-response, one entry per qualifying request.

Output schema (all values strings unless noted):

class        : "rest" | "graphql" | "soap" | "xhr"
method       : uppercase HTTP verb
url          : request URL with userinfo and fragment stripped
content_type : lowercased media type without parameters (optional)
auth         : lowercased auth scheme, e.g. "bearer" / "basic" (optional)
params       : []string of query parameter names in first-seen order (optional)

The extractor is read-only with respect to its inputs: it MUST NOT mutate req or resp (headers, body, URL).

Index

Constants

View Source
const Name = "endpoints"

Variables

This section is empty.

Functions

This section is empty.

Types

type Extractor

type Extractor struct{}

func New

func New() *Extractor

func (*Extractor) Extract

func (e *Extractor) Extract(_ string, req *http.Request, resp *http.Response) map[string]any

func (*Extractor) Name

func (e *Extractor) Name() string

Jump to

Keyboard shortcuts

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