src/PowerPlatform/Dataverse/claude_skill/dataverse-sdk-dev/SKILL.md
Development guidance for contributing to the PowerPlatform Dataverse Client Python SDK repository. Use when working on SDK development tasks like adding features, fixing bugs, or writing tests.
npx skillsauth add microsoft/powerplatform-dataverseclient-python dataverse-sdk-devInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
This skill provides guidance for developers working on the PowerPlatform Dataverse Client Python SDK repository itself (not using the SDK).
src/PowerPlatform/Dataverse/operations/ (records.py, query.py, tables.py, batch.py). The client.py file exposes these via namespace properties (client.records, client.query, client.tables, client.batch). Public types and constants live in their own modules (e.g., models/metadata.py, models/batch.py, common/constants.py)_ prefix (e.g., _odata.py, _relationships.py). Files without the prefix (e.g., constants.py, metadata.py) are public and importable by SDK consumersDataverse uses two different naming conventions for properties. Getting this wrong causes 400 errors that are hard to debug.
| Property type | Name convention | Example | When used |
|---|---|---|---|
| Structural (columns) | LogicalName (always lowercase) | new_name, new_priority | $select, $filter, $orderby, record payload keys |
| Navigation (relationships / lookups) | Navigation Property Name (usually SchemaName, PascalCase, case-sensitive) | new_CustomerId, new_AgentId | $expand, @odata.bind annotation keys |
Navigation property names are case-sensitive and must match the entity's $metadata. Using the logical name instead of the navigation property name results in 400 Bad Request errors.
Critical rule: The OData parser validates @odata.bind property names case-sensitively against declared navigation properties. Lowercasing [email protected] to [email protected] causes: ODataException: An undeclared property 'new_customerid' which only has property annotations...
SDK implementation:
_lowercase_keys() lowercases all keys EXCEPT those containing @odata. (preserves navigation property casing in @odata.bind keys)_lowercase_list() lowercases $select and $orderby params (structural properties)$expand params are passed as-is (navigation properties, PascalCase)_convert_labels_to_ints() skips @odata. keys entirely (they are annotations, not attributes)When adding new code that processes record dicts or builds query parameters:
_lowercase_keys() for record payloads. Never manually call .lower() on all keys$expand values or @odata.bind key prefixes@odata. when doing attribute-level operations[INFO], [WARN], [ERR], [OK] prefixes for console output# noqa: BLE001 or similar linter suppression comments__all__ (e.g., errors.py defines __all__ = ["HttpError", ...]). Package __init__.py files should not re-export or redefine another module's __all__; they use __all__ = [] to indicate no star-import exports.python -m black <changed files> before committing. CI will reject unformatted code. Config is in pyproject.toml under [tool.black].This SDK's API reference is published on Microsoft Learn. The Learn doc pipeline parses :type: and :rtype: directives differently from standard Sphinx -- every word between :class: references is treated as a separate cross-reference (<xref:word>). Using Sphinx-style :class:\list` of :class:`str`produces brokenxref:of` links on Learn.
Rules for :type: and :rtype: directives:
list[str], dict[str, typing.Any], list[dict]or (without :class:) for union types: str or None, dict or list[dict]collections.abc.Iterable[list[dict]]~ prefix for SDK types to show short name: list[~PowerPlatform.Dataverse.models.record.Record]:class: is fine for single standalone types: :class:\str`, :class:`bool``Never use :class:\X` of :class:`Y`or:class:`X` mapping :class:`Y` to :class:`Z`-- the wordsof, mapping, tobecome brokenxref:` links.
Correct examples:
:type data: dict or list[dict]
:rtype: list[str]
:rtype: collections.abc.Iterable[list[~PowerPlatform.Dataverse.models.record.Record]]
:type select: list[str] or None
:type columns: dict[str, typing.Any]
Wrong examples (NEVER use):
:type data: :class:`dict` or :class:`list` of :class:`dict`
:rtype: :class:`list` of :class:`str`
:type columns: :class:`dict` mapping :class:`str` to :class:`typing.Any`
tools
Guidance for using the PowerPlatform Dataverse Client Python SDK. Use when calling the SDK like creating CRUD operations, SQL queries, table metadata management, relationships, and upload files.
tools
Use when work should span one or more detached tasks but still behave like one job with a single owner context. TaskFlow is the durable flow substrate under authoring layers like Lobster, ACPX, plugins, or plain code. Keep conditional logic in the caller; use TaskFlow for flow identity, child-task linkage, waiting state, revision-checked mutations, and user-facing emergence.
tools
# Lobster Lobster executes multi-step workflows with approval checkpoints. Use it when: - User wants a repeatable automation (triage, monitor, sync) - Actions need human approval before executing (send, post, delete) - Multiple tool calls should run as one deterministic operation ## When to use Lobster | User intent | Use Lobster? | | ------------------------------------------------------ | --------------------------
tools
# Lobster Lobster executes multi-step workflows with approval checkpoints. Use it when: - User wants a repeatable automation (triage, monitor, sync) - Actions need human approval before executing (send, post, delete) - Multiple tool calls should run as one deterministic operation ## When to use Lobster | User intent | Use Lobster? | | ------------------------------------------------------ | --------------------------