diff options
author | Yoni Rabkin <yonirabkin@member.fsf.org> | 2014-05-09 12:43:27 -0400 |
---|---|---|
committer | Yoni Rabkin <yonirabkin@member.fsf.org> | 2014-05-09 12:43:27 -0400 |
commit | bd60dc3ed4a12ee6e98702863040cd2fc2e4d903 (patch) | |
tree | 820d4bfd3b69d9360e79b2c5ef9898c67c535b8a | |
parent | e1c818c765f68b9f176d806a50d39d5a6b1b901b (diff) |
* rt-liberation-rest.el: Document the show query issue.
All of the relevant information is in a comment in
rt-liberation-rest.el.
-rw-r--r-- | rt-liberation-rest.el | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/rt-liberation-rest.el b/rt-liberation-rest.el index 5b3d0cb..2fbe8a6 100644 --- a/rt-liberation-rest.el +++ b/rt-liberation-rest.el @@ -63,6 +63,18 @@ "format=i" "&" "orderby=+Created"))) +(defun rt-liber-rest-show-string (scheme url ticket-id-list username password query) + "" + (let ((user (url-encode-url username)) + (pass (url-encode-url password))) + (concat scheme + "://" + url + "/REST/1.0/ticket/" ticket-id-list + "/show" "?" + "user=" user "&" + "pass=" pass "&"))) + (defun rt-liber-rest-call (url) "" (let ((url-request-method "POST")) @@ -88,6 +100,22 @@ rt-liber-rest-username rt-liber-rest-password query-string))) + ;; The "show" API call doesn't support getting multiple + ;; tickets at once. This is a problem. I've emailed the + ;; rt-users mailing list asking how to to this. + ;; + ;; A much more insidious method to figure this out is to + ;; wireshark the CLI connection as it asks for multiple + ;; tickets and see if we can capture the query the CLI + ;; uses. This would necessitate a non-HTTPS connection, such + ;; that the one to the demo servers. + ((string= op "show") + (rt-liber-rest-show-string rt-liber-rest-scheme + rt-liber-rest-url + query-string + rt-liber-rest-username + rt-liber-rest-password + query-string)) (t (error "unknown op [%s]" op)))) (defun rt-liber-rest-parse-http-header () |