Skip to content

feat(auth): support federated credentials (OIDC client assertion) - #1953

Open
radu-mocanu wants to merge 1 commit into
mainfrom
feat/federated-credentials
Open

radu-mocanu wants to merge 1 commit into
mainfrom
feat/federated-credentials

Conversation

@radu-mocanu

@radu-mocanu radu-mocanu commented Oct 20, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • uipath auth --client-id ... --client-assertion <oidc-token> logs in with an OIDC token from the CI provider instead of a client secret (also read from UIPATH_CLIENT_ASSERTION)
  • UiPath(client_id=..., client_assertion=...) does the same from code, e.g. in tests that call Orchestrator
  • the token is sent as a jwt-bearer client assertion, the same request uip login --client-assertion makes
  • new federated-credentials-ci sample with a GitHub Actions workflow

Why

Fixes #1944. CI pipelines had to store a long-lived client secret to use the SDK.

@github-actions github-actions Bot added test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-runtime test:uipath-integrations labels Oct 20, 2026
@radu-mocanu
radu-mocanu force-pushed the feat/federated-credentials branch from a93c92c to 15c0584 Compare October 20, 2026 13:51
@radu-mocanu
radu-mocanu marked this pull request as ready for review October 20, 2026 14:11
Copilot AI balanced review requested due to automatic review settings October 20, 2026 14:11

Copilot AI 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.

🟡 Changes recommended

Incomplete CLI credentials select interactive authentication, and sample scopes and workflow triggers conflict with the documented setup.

3 open issues
What changed in this PR

Adds OIDC federated authentication to the UiPath SDK and CLI, enabling CI pipelines to authenticate without stored client secrets.

Changes:

  • Supports JWT client assertions across CLI, SDK, and Identity services.
  • Adds authentication tests and a GitHub Actions sample.
  • Updates package versions and dependency requirements.
File Description
packages/​uipath/​uv.lock Updates locked package versions.
packages/​uipath/​tests/​cli/​test_auth.py Tests assertion-based CLI login.
packages/​uipath/​src/​uipath/​_cli/​cli_auth.py Adds assertion option and environment variable.
packages/​uipath/​src/​uipath/​_cli/​_auth/​_auth_service.py Routes assertions through client credentials authentication.
packages/​uipath/​samples/​federated-credentials-ci/​tests/​test_orchestrator.py Demonstrates authenticated Orchestrator access.
packages/​uipath/​samples/​federated-credentials-ci/​README.md Documents federated authentication setup.
packages/​uipath/​samples/​federated-credentials-ci/​pyproject.toml Defines sample dependencies.
packages/​uipath/​samples/​federated-credentials-ci/​github-workflow.yml Demonstrates GitHub Actions OIDC login.
packages/​uipath/​pyproject.toml Bumps SDK version and platform requirement.
packages/​uipath-platform/​uv.lock Updates platform version.
packages/​uipath-platform/​tests/​test_uipath_client_credentials.py Tests SDK credential handling.
packages/​uipath-platform/​tests/​services/​test_identity_service.py Tests assertion payloads and validation.
packages/​uipath-platform/​tests/​services/​test_external_application_service.py Updates delegation expectations.
packages/​uipath-platform/​src/​uipath/​platform/​identity/​_identity_service.py Builds JWT assertion token requests.
packages/​uipath-platform/​src/​uipath/​platform/​external_applications/​_external_application_service.py Forwards assertions to Identity.
packages/​uipath-platform/​src/​uipath/​platform/​_uipath.py Accepts and validates SDK assertions.
packages/​uipath-platform/​pyproject.toml Bumps platform version.

Review effort: Balanced

UiPath(
base_url=os.environ["UIPATH_URL"],
client_id=os.environ["UIPATH_CLIENT_ID"],
client_assertion=os.environ["UIPATH_CLIENT_ASSERTION"],

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

fixed

Comment thread packages/uipath/samples/federated-credentials-ci/github-workflow.yml Outdated

async def authenticate(self) -> None:
if self._client_id and self._client_secret:
if self._client_id and (self._client_secret or self._client_assertion):

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

fixed

@radu-mocanu
radu-mocanu force-pushed the feat/federated-credentials branch 9 times, most recently from 877911b to 54876ef Compare October 20, 2026 16:05
@github-actions

Copy link
Copy Markdown

🚨 Heads up: uipath-integrations cross-tests are FAILING 🚨

Your changes may break one or more integrations in uipath-integrations-python:

  • uipath-openai-agents
  • uipath-google-adk
  • uipath-agent-framework
  • uipath-llamaindex
  • uipath-pydantic-ai

⚠️ These checks are NOT enforced by branch protection rules. Please review the failures before merging.

🔍 Inspect the failed run →

@radu-mocanu
radu-mocanu force-pushed the feat/federated-credentials branch from 54876ef to 2f58979 Compare October 20, 2026 16:10
@sonarqubecloud

Copy link
Copy Markdown

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test:uipath-integrations test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-runtime

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Option to use federated credentials/OIDC for uipath auth command

3 participants