Skip to content

Instantly share code, notes, and snippets.

@doapp-grady
Last active December 21, 2015 15:43
Show Gist options
  • Save doapp-grady/806f226d0a97b3cf62d5 to your computer and use it in GitHub Desktop.
Save doapp-grady/806f226d0a97b3cf62d5 to your computer and use it in GitHub Desktop.
{
"location": {
"id":"wx-2396395",
"name":"Rochester, MN",
"lat":44.015076,
"lng":-92.47752,
"countyFips":["27109"]
},
"timestamp":{
"offset":"2015-12-21T09:27:12.000-0600",
"utc":"2015-12-21T15:27:12.000Z",
"epoch":1450711632000,
"timezoneOffset":-21600
},
"alerts": [
{
"title": "Winter Weather Advisory",
"severity": "severe",
"description": "Winter Weather Advisory remains in effect until midnight CST Tuesday night, <br \/>\n<br \/>\nA Winter Weather Advisory remains in effect until midnight CST Tuesday night.<br \/>\n<br \/>\n* Several additional rounds of wintry precipitation will occur from late afternoon through tonight. A mixture of sleet and snow is expected, perhaps mixed with rain at times.<br \/>\n<br \/>\n* The heaviest snowfall rates will occur between 6 PM and midnight this evening, with up to 1 inch per hour.<br \/>\n<br \/>\n* Additional snow and sleet accumulation of 2 to 4 inches is expected.<br \/>\n<br \/>\n* Look for reduced visibility at times.<br \/>\n<br \/>\n* Plan on slippery Road conditions overnight and into Tuesday morning, including during the morning commute.<br \/>\n<br \/>\nPrecautionary\/preparedness actions, <br \/>\n<br \/>\nA Winter Weather Advisory means that periods of snow, sleet, or freezing rain will cause travel difficulties. Be prepared for slippery roads and limited visibilities, and use caution while driving. The latest Road conditions for the state you are calling from can be obtained by calling 5 1 1.<br \/>\n<br \/>\n <p><\/p><br \/>\n",
"expires": {
"offset":"2015-12-21T15:27:16.977+0000",
"utc":"2015-12-21T15:27:16.977Z",
"epoch":1450711636000,
"timezoneOffset":-21600
}
},
{
"title": "Special Statement",
"severity": "moderate",
"description": "Wintry travel expected late tonight into Tuesday morning, <br \/> <br \/> Low pressure will move into southern Minnesota tonight and northwest Wisconsin on Tuesday. As this low pressure system approaches, widespread precipitation in the form of rain, sleet, and snow is expected to move into central and north-central Wisconsin tonight. Some minor accumulations are possible by daybreak, up to an inch.<br \/> <br \/> The wintry mix is expected to change over to snow early Tuesday morning. The snow is then anticipated to continue through about midday Tuesday. Total accumulations could reach into the 2-3 inch range over north-central Wisconsin by the time the snow exits. Lesser amounts are expected further south over Lincoln and Marathon counties, perhaps up to an inch.<br \/> <br \/> The wintry precipitation will likely cause Road conditions to deteriorate late tonight into Tuesday morning. A coating of snow on the roads is possible for the morning commute. Use caution and allow extra time to reach your destination if using the roadways late tonight and Tuesday morning.<br \/> <br \/> Mpc <p><\/p><br \/> 234 PM CST Mon Nov 30 2015 , Wintry travel expected late tonight into Tuesday morning, <br \/> <br \/> Low pressure will move into southern Minnesota tonight and northwest Wisconsin on Tuesday. As this low pressure system approaches, widespread precipitation in the form of rain, sleet, and snow is expected to move into central and north-central Wisconsin tonight. Some minor accumulations are possible by daybreak, up to an inch.<br \/> <br \/> The wintry mix is expected to change over to snow early Tuesday morning. The snow is then anticipated to continue through about midday Tuesday. Total accumulations could reach into the 2-3 inch range over north-central Wisconsin by the time the snow exits. Lesser amounts are expected further south over Lincoln and Marathon counties, perhaps up to an inch.<br \/> <br \/> The wintry precipitation will likely cause Road conditions to deteriorate late tonight into Tuesday morning. A coating of snow on the roads is possible for the morning commute. Use caution and allow extra time to reach your destination if using the roadways late tonight and Tuesday morning.<br \/> <br \/> Mpc <p><\/p><br \/> 234 PM CST Mon Nov 30 2015 , Wintry travel expected late tonight into Tuesday morning, <br \/> <br \/> Low pressure will move into southern Minnesota tonight and northwest Wisconsin on Tuesday. As this low pressure system approaches, widespread precipitation in the form of rain, sleet, and snow is expected to move into central and north-central Wisconsin tonight. Some minor accumulations are possible by daybreak, up to an inch.<br \/> <br \/> The wintry mix is expected to change over to snow early Tuesday morning. The snow is then anticipated to continue through about midday Tuesday. Total accumulations could reach into the 2-3 inch range over north-central Wisconsin by the time the snow exits. Lesser amounts are expected further south over Lincoln and Marathon counties, perhaps up to an inch.<br \/> <br \/> The wintry precipitation will likely cause Road conditions to deteriorate late tonight into Tuesday morning. A coating of snow on the roads is possible for the morning commute. Use caution and allow extra time to reach your destination if using the roadways late tonight and Tuesday morning.<br \/> <br \/> Mpc <p><\/p><br \/> ",
"expires": {
"offset":"2015-12-21T15:27:16.977+0000",
"utc":"2015-12-21T15:27:16.977Z",
"epoch":1450711636000,
"timezoneOffset":-21600
}
}
]
}
@doapp-ryanp
Copy link

In general I would like to say as close as we can to the wx push feed spec for consistency. You can see a full example wx push feed here.

  • Why does the location object need to be in this response - don't you already know this info?
  • What does timestamp represent? I'm guessing just want to know when this file was created? If so would like to stay consistent with the wx push feed
  • what is significance? Can we just be consistent and use the severity attribute that already exists in the wx push feed? See full example here
  • Does expires need to be that complex object? Again to stay consistent can we use the and endDisplay (I can rename to expires) attributes that already exists in the wx push feed? I would also propose we add the effective attribute. See full example here. The TZ offset is already conveyed in the ISO 8601 date/time stamp
  • description: I'd prefer to put in the raw alert from NWS vs putting any html/styling info in here. Since this feed is more for raw alerts, I'd rather give the consumer of the data determine how they would like to display it on the glass. From what I remember seeing in the design, you wont even use this string correct? you'll just be using the title correct?

@doapp-ryanp
Copy link

I am also going to change location to channel because I will be including the channel object

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment