@@ -17,6 +17,17 @@ public static class MutationRequestFactory
1717 /// <summary>
1818 /// Creates a request that should enter the pending lifecycle using type inference for the target state and mutation.
1919 /// </summary>
20+ /// <typeparam name="TState">The target state type.</typeparam>
21+ /// <typeparam name="TMutation">The mutation type.</typeparam>
22+ /// <param name="stateId">Stable identifier of the target state.</param>
23+ /// <param name="intent">Intent associated with the requested mutation.</param>
24+ /// <param name="context">Request context describing who submitted the mutation and why.</param>
25+ /// <param name="pendingReason">Lifecycle reason that keeps the request pending.</param>
26+ /// <param name="requirements">Optional policy requirements attached to the request.</param>
27+ /// <param name="expectedStateVersion">Optional expected state version captured at submission time.</param>
28+ /// <param name="expiresAt">Optional expiration time for the pending request.</param>
29+ /// <param name="metadata">Optional governance metadata carried by the request.</param>
30+ /// <returns>A pending governed mutation request.</returns>
2031 public static MutationRequest Pending < TState , TMutation > (
2132 string stateId ,
2233 MutationIntent intent ,
@@ -42,6 +53,17 @@ public static MutationRequest Pending<TState, TMutation>(
4253 /// <summary>
4354 /// Creates a request that should enter the pending lifecycle.
4455 /// </summary>
56+ /// <param name="stateId">Stable identifier of the target state.</param>
57+ /// <param name="stateType">Logical state type name.</param>
58+ /// <param name="mutationType">Mutation type name.</param>
59+ /// <param name="intent">Intent associated with the requested mutation.</param>
60+ /// <param name="context">Request context describing who submitted the mutation and why.</param>
61+ /// <param name="pendingReason">Lifecycle reason that keeps the request pending.</param>
62+ /// <param name="requirements">Optional policy requirements attached to the request.</param>
63+ /// <param name="expectedStateVersion">Optional expected state version captured at submission time.</param>
64+ /// <param name="expiresAt">Optional expiration time for the pending request.</param>
65+ /// <param name="metadata">Optional governance metadata carried by the request.</param>
66+ /// <returns>A pending governed mutation request.</returns>
4567 public static MutationRequest Pending (
4668 string stateId ,
4769 string stateType ,
@@ -64,7 +86,10 @@ public static MutationRequest Pending(
6486 Status = MutationRequestStatus . Pending ,
6587 PendingReason = pendingReason ,
6688 Requirements = requirements ?? [ ] ,
67- ExpectedStateVersion = expectedStateVersion ,
89+ Versioning = new MutationRequestVersioningDetails
90+ {
91+ ExpectedStateVersion = expectedStateVersion
92+ } ,
6893 ExpiresAt = expiresAt ,
6994 Metadata = metadata ?? new Dictionary < string , object > ( ) ,
7095 Decisions =
@@ -84,6 +109,16 @@ public static MutationRequest Pending(
84109 /// <summary>
85110 /// Creates a request that enters pending approval using type inference for the target state and mutation.
86111 /// </summary>
112+ /// <typeparam name="TState">The target state type.</typeparam>
113+ /// <typeparam name="TMutation">The mutation type.</typeparam>
114+ /// <param name="stateId">Stable identifier of the target state.</param>
115+ /// <param name="intent">Intent associated with the requested mutation.</param>
116+ /// <param name="context">Request context describing who submitted the mutation and why.</param>
117+ /// <param name="requirements">Policy requirements that will be translated into approval requirements.</param>
118+ /// <param name="expectedStateVersion">Optional expected state version captured at submission time.</param>
119+ /// <param name="expiresAt">Optional expiration time for the pending request.</param>
120+ /// <param name="metadata">Optional governance metadata carried by the request.</param>
121+ /// <returns>A governed mutation request pending approval.</returns>
87122 public static MutationRequest PendingApproval < TState , TMutation > (
88123 string stateId ,
89124 MutationIntent intent ,
@@ -107,6 +142,16 @@ public static MutationRequest PendingApproval<TState, TMutation>(
107142 /// <summary>
108143 /// Creates a request that enters pending approval with concrete request-level approval requirements.
109144 /// </summary>
145+ /// <param name="stateId">Stable identifier of the target state.</param>
146+ /// <param name="stateType">Logical state type name.</param>
147+ /// <param name="mutationType">Mutation type name.</param>
148+ /// <param name="intent">Intent associated with the requested mutation.</param>
149+ /// <param name="context">Request context describing who submitted the mutation and why.</param>
150+ /// <param name="requirements">Policy requirements that will be translated into approval requirements.</param>
151+ /// <param name="expectedStateVersion">Optional expected state version captured at submission time.</param>
152+ /// <param name="expiresAt">Optional expiration time for the pending request.</param>
153+ /// <param name="metadata">Optional governance metadata carried by the request.</param>
154+ /// <returns>A governed mutation request pending approval.</returns>
110155 public static MutationRequest PendingApproval (
111156 string stateId ,
112157 string stateType ,
@@ -135,7 +180,10 @@ public static MutationRequest PendingApproval(
135180 PendingReason = PendingMutationReason . Approval ,
136181 Requirements = requirements ,
137182 ApprovalRequirements = approvalRequirements ,
138- ExpectedStateVersion = expectedStateVersion ,
183+ Versioning = new MutationRequestVersioningDetails
184+ {
185+ ExpectedStateVersion = expectedStateVersion
186+ } ,
139187 ExpiresAt = expiresAt ,
140188 Metadata = metadata ?? new Dictionary < string , object > ( ) ,
141189 Decisions =
@@ -163,6 +211,14 @@ public static MutationRequest PendingApproval(
163211 /// <summary>
164212 /// Creates a request that is immediately approved for execution using type inference for the target state and mutation.
165213 /// </summary>
214+ /// <typeparam name="TState">The target state type.</typeparam>
215+ /// <typeparam name="TMutation">The mutation type.</typeparam>
216+ /// <param name="stateId">Stable identifier of the target state.</param>
217+ /// <param name="intent">Intent associated with the requested mutation.</param>
218+ /// <param name="context">Request context describing who submitted the mutation and why.</param>
219+ /// <param name="expectedStateVersion">Optional expected state version captured at submission time.</param>
220+ /// <param name="metadata">Optional governance metadata carried by the request.</param>
221+ /// <returns>An approved governed mutation request.</returns>
166222 public static MutationRequest Approved < TState , TMutation > (
167223 string stateId ,
168224 MutationIntent intent ,
@@ -182,6 +238,14 @@ public static MutationRequest Approved<TState, TMutation>(
182238 /// <summary>
183239 /// Creates a request that is immediately approved for execution.
184240 /// </summary>
241+ /// <param name="stateId">Stable identifier of the target state.</param>
242+ /// <param name="stateType">Logical state type name.</param>
243+ /// <param name="mutationType">Mutation type name.</param>
244+ /// <param name="intent">Intent associated with the requested mutation.</param>
245+ /// <param name="context">Request context describing who submitted the mutation and why.</param>
246+ /// <param name="expectedStateVersion">Optional expected state version captured at submission time.</param>
247+ /// <param name="metadata">Optional governance metadata carried by the request.</param>
248+ /// <returns>An approved governed mutation request.</returns>
185249 public static MutationRequest Approved (
186250 string stateId ,
187251 string stateType ,
@@ -199,7 +263,10 @@ public static MutationRequest Approved(
199263 Intent = intent ,
200264 Context = context ,
201265 Status = MutationRequestStatus . Approved ,
202- ExpectedStateVersion = expectedStateVersion ,
266+ Versioning = new MutationRequestVersioningDetails
267+ {
268+ ExpectedStateVersion = expectedStateVersion
269+ } ,
203270 Metadata = metadata ?? new Dictionary < string , object > ( ) ,
204271 Decisions =
205272 [
0 commit comments