structure for JSON encoding