generate-client

generate-client is a command for Claude Code from Sahib-Sawhney-WH/sahibs-claude-plugin-marketplace. It costs 10 tokens per session (706 once invoked), scanned A, original, MIT.

A command that generates typed Python client code for a Microsoft Dataverse table. Typed code specifies the expected kinds of values, such as text, numbers, or dates.

In plain words
What is it for?
Use it to create Pydantic models and a client with typed create, read, update, and delete methods for a selected Dataverse table.
Why use it?
It removes the repetitive work of reading a table schema and writing models and data-access methods by hand.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: names the AskUserQuestion tool.

Part of the dataverse plugin — 6 skills, 5 commands, 1 MCP server shipped together

Good fit Use it to create Pydantic models and a client with typed create, read, update, and delete methods for a selected Dataverse table.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/sahib-sawhney-wh/sahibs-claude-plugin-marketplace/generate-client
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.

Clone the repo
git clone --depth 1 https://github.com/Sahib-Sawhney-WH/sahibs-claude-plugin-marketplace

Made for: Claude Code.

Or install dataverse, the plugin that ships this one along with the rest of its 6 skills, 5 commands, 1 MCP server.

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 generate-client

README.md
[![agentmods](https://agentmods.dev/badge/commands/sahib-sawhney-wh/sahibs-claude-plugin-marketplace/generate-client/github.svg)](https://agentmods.dev/commands/sahib-sawhney-wh/sahibs-claude-plugin-marketplace/generate-client)
Your own site
<a href="https://agentmods.dev/commands/sahib-sawhney-wh/sahibs-claude-plugin-marketplace/generate-client"><img src="https://agentmods.dev/badge/commands/sahib-sawhney-wh/sahibs-claude-plugin-marketplace/generate-client/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 generate-client

Your own site · 80×15
<a href="https://agentmods.dev/commands/sahib-sawhney-wh/sahibs-claude-plugin-marketplace/generate-client"><img src="https://agentmods.dev/badge/commands/sahib-sawhney-wh/sahibs-claude-plugin-marketplace/generate-client.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 10 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 706 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.
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.00010 $0.00706
Opus 5 $0.00005 $0.00353
Sonnet 5 $0.00002 $0.00141
Haiku 4.5 $0.00001 $0.00071

Measured 12d ago against content hash ff240947dd38, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

generate-client 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 12d 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/dataverse/commands/generate-client.md · 108 lines

How it starts

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

Dataverse Generate Client Command

Generate typed Python client code for a specific Dataverse table.

Instructions

When the user runs /dataverse:generate-client <table>:

  1. Get table schema

    • Use dataverse_get_table_info to get columns and types
    • Extract column names, types, and metadata
  2. Generate Pydantic models

    • Create model class for the table
    • Map Dataverse types to Python types
    • Add Optional for nullable fields
  3. Generate client class

    • CRUD methods for the table
    • Type hints for all parameters and returns
    • Docstrings with examples
  4. Write output file

    • Default: <table>_client.py
    • Include all imports

Type Mapping

Dataverse Type Python Type
string str
int int
decimal Decimal
bool bool
datetime datetime
lookup str (GUID)
picklist int or Enum

Generated Code Template

"""
Auto-generated Dataverse client for {table_name}
Generated by dataverse plugin
"""

from dataclasses import dataclass
from typing import Optional, List
from datetime import datetime
from decimal import Decimal
from PowerPlatform.Dataverse.client import DataverseClient

@dataclass
class {TableClass}:
    """{table_name} record model."""
    {table_id}: Optional[str] = None
    {columns}

class {TableClass}Client:
    """Client for {table_name} operations."""

    def __init__(self, client: DataverseClient):
        self.client = client
        self.table = "{table_schema_name}"

    def create(self, record: {TableClass}) -> str:
        """Create a new {table_name} record."""
        data = {k: v for k, v in record.__dict__.items() if v is not None}
        ids = self.client.create(self.table, data)
        return ids[0]

    def get(self, record_id: str) -> {TableClass}:
        """Get a {table_name} record by ID."""
        data = self.client.get(self.table, record_id)
        return {TableClass}(**data)

    def update(self, record_id: str, updates: dict) -> None:
        """Update a {table_name} record."""
        self.client.update(self.table, record_id, updates)

    def delete(self, record_id: str) -> None:
        """Delete a {table_name} record."""
        self.client.delete(self.table, record_id)

    def list(self, filter: str = None, top: int = 100) -> List[{TableClass}]:
        """List {table_name} records."""
        pages = self.client.get(self.table, filter=filter, top=top)
        records = []
        for page in pages:
            records.extend([{TableClass}(**r) for r in page])
        return records

Read the full file on GitHub · 108 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. 12d ago First seen · 108 lines · 10 tokens per session scan A ff240947dd38

Subscribe to this mod's changes

generate-client is a command published in the GitHub repository Sahib-Sawhney-WH/sahibs-claude-plugin-marketplace (4 stars, last pushed 8mo ago), licensed MIT. It adds 10 tokens to every session and 706 once invoked, about $0.0001 per session on Opus 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-31.