MCP server reference
This page describes the Fluence MCP server at https://api.fluence.dev/mcp. To connect a client, see Connect an AI client through MCP.
Endpoint and protocol
| Property | Value |
|---|---|
| URL | https://api.fluence.dev/mcp |
| Transport | Streamable HTTP, stateless, JSON responses. Requests use POST. There are no sessions and no event stream. |
| Protocol versions | 2025-11-25, 2026-07-28 |
| Capabilities | Tools only. The server has no prompts and no resources. |
| Scope | CPU virtual machines, disks, VPCs, subnets, security groups, public IP addresses, SSH keys, catalog, and prices |
Each tool calls one operation of the Fluence public API v3 with your API key. A tool result is the same JSON that the API returns.
Authentication
Every request needs exactly one X-API-KEY header with a Fluence API key. Keys start with fl_v1_. Create keys in the Fluence Console under Settings > API keys.
The server refuses a request before it checks the key in these cases:
| Request | Response |
|---|---|
Has an Origin header. Browsers always send one. | 403, empty body |
Has an Authorization header | 401, A single X-API-KEY header and native client are required |
| Has a query string in the URL | 401, same message |
Has no X-API-KEY header, or more than one | 401, same message |
The server then checks the key on every request. A deleted or expired key stops working at once, and so does a key of a blocked account.
The server does not support OAuth. Clients that can only sign in with OAuth, and hosted connectors that cannot send a custom header, cannot connect.
Tools and scopes
tools/list returns only the tools that your key has every permission for. If a client calls a tool anyway, the tool returns the error code forbidden. A key needs all permissions listed for a tool. vms:write does not include vms:read.
| Permissions | Tools |
|---|---|
| Any valid key | list_images |
clusters:read | list_clusters, get_cluster_options |
clusters:read, vm:list, prices:read | list_vm_offerings |
vm:list | list_configurations |
prices:read | list_vm_prices, list_storage_prices, list_public_ip_prices, estimate_resource_cost, estimate_vm |
vms:read, prices:read | estimate_saved_vm |
vms:read | list_vms, get_vm, list_vm_interfaces |
vms:write | create_vm, update_vm, provision_vm, restart_vm, soft_reboot_vm, terminate_vm, discard_vm, set_vm_cloud_init, clear_vm_cloud_init, replace_vm_ssh_keys, move_vm_cluster, add_vm_interface, update_vm_interface, detach_vm_security_group, remove_vm_interface, set_default_vm_interface, attach_vm_storage, create_vm_data_disk, create_vm_boot_disk, replace_vm_boot_disk, update_vm_storage, remove_vm_storage |
ssh_key:list | list_ssh_keys |
ssh_key:create | create_ssh_key |
ssh_key:remove | delete_ssh_key |
storage:read | list_storage_types, list_storages, get_storage |
storage:write | create_storage, update_storage, delete_storage |
vpc:read | list_vpcs |
vpc:write | create_vpc, update_vpc, delete_vpc |
subnet:read | list_subnets |
subnet:write | create_subnet, update_subnet, delete_subnet, set_default_subnet |
security_groups:read | list_security_groups |
security_groups:write | create_security_group, update_security_group, delete_security_group |
public_ip:read | list_public_ips |
public_ip:write | create_public_ip, update_public_ip, delete_public_ip |
account:read | get_balances |
How the console's permission presets map to these permissions:
- Read only gives the
*:readscopes for VMs, disks, VPCs, subnets, security groups, and public IP addresses, plusssh_key:list,api_key:list,billing:get_history, andbilling:get_spending_history. It does not giveclusters:read,vm:list, orprices:read, so a Read only key cannot use the catalog, price, or estimate tools. - Custom scopes with Virtual machines set to Manage gives
vms:readandvms:write, and addsclusters:read,vm:list, andprices:read. - The console does not offer
account:read, soget_balancesdoes not work with a key created in the console.
A key can only receive permissions that your account has.
Arguments
- Resource IDs are UUIDs in camelCase arguments:
vmId,clusterId,storageId,publicIpId,vpcId,subnetId,securityGroupId,sshKeyId,interfaceId. - The request body of the API operation goes in the
specargument. The server rejects unknown top-level arguments. - Names of VMs, disks, VPCs, subnets, security groups, public IP addresses, and SSH keys are 1 to 25 characters: lowercase letters, digits, and hyphens. A name starts and ends with a letter or digit.
- List tools accept
page(default 1) andperPage(default 50, maximum 200).
Results and errors
A successful call returns the API response in structuredContent.result, and the same JSON as text in content. An operation with no response body returns {"result": null}.
A failed call returns isError: true and an error object in structuredContent. Use the code field to decide what to do. The other fields of the error object can change.
| Code | Meaning |
|---|---|
bad_request | The arguments do not match the tool's input schema |
forbidden | The key lacks a permission the tool needs |
not_found | The resource does not exist or belongs to another account |
busy | Too many calls are running. This call did not start. |
rate_limited | The key exceeded the request budget. Wait for the time in retryAfter. |
operation_timeout | The server stopped waiting for the operation. A write may have finished. |
operation_unavailable | The server could not run the operation, for example during a restart |
output_too_large | The result was larger than the server returns. A write may have finished. |
idempotency_conflict | A previous call used the same requestKey with different arguments |
request_in_progress | A call with the same requestKey is still running. Wait for the time in retryAfter. |
idempotent_resource_gone | The resource created under this requestKey has been deleted since |
vm_not_draft | The operation needs a VM in the draft status |
Limits
- Each server instance runs at most 2 tool calls at a time for one user and 8 in total. A call over the limit returns
busyand does not start. Wait for a running call to finish, then retry with the same arguments. - MCP calls and API calls made with the same key share one request budget.
- A write keeps running after a timeout or after the client disconnects. A read stops when the client disconnects.
Retries
Nine tools take a required requestKey argument: create_vm, create_storage, create_vm_data_disk, create_vm_boot_disk, create_public_ip, create_vpc, create_subnet, create_security_group, and terminate_vm. The key is 1 to 128 characters: letters, digits, ., _, :, and -. If the outcome of a call is unknown, call the tool again with the same requestKey and the same arguments. The server returns the result of the first call and does not create a second resource. The same key works across MCP and the API.
Other writes have no requestKey, for example provision_vm, create_ssh_key, interface changes, and deletions. If the outcome of such a call is unknown, read the resource state before you retry.
Tool annotations
Every tool sets readOnlyHint, destructiveHint, and idempotentHint, and openWorldHint is false.
readOnlyHintistruefor list, get, and estimate tools.destructiveHintistruefor tools that start billing, terminate or delete resources, or change network access. Clients can use it to ask for confirmation.create_vmis not destructive. It creates a draft that is not billed.provision_vmis destructive. It starts the VM and billing.idempotentHintistrueonly for the tools that take arequestKey.
VM lifecycle
A VM goes through these tool calls:
list_clustersreturns the clusters and their locations.list_vm_offeringsreturns the configurations available in a cluster with your hourly price.list_imagesreturns the OS images and the login user name of each image.list_ssh_keysorcreate_ssh_keygives the SSH key IDs for the VM.estimate_vmreturns the hourly and monthly cost of a full VM specification. This step is optional.create_vmcreates a draft. A draft is not running and is not billed.provision_vmstarts the VM and billing.get_vmandlist_vm_interfacesshow the status and the assigned IP addresses.terminate_vmstops the VM. Its disks and public IP addresses stay and continue to be billed.delete_storageanddelete_public_ipremove the retained disks and addresses. To delete a draft that was never provisioned, usediscard_vm.
VM statuses: draft, new, launching, launched, failed, updating, terminating, terminated, suspending, suspended, restarting, softRebooting, unknown.
Rules that agents often get wrong:
- If
create_vmhas nosshKeyIds, the draft gets all active SSH keys of the account. An empty list gives no keys.estimate_vmrequiressshKeyIds. launchedcan come before the VM has an IP address. Readlist_vm_interfacesuntil the interface has a non-emptyassignedIps. An IP address does not mean that SSH is ready.replace_vm_ssh_keyschanges a draft only.delete_ssh_keyremoves a key from the account but does not remove it from VMs that already run.create_security_grouprequires bothingressRulesandegressRules. An empty list denies all traffic in that direction. Before you attach a group, readlist_security_groupsuntil the group status isready.- Catalog, offering, and estimate results do not reserve capacity.
Prices
list_vm_prices,list_storage_prices,list_public_ip_prices, andlist_vm_offeringsreturnpriceInfowithcurrency(USD),pricePerHourPerQty(a decimal string), andunit(vm,gb, orip_address).estimate_vmandestimate_saved_vmreturnhourlyTotal,monthlyTotal, and abreakdownfor the VM, storage, and public IP address. A month is 730 hours. ThehourlyIncrementalandmonthlyIncrementalfields leave out resources that are already billed.estimate_resource_costreturns the cost of listed resources per second and for a period. The default period is 3600 seconds.- The server returns the prices that currently apply to your account. An estimate is not a quote and does not fix the price.
Tools
Catalog and prices
| Tool | What it does |
|---|---|
list_clusters | Lists clusters with city and country |
list_vm_offerings | Lists VM configurations in a cluster with vCPU, RAM, CPU family, and your hourly price |
get_cluster_options | Returns the configurations and the disk and IP capacity of a cluster |
list_configurations | Resolves configuration IDs to CPU, RAM, and hardware |
list_images | Lists OS images with the login user name |
list_storage_types | Lists disk types |
list_vm_prices, list_storage_prices, list_public_ip_prices | Return hourly prices |
estimate_vm | Estimates the cost of a full VM specification |
estimate_saved_vm | Estimates the cost of a saved draft |
estimate_resource_cost | Estimates the cost of listed resources |
get_balances | Returns the account balances |