Plan Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Explicit, prompt-bound plan updates. This helper does not own a workflow or a stream.
public sealed class Plan
type Plan = class
Public NotInheritable Class Plan
- Inheritance
-
Plan
Remarks
Persist the IDs (and ReplyChain, when set) and supply a service-scoped API client when reconstructing for delayed work. Targeted Plan scenarios are not supported. Plan activities use ordinary create routing, and Completion() does not inherit targeting from the originating context. In a chat thread, CompleteAsync is posted to the reply chain like ctx.send. Typing updates (start, update, stop, error) are sent to the conversation, as ctx.send does for typing activities.
Constructors
| Name | Description |
|---|---|
| Plan(ApiClient, PlanOptions) |
Creates a helper from a saved prompt binding and an already service-scoped client. Sends nothing. |
| Plan(ApiClient, String, String) |
Creates a helper from saved IDs and an already service-scoped client. Sends nothing. |
Properties
| Name | Description |
|---|---|
| ConversationId |
The full conversation ID, including any thread suffix. |
| ReplyChain |
The reply chain (thread) of a chat that the completion is posted to, if any. |
| ReplyToId |
The originating prompt's activity ID. |
Methods
| Name | Description |
|---|---|
| CompleteAsync(MessageActivityInput, CancellationToken) |
Creates a final message, preserving caller content and existing completion metadata without mutating it. |
| CompleteAsync(String, CancellationToken) |
Completes the plan by creating a final message. |
| Completion() |
Builds a fresh completion message for this Plan's prompt without sending it. |
| CreateFromContext<TActivity>(Context<TActivity>) |
Creates a standalone helper bound to the incoming activity's own ID. |
| ErrorAsync(CancellationToken) |
Explicitly reports a plan error. |
| StartAsync(IEnumerable<PlanStep>, CancellationToken) |
Starts a plan with the supplied steps. |
| StopAsync(CancellationToken) |
Explicitly stops the plan. |
| UpdateAsync(IEnumerable<PlanStep>, CancellationToken) |
Adds or updates only the supplied steps. The application owns their versions. |
Events
| Name | Description |
|---|---|
| Sent |
Raised after a successful send; typing acknowledgements have no message response. |