Skip to content

Cores ​

Xray core configuration and control.

12 endpoints

GET /api/core ​

Get Core Stats

Retrieve core statistics such as version and uptime.

Any admin

Response 200 Successful Response · CoreStats

Response fields
FieldTypeDescription
versionstring
startedboolean
logs_websocketstring
json
{
  "version": "string",
  "started": false,
  "logs_websocket": "string"
}

Errors: 401 Unauthorized

bash
curl -X GET 'https://YOUR-PANEL/api/core' \
  -H 'Authorization: Bearer $TOKEN'

GET /api/core/config ​

Get Core Config

Get the current core configuration.

Sudo admin only

Response 200 Successful Response · object

json
{}

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X GET 'https://YOUR-PANEL/api/core/config' \
  -H 'Authorization: Bearer $TOKEN'

PUT /api/core/config ​

Modify Core Config

Modify the core configuration and restart the core.

Sudo admin only

Request body application/json · object

json
{}

Response 200 Successful Response · object

json
{}

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X PUT 'https://YOUR-PANEL/api/core/config' \
  -H 'Authorization: Bearer $TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{}'

POST /api/core/outbound-from-link ​

Outbound From Link

Turn a vless/vmess/trojan/ss/hysteria2 share link into an Xray outbound.

Sudo admin only

Request body application/json · OutboundLink

FieldTypeRequiredDescription
linkstringyes
tagstringno
json
{
  "link": "string",
  "tag": "string"
}

Response 200 Successful Response · object

json
{}

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X POST 'https://YOUR-PANEL/api/core/outbound-from-link' \
  -H 'Authorization: Bearer $TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"link": "string", "tag": "string"}'

POST /api/core/restart ​

Restart Core

Restart the core and all connected nodes.

Sudo admin only

Response 200 Successful Response

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X POST 'https://YOUR-PANEL/api/core/restart' \
  -H 'Authorization: Bearer $TOKEN'

GET /api/core/x25519 ​

Generate X25519

A fresh x25519 key pair for a REALITY inbound.

Sudo admin only

Response 200 Successful Response · object

json
{}

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X GET 'https://YOUR-PANEL/api/core/x25519' \
  -H 'Authorization: Bearer $TOKEN'

GET /api/cores ​

List Cores

List the main core and the extra cores nodes can run.

Sudo admin only

Response 200 Successful Response · CoreInfo[]

Response fields
FieldTypeDescription
idstring
namestring
inboundsstring[]
json
[
  {
    "id": "string",
    "name": "string",
    "inbounds": [
      "string"
    ]
  }
]

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X GET 'https://YOUR-PANEL/api/cores' \
  -H 'Authorization: Bearer $TOKEN'

POST /api/cores ​

Create Core

Add an extra core, from a given config or a copy of another core.

Sudo admin only

Request body application/json · CoreCreate

FieldTypeRequiredDescription
namestringyes
configobjectno
copy_fromstringnoDefault: "main".
json
{
  "name": "string",
  "config": {},
  "copy_from": "main"
}

Response 200 Successful Response · CoreInfo

Response fields
FieldTypeDescription
idstring
namestring
inboundsstring[]
json
{
  "id": "string",
  "name": "string",
  "inbounds": [
    "string"
  ]
}

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X POST 'https://YOUR-PANEL/api/cores' \
  -H 'Authorization: Bearer $TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"name": "string", "config": {}, "copy_from": "main"}'

PUT /api/cores/{core_id} ​

Rename Core

Rename an extra Xray core.

Sudo admin only

Parameters

NameInTypeRequiredDescription
core_idpathstringyes

Request body application/json · CoreModify

FieldTypeRequiredDescription
namestringno
json
{
  "name": "string"
}

Response 200 Successful Response · CoreInfo

Response fields
FieldTypeDescription
idstring
namestring
inboundsstring[]
json
{
  "id": "string",
  "name": "string",
  "inbounds": [
    "string"
  ]
}

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X PUT 'https://YOUR-PANEL/api/cores/<core_id>' \
  -H 'Authorization: Bearer $TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"name": "string"}'

DELETE /api/cores/{core_id} ​

Delete Core

Delete an extra core; its nodes go back to the main core.

Sudo admin only

Parameters

NameInTypeRequiredDescription
core_idpathstringyes

Response 200 Successful Response

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X DELETE 'https://YOUR-PANEL/api/cores/<core_id>' \
  -H 'Authorization: Bearer $TOKEN'

GET /api/cores/{core_id}/config ​

Get Extra Core Config

Get the Xray configuration of an extra core.

Sudo admin only

Parameters

NameInTypeRequiredDescription
core_idpathstringyes

Response 200 Successful Response · object

json
{}

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X GET 'https://YOUR-PANEL/api/cores/<core_id>/config' \
  -H 'Authorization: Bearer $TOKEN'

PUT /api/cores/{core_id}/config ​

Modify Extra Core Config

Save a core's config and restart the nodes running it.

Sudo admin only

Parameters

NameInTypeRequiredDescription
core_idpathstringyes

Request body application/json · object

json
{}

Response 200 Successful Response · object

json
{}

Errors: 401 Unauthorized, 403 Forbidden

bash
curl -X PUT 'https://YOUR-PANEL/api/cores/<core_id>/config' \
  -H 'Authorization: Bearer $TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{}'

Alexen v2.3.14 · 204 API endpoints