unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Get all closed tickets with kolam
@ 2022-10-21 23:52 jgart
  2022-10-24 13:25 ` Arun Isaac
  0 siblings, 1 reply; 2+ messages in thread
From: jgart @ 2022-10-21 23:52 UTC (permalink / raw)
  To: Guix Devel; +Cc: Arun Isaac

Hi Arun,

Is there currently a way to get all closed tickets on mumi?

If so, is that endpoint currently deployed and accessible via mumi's graphql API?

I'm asking this on the guix-devel mailing list because I find others
might find this info useful.

all best,

jgart



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Get all closed tickets with kolam
  2022-10-21 23:52 Get all closed tickets with kolam jgart
@ 2022-10-24 13:25 ` Arun Isaac
  0 siblings, 0 replies; 2+ messages in thread
From: Arun Isaac @ 2022-10-24 13:25 UTC (permalink / raw)
  To: jgart, Guix Devel


Hi jgart,

> If so, is that endpoint currently deployed and accessible via mumi's
> graphql API?

Yes, the currently deployed mumi GraphQL endpoint is functioning
normally.

Sorry about the complete lack of documentation about how to use the
GraphQL endpoint. Here is some working code with a bunch of GraphQL
queries. I hope it helps. If it doesn't, do not hesitate to ping me. I
will write better documentation "at some point". ;-)

--8<---------------cut here---------------start------------->8---
(use-modules (ice-9 pretty-print)
             (kolam http))

(define %graphql-endpoint
  "https://issues.guix.gnu.org/graphql")

;; Shown below are different GraphQL queries. Comment out all except
;; one.

;; Find the number, title and date of all closed issues.
(define %graphql-document
  '(document
    (query (#(issues #:search "is:closed")
            number
            title
            date))))

;; Find the number, title, status and date of all issues submitted by
;; "arun".
(define %graphql-document
  '(document
    (query (#(issues #:search "is:open submitter:arun")
            number
            title
            open
            date))))

;; Find the title and submitter of issue 34948.
(define %graphql-document
  '(document (query (#(issue #:number 34948)
                     title
                     (submitter name address)))))

;; Find issues Arun Isaac participated in, the title of those issues
;; and who closed those issues.
(define %graphql-document
  '(document
    (query (#(person #:email "Arun Isaac <arunisaac@systemreboot.net>")
            name
            (participated_in_issues
             title
             (closer name address))))))

;; Run the GraphQL query, and print the results.
(pretty-print
 (graphql-http-get %graphql-endpoint %graphql-document))
--8<---------------cut here---------------end--------------->8---

> Is there currently a way to get all closed tickets on mumi?

Yes, there is. See the first example query in the code above. In fact,
in the #:search field of `#(issues #:search "is:closed")`, you can put
in any search query that you can put in at the
https://issues.guix.gnu.org web interface. The GraphQL endpoint and the
web interface share the same search code.

Currently, mumi provides three different GraphQL object types---issue,
person and email. Please see
https://git.elephly.net/gitweb.cgi?p=software/mumi.git;a=blob;f=mumi/web/graphql.scm;h=56110a088c044e44ff10262a596c1f8823f2ded4;hb=HEAD
for a complete list of fields provided by each object.

Also, only GraphQL query operations are supported at the
moment. Mutation and subscription operations are not.

> I'm asking this on the guix-devel mailing list because I find others
> might find this info useful.

Good thinking! :-)

Cheers,
Arun


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-10-24 17:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-21 23:52 Get all closed tickets with kolam jgart
2022-10-24 13:25 ` Arun Isaac

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).