1 # Pleroma: A lightweight social networking server
2 # Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/>
3 # SPDX-License-Identifier: AGPL-3.0-only
5 defmodule Pleroma.Web.ApiSpec.CustomEmojiOperation do
6 alias OpenApiSpex.Operation
7 alias Pleroma.Web.ApiSpec.Schemas.CustomEmojisResponse
9 def open_api_operation(action) do
10 operation = String.to_existing_atom("#{action}_operation")
11 apply(__MODULE__, operation, [])
14 def index_operation do
16 tags: ["custom_emojis"],
17 summary: "List custom custom emojis",
18 description: "Returns custom emojis that are available on the server.",
19 operationId: "CustomEmojiController.index",
21 200 => Operation.response("Custom Emojis", "application/json", CustomEmojisResponse)