summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarpenter, Adam (CORP) <adam.carpenter@adp.com>2021-12-10 11:35:06 -0500
committerCarpenter, Adam (CORP) <adam.carpenter@adp.com>2021-12-10 11:35:06 -0500
commitf98a1fa3035fb4834441ead1cce6710739312e14 (patch)
treee10ec339108a8f8dbd2dd0f4737d580a0fc26ac1
parent20b58ca9ded468e113bf5fdda795f3bc9a732cc2 (diff)
downloadaltruistic-angelshark-f98a1fa3035fb4834441ead1cce6710739312e14.tar.xz
altruistic-angelshark-f98a1fa3035fb4834441ead1cce6710739312e14.zip
docs: add readme for deprov
-rw-r--r--angelsharkd/src/routes/extensions/simple_deprov/README.md61
1 files changed, 61 insertions, 0 deletions
diff --git a/angelsharkd/src/routes/extensions/simple_deprov/README.md b/angelsharkd/src/routes/extensions/simple_deprov/README.md
new file mode 100644
index 0000000..4900075
--- /dev/null
+++ b/angelsharkd/src/routes/extensions/simple_deprov/README.md
@@ -0,0 +1,61 @@
+# Daemon Extension `simple_deprov`
+
+This extension implements excruciatingly simple extension de-provisioning. For
+example, if an agent was provisioned with a `station-user` and an
+`agent-loginid`, you can submit those extensions, their type, and the ACM they
+were provision on. They relevant commands to remove those objects will be
+executed in parallel, and any errors encountered will be returned.
+
+## Getting Started
+
+To enable this feature, compile `angelsharkd` with the `simple_deprov` flag:
+
+```sh
+cargo build --bin angelsharkd --features simple_deprov ...
+```
+
+## `POST /extensions/deprov` Remove Objects
+
+The request type is TODO:
+
+```json
+POST /extensions/deprov
+[
+ {
+ "station-user": {
+ "acm": "01",
+ "ext": "17571230000"
+ }
+ },
+ {
+ "agent-loginid": {
+ "acm": "01",
+ "ext": "17571240000"
+ }
+ }
+]
+```
+
+If all of the deprov commands were successful, the response is an empty array.
+
+```json
+200 OK
+[]
+```
+
+If there were errors running the relevant deprov commands (such as when an
+extension does not exist), they are included in the resulting array.
+
+```json
+200 OK
+[
+ "ACM lab: 1 00000000 309e Extension exists but assigned to a different object",
+ "ACM lab: 1 00000000 2ed5 Extension assigned as remote extension on the uniform-dialplan form",
+ "ACM lab: 1 00000000 2ed5 Extension assigned as remote extension on the uniform-dialplan form"
+]
+```
+
+## Logging
+
+The `deprov` endpoint always returns successfully. Any errors encountered during
+the command execution are logged as `ERROR`.