excludes announcements with show_until date in the past
GET /api/v1/announcements/
Request
Headers
Route
GET /api/v1/announcements/
Query Parameters
{}:
cURL
curl "http://localhost:3000/api/v1/announcements/" -X GET \
-H "Accept: application/json" \
-H "X-Api-Token: VTTxnFk5_FWkPSCW4W9yDkA_gfAbW7ijmw" \
-H "X-Api-Email: user-387@example.com" \
-H "Content-Type: application/json" \
-H "Host: school.worksonmy.computer"
Response
Headers
Status
200 OK
Body
{
"announcements": [
{
"id": 19,
"title": "MyText",
"body": "MyText",
"button_text": "MyText",
"released_at": "2019-10-31T22:10:43Z",
"show_until": "2019-11-30T23:10:43Z",
"created_at": "2019-10-31T22:10:43Z",
"updated_at": "2019-10-31T22:10:43Z"
}
]
}