fsharp-verify-api
Check the real signature of a .NET or F# API before F# code uses it, so the build does not loop on FS0039, FS0001, FS0074, or FS0078. Use when writing F# against a NuGet package, a package version that changed its API, an unfamiliar type, or an .fsx script with
Unsigned, install at your own risk
UnverifiedThis skill has no cryptographic signature attached. We can't verify the contents match what the publisher intended.
Install this skill
No account required. Pick your tool, or use the command that detects it for you.
Run in your terminal. It detects your AI tool.
npx @skills-hub-ai/cli install fsharp-skills-fsharp-verify-apiManual setup by platform
Claude Code
~/.claude/skills/fsharp-skills-fsharp-verify-api/SKILL.md
Instructions
Verify an F# API before you use it
Agents write the API that they remember. Packages move, rename, and remove members between versions.
The compiler then reports FS0039 (not defined), and each guess costs one more failed build.
Session evidence ranks FS0039 as the top compiler error. 177 Codex sessions had 4 or more failed builds or test runs.
The fix is to read the signature first. One listing is cheaper than three failed builds.
Rules
- Find the package version that the project uses. Read the
.fsproj,Directory.Packages.props, orpaket.lock. Do not assume the latest version. - Before you call a member that you have not seen in this codebase or in this version, list its signature.
Usescripts/show-api.ps1. It prints the public constructors, methods, properties, and extension methods of a type, with inherited members and F# source names.
The script exits 0 when the type or member does not exist. A missing member is information, not a failed build. - Do not probe an API with a build or with speculative
dotnet fsicode. Each failed probe is a failed build. - When a type is not defined (FS0039), check the open first: find the namespace of the type in the listing (
TYPEline) and add thatopen. - When the compiler reports FS0074, the type comes from an assembly that the project does not reference. Add the package that holds that assembly. Do not add an unrelated package.
- Before you write a helper, search the codebase for one that does the same work. Use
rgfor the result type or for a verb in the name. - In an
.fsxscript, a relative#rpath resolves from the script's directory, not from the current directory. FS0078 means the path is wrong.
Pin each#r "nuget: Package, Version"to the project's version. Without a version, FSI loads the latest stable version.
Read references/LOOKUP.md for each lookup method, the XML docs in the NuGet cache, and the .fsx rules.
Steps
-
List each external type and member that the change uses and that the codebase does not use already.
Done when each item has a package and a version. -
For each item, run the listing script and read the real signature:
pwsh <skill-root>/scripts/show-api.ps1 -Package FsToolkit.ErrorHandling -Version 5.2.0 -Type FsToolkit.ErrorHandling.Result -Member requireUse
-Member ''to list all members,-Member ctorfor constructors, and-Assemblywhen the assembly name differs from the package ID. -
When the signature is not what you remember, find the replacement member in the same listing or in the XML docs. Do not guess a second name.
-
Write the code with the listed signatures, then build once.
-
When the build fails, read the first error only. Later errors are often cascades of the first. Fix it with step 2, not with a guess.
Verify
Run the proof script from the skill root:
pwsh ./scripts/run.ps1
The script lists members of two versions of a package that moved its API between versions.
It fails when an expected member is missing or a removed member is present.
Security
Reviews (0)
Related skills
Browse all →More from F# Skills
View source →More Build skills
Browse category →Frequently asked questions about fsharp-verify-api
What does the fsharp-verify-api skill do?
Check the real signature of a .NET or F# API before F# code uses it, so the build does not loop on FS0039, FS0001, FS0074, or FS0078. Use when writing F# against a NuGet package, a package version that changed its API, an unfamiliar type, or an .fsx script with It's a reusable SKILL.md instruction set that loads into your AI coding assistant on demand, no prompt engineering, no copy-pasting every session.
How do I install the fsharp-verify-api skill?
Run `npx @skills-hub-ai/cli install fsharp-skills-fsharp-verify-api` from your terminal. The CLI writes the SKILL.md to the correct location for your AI tool (e.g. ~/.claude/skills/fsharp-skills-fsharp-verify-api/ for Claude Code or ~/.cursor/skills/ for Cursor with --target cursor) and adds it to your project's .skills.json lockfile.
Which AI tools does fsharp-verify-api work with?
fsharp-verify-api runs in Claude Code. It follows the open Agent Skills standard (SKILL.md), so the same skill works in every supported tool without modification.
Is the fsharp-verify-api skill free?
Yes. Every skill on skills-hub.ai is free and open-source. There are no premium tiers, paywalls, or usage limits. You only pay for whatever AI assistant you're already using.
How do I use fsharp-verify-api after installing it?
In Claude Code, type `/fsharp-skills-fsharp-verify-api` (or whatever slash command the skill registers) and the AI follows the skill's instructions immediately. You can also reference it by name in natural language, your AI loads the skill into context when relevant.
Can I share the fsharp-verify-api skill with my team?
Yes. Commit your project's .skills.json lockfile and teammates run `npx @skills-hub-ai/cli install` (no args) to install every skill at the exact version you pinned. Organization-scoped installs work via skills-hub.ai organizations.