Client-Server Communication API

Client-Server Communication API

Communication API for Fabric client and Paper server

by
197 Downloads
fabricpaper
Rent Server with this Mod

About this Mod

Client-Server Communication API

how to use for developer:

  • Register packet in common code:
public class FooBarPacket implements CscPacket{
    
    public FooBarPacket(ByteBuf buf) {
        read(buf);
    }

    private int foo;

    @Override
    public void read(ByteBuf buf) {
        foo = buf.readInt();
    }

    @Override
    public void write(ByteBuf buf) {
        buf.writeInt(foo);
    }
}
public static CscPacketType<FooBarPacket> FOO_BAR_PACKET = CscApi.registerPacket(
  "foo_bar", 
  FooBarPacket.class, 
  FooBarPacket::new
);
  • Use it on Server:
public class ServerClass {
    private static final Logger log = LoggerFactory.getLogger(ServerClass.class);

    public void init() {
        CscServer.getService().registerListener((packet, player) -> {
            log.info("Received packet {} from player {}", packet.getClass().getSimpleName(), player.getName());
        }, ModPackets.FOO_BAR_PACKET);
    }
    
    public void sendFooBarPacket(Player player) {
        CscServer.getService().sendPacket(new FooBarPacket(), player);
    }
}
  • Use it on Client:
public class ClientClass {
    private static final Logger log = LoggerFactory.getLogger(ClientClass.class);

    public void init() {
        CscClient.getService().registerListener(packet -> {
            log.info("Received packet: {}", packet);
        }, ModPackets.FOO_BAR_PACKET);
    }
    
    public void sendFooBarPacket() {
        CscClient.getService().sendPacket(new FooBarPacket());
    }
}

Available Versions

Client-Server Communication API 1.0release
MC 1.21.8paper
February 14, 2026
Client-Server Communication API 1.0release
MC 1.21.8fabric
February 14, 2026
Client-Server Communication API 1.0release
MC 1.21.11fabric
February 14, 2026
Client-Server Communication API 1.0release
MC 1.21.11paper
February 14, 2026

How to Install Client-Server Communication API on Your Server

1

Order Server

Order a Minecraft Java server with at least 3 GB RAM (4 GB recommended).

2

Set fabric Loader

In the panel under "Egg", select the fabric loader and matching Minecraft version (1.21.11).

3

Install Mod

Open the mod browser in the dashboard and search for "Client-Server Communication API". Click "Install" – done! Alternatively, upload the .jar via SFTP to the /mods folder.

Compatibility

Mod Loaders

fabricpaper

Minecraft Versions

1.21.11, 1.21.8

Server-side

Unsupported

Recommended RAM

4 GB(min. 3 GB)

Frequently Asked Questions

Client-Server Communication API server crashes on startup – what to do?

Most common cause: wrong fabric version or insufficient RAM. Check the server log (latest.log) for "OutOfMemoryError" or "Mixin" errors. With Mado Hosting: ensure at least 3 GB RAM is allocated and the loader matches the mod version (1.21.11). You can switch loaders with one click in the panel.

Is Client-Server Communication API compatible with fabric and paper?

Client-Server Communication API officially supports fabric, paper for Minecraft 1.21.11, 1.21.8. The Mado dashboard automatically detects incompatible loader combinations.

Server lagging with Client-Server Communication API – how to optimize performance?

Recommended RAM: 4 GB (per 8 players). Use /spark profiler to check if Client-Server Communication API consumes the most tick time. Common fixes: reduce server view-distance to 8-10, install "performant" or "starlight" as supplementary mods on Forge. With Mado Hosting, your server runs on NVMe SSDs with dedicated CPU cores for minimal latency.

Rent Modded Server

Install Client-Server Communication API with just one click on your server.

Recommended RAM
4 GBab €8/mo
Min. 3 GB | +1 GB pro 8 Spieler
Create Server Now
1-Click Mod Install
NVMe SSD Storage
DDoS Protection included

Details

License
MIT License
Server-side
Unsupported

Supported Versions

1.21.111.21.8