Skip to content

Commit 7ecff61

Browse files
committedMar 8, 2025
Update contact data example + add description
Naming the example field "tags" might have created unnecessary confusion with people thinking that it's a required field name
1 parent f4c7d8d commit 7ecff61

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed
 

‎lib/keila_web/api/schemas/contact.ex

+4-2
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ defmodule KeilaWeb.Api.Schemas.Contact do
3131
},
3232
data: %{
3333
type: :map,
34-
example: %{"tags" => ["rocket-scientist"]}
34+
description: "Custom data fields",
35+
example: %{"interests" => ["chess", "books"], "city" => "Munich"}
3536
},
3637
inserted_at: %{
3738
type: :string,
@@ -102,7 +103,8 @@ defmodule KeilaWeb.Api.Schemas.Contact.DataParams do
102103
properties: %{
103104
data: %OpenApiSpex.Schema{
104105
type: :object,
105-
example: %{"tags" => ["rocket-scientist"]}
106+
description: "Custom data fields",
107+
example: %{"interests" => ["chess", "books"], "city" => "Munich"}
106108
}
107109
}
108110
}

0 commit comments

Comments
 (0)