Skip to content

feat: add ArgumentEmail and ArgumentGroupName escalation recipient types#1521

Merged
dushyant-uipath merged 1 commit intomainfrom
feat/escalation-argument-assignee
Apr 15, 2026
Merged

feat: add ArgumentEmail and ArgumentGroupName escalation recipient types#1521
dushyant-uipath merged 1 commit intomainfrom
feat/escalation-argument-assignee

Conversation

@dushyant-uipath
Copy link
Copy Markdown
Contributor

@dushyant-uipath dushyant-uipath commented Mar 27, 2026

Summary

Adds two new recipient types to the escalation data model to support argument-driven assignees — where the assignee is resolved from a named input argument at runtime rather than being fixed at design time.

Type value Name Wire field (argumentName) Resolves to
7 ArgumentEmail argument_path: str Email recipient
8 ArgumentGroupName argument_path: str Group-name recipient

Both extend BaseEscalationRecipient and are included in the AgentEscalationRecipient discriminated union.

Note on field naming: the Python field is argument_path (supports dot-notation for nested fields e.g. user.email). The JSON alias on the wire remains argumentName — wire format is unchanged.

Changed files

File Change
src/uipath/agent/models/agent.py ARGUMENT_EMAIL = "ArgumentEmail", ARGUMENT_GROUP_NAME = "ArgumentGroupName" enum values; normalization map entries (int 7, 8); ArgumentEmailRecipient and ArgumentGroupNameRecipient classes; discriminated union updated

Failure modes & what was tested

What can fail

These model classes have no runtime logic — they are pure data containers. The only failure modes are deserialization:

  1. Unknown type value: a recipient with type not in the normalization map raises a Pydantic validation error. This is existing behavior, unchanged.
  2. Missing argumentName field: argument_path is required with no default — a recipient missing the field raises a Pydantic validation error at parse time, before any tool runs.

Both are fail-fast at agent startup, not at task creation time.

What was tested

  • Deserialized { "type": 7, "argumentName": "assigneeEmail" }ArgumentEmailRecipient(argument_path="assigneeEmail")
  • Deserialized { "type": 8, "argumentName": "assigneeGroup" }ArgumentGroupNameRecipient(argument_path="assigneeGroup")
  • Deserialized via integer type 7/8 (normalization map path) ✓
  • Deserialized via string "ArgumentEmail"/"ArgumentGroupName" (enum path) ✓
  • Existing recipient types 1–6 unaffected ✓
  • Full end-to-end HC run: agent with ArgumentEmail recipient created Action Center task with correct assignee ✓

Related

Test plan

  • Deserialize { "type": 7, "argumentName": "assigneeEmail" }ArgumentEmailRecipient(argument_path="assigneeEmail")
  • Same for type 8ArgumentGroupNameRecipient
  • Deserialize via integer type and string type for both
  • Verify existing recipient types 1–6 unaffected

Tested locally using HackedCoded

image

@github-actions github-actions bot added test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-llamaindex Triggers tests in the uipath-llamaindex-python repository labels Apr 6, 2026
@dianagrecu-uipath
Copy link
Copy Markdown
Contributor

Please also add tests for the deserialization of the new recipient types. test_agent.py only covers StandardRecipient and AssetRecipient.

@dushyant-uipath dushyant-uipath force-pushed the feat/escalation-argument-assignee branch 5 times, most recently from 639f866 to 2502656 Compare April 7, 2026 16:53
Comment thread packages/uipath/src/uipath/agent/models/agent.py Outdated
Copy link
Copy Markdown

@akashd-uipath akashd-uipath left a comment

Choose a reason for hiding this comment

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

LGTM

@dushyant-uipath dushyant-uipath force-pushed the feat/escalation-argument-assignee branch from 8c0fc7a to 3e2d531 Compare April 15, 2026 16:09
@dushyant-uipath dushyant-uipath merged commit 54f3293 into main Apr 15, 2026
133 checks passed
@dushyant-uipath dushyant-uipath deleted the feat/escalation-argument-assignee branch April 15, 2026 16:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-llamaindex Triggers tests in the uipath-llamaindex-python repository

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants