Skip to content
This repository was archived by the owner on Oct 22, 2025. It is now read-only.

Commit 22ab436

Browse files
Update README.md
1 parent 95250c5 commit 22ab436

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,25 @@ _THIS PROJECT IN DEVELOPMENT. DON'T USE IT IN PRODUCTION_
2020
* Add package `composer require pavlusha311245/unit-php-sdk`
2121

2222
Congratulations! You installed package. Now you can use the full power of this SDK.
23+
24+
* Create `index.php` file
25+
* Paste code and change this line `socket: <your socket path to Nginx Unit>` for your configuration
26+
```php
27+
<?php
28+
29+
use Pavlusha311245\UnitPhpSdk\Unit;
30+
31+
require '../vendor/autoload.php';
32+
33+
$unit = new Unit(
34+
socket: <your socket path to Nginx Unit>,
35+
address: 'http://localhost'
36+
);
37+
38+
$unit->getConfig();
39+
```
40+
* Run index.php
41+
2342
#### Happy coding 😊
2443

2544
## Documentation

0 commit comments

Comments
 (0)