Unity/Firebase/Realtimedatabase/json
提供: 初心者エンジニアの簡易メモ
jsonをそのまま送信
User user = new User("taro", "taro@example"); string json = JsonUtility.ToJson(user); string userId = "111"; FirebaseDatabase.DefaultInstance.GetReference("user").Child(userId) .SetRawJsonValueAsync(json);
User.cs
public class User { public string username; public string email; public User(string username, string email) { this.username = username; this.email = email; } }
参考
https://firebase.google.com/docs/database/unity/save-data?hl=ja