The documentation for Unmarshal
states that
Struct fields are only unmarshalled if they are exported (have an upper case first letter) and are unmarshalled using the field name lowercased as the default key.
So capitalizing your struct elements is the right thing to do.
type example struct {
Variable1 string
Variable2 string
}