├── docs
├── .nojekyll
├── _navbar.md
├── _media
│ └── v2ray.png
├── _coverpage.md
├── index.html
├── index.md
├── app.css
└── how-to-use.md
├── .idea
├── vcs.xml
├── .gitignore
├── modules.xml
├── v2ray-api-php.iml
├── deployment.xml
├── php.xml
└── inspectionProfiles
│ └── Project_Default.xml
├── README.md
├── class
├── .xuiConfig.json
└── xuiConnect.php
└── LICENSE
/docs/.nojekyll:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/docs/_navbar.md:
--------------------------------------------------------------------------------
1 | * [Home](/)
2 | * [Doc](/how-to-use)
--------------------------------------------------------------------------------
/docs/_media/v2ray.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobinjavari/v2ray-api-php/HEAD/docs/_media/v2ray.png
--------------------------------------------------------------------------------
/docs/_coverpage.md:
--------------------------------------------------------------------------------
1 |
2 |
3 | # V2ray API Core1.1
4 |
5 | [GitHub](https://github.com/mobinjavari/v2ray-api-php/)
6 | [Get Started](/how-to-use)
7 |
--------------------------------------------------------------------------------
/.idea/vcs.xml:
--------------------------------------------------------------------------------
1 |
2 |
Contact me to participate in project development or become a sponsor
4 |A functional class for 3X-UI API
6 || Project | 10 |Description | 11 |Links | 12 |
|---|---|---|
| 👉 V2Ray API | 17 |API Wrapper for 3x-ui and x-ui panel | 18 |19 | Github / 20 | Docs 21 | | 22 |
| Marzban API | 25 |API Wrapper for Marzban panel | 26 |27 | Github 28 | | 29 |
| Marzneshin API | 32 |API Wrapper for Marzneshin panel | 33 |34 | Github 35 | | 36 |
bc1qsmc7jy5vv7s8wscfj0kvwv9j43wmyfwxwlc8eu Trust Wallet
28 |
29 | DOGE D8f4nTWebeDrSHRjHk4YFXawtcJJfMw1Xg Trust Wallet
30 |
31 | USDT (TRC20) TJsJgQfNSPrGJW9CMsU47nCYzDBJoaDd9L Trust Wallet
32 |
33 | USDT (BEP20) 0x4Dab2E702D08a1a8BC793EB8fdaBA91b62DB8C1C Trust Wallet
34 |
35 | USDT (PLYGON) 0x4Dab2E702D08a1a8BC793EB8fdaBA91b62DB8C1C Trust Wallet
36 |
37 | SHIB (BEP20) 0x4Dab2E702D08a1a8BC793EB8fdaBA91b62DB8C1C Trust Wallet
38 |
39 | | ☑️ Variable | 21 |🗂️ Data Type | 22 |✔️ Sample correct input | 23 |❌ Sample wrong input | 24 |🧾 Description | 25 |
|---|---|---|---|---|
| $serverAddress | 28 |string | 29 |
30 | api://example.org:54321/31 | api://10.10.10.10:54321/
32 | |
33 |
34 | https://example.org:54321/35 | http://10.10.10.10:54321/
36 | |
37 | Server address and port on which the panel is installed | 38 |
| $tunnelServerAddress | 41 |string | 42 |
43 | api://example.org:54321/44 | api://10.10.10.10:54321/
45 | |
46 |
47 | https://example.org:54321/48 | http://10.10.10.10:54321/
49 | |
50 | Tunnel server address and panel port (if there is no tunnel, leave its value null) |
51 |
| $username | 54 |string | 55 |admin |
56 | - | 57 |Username to login to the panel | 58 |
| $password | 61 |string | 62 |admin |
63 | - | 64 |Password to enter the panel | 65 |
| $panel | 68 |int | 69 |1 |
70 | - | 71 |Specifying the panel type, enter the value 1 for the Sinai panel (3xui) and the value 0 for the Chinese or English panel (xui). |
72 |
| 📘 Name | 81 |📤 Return | 82 |🧾 Description | 83 |
|---|---|---|
| status | 86 |array | 87 |It returns the status of the server, including upload and download information, etc. in the form of an array | 88 |
| 📘 Name | 98 |📩 Inputs | 99 |📤 Return | 100 |🧾 Description | 101 |
|---|---|---|---|
| setDefaultProtocol | 104 |$protocol (string) |
105 | void | 106 |Changing the default protocol value, values vless , vmess , trojan can be used. |
107 |
| setDefaultTransmission | 110 |$transmission (string) |
111 | void | 112 |Changing the default transmission value, values ws, tcp can be used. |
113 |
| setDefaultHeader | 116 |$header (string) |
117 | void | 118 |To change the default header, used in the config link | 119 |
| setSniffing | 122 |
123 | $enable (bool) 124 | $destOverride (array)
125 | |
126 | void | 127 |Setting the sniffing value receives a boolean value in the first input and an array containing http, tls, quic... in the second input. |
128 |
| deleteCookie | 131 |- | 132 |void | 133 |To delete the set cookie (used if the speed of sending and receiving information is slow) | 134 |
| createUrl | 137 |
138 | $where (array)
139 | 140 | $customRemark (string)
141 | |
142 | array | 143 |It is used to create the url (config link) of the user, in the first input, the provided value is used to bet the user's key information (uuid, email, port...) and in the second input, it takes the personalized remark value, which is by default has the null value |
144 |
| add | 149 |
150 | $total (float)
151 | 152 | $expiryDays (int)
153 | 154 | $protocol (string|null)
155 | 156 | $transmission (string|null)
157 | 158 | $xuiRemark (string|null)
159 | |
160 | array | 161 |It is used to add a user to the panel, the $total input gets the volume in gigabytes, the input $expiryDays receives the expiration date as a number such as 30 days, the default value is 0, which means infinity., $xuiRemark input is 0 (Chinese,..) for panels. |
162 |
| update | 165 |
166 | $update (array)
167 | 168 | $where (array)
169 | |
170 | array | 171 |Used to update user information, $update entry contains an array of changes, $where entry contains an array that specifies It allows the update to be applied to which user or users |
172 |
| fetch | 175 |$where (array) |
176 | array | 177 |Used to get user information, the $fetch entry takes an array of unique user information and returns the first user found. |
178 |
| delete | 181 |
182 | $where (array)
183 | 184 | $toDate (int)
185 | |
186 | array | 187 |It is used to delete the user from the panel, the first input is the condition of the users who are deleted and the second input is the users whose expiration date is $toDate, which is null by default and all users which includes $where, deletes it |
188 |