Skip to content

feat: add localized taxonomy and term delivery (CDA) support#190

Merged
cs-raj merged 11 commits into
v2-legacyfrom
feat/taxonomy-publishing-localisation-2
Jul 16, 2026
Merged

feat: add localized taxonomy and term delivery (CDA) support#190
cs-raj merged 11 commits into
v2-legacyfrom
feat/taxonomy-publishing-localisation-2

Conversation

@cs-raj

@cs-raj cs-raj commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Extends the .NET SDK with published-taxonomy fetch and term delivery endpoints to match the TypeScript feat/taxonomy-publishing parity.

New:

  • Term.cs — Fetch(locale?), Locales(), Ancestors(), Descendants()
  • TermQuery.cs — SetLocale()/IncludeFallback() chainable builder + Find()

Extended Taxonomy class:

  • Taxonomy(stack, uid) constructor
  • _Url switches to /taxonomies/{uid} when uid is set
  • Fetch(locale?) — own HTTP path, parses $.taxonomy
  • Term(termUid) → Term, Terms() → TermQuery

Extended ContentstackClient:

  • Taxonomies(uid) overload

Tests:

  • TaxonomyUnitTests — 46 unit tests (all pass)
  • TaxonomyLocalisationTest — integration tests per CDA call
  • TestDataHelper — taxonomy-publish stack config properties

@cs-raj cs-raj requested a review from a team as a code owner July 15, 2026 12:58
@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

@cs-raj cs-raj changed the base branch from master to v2-legacy July 15, 2026 13:00
@cs-raj cs-raj requested a review from a team as a code owner July 15, 2026 13:00
Extends the .NET SDK with published-taxonomy fetch and term delivery
endpoints to match the TypeScript feat/taxonomy-publishing parity (CD-11371).

New:
- Term.cs — Fetch(locale?), Locales<T>(), Ancestors<T>(), Descendants<T>()
- TermQuery.cs — SetLocale()/IncludeFallback() chainable builder + Find<T>()

Extended Taxonomy class:
- Taxonomy(stack, uid) constructor
- _Url switches to /taxonomies/{uid} when uid is set
- Fetch<T>(locale?) — own HTTP path, parses $.taxonomy
- Term(termUid) → Term, Terms() → TermQuery

Extended ContentstackClient:
- Taxonomies(uid) overload

Tests:
- TaxonomyUnitTests — 46 unit tests (all pass)
- TaxonomyLocalisationTest — integration tests per CDA call
- TestDataHelper — taxonomy-publish stack config properties

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@cs-raj cs-raj force-pushed the feat/taxonomy-publishing-localisation-2 branch from 6274caa to 1940b78 Compare July 15, 2026 13:05
@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

…ntegration tests

- Add includeFallback param to Term.Fetch<T>; serialize as string "true" to match
  CDA case-sensitivity (bool true serializes as "True" which the API rejects)
- Pass includeFallback: true in Fetch_SingleTerm test to be consistent with how
  GetFirstTermUidAsync lists terms (with IncludeFallback)
- Rewrite Find_AllTaxonomies test to call Terms().Find<JObject>() without locale
  instead of the entries-by-taxonomy endpoint which requires tagged entries
@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

netrajpatel
netrajpatel previously approved these changes Jul 15, 2026
OMpawar-21
OMpawar-21 previously approved these changes Jul 15, 2026
@OMpawar-21 OMpawar-21 dismissed stale reviews from netrajpatel and themself via f858c72 July 16, 2026 03:18
@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

fix: added branch set via the stack config
@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

OMpawar-21
OMpawar-21 previously approved these changes Jul 16, 2026
netrajpatel
netrajpatel previously approved these changes Jul 16, 2026
Comment thread CHANGELOG.md Outdated
…convention

- Replace Taxonomy.Fetch<T>(string locale) and Term.Fetch<T>(string locale, bool includeFallback)
  with chainable SetLocale()/IncludeFallback()/AddParam() before Fetch<T>() — matching
  the convention used by Asset, Entry, and AssetLibrary

- Fix Branch ?? "main" fallback across Taxonomy, Term, TermQuery — was injecting
  branch=main into every CDA request when branching was not configured, causing
  422 Branch not found errors

- Wire GetContentstackError() into all catch blocks across Taxonomy, Term, TermQuery —
  replaces TaxonomyException.CreateForProcessingError() which never read the API
  response body, leaving ErrorCode/StatusCode/Errors unpopulated on 4xx responses

- Rename _queryParams → UrlQueries in Term and TermQuery to match Taxonomy and Entry
- Fix TermQuery.SetLocale(null) to no-op instead of throwing, consistent with Taxonomy/Term/Entry
- Add AddParam() to TermQuery (was missing)
- Add class-level XML doc and <example> blocks across Taxonomy, Term, TermQuery

Adds 15 new unit tests (Taxonomy.SetLocale/IncludeFallback/AddParam, Term.SetLocale/
IncludeFallback/AddParam, TermQuery.AddParam) — 1016 total, all passing
@cs-raj cs-raj dismissed stale reviews from netrajpatel and OMpawar-21 via cbe3817 July 16, 2026 07:47
@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

@reeshika-h reeshika-h requested a review from netrajpatel July 16, 2026 08:14
@reeshika-h reeshika-h requested a review from OMpawar-21 July 16, 2026 08:14
reeshika-h
reeshika-h previously approved these changes Jul 16, 2026

@reeshika-h reeshika-h left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

netrajpatel
netrajpatel previously approved these changes Jul 16, 2026
reeshika-h
reeshika-h previously approved these changes Jul 16, 2026
@cs-raj cs-raj dismissed stale reviews from reeshika-h and netrajpatel via eacbd71 July 16, 2026 08:40
@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

OMpawar-21
OMpawar-21 previously approved these changes Jul 16, 2026
@cs-raj cs-raj dismissed stale reviews from abhishek-ezhava-cstk and OMpawar-21 via be9e17b July 16, 2026 08:52
@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

@cs-raj cs-raj merged commit ba679e1 into v2-legacy Jul 16, 2026
11 checks passed
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.

5 participants