Update
...
a notice
Description
Updates an existing outage notice.
Package Details
Interface
IOutageNoticeManagerINoticeManager
Syntax
await OutageNoticeManagerNoticeManager.Update(OutageNotice outageNoticeNotice notice);
Returns
Task<OutageNotice>
Task<Notice>
API
PUT
/api/v1/outage-notices
Parameters
Request Body
Code Block |
---|
{ |
...
Id: "123" |
...
"Services": [ |
...
11 ], "NoticeTypeCd": "InformationNotice", "EnglishHeaderText": "en updated header", |
...
"FrenchHeaderText": "fr updated header", |
...
"EnglishBodyText": "en updated body", |
...
"FrenchBodyText": "fr updated body", |
...
"StartDate": "2020-10- |
...
25T09:00:00.000Z" "EndDate": "2020-10-25T11:00:00.000Z" "DisplayDate": "2020-10- |
...
19T13:14:00.000Z" } |
Returns
200 OK - Outage Notice
Example
...
Code Block | ||
---|---|---|
| ||
var notice = new Notice { Id = 123, Services = new List<int> {2}, NoticeTypeCd = 4, EnglishHeaderText = "header text en", FrenchHeaderText = "header text fr", EnglishBodyText = "english body en", FrenchBodyText = "french body text", DisplayDate = DateTime.Now.AddDays(1) StartDate = DateTime.Now.AddDays(2) EndDate = DateTime.Now.AddDays(5) |
...
}; |
...
var notice = await _ |
...
noticeManager.Update( |
...
notice); |