aboutsummaryrefslogtreecommitdiff
path: root/lib/pleroma/web/api_spec
diff options
context:
space:
mode:
Diffstat (limited to 'lib/pleroma/web/api_spec')
-rw-r--r--lib/pleroma/web/api_spec/operations/o_auth_operation.ex31
1 files changed, 12 insertions, 19 deletions
diff --git a/lib/pleroma/web/api_spec/operations/o_auth_operation.ex b/lib/pleroma/web/api_spec/operations/o_auth_operation.ex
index d507fddd5..cb049e5e8 100644
--- a/lib/pleroma/web/api_spec/operations/o_auth_operation.ex
+++ b/lib/pleroma/web/api_spec/operations/o_auth_operation.ex
@@ -77,8 +77,18 @@ defmodule Pleroma.Web.ApiSpec.OAuthOperation do
"Set equal to `authorization_code` if `code` is provided in order to gain user-level access. Set equal to `password` if `username` and `password` are provided. Otherwise, set equal to `client_credentials` to obtain app-level access only.",
required: true
),
- Operation.parameter(:username, :query, :string, "User's username, used with `grant_type=password`"),
- Operation.parameter(:password, :query, :string, "User's password, used with `grant_type=password`")
+ Operation.parameter(
+ :username,
+ :query,
+ :string,
+ "User's username, used with `grant_type=password`"
+ ),
+ Operation.parameter(
+ :password,
+ :query,
+ :string,
+ "User's password, used with `grant_type=password`"
+ )
],
responses: %{
200 =>
@@ -161,23 +171,6 @@ defmodule Pleroma.Web.ApiSpec.OAuthOperation do
}
end
- def create_authorization_operation do
- %Operation{
- tags: ["OAuth"],
- summary: "Create Authorization",
- operationId: "OAuthController.create_authorization",
- parameters: [],
- responses: %{
- 200 =>
- Operation.response("Success", "application/json", %Schema{
- type: :object,
- properties: %{status: %Schema{type: :string, example: "success"}}
- }),
- 400 => Operation.response("Error", "application/json", ApiError)
- }
- }
- end
-
def prepare_request_operation do
%Operation{
tags: ["OAuth"],