mirror of
https://github.com/plausible/analytics.git
synced 2024-12-26 11:02:52 +03:00
38b1834b3f
* Tidy up OpenAPI schema * Remove `items` from object schema
23 lines
494 B
Elixir
23 lines
494 B
Elixir
defmodule PlausibleWeb.Plugins.API.Schemas.NotFound do
|
|
@moduledoc """
|
|
OpenAPI schema for a generic 404 response
|
|
"""
|
|
|
|
use PlausibleWeb, :open_api_schema
|
|
|
|
OpenApiSpex.schema(%{
|
|
description: """
|
|
The response that is returned when the user makes a request to a non-existing resource
|
|
""",
|
|
type: :object,
|
|
title: "NotFoundError",
|
|
required: [:errors],
|
|
properties: %{
|
|
errors: %Schema{
|
|
items: Schemas.Error,
|
|
type: :array
|
|
}
|
|
}
|
|
})
|
|
end
|