Skip to content

Commit 6c9453a

Browse files
authored
Merge pull request modelcontextprotocol#197 from modelcontextprotocol/jerome/feature/progress-update-message
Added optional message field to progress notifications
2 parents 6828f3e + 0553085 commit 6c9453a

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

docs/specification/draft/basic/utilities/progress.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ The receiver **MAY** then send progress notifications containing:
3636
- The original progress token
3737
- The current progress value so far
3838
- An optional "total" value
39+
- An optional "message" value
3940

4041
```json
4142
{
@@ -44,14 +45,16 @@ The receiver **MAY** then send progress notifications containing:
4445
"params": {
4546
"progressToken": "abc123",
4647
"progress": 50,
47-
"total": 100
48+
"total": 100,
49+
"message": "Reticulating splines..."
4850
}
4951
}
5052
```
5153

5254
- The `progress` value **MUST** increase with each notification, even if the total is
5355
unknown.
5456
- The `progress` and the `total` values **MAY** be floating point.
57+
- The `message` field **SHOULD** provide relevant human readable progress information.
5558

5659
## Behavior Requirements
5760

schema/draft/schema.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1284,6 +1284,10 @@
12841284
},
12851285
"params": {
12861286
"properties": {
1287+
"message": {
1288+
"description": "An optional message describing the current progress.",
1289+
"type": "string"
1290+
},
12871291
"progress": {
12881292
"description": "The progress thus far. This should increase every time progress is made, even if the total is unknown.",
12891293
"type": "number"

schema/draft/schema.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,10 @@ export interface ProgressNotification extends Notification {
289289
* @TJS-type number
290290
*/
291291
total?: number;
292+
/**
293+
* An optional message describing the current progress.
294+
*/
295+
message?: string;
292296
};
293297
}
294298

0 commit comments

Comments
 (0)