Import and Use Numbered Code Snippets

If you did want to go this route, rather than using a single macro with a JSON array (or KM text pseudo array), it wouldn't be that difficult to automate the creation of a Group of individual macros, one for each snippet with a typed string trigger corresponding to the snippet number, with AppleScript.

In this case I think I'd go with @ComplexPoint's suggestion. If you were going to be using these snippets a lot I'd make individual macros, my totally untested theory being that the individuals would be snappier since they wouldn't have to such a large variable to work with and you'd eventually regain the initial setup time and more.