From 53035fa4aa5f3a471d4093e70269ae992b12feef Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Sat, 7 May 2022 00:28:08 +0200 Subject: Try querying issues from Jira Set up a Common Lisp project skeleton and make a request to the Atlassian API to get a filtered list of issues that the current user isn't watching. --- src/main.lisp | 17 +++++++++++++++++ src/package.lisp | 4 ++++ 2 files changed, 21 insertions(+) create mode 100644 src/main.lisp create mode 100644 src/package.lisp (limited to 'src') diff --git a/src/main.lisp b/src/main.lisp new file mode 100644 index 0000000..4c1c498 --- /dev/null +++ b/src/main.lisp @@ -0,0 +1,17 @@ +(in-package :wajir) + +(defun main () + ;; Query page of issues + ;; [Check not in database?] <- no + ;; Start watching issue + ;; Send email to ^maildir^program^ containing message with issue metadata + ;; Continue to next page + + (dex:post "https://example.atlassian.net/rest/api/3/search" + :content + "{ + \"jql\": \"project = \\\"FAKE\\\" AND watcher != currentUser() AND key > \\\"FAKE-100\\\" ORDER BY created DESC\", + \"fields\": [\"id\", \"key\", \"self\"] + }" + :headers '((:content-type . "application/json") + (:authorization . "Basic TOKEN")))) diff --git a/src/package.lisp b/src/package.lisp new file mode 100644 index 0000000..a340f86 --- /dev/null +++ b/src/package.lisp @@ -0,0 +1,4 @@ +(defpackage :wajir + (:use :cl) + + (:export :main)) -- cgit v1.2.3