lib/spatio/model/update_note_request.ex

# NOTE: This file is auto generated by OpenAPI Generator 7.22.0 (https://openapi-generator.tech).
# Do not edit this file manually.

defmodule Spatio.Model.UpdateNoteRequest do
  @moduledoc """
  Partial update. Every field is optional; only fields present in the body are touched. `null` for `parentId` clears the parent. 
  """

  @derive JSON.Encoder
  defstruct [
    :title,
    :content,
    :icon,
    :coverImage,
    :parentId,
    :properties,
    :archived
  ]

  @type t :: %__MODULE__{
    :title => String.t | nil,
    :content => String.t | nil,
    :icon => String.t | nil,
    :coverImage => Uri | nil,
    :parentId => String.t | nil,
    :properties => %{optional(String.t) => any()} | nil,
    :archived => boolean() | nil
  }

  alias Spatio.Deserializer

  def decode(value) do
    value
     |> Deserializer.deserialize(:coverImage, :struct, Spatio.Model.Uri)
  end
end