Skip to content

Epic: VS Code extension (editors/vscode) #29

Open
10 of 10 issues completed
Open

Description

@dataGriff

Why

apic's files already open in VS Code with the REST Client extension, but nothing in the editor knows about # @assert, # @capture, environments, the session or Gherkin features. An apic extension closes that loop: run a request from a CodeLens with apic's runner (so what you see is what CI sees), get apic validate diagnostics as you type, switch environment from the status bar, and see the response with assertions and captures.

Design

  • Lives in this repo under editors/vscode/ (monorepo: shared CI, shared releases, the extension can pin the apic version it drives, docs in one place). Node is confined to that directory and its CI job; the Go tree stays Node-free.
  • A thin TypeScript extension that shells out to the apic binary through its existing --json contract (list, describe, run, validate, env, session, test). It never re-implements parsing or auth.
  • Coexists with REST Client: it does not register the http language itself. It injects a TextMate grammar for # @directive lines only, and contributes commands, CodeLens, diagnostics, views and a webview. People keep REST Client's "Send Request" if they like it.
  • Publishes to the Marketplace and Open VSX from a vscode-v* tag.
  • Later, the diagnostics/hover/completion pieces move into a Go apic lsp so Neovim, JetBrains and Zed get the same, and the extension becomes a client.

What is in scope

  • P1 scaffold with build/test/CI; CodeLens run/describe/curl; diagnostics from validate; response viewer; environment picker with session and request views; publish workflow
  • P2 completions, hovers and snippets; Test Explorer for .feature files; schema associations and format-on-save
  • P3 apic lsp

Depends on (in the other epics)

  • apic validate columns for precise squiggles (runner epic)
  • JSON schemas for apic.yaml and env files (docs epic)
  • apic fmt for Format Document (runner epic)

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions