← ClaudeAtlas

csharp-modelslisted

Work with models from the PayPal Server SDK C# SDK. Load before building a request payload or mapping a response onto your own types. The class won't tell you which fields serialize on a model you never touched, how optional-and-nullable state is tracked, how a oneOf/anyOf container matches, or where unknown fields land.
MuHamza30/paypal-api-plugin · ★ 0 · AI & Automation · score 70
Install: claude install-skill MuHamza30/paypal-api-plugin
# Working with models in an APIMatic C# SDK Data models are plain classes under `Models/`, namespace `PaypalServerSdk.Standard.Models`. **If** the API declares a `oneOf`/`anyOf`, containers sit beside them in `Models/Containers/` — `ls` that folder first, because many APIs declare none and it is then absent. Plain scalars need nothing from this skill — see **csharp-calling-endpoints**. The emitted shapes are catalogued in [reference.md](reference.md); this skill is the rules for using them. ## Anatomy of a generated model A model emits a parameterless constructor and an all-fields one, and `doc/models/*.md` builds its examples with an object initializer. The all-fields constructor puts the **required parameters first, then the optional ones**, each group in spec order — so its parameter order is not the spec's field order, and you cannot read one off the other. **Nor is the C# required/optional split reliable**: a required-but-nullable field is emitted as a C# optional argument defaulting to `null`, so `new {Model}()` can compile while leaving required fields unset and serializing them as `null`. Take required-vs-optional from the **Tags** column of `doc/models/{model}.md`, and prefer the object initializer so every omission is explicit: > **`Models.{Model}` does not compile in your code.** The skills and the generated source write model > types that way because that source sits *inside* `PaypalServerSdk.Standard`, where `Models` is a nested > namespace. A `using` directi