Skip to content

Conversation

@konstantin-msft
Copy link
Collaborator

Add PCAFactory and correlation id optional params to createNestablePublicClientApplication

@konstantin-msft konstantin-msft changed the title Add PCAFactory and correlation id optional params to createNestablePublicClientApplication [v5] Add PCAFactory and correlation id optional params to createNestablePublicClientApplication Oct 10, 2025
@konstantin-msft konstantin-msft marked this pull request as ready for review October 10, 2025 21:02
@konstantin-msft konstantin-msft requested a review from a team as a code owner October 10, 2025 21:02
Copilot AI review requested due to automatic review settings October 10, 2025 21:02
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR enhances the createNestablePublicClientApplication function by adding two optional parameters: correlationId and pcaFactory. The enhancement allows users to provide their own correlation ID instead of auto-generating one and to use a custom factory function for creating the PublicClientApplication instance.

Key changes:

  • Added optional correlationId parameter to allow custom correlation IDs
  • Added optional pcaFactory parameter to enable custom PCA instance creation
  • Updated function signature and implementation to handle the new parameters

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
lib/msal-browser/src/app/PublicClientApplication.ts Updated function signature and implementation to support optional correlationId and pcaFactory parameters
lib/msal-browser/test/app/createNestablePublicClientApplication.spec.ts Added comprehensive test coverage for the new optional parameters including edge cases
lib/msal-browser/apiReview/msal-browser.api.md Updated API documentation to reflect the new function signature
change/@azure-msal-browser-e8a7eb79-1f90-43a2-8788-a2e901e835ca.json Added beachball change file for the minor version update

Copy link
Member

@sameerag sameerag left a comment

Choose a reason for hiding this comment

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

There is an officeAddin sample in our repo, we may want to test it with the new PCA Params before merging this. Let me know if you need help there.

@konstantin-msft konstantin-msft merged commit 8cb3863 into msal-v5 Oct 27, 2025
6 checks passed
@konstantin-msft konstantin-msft deleted the enable_1p_naa branch October 27, 2025 19:28
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.

4 participants