8000 feat: support ui action result types by liady · Pull Request #6 · idosal/mcp-ui · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat: support ui action result types #6

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 3, 2025

Conversation

liady
Copy link
Collaborator
@liady liady commented May 28, 2025

This WIP PR extends the possible results returned from a UI action, to these types: 'tool' | 'prompt' | 'link' | 'intent' | 'notification'

Each type has its own payload:

type UiActionType = 'tool' | 'prompt' | 'link' | 'intent' | 'notification';

type UiActionResultToolCall = {
  type: 'tool';
  payload: {
    toolName: string;
    params: Record<string, unknown>;
  };
};

type UiActionResultPrompt = {
  type: 'prompt';
  payload: {
    prompt: string;
  };
};

type UiActionResultLink = {
  type: 'link';
  payload: {
    url: string;
  };
};

type UiActionResultIntent = {
  type: 'intent';
  payload: {
    intent: string;
    params: Record<string, unknown>;
  };
};

type UiActionResultNotification = {
  type: 'notification';
  payload: {
    message: string;
  };
};


type UiActionResult =
  | UiActionResultToolCall
  | UiActionResultPrompt
  | UiActionResultLink
  | UiActionResultIntent
  | UiActionResultNotification;

@liady liady force-pushed the feat/support-action-result-types branch from 5b811e5 to 901a2e9 Compare May 28, 2025 05:40
@liady liady changed the title feat!: support ui action result types feat: support ui action result types May 31, 2025
@liady liady marked this pull request as ready for review May 31, 2025 03:37
@liady liady requested a review from idosal May 31, 2025 03:37
@liady liady merged commit 899d152 into idosal:main Jun 3, 2025
2 checks passed
github-actions bot pushed a commit that referenced this pull request Jun 3, 2025
# [2.2.0](v2.1.0...v2.2.0) (2025-06-03)

### Features

* support ui action result types ([#6](#6)) ([899d152](899d152))
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.

1 participant
0