---
title: "Ordering with an agent · API docs | Rdp.Vision"
description: "Manage Rdp.Vision servers from code or an AI agent: order, start, stop, renew and top up with an API key, or connect Claude, Cursor and other agents to the MCP server."
url: https://rdp.vision/docs/api/agents
---

Open in AI

[ChatGPT](https://chatgpt.com/?q=Read%20https%3A%2F%2Frdp.vision%2Fdocs%2Fapi%2Fagents.md%20and%20help%20me%20use%20the%20Rdp.Vision%20API.)[Claude](https://claude.ai/new?q=Read%20https%3A%2F%2Frdp.vision%2Fdocs%2Fapi%2Fagents.md%20and%20help%20me%20use%20the%20Rdp.Vision%20API.)

# Ordering with an agent

Give a key the read, credentials, order and topup scopes and ask: “Get me a Windows server in Frankfurt for MetaTrader.” The agent calls list\_plans, checks get\_account, tops up with create\_topup\_invoice if needed and asks you to pay, then order\_server, and polls get\_server until it can hand you the IP and login.

## The same in Python

import os, time, requests

API = "https://rdp.vision/api/v1"
H = {"Authorization": f"Bearer {os.environ\['RDPVISION\_KEY'\]}"}

server = requests.post(f"{API}/orders", headers=H, json={
    "plan\_id": 1, "region\_id": 10, "distro\_id": 2, "duration": 1,   # Windows, Frankfurt, Server 2022
}).json()

while True:
    s = requests.get(f"{API}/servers/{server\['id'\]}", headers=H).json()
    if s\["status"\] == "running" and not s.get("setup"):
        break
    time.sleep(30)

print(s\["ip\_address"\], s\["username"\], s\["password"\])
