HTTP Block

Quick rating

HTTP Block

No reviews yet

HTTP Block adds two redstone-powered blocks that connect Minecraft to HTTP services. Send HTTP POST requests from redstone circuits and receive HTTP events as redstone pulses.

Tech
Automation & Processing
Redstone Improvements
Mod Loaders
Fabric
Minecraft
26.2

Community voices

Reviews

Versions
Loading versions…
Match includes

Click once to include, again to exclude, again to clear

Rating Any
Any 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0
Min
Max
Play Status
Reviews
Time Played
hrs+
Verified developers only
Has developer response
List view
Grid view
Compact view
Sort by
Date
Rating
Helpful
Unhelpful
Edited
Sort ascending
Delete this review?

This removes your review from the project. You can write a new review after.

Review submitted for moderation

Your review has been sent to moderators, who will check that it meets our guidelines before it appears publicly.

No reviews yet. Be the first to review this project!

Get it on

Available Platforms

Compatibility

Supported Environments

Dev Environment
Client Required
Server Required

About

Project Details

Type
Mod
License
GNU General Public License v3.0 or later
Latest Version
http-block-1.0.2.jar
Authors
CurseForge
Modrinth

For authors

Embed Badge

If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.

Custom banner text
ModDex rating badge preview

Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.

Identifiers

Platform IDs

CurseForge ID
Modrinth ID

Resources

External Links

Source Issues Wiki Discord

About

Description

HTTP Block

HTTP Block adds two configurable redstone blocks that allow Minecraft to communicate with external HTTP services. The HTTP Sender can send JSON POST requests when powered by redstone, while the HTTP Receiver continuously polls an HTTP endpoint and emits a redstone pulse whenever it detects a new event. This makes it easy to exchange data between Minecraft and any application capable of sending or receiving HTTP requests, regardless of the programming language or framework used.

  • HTTP Sender — sends an HTTP POST request when it receives a redstone rising edge.
  • HTTP Receiver — polls an HTTP endpoint and emits a short redstone pulse whenever a new event is detected.

HTTP Sender

Right-click the block to configure it.

URL

The HTTP endpoint that will receive the request.

Example:

http://localhost:8000/event

Payload

The raw JSON body that will be sent with the request.

Example:

{ "message": "Hello" }

Behavior

  • Sends an HTTP POST request only when redstone changes from OFF to ON.
  • Does not repeatedly send requests while continuously powered.
  • Uses Content-Type: application/json.
  • Requests are performed asynchronously and do not block the game.

HTTP Receiver

Right-click the block to configure it.

URL

The endpoint to poll for events.

Example:

http://localhost:8000/event

Note: The endpoint must return JSON matching the Event Format described below. The receiver expects that structure to detect new events correctly.

Last Message

Displays the message from the most recently received event.

Behavior

  • Polls the configured endpoint periodically.
  • Compares the returned event's hash with the last one it received.
  • Emits a redstone pulse only when the hash changes.
  • Duplicate events do not trigger another pulse.
  • Pulse strength is always 15.
  • Pulse duration is configurable.

Event Format

The receiver expects the endpoint to return JSON in the following format:

{
    "timestamp": 1750412345,
    "message": "Hello",
    "hash": "6a8f6c5d..."
}
Field Description
timestamp Unix timestamp of the event.
message Text shown in the receiver GUI.
hash Unique identifier for the event. A new hash triggers a pulse.

Only the hash is used to detect new events. A simple Python Example is shown below.

Example Relay (FastAPI)

The HTTP Receiver expects an endpoint that returns events in the format shown above. Below is a minimal FastAPI relay implementation that satisfies the required API.

from fastapi import FastAPI
from pydantic import BaseModel
import hashlib
import time
import uvicorn

app = FastAPI()

latest_event = {
    "timestamp": 0,
    "message": "",
    "hash": "",
}


class EventIn(BaseModel):
    message: str


@app.post("/send_event")
async def create_event(data: EventIn):
    global latest_event
    message = str(data.message)
    timestamp = int(time.time())
    event_hash = hashlib.sha256(f"{timestamp}:{message}".encode()).hexdigest()
    latest_event = {
        "timestamp": timestamp,
        "message": message,
        "hash": event_hash,
    }
    return {"success": True}


@app.get("/get_event")
async def get_event():
    return latest_event


if __name__ == "__main__":
    uvicorn.run(app, host="0.0.0.0", port=9000)

Install the required packages:

pip install fastapi uvicorn

Run the relay:

python relay.py

Then configure your blocks:

  • HTTP Sender URL: http://localhost:9000/send_event
  • HTTP Receiver URL: http://localhost:9000/get_event

Commands

/http pollrate <ticks>

Sets how often receivers poll their configured URL.

/http pulselength <ticks>

Sets how long receiver pulses last.

/http status

Shows the current configuration and registered sender/receiver counts.

/http reload

Reloads the configuration from disk.


HTTP Block

HTTP Block adds two configurable redstone blocks that allow Minecraft to communicate with external HTTP services. The HTTP Sender can send JSON POST requests when powered by redstone, while the HTTP Receiver continuously polls an HTTP endpoint and emits a redstone pulse whenever it detects a new event. This makes it easy to exchange data between Minecraft and any application capable of sending or receiving HTTP requests, regardless of the programming language or framework used.

  • HTTP Sender — sends an HTTP POST request when it receives a redstone rising edge.
  • HTTP Receiver — polls an HTTP endpoint and emits a short redstone pulse whenever a new event is detected.

HTTP Sender

Right-click the block to configure it.

URL

The HTTP endpoint that will receive the request.

Example:

http://localhost:8000/event

Payload

The raw JSON body that will be sent with the request.

Example:

{ "message": "Hello" }

Behavior

  • Sends an HTTP POST request only when redstone changes from OFF to ON.
  • Does not repeatedly send requests while continuously powered.
  • Uses Content-Type: application/json.
  • Requests are performed asynchronously and do not block the game.

HTTP Receiver

Right-click the block to configure it.

URL

The endpoint to poll for events.

Example:

http://localhost:8000/event

Note: The endpoint must return JSON matching the Event Format described below. The receiver expects that structure to detect new events correctly.

Last Message

Displays the message from the most recently received event.

Behavior

  • Polls the configured endpoint periodically.
  • Compares the returned event's hash with the last one it received.
  • Emits a redstone pulse only when the hash changes.
  • Duplicate events do not trigger another pulse.
  • Pulse strength is always 15.
  • Pulse duration is configurable.

Event Format

The receiver expects the endpoint to return JSON in the following format:

{
    "timestamp": 1750412345,
    "message": "Hello",
    "hash": "6a8f6c5d..."
}
Field Description
timestamp Unix timestamp of the event.
message Text shown in the receiver GUI.
hash Unique identifier for the event. A new hash triggers a pulse.

Only the hash is used to detect new events. A simple Python Example is shown below.

Example Relay (FastAPI)

The HTTP Receiver expects an endpoint that returns events in the format shown above. Below is a minimal FastAPI relay implementation that satisfies the required API.

from fastapi import FastAPI
from pydantic import BaseModel
import hashlib
import time
import uvicorn

app = FastAPI()

latest_event = {
    "timestamp": 0,
    "message": "",
    "hash": "",
}


class EventIn(BaseModel):
    message: str


@app.post("/send_event")
async def create_event(data: EventIn):
    global latest_event
    message = str(data.message)
    timestamp = int(time.time())
    event_hash = hashlib.sha256(f"{timestamp}:{message}".encode()).hexdigest()
    latest_event = {
        "timestamp": timestamp,
        "message": message,
        "hash": event_hash,
    }
    return {"success": True}


@app.get("/get_event")
async def get_event():
    return latest_event


if __name__ == "__main__":
    uvicorn.run(app, host="0.0.0.0", port=9000)

Install the required packages:

pip install fastapi uvicorn

Run the relay:

python relay.py

Then configure your blocks:

  • HTTP Sender URL: http://localhost:9000/send_event
  • HTTP Receiver URL: http://localhost:9000/get_event

Commands

/http pollrate <ticks>

Sets how often receivers poll their configured URL.

/http pulselength <ticks>

Sets how long receiver pulses last.

/http status

Shows the current configuration and registered sender/receiver counts.

/http reload

Reloads the configuration from disk.


Screenshots

Gallery

This project has no gallery images yet.

Versions

Files

Relations

Project Relations

More like this

Similar Mods

Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.

On ModDex

Community snapshot

0
Ratings
0
Followers
0
In stacks

By the numbers

Statistics

<1,000
Total Downloads
CurseForge
<1,000
Modrinth
<1,000
Last Updated
CurseForge
Created
CurseForge
Modrinth
Last synced
When ModDex last fetched this project from CurseForge or Modrinth. Every project is re-checked on a schedule, and any project that ships a new file is synced automatically within hours of the release.
New file updates sync automatically
How syncing works