Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Alejandrin08/Hackathon-SPEI/llms.txt

Use this file to discover all available pages before exploring further.

This endpoint requires a valid Authorization: Bearer <token> header. Requests without a valid token return 401 Unauthorized.

POST /api/analytics/events

Records a user interaction event. Used internally to measure the impact of accessibility features — tracking how often accessibility modes are used, where users encounter difficulty, and how nudging affects flow completion rates.
Events are only stored if the user has granted analytics consent. See Consent Management to check or update consent.
No personal financial data is stored in events. Only behavioral interaction metadata is recorded.

Request body

screen
string
required
Name of the screen where the event occurred, e.g., "send-money", "login", "transfer-confirm".
eventType
string
required
Type of interaction event. Examples:
  • "screen_view" — user navigated to a screen
  • "nudge_accepted" — user accepted a nudge prompt
  • "nudge_dismissed" — user dismissed a nudge prompt
  • "theme_changed" — user changed their accessibility theme
  • "transfer_completed" — user completed a SPEI transfer
details
string
Optional additional details about the event as a free-form string.

Response

Returns 202 Accepted. The event is queued for asynchronous processing.

Error responses

StatusDescription
400Validation error — screen and eventType are required.
401Invalid or missing bearer token.
curl --request POST \
  --url http://localhost:5000/api/analytics/events \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "screen": "send-money",
  "eventType": "screen_view"
}'