Download the PHP package novada/sdk without Composer
On this page you can find all versions of the php package novada/sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Package sdk
Short Description Official PHP SDK for the Novada API (proxy management, scraping, wallet).
License MIT
Homepage https://github.com/NovadaLabs/novada-php
Informations about the package sdk
novada-php
PHP SDK for the Novada API — proxy management, scraping, and wallet endpoints. PHP 8.1+, PSR-18/PSR-17 HTTP client agnostic (no Guzzle hard dependency).
Install
The SDK talks HTTP through PSR-18 (psr/http-client) and PSR-17 factories, discovered automatically via php-http/discovery. If your project doesn't already have a PSR-18 client installed, pull in Guzzle:
You can also inject your own PSR-18 client/PSR-17 factories via ClientConfig — see Configuration below.
Quick start
Configuration
All fields are optional and have production defaults. The Bearer API key is injected on every request. Retries apply only to network errors and HTTP 429/5xx — never to a non-zero business code.
The three base URLs
Novada serves requests from three hosts. All are configurable via ClientConfig and default to production:
| Purpose | Default | Used by |
|---|---|---|
| General | https://api-m.novada.com |
Every /v1/* endpoint (proxy, wallet, and the scraper area/balance/unit queries) |
| Web Unblocker | https://webunlocker.novada.com |
$client->scraper->unblocker->scrape() (typed), or ->scraper->do() with Target::WebUnblocker |
| Scraper API | https://scraper.novada.com |
->scraper->do() / ->scraper->api->* with Target::ScraperApi |
Only the scrape POST /request calls go to the Web Unblocker / Scraper API hosts; everything else (/v1/*) uses the general host.
Proxy
Sub-services: account, whitelist, residential, mobile, rotatingIsp, rotatingDc, staticIsp, dedicatedDc, unlimited, prohibitDomain. Required parameters are validated client-side and reported as a Novada\Exception\ValidationException before any request is sent.
Scraper
$client->scraper->do() JSON-encodes params, places it in the scraper_params form field, URL-encodes the body, and routes to the host selected by target. Scrape responses are returned raw because their format varies by scraper. $client->scraper->unblocker->scrape() is the dedicated Web Unblocker call: it sends the endpoint's own fields (target_url, response_format, js_render, country, wait_ms, …) and decodes the JSON envelope into a structured UnblockerResult (html, code, msg, msgDetail, useBalance).
Wallet
Error handling
Management endpoints return a uniform envelope {code, data, msg, timestamp}; only code === 0 is success. A non-zero code or a non-2xx HTTP status becomes a Novada\Exception\ApiException.
Examples
Runnable examples live in wallet.php. Set NOVADA_API_KEY and run e.g. php examples/proxy.php.
Development
License
MIT
All versions of sdk with dependencies
psr/http-client Version ^1.0
psr/http-factory Version ^1.0 || ^1.1
psr/http-message Version ^1.0 || ^1.1 || ^2.0
php-http/discovery Version ^1.19