logo

pleroma

My custom branche(s) on git.pleroma.social/pleroma/pleroma git clone https://hacktivis.me/git/pleroma.git

account_relationship.ex (1522B)


  1. # Pleroma: A lightweight social networking server
  2. # Copyright © 2017-2022 Pleroma Authors <https://pleroma.social/>
  3. # SPDX-License-Identifier: AGPL-3.0-only
  4. defmodule Pleroma.Web.ApiSpec.Schemas.AccountRelationship do
  5. alias OpenApiSpex.Schema
  6. alias Pleroma.Web.ApiSpec.Schemas.FlakeID
  7. require OpenApiSpex
  8. OpenApiSpex.schema(%{
  9. title: "AccountRelationship",
  10. description: "Relationship between current account and requested account",
  11. type: :object,
  12. properties: %{
  13. blocked_by: %Schema{type: :boolean},
  14. blocking: %Schema{type: :boolean},
  15. domain_blocking: %Schema{type: :boolean},
  16. endorsed: %Schema{type: :boolean},
  17. followed_by: %Schema{type: :boolean},
  18. following: %Schema{type: :boolean},
  19. id: FlakeID,
  20. muting: %Schema{type: :boolean},
  21. muting_notifications: %Schema{type: :boolean},
  22. note: %Schema{type: :string},
  23. requested: %Schema{type: :boolean},
  24. showing_reblogs: %Schema{type: :boolean},
  25. subscribing: %Schema{type: :boolean},
  26. notifying: %Schema{type: :boolean}
  27. },
  28. example: %{
  29. "blocked_by" => false,
  30. "blocking" => false,
  31. "domain_blocking" => false,
  32. "endorsed" => false,
  33. "followed_by" => false,
  34. "following" => false,
  35. "id" => "9tKi3esbG7OQgZ2920",
  36. "muting" => false,
  37. "muting_notifications" => false,
  38. "note" => "",
  39. "requested" => false,
  40. "showing_reblogs" => true,
  41. "subscribing" => false,
  42. "notifying" => false
  43. }
  44. })
  45. end