Skip to main content

1. API Purpose

The Noticeboard API serves as the school’s official broadcast channel. It provides a permanent and searchable record of formal announcements, replacing physical notice boards.

2. Endpoint Definition


3. Authentication Flow

Standard JWT validation. All parents and staff within the same school (skole_id) see the same global noticeboard feed.

4. Request Structure

GET /parent-app/noticeboard

Headers:

GET /teachers-app/noticeboard

Query Parameters:

GET /web-app/noticeboard

Query Parameters:

POST /web-app/noticeboard

Request Body:

PUT /web-app/noticeboard/:id

Request Body:

DELETE /web-app/noticeboard/:id

URL Parameters:

5. Response Structure

Success: Parent Notice Feed (200 OK)

Route: GET /parent-app/noticeboard

Success: Teacher Notice Feed (200 OK)

Route: GET /teachers-app/noticeboard

Success: Admin Notice List (200 OK)

Route: GET /web-app/noticeboard

Success: Notice Created (201 Created)

Route: POST /web-app/noticeboard

Success: Notice Updated (200 OK)

Route: PUT /web-app/noticeboard/:id

Success: Notice Deleted (200 OK)

Route: DELETE /web-app/noticeboard/:id

6. Error Responses


7. Security Considerations

  • Integrity: Only users with noticeboard.create staff permissions can broadcast notices.
  • Soft Delete: notice_deleted = 1 removes the notice from public view while preserving audit logs.

8. Token Usage


9. Token Refresh

N/A.

10. Logout / Session Invalidation

N/A.

11. Usage Example (cURL)


12. Notes / Special Behaviors

  • Typing: Notice types determine the color-coding in the mobile app (e.g., Blue for exam, Orange for fee).
  • Persistence: Unlike Activities, notices are generally long-lived and pinned to the top of the feed if marked as high importance.