syntax = "proto3";

message Person {
	bytes first_name = 1;
	uint32 age = 2;
}

message Image {
	bytes binary = 1;
}

message Link {
	bytes url = 1;
}

message Attachment {
	oneof attachment {
		Image image = 1;
		Link link = 2;
	}
}

message MyMessage {
	bytes title = 1;
	Person from = 2;
	Person to = 3;
	bytes content = 4;
	repeated Attachment attachments = 5;
}