mirror of
https://github.com/YGGverse/web-api.git
synced 2026-03-31 09:35:30 +00:00
Web API tools with native Yggdrasil/IPv6 support
| src/public | ||
| .gitignore | ||
| composer.json | ||
| composer.lock | ||
| LICENSE | ||
| README.md | ||
net-api
Simple Network Tools API
Install
git clone https://github.com/YGGverse/net-api.git
cd net-api
composer install
Run
cd src/public
php -S localhost:8080
Usage
Socket
Check socket
Usage
Attributes
port- requiredhost- optional, name, IPv4 or IPv6REMOTE_ADDRby default
Request
GET socket.php?port=80&host=yo.index
Response
JSON
{
success: bool
}
Dig
Show host records
Usage
Attributes
name- required host name, IPv4 or IPv6record- required ifrecordsnot providedrecords- required ifrecordnot provided
Records support
- A
- AAAA
- SRV #1
Request
Single record
GET dig.php?name=yo.index&record=A
Multiple records
GET dig.php?name=yo.index&records[]=A&records[]=AAAA
Response
JSON
{
success: bool
records: array
}