using System.Reflection.Metadata.Ecma335;
using System.Text.Json.Serialization;

public class PersonalData
{
    public PersonalData(Metadata metadata, Data data) 
    { 
        this.metadata = metadata;
        this.data = data;
    }

    public Metadata metadata { get; set; }
    public Data data { get; set; }

    public class Metadata
    {
        public Metadata(string encryptedEphemeralKey) 
        {
            this.encryptedEphemeralKey = encryptedEphemeralKey;
        }

        [JsonPropertyName("encryptedEphemeralKey")]
        public string encryptedEphemeralKey { get; set; }
    }

    public class Data
    {
        public Data(string name, string birthdate, string photo) 
        {
            this.name = name;
            this.birthdate = birthdate;
            this.photo = photo;
        }

        [JsonPropertyName("name")]
        public string name { get; set; }
        [JsonPropertyName("birthdate")]
        public string birthdate { get; set; }
        [JsonPropertyName("photo")]
        public string photo { get; set; }
    }
}