Logo
Explore Help
Sign In
darkhelm/notifications-api
1
0
Fork 0
You've already forked notifications-api
mirror of https://github.com/GSA/notifications-api.git synced 2026-08-23 15:56:45 -04:00
Code Issues Packages Projects Releases Wiki Activity
Files
cache-performance
notifications-api/app/letters/letter_schemas.py

18 lines
456 B
Python
Raw Permalink Normal View History

Add a task to process returned letter lists Adds an API endpoint `/letters/returned` that accepts a list of notification references and creates a task to update their status. Adds a new task that uses the list of references to update the status of notifications to 'returned-letter'. The update is currently done using a single query and logs the number of changed records (including notification history records). This could potentially be done within the `/letters/returned` endpoint, but creating a job right away allows us to extend this more easily in the future (e.g. logging missing notifications or adding callbacks). The job is using the database tasks queue.
2018-08-31 16:49:06 +01:00
letter_references = {
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "list of letter notification references",
"type": "object",
"title": "references",
"properties": {
"references": {
"type": "array",
"items": {
"type": "string",
"pattern": "^[0-9A-Z]{16}$"
},
"minItems": 1
},
},
"required": ["references"]
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.25.0 Page: 292ms Template: 23ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API