{% extends "base.html" %} {% block title %}Item Editor - Command Storage - Devanturas{% endblock %} {% block description %}Store commands longer than 256 characters temporarily for Minecraft Item Editor plugin{% endblock %} {% block content %} Projects / Item Editor / Command Storage Item Editor Command Storage Store long commands (>256 chars) temporarily and generate a retrievable link Store Command Paste your Minecraft command below. Commands longer than 256 characters will be stored for 30 minutes and a unique retrieval link will be generated. Minecraft Command 0 characters Store Command Command Stored Successfully! Your command has been stored for 30 minutes. Retrieval Link (JSON): Copy Use this link in your Item Editor plugin to load the command. Expires in: 30 minutes Store Another Command Recently Stored Commands How It Works Paste your long Minecraft command Click "Store Command" to generate a link Copy the generated JSON link Use the link in your Item Editor plugin Storage Limits Duration: 30 minutes Max Length: 10,000 characters Format: JSON response Access: Anyone with link Self-Hosting Host this system on your own webserver with this simple PHP script: <?php header('Content-Type: application/json'); $storage_file = 'commands.json'; // Store command (POST) if ($_SERVER['REQUEST_METHOD'] === 'POST') { $data = json_decode(file_get_contents('php://input'), true); $command = $data['command'] ?? ''; if (strlen($command) > 10000) { http_response_code(400); echo json_encode(['error' => 'Too long']); exit; } $uuid = bin2hex(random_bytes(16)); $expires = time() + 1800; // 30 min $storage = file_exists($storage_file) ? json_decode(file_get_contents($storage_file), true) : []; $storage[$uuid] = [ 'command' => $command, 'expires_at' => $expires ]; file_put_contents($storage_file, json_encode($storage)); echo json_encode([ 'success' => true, 'url' => "https://yourserver.com/storage.php?id=$uuid" ]); exit; } // Retrieve command (GET) if (isset($_GET['id'])) { $storage = file_exists($storage_file) ? json_decode(file_get_contents($storage_file), true) : []; $uuid = $_GET['id']; if (!isset($storage[$uuid])) { http_response_code(404); echo json_encode(['error' => 'Not found']); exit; } if ($storage[$uuid]['expires_at'] < time()) { unset($storage[$uuid]); file_put_contents($storage_file, json_encode($storage)); http_response_code(410); echo json_encode(['error' => 'Expired']); exit; } echo json_encode($storage[$uuid]); exit; } ?> Setup: Save as storage.php on your webserver. Make sure the directory is writable for commands.json. {% endblock %}
Store long commands (>256 chars) temporarily and generate a retrievable link
Paste your Minecraft command below. Commands longer than 256 characters will be stored for 30 minutes and a unique retrieval link will be generated.
Your command has been stored for 30 minutes.
Host this system on your own webserver with this simple PHP script:
<?php header('Content-Type: application/json'); $storage_file = 'commands.json'; // Store command (POST) if ($_SERVER['REQUEST_METHOD'] === 'POST') { $data = json_decode(file_get_contents('php://input'), true); $command = $data['command'] ?? ''; if (strlen($command) > 10000) { http_response_code(400); echo json_encode(['error' => 'Too long']); exit; } $uuid = bin2hex(random_bytes(16)); $expires = time() + 1800; // 30 min $storage = file_exists($storage_file) ? json_decode(file_get_contents($storage_file), true) : []; $storage[$uuid] = [ 'command' => $command, 'expires_at' => $expires ]; file_put_contents($storage_file, json_encode($storage)); echo json_encode([ 'success' => true, 'url' => "https://yourserver.com/storage.php?id=$uuid" ]); exit; } // Retrieve command (GET) if (isset($_GET['id'])) { $storage = file_exists($storage_file) ? json_decode(file_get_contents($storage_file), true) : []; $uuid = $_GET['id']; if (!isset($storage[$uuid])) { http_response_code(404); echo json_encode(['error' => 'Not found']); exit; } if ($storage[$uuid]['expires_at'] < time()) { unset($storage[$uuid]); file_put_contents($storage_file, json_encode($storage)); http_response_code(410); echo json_encode(['error' => 'Expired']); exit; } echo json_encode($storage[$uuid]); exit; } ?>
Setup: Save as storage.php on your webserver. Make sure the directory is writable for commands.json.
storage.php
commands.json