Skip to content

Conversation

radugheo
Copy link
Collaborator

@radugheo radugheo commented Sep 5, 2025

OAuth External Apps Agent Sample

Overview

This sample shows how to build an agent that connects to remote MCP servers with automatic OAuth token management.
The agent handles token expiration transparently and re-authenticates as needed.

Implementation

The agent uses a two-node graph architecture where fetch_new_access_token obtains OAuth tokens via the UiPath SDK
client credentials flow, and connect_to_mcp connects to the MCP server to execute tasks using Claude 3.5 Sonnet.
Conditional edges handle token validation at startup and automatically retry authentication when encountering 401
errors.

@radugheo radugheo self-assigned this Sep 5, 2025
@radugheo radugheo changed the title feat(samples): create oauth sample agent [🚧] feat(samples): create oauth sample agent Oct 7, 2025
@radugheo radugheo force-pushed the feat/create-oauth-sample-agent branch 7 times, most recently from 0914a38 to a7b3788 Compare October 20, 2025 09:57
@radugheo radugheo changed the title [🚧] feat(samples): create oauth sample agent feat(samples): create oauth sample agent Oct 20, 2025
@radugheo radugheo force-pushed the feat/create-oauth-sample-agent branch from a7b3788 to 4ec8dd3 Compare October 20, 2025 15:24
@radugheo radugheo requested a review from radu-mocanu October 20, 2025 15:24
@radugheo radugheo force-pushed the feat/create-oauth-sample-agent branch from 4ec8dd3 to bf4cf93 Compare October 20, 2025 15:27
@radugheo radugheo force-pushed the feat/create-oauth-sample-agent branch from bf4cf93 to e5d88d1 Compare October 20, 2025 15:42
@radugheo radugheo merged commit 38324ad into main Oct 20, 2025
36 checks passed
@radugheo radugheo deleted the feat/create-oauth-sample-agent branch October 20, 2025 15:46
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