Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F84165145
app_controller.ex
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Size
728 B
Referenced Files
None
Subscribers
None
app_controller.ex
View Options
# Pleroma: A lightweight social networking server
# Copyright © 2017-2022 Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
defmodule
Pleroma.Web.PleromaAPI.AppController
do
use
Pleroma.Web
,
:controller
alias
Pleroma.Web.OAuth.App
alias
Pleroma.Web.Plugs.OAuthScopesPlug
plug
(
OAuthScopesPlug
,
%{
scopes
:
[
"follow"
,
"read"
]}
when
action
in
[
:index
])
plug
(
Pleroma.Web.ApiSpec.CastAndValidate
)
defdelegate
open_api_operation
(
action
),
to
:
Pleroma.Web.ApiSpec.PleromaAppOperation
@doc
"GET /api/v1/pleroma/apps"
def
index
(%{
assigns
:
%{
user
:
user
}}
=
conn
,
_params
)
do
with
apps
<-
App
.
get_user_apps
(
user
)
do
render
(
conn
,
"index.json"
,
%{
apps
:
apps
})
end
end
end
File Metadata
Details
Attached
Mime Type
text/x-ruby
Expires
Thu, Jun 4, 6:35 PM (1 d, 19 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1184105
Default Alt Text
app_controller.ex (728 B)
Attached To
Mode
rPUBE pleroma-upstream
Attached
Detach File
Event Timeline
Log In to Comment