Skip to content

API Reference parrot.integrations.msteams.formdesigner_mixin

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot.integrations.msteams.formdesigner_mixin

View source

Teams FormDesigner mixin for serving Adaptive Card forms.

Alias PICKER_ACTION_KEY

Re-exported from parrot.integrations.msteams.formdesigner_cards.PICKER_ACTION_KEY.

Class TeamsFormDesignerMixin

Adds FormDesigner form serving to a Teams-exposed agent.

Parameter Type Default Description
*args Any ()
formdesigner_mode Literal['remote', 'local'] | None None
formdesigner_base_url str | None None
formdesigner_api_base_path str | None None
formdesigner_public_url str | None None
formdesigner_signing_secret str | None None
formdesigner_tenant str | None None
formdesigner_registry Any | None None
formdesigner_authorizer LocalFormAuthorizer | None None
formdesigner_session_store TeamsSessionStoreLike | None None
formdesigner_client Any | None None
**kwargs Any {}

Attributes:

Attribute Type Description
formdesigner_serving bool
formdesigner_mode Literal['remote', 'local']

Method TeamsFormDesignerMixin.apply_teams_config

Fill unset configuration from an MSTeamsAgentConfig instance.

apply_teams_config(config: Any) -> None

Parameter Type Default Description
config Any

Method TeamsFormDesignerMixin.bind_teams_identity

Receive the wrapper-owned Teams session store.

bind_teams_identity(store: TeamsSessionStoreLike) -> None

Parameter Type Default Description
store TeamsSessionStoreLike

Method TeamsFormDesignerMixin.teams_commands

Return commands that need the Bot Framework turn context.

teams_commands() -> dict[str, Callable[[TurnContext], Awaitable[None]]]

Returns: dict[str, Callable[[TurnContext], Awaitable[None]]]

Method TeamsFormDesignerMixin.handle_getform

Serve /getform [slug-or-uid], or show the picker without an argument.

handle_getform(turn_context: TurnContext) -> None

Parameter Type Default Description
turn_context TurnContext

Method TeamsFormDesignerMixin.handle_listforms

Send a tenant-scoped form picker or an empty-state card.

handle_listforms(turn_context: TurnContext) -> None

Parameter Type Default Description
turn_context TurnContext

Method TeamsFormDesignerMixin.serve_form

Resolve, render and send a form card without raising into Teams.

serve_form(turn_context: TurnContext, *, form_ref: str | uuid.UUID, turn: FormDesignerTurn | None = None) -> None

Parameter Type Default Description
turn_context TurnContext
form_ref str | uuid.UUID
turn FormDesignerTurn | None None

Method TeamsFormDesignerMixin.agent_tools

Return parent tools plus FormDesigner request-local tools.

agent_tools() -> list[Any]

Returns: list[Any]

Method TeamsFormDesignerMixin.formdesigner_turn

Bind a fresh request-local identity and pending-card queue.

formdesigner_turn(turn_context: TurnContext) -> AsyncIterator[None]

Parameter Type Default Description
turn_context TurnContext

Returns: AsyncIterator[None]

Method TeamsFormDesignerMixin.flush_formdesigner_cards

Drain distinct queued UIDs through fresh identity checks.

flush_formdesigner_cards(turn_context: TurnContext) -> None

Parameter Type Default Description
turn_context TurnContext

Method TeamsFormDesignerMixin.handle_formdesigner_card

Route picker, wizard, and signed terminal FormDesigner card submissions.

Every submission carrying PICKER_ACTION_KEY is answered here (True), so a stale or malformed control can never fall through to the wrapper's FEAT-551 service-token branch. The one deliberate False fallback is an envelope-only submission while this mixin is not enabled: the wrapper's standalone FEAT-551 branch then verifies and forwards it.

handle_formdesigner_card(turn_context: TurnContext, submitted_data: dict[str, Any]) -> bool

Parameter Type Default Description
turn_context TurnContext
submitted_data dict[str, Any]

Returns: bool

Method TeamsFormDesignerMixin.aclose

Close FormDesigner client and submission session resources.

aclose() -> None

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally