Chats: Add API specs.
[akkoma] / lib / pleroma / web / api_spec / schemas / chat_message_create_request.ex
1 # Pleroma: A lightweight social networking server
2 # Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/>
3 # SPDX-License-Identifier: AGPL-3.0-only
4
5 defmodule Pleroma.Web.ApiSpec.Schemas.ChatMessageCreateRequest do
6 alias OpenApiSpex.Schema
7 require OpenApiSpex
8
9 OpenApiSpex.schema(%{
10 title: "ChatMessageCreateRequest",
11 description: "POST body for creating an chat message",
12 type: :object,
13 properties: %{
14 content: %Schema{type: :string, description: "The content of your message"}
15 },
16 example: %{
17 "content" => "Hey wanna buy feet pics?"
18 }
19 })
20 end