View .md

Pterodactyl Importer endpoints (Admin API)

13 FeatherPanel Admin API endpoints from admin/pterodactyl-importer.php: methods, paths, auth, permissions, rate limits, parameters and responses.

Last synced from FeatherPanel 15b94e9 on .

On this page

Defined in backend/app/routes/admin/pterodactyl-importer.php. Authentication used here: Admin. Read Authentication for how to send credentials and Rate limits and errors for the response envelope.

Paths, methods, permissions and rate limits come from the route file. Summaries, parameters and response codes come from the OpenAPI annotations on the controllers; endpoints without annotations show only what the route file declares.

Endpoints

GET/api/admin/pterodactyl-importer/prerequisites

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-prerequisitesController: PterodactylImporterController::prerequisitesroute source

Check prerequisites for Pterodactyl import Verify that the panel meets the requirements for importing Pterodactyl data. Checks user count (must be <= 1), nodes (must be 0), locations (must be 0), realms (must be 0), spells (must be 0), servers (must be 0), databases (must be 0), and allocations (must be 0).

Response data fieldTypeDescription
users_countintegerCurrent number of users
nodes_countintegerCurrent number of nodes
locations_countintegerCurrent number of locations
realms_countintegerCurrent number of realms
spells_countintegerCurrent number of spells
servers_countintegerCurrent number of servers
databases_countintegerCurrent number of databases
allocations_countintegerCurrent number of allocations
panel_cleanbooleanWhether all prerequisites are met
curl -X GET "$PANEL_URL/api/admin/pterodactyl-importer/prerequisites" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json"

Responses: 200 Prerequisites check completed successfully · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 500 Internal server error

POST/api/admin/pterodactyl-importer/import

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-importController: PterodactylImporterController::importroute source

Import Pterodactyl data (deprecated) Deprecated: Direct HTTP import is no longer supported. Use the external Pterodactyl Migration Agent instead.

curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json"

Responses: 401 Unauthorized · 403 Forbidden - Insufficient permissions · 410 Deprecated - Import must be performed via the Pterodactyl Migration Agent · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-egg

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-eggController: PterodactylImporterController::importEggroute source

Import Pterodactyl egg as spell Import a Pterodactyl egg (with variables) as a FeatherPanel spell. Maps nest_id to realm_id and converts egg_variables to spell_variables.

Body fieldTypeRequiredDescription
eggobjectyesPterodactyl egg data
variablesobject[]noEgg variables to import
nest_to_realm_mappingobjectnoMapping of Pterodactyl nest_id to FeatherPanel realm_id. If not provided, will use realm_id from egg data or default to realm_id=1.
Response data fieldTypeDescription
spellSpell
variables_importedintegerNumber of variables imported
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-egg" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"egg":{},"variables":[],"nest_to_realm_mapping":{}}'

Responses: 201 Egg imported successfully as spell · 400 Bad request - Invalid data, missing required fields, invalid realm, or UUID already exists · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 Realm not found · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-node

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-nodeController: PterodactylImporterController::importNoderoute source

Import Pterodactyl node Import a Pterodactyl node as a FeatherPanel node. Maps location_id and generates new daemon tokens.

Body fieldTypeRequiredDescription
nodeobjectyesPterodactyl node data
location_to_location_mappingobjectnoMapping of Pterodactyl location_id to FeatherPanel location_id. If not provided, will use location_id from node data.
generate_new_tokensbooleannoWhether to generate new daemon tokens (default: true). Set to false to preserve original tokens (not recommended).
Response data fieldTypeDescription
nodeNode
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-node" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"node":{},"location_to_location_mapping":{},"generate_new_tokens":false}'

Plugin events: featherpanel:admin:nodes:node:created

Responses: 201 Node imported successfully · 400 Bad request - Invalid data, missing required fields, invalid location, or UUID already exists · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 Location not found · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-allocation

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-allocationController: PterodactylImporterController::importAllocationroute source

Import Pterodactyl allocation Import a Pterodactyl allocation as a FeatherPanel allocation. Maps node_id and allows unknown/non-existent server_id (will be set to null).

Body fieldTypeRequiredDescription
allocationobjectyesPterodactyl allocation data
node_to_node_mappingobjectnoMapping of Pterodactyl node_id to FeatherPanel node_id. If not provided, will use node_id from allocation data.
server_to_server_mappingobjectnoMapping of Pterodactyl server_id to FeatherPanel server_id. If not provided, server_id will be used as-is (no existence checks).
Response data fieldTypeDescription
allocationobjectCreated allocation data
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-allocation" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"allocation":{},"node_to_node_mapping":{},"server_to_server_mapping":{}}'

Responses: 201 Allocation imported successfully · 400 Bad request - Invalid data, missing required fields, invalid node, or IP/port already exists · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 Node not found · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-user

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-userController: PterodactylImporterController::importUserroute source

Import Pterodactyl user Import a Pterodactyl user as a FeatherPanel user. Maps fields and preserves bcrypt passwords. ID 1 is reserved for the main user and will be skipped.

Body fieldTypeRequiredDescription
userobjectyesPterodactyl user data
Response data fieldTypeDescription
userobjectCreated user data
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-user" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"user":{}}'

Plugin events: featherpanel:user:created

Responses: 201 User imported successfully · 400 Bad request - Invalid data, missing required fields, duplicate email/username, or ID 1 provided · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 409 Conflict - User with email/username/ID already exists · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-ssh-key

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-ssh-keyController: PterodactylImporterController::importSshKeyroute source

Import Pterodactyl SSH key Import a Pterodactyl SSH key as a FeatherPanel SSH key. Maps user_id and preserves fingerprint.

Body fieldTypeRequiredDescription
ssh_keyobjectyesPterodactyl SSH key data
user_to_user_mappingobjectnoMapping of Pterodactyl user_id to FeatherPanel user_id. If not provided, will use user_id from SSH key data.
Response data fieldTypeDescription
ssh_keyobjectCreated SSH key data
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-ssh-key" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"ssh_key":{},"user_to_user_mapping":{}}'

Plugin events: featherpanel:user:ssh_key:created

Responses: 201 SSH key imported successfully · 400 Bad request - Invalid data, missing required fields, invalid user, duplicate fingerprint, or invalid SSH key format · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 User not found · 409 Conflict - SSH key with fingerprint already exists · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-server

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-serverController: PterodactylImporterController::importServerroute source

Import Pterodactyl server Import a Pterodactyl server as a FeatherPanel server. Maps nest_id to realms_id, egg_id to spell_id, and preserves server variables. Skips Wings API calls.

Body fieldTypeRequiredDescription
serverobjectyesPterodactyl server data
server_variablesobject[]noServer variables array
nest_to_realm_mappingobjectnoMapping of Pterodactyl nest_id to FeatherPanel realm_id
egg_to_spell_mappingobjectnoMapping of Pterodactyl egg_id to FeatherPanel spell_id
node_to_node_mappingobjectnoMapping of Pterodactyl node_id to FeatherPanel node_id
user_to_user_mappingobjectnoMapping of Pterodactyl user_id to FeatherPanel user_id
allocation_to_allocation_mappingobjectnoMapping of Pterodactyl allocation_id to FeatherPanel allocation_id
variable_to_variable_mappingobjectnoMapping of Pterodactyl egg_variable_id to FeatherPanel spell_variable_id
server_to_server_mappingobjectnoMapping of Pterodactyl server_id to FeatherPanel server_id (for parent_id)
Response data fieldTypeDescription
serverobjectCreated server data
variables_importedintegerNumber of server variables imported
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-server" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"server":{},"server_variables":[],"nest_to_realm_mapping":{},"egg_to_spell_mapping":{},"node_to_node_mapping":{},"user_to_user_mapping":{},"allocation_to_allocation_mapping":{},"variable_to_variable_mapping":{},"server_to_server_mapping":{}}'

Plugin events: featherpanel:server:created

Responses: 201 Server imported successfully · 400 Bad request - Invalid data, missing required fields, or invalid mappings · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 Node, user, allocation, realm, or spell not found · 409 Conflict - Server with UUID or ID already exists · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-server-database

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-server-databaseController: PterodactylImporterController::importServerDatabaseroute source

Import Pterodactyl server database Import a Pterodactyl server database as a FeatherPanel server database. Maps server_id and database_host_id.

Body fieldTypeRequiredDescription
databaseobjectyesPterodactyl server database data
server_to_server_mappingobjectnoMapping of Pterodactyl server_id to FeatherPanel server_id
database_host_to_database_host_mappingobjectnoMapping of Pterodactyl database_host_id to FeatherPanel database_host_id
Response data fieldTypeDescription
databaseobjectCreated server database data
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-server-database" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"database":{},"server_to_server_mapping":{},"database_host_to_database_host_mapping":{}}'

Responses: 201 Server database imported successfully · 400 Bad request - Invalid data, missing required fields, or invalid mappings · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 Server or database host not found · 409 Conflict - Database already exists for this server · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-backup

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-backupController: PterodactylImporterController::importBackuproute source

Import Pterodactyl backup Import a backup from Pterodactyl to FeatherPanel. Maps server_id using provided mapping and preserves original backup ID, UUID, and metadata.

Body fieldTypeRequiredDescription
backupobjectyesPterodactyl backup data
server_to_server_mappingobjectyesMapping of Pterodactyl server IDs to FeatherPanel server IDs
Response data fieldTypeDescription
backupobjectImported backup data
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-backup" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"backup":{},"server_to_server_mapping":{}}'

Responses: 201 Backup imported successfully · 400 Bad request - Invalid JSON, missing required fields, or validation errors · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 Server not found · 409 Conflict - Backup with UUID or ID already exists · 500 Internal server error - Failed to import backup

POST/api/admin/pterodactyl-importer/import-subuser

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-subuserController: PterodactylImporterController::importSubuserroute source

Import Pterodactyl subuser Import a subuser from Pterodactyl to FeatherPanel. Maps user_id and server_id using provided mappings and preserves original subuser ID and permissions.

Body fieldTypeRequiredDescription
subuserobjectyesPterodactyl subuser data
user_to_user_mappingobjectyesMapping of Pterodactyl user IDs to FeatherPanel user IDs
server_to_server_mappingobjectyesMapping of Pterodactyl server IDs to FeatherPanel server IDs
Response data fieldTypeDescription
subuserobjectImported subuser data
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-subuser" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"subuser":{},"user_to_user_mapping":{},"server_to_server_mapping":{}}'

Responses: 201 Subuser imported successfully · 400 Bad request - Validation errors · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 409 Conflict - Subuser already exists · 500 Internal server error

POST/api/admin/pterodactyl-importer/import-schedule

Auth: AdminPermission: admin.rootRoute name: admin-pterodactyl-importer-import-scheduleController: PterodactylImporterController::importScheduleroute source

Import Pterodactyl schedule Import a schedule from Pterodactyl to FeatherPanel. Maps server_id using provided mapping and preserves original schedule ID, cron settings, and timestamps. Calculates next_run_at if not provided.

Body fieldTypeRequiredDescription
scheduleobjectyesPterodactyl schedule data
server_to_server_mappingobjectyesMapping of Pterodactyl server IDs to FeatherPanel server IDs
Response data fieldTypeDescription
scheduleobjectImported schedule data
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-schedule" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"schedule":{},"server_to_server_mapping":{}}'

Responses: 201 Schedule imported successfully · 400 Bad request - Invalid JSON, missing required fields, or validation errors · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 Server not found · 409 Conflict - Schedule with ID already exists · 500 Internal server error - Failed to import schedule

POST/api/admin/pterodactyl-importer/import-task

Auth: AdminPermission: admin.servers.createRoute name: admin-pterodactyl-importer-import-taskController: PterodactylImporterController::importTaskroute source

Import Pterodactyl task Import a task from Pterodactyl to FeatherPanel. Maps schedule_id using provided mapping and preserves original task ID, sequence, action, payload, and other settings.

Body fieldTypeRequiredDescription
taskobjectyesPterodactyl task data
schedule_to_schedule_mappingobjectyesMapping of Pterodactyl schedule IDs to FeatherPanel schedule IDs
Response data fieldTypeDescription
taskobjectImported task data
curl -X POST "$PANEL_URL/api/admin/pterodactyl-importer/import-task" \
  -H "Authorization: Bearer $FEATHERPANEL_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"task":{},"schedule_to_schedule_mapping":{}}'

Responses: 201 Task imported successfully · 400 Bad request - Invalid JSON, missing required fields, or validation errors · 401 Unauthorized · 403 Forbidden - Insufficient permissions · 404 Schedule not found · 409 Conflict - Task with ID already exists · 500 Internal server error - Failed to import task