class

Analyzer::Specification::GraphqlOperation

Inherits Analyzer::Specification::SpecificationEngine < Analyzer < FileHelper < Reference < Object

Emits one POST /graphql endpoint per named top-level operation found in a GraphQL operation document (query Foo { … } in a .graphql / .gql file). The optimizer merges them on method + url, so a project ends up with one endpoint carrying one param per operation.

This used to be a FileAnalyzer hook, which put it outside the tech registry: its endpoints carried "technology": null and, because the file analyzer runs unconditionally, they were returned by every --only-techs <T> run as well — six technologies on the hoppscotch corpus each reported one endpoint their analyzer had not produced. Registering it as a technology is what puts it back under the same detection and tech-selection rules as everything else.

SDL schema documents are graphql_sdl's; the parser reports nothing for them, and the detector only registers files it would produce something from.

Class methods

tech_name
Source

Instance methods

analyze
Source
tech

Instance-side view of the same declaration. The per-file rescues live on this base class, which has no way to name the analyzer that is running inside them, so a skipped file could not be attributed to a tech. Deriving it from analyzer_for keeps the name written exactly once.

Source