Add my own json if condition satisfies

I want to add my own schema based on condition. Example:

if id == 1 then '{"enum": ["<1L", "1L-5L", "5L-10L", "10L+"]}' elif id == 2 then '{"enum": ["Wedding","Business","Education","Medical Emergency","Other"]}' else nil end

But when I run this, the values come as string with escaped double quotes instead of json like below:

"{\"enum\": [\"<1L\", \"1L-5L\", \"5L-10L\", \"10L+\"]}"

Please help.

Create the enum without the quotes in a Formula field:

if id == 1 then {"enum" => ["<1L", "1L-5L", "5L-10L", "10L+"]} 
elsif id == 2 then {"enum" => ["Wedding","Business","Education","Medical Emergency","Other"]} 
else nil end

You can find an example here