Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Bretterklieber committed Jun 4, 2018
2 parents b29b262 + 99a5fa8 commit a4863f4
Showing 1 changed file with 25 additions and 1 deletion.
26 changes: 25 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,28 @@

ACME2 low level php library

in beta state dont use it at the moment
This library has been built to be integrated into applications, not as standalone acme client.

Benefits:

* no dependencies like curl or other packages
* it comes up with a builtin httpclient, but any other PSR7 compliant http client may be used
* it uses standard classes, but you can use your own data objects

## setup new account

```php
use Karl\Acme2;
use Karl\Acme2\Resources;

$acme = new Acme2\Acme();

$key = new Acme2\Key\RSA();
$key->generate();
$pem = $key->getPem(); // store your key somewhere

$acme->setKey($key); // acme needs a key to operate

$account = new Resources\Account($acme);
$account->create(['termsOfServiceAgreed' => true, 'contact' => ['mailto:example@example.com']]);
```

0 comments on commit a4863f4

Please sign in to comment.