You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Add UnixMillisecondsDateTimeOffsetConverter for unix-millis-as-JSON-number
timestamps
- Convert long Timestamp fields on hook *Input* types and PingResponse to
DateTimeOffset via the new converter
- Convert SessionLifecycleEventMetadata.StartTime/ModifiedTime from ISO 8601
strings to DateTimeOffset
- Convert SessionMetadata.StartTime/ModifiedTime from DateTime to DateTimeOffset
- Add PermissionRequestResult.Feedback property (parity with the RPC
PermissionDecisionReject type's feedback field); forward to the wire only
on reject decisions
- Tidy XML doc on PermissionRequestResult.Kind to reference the well-known
PermissionRequestResultKind static members directly
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copy file name to clipboardExpand all lines: dotnet/src/Types.cs
+32-18Lines changed: 32 additions & 18 deletions
Original file line number
Diff line number
Diff line change
@@ -689,13 +689,13 @@ public override void Write(Utf8JsonWriter writer, PermissionRequestResultKind va
689
689
publicsealedclassPermissionRequestResult
690
690
{
691
691
/// <summary>
692
-
/// Permission decision kind. Use the static members of <see cref="PermissionRequestResultKind"/>
693
-
/// to construct values. Valid kinds are:
692
+
/// Permission decision kind. Construct values with the static members on
693
+
/// <see cref="PermissionRequestResultKind"/>:
694
694
/// <list type="bullet">
695
-
/// <item><description><c>"approve-once"</c> (<see cref="PermissionRequestResultKind.Approved"/>) — allow this single request.</description></item>
696
-
/// <item><description><c>"reject"</c> (<see cref="PermissionRequestResultKind.Rejected"/>) — deny the request.</description></item>
697
-
/// <item><description><c>"user-not-available"</c> (<see cref="PermissionRequestResultKind.UserNotAvailable"/>) — deny because no user is available to confirm.</description></item>
698
-
/// <item><description><c>"no-result"</c> (<see cref="PermissionRequestResultKind.NoResult"/>) — leave the pending request unanswered (protocol v1 only; rejected by protocol v2 servers).</description></item>
695
+
/// <item><description><see cref="PermissionRequestResultKind.Approved"/> — allow this single request.</description></item>
696
+
/// <item><description><see cref="PermissionRequestResultKind.Rejected"/> — deny the request.</description></item>
697
+
/// <item><description><see cref="PermissionRequestResultKind.UserNotAvailable"/> — deny because no user is available to confirm.</description></item>
698
+
/// <item><description><see cref="PermissionRequestResultKind.NoResult"/> — leave the pending request unanswered (protocol v1 only; rejected by protocol v2 servers).</description></item>
699
699
/// </list>
700
700
/// </summary>
701
701
[JsonPropertyName("kind")]
@@ -706,6 +706,14 @@ public sealed class PermissionRequestResult
706
706
/// </summary>
707
707
[JsonPropertyName("rules")]
708
708
publicIList<object>?Rules{get;set;}
709
+
710
+
/// <summary>
711
+
/// Optional human-readable feedback to forward to the LLM along with the
712
+
/// decision. Mirrors the <c>feedback</c> field on the RPC-level
713
+
/// <see cref="Rpc.PermissionDecision"/> type.
714
+
/// </summary>
715
+
[JsonPropertyName("feedback")]
716
+
publicstring?Feedback{get;set;}
709
717
}
710
718
711
719
/// <summary>
@@ -1167,7 +1175,8 @@ public sealed class PreToolUseHookInput
1167
1175
/// Unix timestamp in milliseconds when the tool use was initiated.
0 commit comments