Skip to content

Commit 6f47e35

Browse files
committed
Update simpleid-tool documentation
1 parent 831511a commit 6f47e35

1 file changed

Lines changed: 32 additions & 2 deletions

File tree

docs/2/simpleid-tool.md

Lines changed: 32 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,34 @@ eleventyNavigation:
99
order: 40
1010
---
1111

12-
1312
`simpleid-tool` is a command-line tool that performs various maintenance functions.
1413

1514
## Installing {#installing}
1615

1716
The tool can be installed using Composer:
1817

1918
```shell
20-
composer require simpleid/simpleid-tool:dev-master
19+
composer require simpleid/simpleid-tool
20+
```
21+
22+
## Basic usage {#basic}
23+
24+
`simpleid-tool` contains a collection of different commands. The basic syntax for running a command is as follows:
25+
26+
```shell
27+
php simpleid-tool.phar [command] [options]
28+
```
29+
30+
You can list the available commands using the `list` command:
31+
32+
```shell
33+
php simpleid-tool.phar list
34+
```
35+
36+
You can get help on each command by using the `help` command:
37+
38+
```shell
39+
php simpleid-tool.phar help [command]
2140
```
2241

2342
## Encoding passwords {#passwd}
@@ -57,3 +76,14 @@ php simpleid-tool.phar migrate-user [example.identity]
5776
The tool will then migrate as much of the data in the identity file as it can into a new SimpleID 2 user file, which is displayed.
5877

5978
Note that in most cases, the password stored in a SimpleID 1 identity file will *not* meet the password requirements for SimpleID 2. In these cases you will need to re-encode your password (e.g. via [simpleid-tool](#passwd)) insert it into the new user file.
79+
80+
## Calling SimpleID API endpoints {#api}
81+
`simpleid-tool` can be used to call endpoints made available by the SimpleID API. This can be invoked using the following command:
82+
83+
```shell
84+
php simpleid-tool.phar api -d [simpleid-dir] -- [route] [params ...]
85+
```
86+
87+
`[simpleid-dir]` should be replaced with the location of the `www` directory of the SimpleID installation (i.e where `index.php` is located.
88+
89+
The `[route]` and `[params]` parameters should be replaced with the API endpoint and GET parameters, using the syntax set out in [Fat-Free Framework documentation](https://fatfreeframework.com/3.9/routing-engine#RoutinginCLImode). If you are using the shell syntax, note that you will need to add a `--` before specifying the endpoint parameters, so that those parameters are not interpreted by `simpleid-tool`.

0 commit comments

Comments
 (0)