To effectively use a service's API, I'm leveraging
json-read to turn the JSON response into an understandable data structure:
(let ((json-object-type 'alist) (json-array-type 'list) (json-key-type 'symbol) (json-false nil) (json-null nil)) (json-read))
This works great, but gives me a bunch of garbage that I don't care about.
I want a function
keep-structure that works through this alist and filters out all of the junk:
(keep-structure '((owner login) name) '((owner (login . "octocat") (avatar . "blah")) (name . "Hello-World") (some-url . "https://some-domain") (stars . 42))) ;; => ((owner (login . "octocat")) (name . "Hello-World"))