Instant Mock RPC Endpoints for Developers

Free, fast, and ephemeral mock JSON-RPC and gRPC endpoints.
No sign-up. No installation. Just fetch

Quick Start

Get your first mock endpoint running in under 10 seconds.

1. Create a Workspace

bash
curl -X POST https://rpcmock.com/api/v1/workspaces \
  -H "Content-Type: application/json" \
  -d '{"name": "my workspace", "ttl_hours": 24}'

2. Create a Mock

bash
curl -X POST https://rpcmock.com/api/v1/workspaces/<id>/mocks \
  -H "Content-Type: application/json" \
  -d '{
    "protocol": "jsonrpc",
    "method": "getUser",
    "response": {
      "id": 123,
      "name": "John Doe",
      "email": "[email protected]"
    }
  }'

3. Call Your Mock

bash
curl -X POST https://rpcmock.com/jsonrpc/<id> \
  -H "Content-Type: application/json" \
  -d '{
    "jsonrpc": "2.0",
    "method": "getUser",
    "params": {"id": 123},
    "id": 1
  }'

Everything You Need for API Mocking

Powerful features designed to make your development and testing workflow seamless.

Instant Setup
No installation, no configuration files, no complex setup. Create a workspace and start mocking API endpoints in seconds.
JSON-RPC & gRPC Support
Native support for JSON-RPC 2.0 and gRPC with server reflection. Test your microservices and RPC endpoints without writing proto files.
Isolated Workspaces
Each workspace provides unique endpoints with independent mocks and request logs. Perfect for parallel testing and team collaboration.
Conditional Response Matching
Match requests by method name and parameters using priority-based routing. Create multiple mocks for different test scenarios and edge cases.
Real-Time Request Logging
Automatically capture all API requests with timestamps and response times. Debug your integrations faster with detailed request history.
Network Latency Simulation
Add configurable delays to simulate slow networks, timeouts, and production conditions. Test error handling and resilience patterns.

Built for Your Workflow

Whether you're building, testing, or exploring APIs, RPC Mock has you covered.

Frontend Development

Build frontend features without waiting for backend APIs. Create realistic mock data and continue development independently.

Example

Mock getUserProfile while the backend team builds the real endpoint

Integration Testing

Test your microservices without external dependencies. Simulate success, error, and timeout scenarios reliably.

Example

Test payment processing with different error conditions

API Exploration

Experiment with different response formats and error conditions without affecting real data or production systems.

Example

Try different API designs before committing to implementation

Advanced Capabilities

Go beyond the basics with powerful features for testing complex scenarios.

Conditional Response Matching

Create multiple mocks for the same method with different match conditions. Use priority-based routing to return different responses based on request parameters.

1. Create Mocks with Match Conditions

Admin Mock (Priority 1)
curl -X POST https://rpcmock.com/api/v1/workspaces/<id>/mocks \
  -d '{
    "method": "getPermissions",
    "match_conditions": {"role": "admin"}, "priority": 1,
    "response": {"permissions": ["read","write","delete","admin"]}
  }'
User Mock (Priority 2)
curl -X POST https://rpcmock.com/api/v1/workspaces/<id>/mocks \
  -d '{
    "method": "getPermissions",
    "match_conditions": {"role": "user"}, "priority": 2,
    "response": {"permissions": ["read"]}
  }'

Error Simulation

Test error handling by returning custom error responses. Simulate various failure scenarios without touching production systems.

1. Create Mock with Error Response

bash
curl -X POST https://rpcmock.com/api/v1/workspaces/<id>/mocks \
  -H "Content-Type: application/json" \
  -d '{
    "protocol": "jsonrpc",
    "method": "processPayment",
    "error": {
      "code": -32001,
      "message": "Insufficient funds",
      "data": {"balance": 50.00, "required": 100.00}
    },
    "delay_ms": 500
  }'

Batch Requests (JSON-RPC)

Full support for JSON-RPC batch requests. Test multiple operations in a single HTTP call.

1. Create Multiple Mocks

Creating 3 mocks: getUser, getStats, and getSettings

gRPC Reflection

No proto files needed! Use gRPC reflection to call your mock endpoints with grpcurl or any gRPC client.

1. Create gRPC Mock with Reflection

bash
curl -X POST https://rpcmock.com/api/v1/workspaces/<id>/mocks \
  -H "Content-Type: application/json" \
  -d '{
    "protocol": "grpc",
    "method": "/users.UserService/GetUser",
    "response": {"id": 42, "username": "demo_user"...}
  }'

Start Mocking in Seconds

No sign-up required. Create your first workspace and start testing immediately.