https://github.com/roxy-wi/pyminitcp
A tiny, dependency-free Python library for TCP connectivity checks with IPv4/IPv6 and DNS support.
https://github.com/roxy-wi/pyminitcp
Last synced: 11 months ago
JSON representation
A tiny, dependency-free Python library for TCP connectivity checks with IPv4/IPv6 and DNS support.
- Host: GitHub
- URL: https://github.com/roxy-wi/pyminitcp
- Owner: roxy-wi
- License: mit
- Created: 2025-07-04T08:08:00.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2025-07-04T09:11:28.000Z (11 months ago)
- Last Synced: 2025-07-04T09:28:36.300Z (11 months ago)
- Language: Python
- Size: 4.88 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# pyminitcp




A tiny, dependency-free Python library for TCP connectivity checks with IPv4/IPv6 and DNS support.
## Features
- Checks TCP connectivity for IPv4, IPv6, or domain names
- Distinguishes between address families automatically
- Returns response time and detailed error info
## Usage
```python
from pyminitcp import tcp_check
result = tcp_check('google.com', 443)
print(result.as_dict())
```
## Result
```python
{
"status": 1,
"resp_time": 10.468006134033203,
"error": "",
"family": 2,
"sockaddr": [
"74.125.205.139",
80
]
}
```
## CLI Usage
```sh
pyminitcp google.com 443
pyminitcp 8.8.8.8 53 --timeout 1
pyminitcp --json example.com 80
```