@@ -51,19 +51,24 @@ One or more system messages can be shown between the header and the breadcrumb b
51
51
things related to the instance, e.g. a planned update of Jenkins, a downtime due to hardware replacement or an ongoing
52
52
incident. You can include html (sanitized with owasp) in the message to apply some simple styling or include a link
53
53
with more details.<br />
54
- System messages can have an expiration time to automatically remove them. They can be dismissed on a per-user basis.
54
+ System messages can have an expiration time to automatically remove them. They can be dismissed on a per-user basis.
55
55
56
- ### Create System Message via REST api
56
+ ![ System Message] ( /docs/pics/system-message.png ) <br />
57
+
58
+ ### Create/Delete System Messages via REST api
57
59
You can create system messages by doing a post request to ` <jenkins_url>/customizable-header/addSystemMessage ` .
60
+ To be able to later delete a system message, pass an id parameter in the call. In case you omit the id, an id will be generated and returned in the response body.
61
+
58
62
Parameters:
59
63
60
- | Parameter| required| description |
61
- | ---------| --------| --------------------------------------------------------------|
62
- | message | true | The message, can contain html |
63
- | level | true | Message level, one of ` info ` , ` success ` , ` warning ` , ` danger ` |
64
- | expireDate | false | Expiration date for the message, format: ` yyyy-M-d H:m ` |
64
+ | Parameter | required| description |
65
+ | ------------| --------| --------------------------------------------------------------|
66
+ | message | true | The message, can contain html |
67
+ | level | true | Message level, one of ` info ` , ` success ` , ` warning ` , ` danger ` |
68
+ | expireDate | false | Expiration date for the message, format: ` yyyy-M-d H:m ` |
69
+ | uid | false | An optional unique id |
65
70
66
- ![ System Message ] ( /docs/pics/ system- message.png ) < br />
71
+ To delete a system message do a post request to ` <jenkins_url>/customizable-header/deleteSystemMessage?id=<id> `
67
72
68
73
## The weather symbols
69
74
To demonstrate the custom weather symbols download the svgs from ` docs/svgs ` to ` userContent/svgs ` in your
0 commit comments