maui-ai-tool-bindings

maui-ai-tool-bindings is a skill for Claude Code, Codex from dotnet/maui-labs. It costs 83 tokens per session (1,126 once invoked), scanned A, original, MIT.

A set of MAUI instructions for exposing application methods as tools that an AI chat client can call. Microsoft .NET MAUI is a framework for building apps for multiple platforms from shared code.

In plain words
What is it for?
Use it to expose app services or utility methods as AI-callable functions, define tool descriptions and parameters, create tool contexts, register dependencies, and enable function invocation in a MAUI chat app.
Why use it?
It generates the tool bindings at compile time, so MAUI services and view models can be made available to AI calls without relying on reflection-heavy invocation. It also covers registering those services and connecting the generated tools to a chat client.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to expose app services or utility methods as AI-callable functions, define tool descriptions and parameters, create tool contexts, register dependencies, and enable function invocation in a MAUI chat app.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/dotnet/maui-labs/maui-ai-tool-bindings
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add dotnet/maui-labs --skill maui-ai-tool-bindings
Clone the repo
git clone --depth 1 https://github.com/dotnet/maui-labs

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for maui-ai-tool-bindings

README.md
[![agentmods](https://agentmods.dev/badge/skills/dotnet/maui-labs/maui-ai-tool-bindings/github.svg)](https://agentmods.dev/skills/dotnet/maui-labs/maui-ai-tool-bindings)
Your own site
<a href="https://agentmods.dev/skills/dotnet/maui-labs/maui-ai-tool-bindings"><img src="https://agentmods.dev/badge/skills/dotnet/maui-labs/maui-ai-tool-bindings/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for maui-ai-tool-bindings

Your own site · 80×15
<a href="https://agentmods.dev/skills/dotnet/maui-labs/maui-ai-tool-bindings"><img src="https://agentmods.dev/badge/skills/dotnet/maui-labs/maui-ai-tool-bindings.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 83 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,126 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00083 $0.01126
Opus 5.5 $0.00033 $0.00450
Sonnet 5.5 $0.00017 $0.00225
Haiku 4.5 $0.00008 $0.00113

Measured 2mo ago against content hash 3718f9be7cb0, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

maui-ai-tool-bindings scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/dotnet-maui/skills/maui-ai-tool-bindings/SKILL.md · 148 lines

How it starts

The opening of the file, as written. The whole thing — 148 lines — stays where its author put it; the contents beside it link to each section on GitHub.

MAUI AI Tool Bindings

Use this skill when a MAUI app needs AI-callable tools backed by app services, view models, or static utility methods. Microsoft.Maui.AI.Attributes generates Microsoft.Extensions.AI tools at compile time to avoid reflection-heavy invocation paths.

Basic Workflow

  1. Install the package:

    dotnet add package Microsoft.Maui.AI.Attributes --prerelease
    
  2. Annotate methods or property accessors:

    using System.ComponentModel;
    using Microsoft.Maui.AI.Attributes;
    
    public sealed class PlantCatalogService
    {
        [Description("Searches the plant catalog by name or category.")]
        [ExportAIFunction("search_plants")]
        public IReadOnlyList<PlantInfo> SearchPlants(
            [Description("Optional filter text")] string? query = null)
        {
            return [];
        }
    }
    
  3. Create a curated tool context:

    [AIToolSource(typeof(PlantCatalogService))]
    public partial class GardenTools : AIToolContext
    {
    }
    
  4. Register services normally in MauiProgram.cs:

    builder.Services.AddSingleton<PlantCatalogService>();
    
  5. Pass generated tools into an IChatClient:

    var client = innerClient.AsBuilder()
        .UseFunctionInvocation()
        .ConfigureOptions(options =>
        {
            options.Tools ??= [];
            foreach (var tool in GardenTools.Default.Tools)
                options.Tools.Add(tool);
        })
        .Build(serviceProvider);
    

Tool Context Choices

Need Pattern
Curated feature-specific tools Explicit partial AIToolContext with [AIToolSource]
Small prototype exposing all exported tools Assembly-wide <AssemblyName>ToolContext.Default.Tools
Sensitive mutation [ExportAIFunction(ApprovalRequired = true)]
Static utility tool Static [ExportAIFunction] method
Service-backed tool Instance method on a DI-registered service

Prefer explicit contexts for production features so tool names and scope stay stable.

Read the full file on GitHub · 148 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago Changed · -12 tokens per session 3718f9be7cb0
  2. 3mo ago First seen · 148 lines · 95 tokens per session scan A 45afb1552cd4

Subscribe to this mod's changes

maui-ai-tool-bindings is a skill published in the GitHub repository dotnet/maui-labs (244 stars, last pushed today), licensed MIT. It adds 83 tokens to every session and 1,126 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

maui-ai-tool-bindings compared with skills from other repositories

maui-ai-tool-bindings next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
maui-ai-tool-bindingsdotnet/maui-labsSkill244todayMITA83Claude Code, Codex
argent-react-native-app-workflowsoftware-mansion/argentSkill3.3ktodayApache-2.0A41Claude Code, Codex
argent-react-native-optimizationsoftware-mansion/argentSkill3.3ktodayApache-2.0A46Claude Code, Codex
mobile-automationmobile-next/mobile-mcpSkill11k5d agoApache-2.0A58Claude Code, Codex
argent-metro-debuggersoftware-mansion/argentSkill3.3ktodayApache-2.0A50Claude Code, Codex
argent-native-profilersoftware-mansion/argentSkill3.3ktodayApache-2.0A41Claude Code, Codex
argent-screen-recordingsoftware-mansion/argentSkill3.3ktodayApache-2.0A38Claude Code, Codex