Current section

Files

Jump to
polarex lib polarex schemas benefit_feature_flag.ex
Raw

lib/polarex/schemas/benefit_feature_flag.ex

defmodule Polarex.BenefitFeatureFlag do
@moduledoc """
Provides struct and type for a BenefitFeatureFlag
"""
@type t :: %__MODULE__{
created_at: DateTime.t(),
deletable: boolean,
description: String.t(),
id: String.t(),
is_deleted: boolean,
metadata: map,
modified_at: DateTime.t() | nil,
organization_id: String.t(),
properties: map,
selectable: boolean,
type: String.t(),
visibility: String.t(),
visibility_configurable: boolean
}
defstruct [
:created_at,
:deletable,
:description,
:id,
:is_deleted,
:metadata,
:modified_at,
:organization_id,
:properties,
:selectable,
:type,
:visibility,
:visibility_configurable
]
@doc false
@spec __fields__(atom) :: keyword
def __fields__(type \\ :t)
def __fields__(:t) do
[
created_at: {:string, "date-time"},
deletable: :boolean,
description: :string,
id: {:string, "uuid4"},
is_deleted: :boolean,
metadata: :map,
modified_at: {:union, [{:string, "date-time"}, :null]},
organization_id: {:string, "uuid4"},
properties: :map,
selectable: :boolean,
type: {:const, "feature_flag"},
visibility: {:enum, ["draft", "private", "public"]},
visibility_configurable: :boolean
]
end
end