Skip to content

Conversation

@cicoyle
Copy link
Contributor

@cicoyle cicoyle commented Nov 3, 2025

Example updates and docs for how to implement App API Token authentication in Java applications for building blocks where Dapr makes incoming calls (pubsub, bindings, jobs).

Signed-off-by: Cassandra Coyle <[email protected]>
Signed-off-by: Cassandra Coyle <[email protected]>
@cicoyle cicoyle requested review from a team as code owners November 3, 2025 21:30
@codecov
Copy link

codecov bot commented Nov 3, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.49%. Comparing base (d759c53) to head (d9f2d63).
⚠️ Report is 237 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #1589      +/-   ##
============================================
+ Coverage     76.91%   78.49%   +1.57%     
- Complexity     1592     1935     +343     
============================================
  Files           145      216      +71     
  Lines          4843     5872    +1029     
  Branches        562      659      +97     
============================================
+ Hits           3725     4609     +884     
- Misses          821      926     +105     
- Partials        297      337      +40     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

String apiToken = metadata.get(
Metadata.Key.of("dapr-api-token", Metadata.ASCII_STRING_MARSHALLER));

// Validate token accordingly
Copy link
Contributor

Choose a reason for hiding this comment

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

Would it be good to add what validations to perform on this token ? (best practices kind of)

Are they typical jwt validation checks like expiry, audience ?

Copy link
Contributor

@siri-varma siri-varma left a comment

Choose a reason for hiding this comment

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

LGTM

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.

2 participants