Who is client and who is server in Wireguard?

Wireguard doesn’t really use the concept of client and server the same way OpenVPN does. A wireguard interface does not have a fixed role as client or server - think about it like this:

For a single connection:

Endpoint = vpn.mydomain.com:31265

client will take the initiative and send packets to the server without having received any packet from the server beforehand - just like in classical VPNs.

Most real-world wireguard connections have one clientand one server. There are exceptions to this, namely if both endpoints have a static IP address or fixed host name, so both wireguard instances always know which IP address or hostname to send packets to.