diff --git a/docs/tech_specs/pa_message_api.md b/docs/tech_specs/pa_message_api.md new file mode 100644 index 00000000..e6d0e549 --- /dev/null +++ b/docs/tech_specs/pa_message_api.md @@ -0,0 +1,54 @@ +# List Active Messages + +Lists all PA messages that are currently eligible to play. + +**URL** : `/api/active_pa_messages` + +**Method** : `GET` + +**Parameters**: None + +**API key required** : YES + +## Success Responses + +**Code** : `200 OK` + +**Response**: + +```json +[ + { + "id": 1, + "sign_ids": ["sign_1", "sign2"], + "priority": 0, + "interval_in_minutes": 4, + "visual_text": "This message will be played.", + "audio_text": "This message will be played." + }, + { + "id": 2, + "sign_ids": ["sign_3", "sign4"], + "priority": 0, + "interval_in_minutes": 3, + "visual_text": "This message will be played.", + "audio_text": "This message will be played." + }, + { + "id": 3, + "sign_ids": ["sign_1"], + "priority": 0, + "interval_in_minutes": 2, + "visual_text": "This message will be played.", + "audio_text": "This message will be played." + } +] +``` + +## Failure Responses + +**Code** : `403 Forbidden` + +**Response**: + +`Invalid API key`