Skip to content

fix(assets)!: allow decimal effective life years - #843

Open
miachillgood wants to merge 1 commit into
XeroAPI:masterfrom
miachillgood:codex/issue-634-effective-life-decimal
Open

fix(assets)!: allow decimal effective life years#843
miachillgood wants to merge 1 commit into
XeroAPI:masterfrom
miachillgood:codex/issue-634-effective-life-decimal

Conversation

@miachillgood

Copy link
Copy Markdown

Description

The Assets API can return decimal strings such as 10.00 for bookDepreciationSetting.effectiveLifeYears, but the schema declares the field as an integer. Generated SDKs therefore fail while deserializing valid asset responses.

This changes the schema to an OpenAPI number with double format so generated clients can represent both whole and fractional effective-life values.

Fixes XeroAPI/Xero-NetStandard#634.

Compatibility

This changes the generated SDK property type, so the commit carries the repository's Conventional Commits breaking marker and an explicit BREAKING CHANGE footer.

Validation

  • parsed xero_assets.yaml successfully with PyYAML
  • scripts/api-diff/api-diff.test.sh: 9/9 passed, including breaking-marker detection
  • git diff --check

Repository CI will run the official API-diff and code-generation validation.

BREAKING CHANGE: generated SDKs will represent effectiveLifeYears with a floating-point numeric type instead of an integer type.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

BookDepreciationSetting.EffectiveLifeYears int? - decimal? sterilization error

1 participant