Download the PHP package hypernic/nawala without Composer
On this page you can find all versions of the php package hypernic/nawala. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package nawala
Hypernic Nawala
A PHP library to check whether a website or domain is blocked in Indonesia.
Requirements
- PHP >= 8.0
curl,jsonintloptional for IDN domains
Installation
`
Quick Start
index.php:
Example output (success, not blocked):
Example output (success, blocked):
Example output (invalid input):
API
Class: Hypernic\Nawala
__construct(array $config = [])
Config options:
timeout(int, default15): request timeout.connect_timeout(int, default10): connection timeout.retries(int, default1): retry count for transient errors (408, 429, 5xx).
check(string $domain): array
- Normalizes the domain (lowercase, strips scheme, trims trailing dot).
- Supports IDN via
intlwhen available. -
Calls the Komdigi endpoint and maps result:
blocked = truewhenStatus === "Ada".
How It Works
- Data source:
https://trustpositif.komdigi.go.id. -
Flow:
- Normalize domain + IDN handling.
- POST to the public endpoint.
- Pick the most relevant row and determine
blocked.
Note: The upstream service may change without notice. Handle network failures and schema changes in your application.
Testing
This project includes PHPUnit tests.
Notes
- Subject to Komdigi availability and rate limits.
- Upstream HTML/token/endpoint changes may require library updates.
- Results reflect the status at query time only.
All versions of nawala with dependencies
PHP Build Version
Package Version
The package hypernic/nawala contains the following files
Loading the files please wait ...