aboutsummaryrefslogtreecommitdiff
path: root/lisp/mastodon-auth.el
diff options
context:
space:
mode:
authormarty hiatt <martianhiatus [a t] riseup [d o t] net>2022-11-14 19:09:27 +0100
committermarty hiatt <martianhiatus [a t] riseup [d o t] net>2022-11-15 10:41:19 +0100
commit370f0a8367e381345950e145554481d988a1709c (patch)
treee674d7d9d6751aef727a28676b998e12659e54dd /lisp/mastodon-auth.el
parent7593590d5c7a1ea9824424cc46d0cad4130eb9b2 (diff)
make a start on lists
Diffstat (limited to 'lisp/mastodon-auth.el')
-rw-r--r--lisp/mastodon-auth.el8
1 files changed, 8 insertions, 0 deletions
diff --git a/lisp/mastodon-auth.el b/lisp/mastodon-auth.el
index 02799bf..263ece2 100644
--- a/lisp/mastodon-auth.el
+++ b/lisp/mastodon-auth.el
@@ -222,6 +222,14 @@ Handle any errors from the server."
(mastodon-http--api
"accounts/verify_credentials"))))
+(defun mastodon-auth--get-account-id ()
+ "Request user credentials and return an account name."
+ (alist-get
+ 'id
+ (mastodon-http--get-json
+ (mastodon-http--api
+ "accounts/verify_credentials"))))
+
(defun mastodon-auth--user-acct ()
"Return a mastodon user acct name."
(or (cdr (assoc mastodon-instance-url mastodon-auth--acct-alist))