docs(sdk): update Go authorization samples to use EntityIdentifier helpers#269
docs(sdk): update Go authorization samples to use EntityIdentifier helpers#269marythought wants to merge 5 commits intomainfrom
Conversation
…lpers Simplifies the V2 Go code samples for GetDecision and GetEntitlements by using the new sdk.ForClientID helper instead of manual proto nesting. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✅ Files skipped from review due to trivial changes (2)
📝 WalkthroughWalkthroughUpdated two Go authorization sample files to use v2 helpers and SDK call variants (replacing manual entity chain construction with Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
❌ Surge preview build failed — no preview was deployed. Check the workflow logs for details. Once the build passes, the preview will be at: https://opentdf-docs-pr-269.surge.sh Common cause: If the build failed on vendored YAML validation, run the following locally and commit the result: |
Updates Go authorization samples to use the new EntityIdentifier helpers from the authorizationv2 package — no extra import needed. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Mary Dickson <mary.dickson@virtru.com>
Uses `authorization` instead of `authorizationv2` as the import alias
for cleaner calling convention: authorization.ForClientID("opentdf").
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Mary Dickson <mary.dickson@virtru.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Mary Dickson <mary.dickson@virtru.com>
The helpers moved from the authorization/v2 proto package to the sdk package and were renamed (e.g., ForClientID → EntityIdentifierForClientID). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Mary Dickson <mary.dickson@virtru.com>
|
draft pending ADR decision on which pattern to use for sustainability 🚀 |
Summary
get_decision.mdxandget_entitlements.mdxto use the newsdk.ForClientID()helper instead of manual 4-level proto nestingAuthorizationV2) instead of v1Depends on opentdf/platform#3232.
Test plan
🤖 Generated with Claude Code
Summary by CodeRabbit