The STAR API has a `messages` endpoint that can be used to create, update, and delete banner messages that display globally to all users who log into STAR.
A message has the following properties:
`displayStart`: epoch timestamp in **milliseconds** for the local time that the banner should start being displayed. (You can use a tool like [this](https://www.epochconverter.com/) to generate the correct timestamp.)
`displayEnd`: epoch timestamp in **milliseconds** for the local time that the banner should stop being displayed. (You can use a tool like [this](https://www.epochconverter.com/) to generate the correct timestamp.)
`text`: string for the message that can include html elements. e.g. `<a>` tags and formatting tags like `<strong>`. *Make sure quotes are escaped appropriately within the text.*
`level`: corresponds to the color of the banner. Possible values: `info` = light blue, `warn` = yellow, `error` = red
`id`: the autogenerated id for the message
**Note:** Requests must be sent using basic authentication for the api user (`-u apiusername` will prompt you for a password. LastPass will have the user/pass) and the `On-Behalf-Of` header set to the NetID of the admin user sending the request.
### Example Requests using TEST URL & curl
**GET** (use this to get the ID of messages you want to update/delete)
- You can make sure the the messages are being receivdfed by the front end by navigating to [my.wisc.edu/star](https://my.wisc.edu/star)(or whichever environment you are testing) and inspecting the network traffic for `messages.json`.