~ knotless Search/
↑↓ move↵ open⇧↵ all results
0
0

Moving a group and revoking a token name their errors

Merged chadtmiller.com asked to merge into main from chadtmiller.com/group-host:lexicons/method-errors
.changeset/migration-method-errors.mdnew+7−0
@@ -0,0 +1,7 @@
---
default: patch
---
# Moving a group and revoking a token name their errors
The lexicons of `org.atgrp.internal.migratePrepare`, `migrateReceive`, `migrateComplete`, `migrateActivate` and `revokeGroupToken` now list the errors each answers beyond those any method may, with when, so a client can tell one refusal from another by its name: `NotController`, `NotAllowed`, `AlreadyHere`, `BadServiceJwt`, `HandleNotAvailable`, `SourceUnreadable`, `InvalidOperation`, `NotYet` and `NotFound`.
lexicons/org/atgrp/internal/migrateActivate.json+11−1
@@ -30,7 +30,17 @@
}
}
}
}
},
"errors": [
{
"name": "NotYet",
"description": "The group's DID document doesn't yet name this host and the signing key made here: ask again once the directory catches up."
},
{
"name": "SourceUnreadable",
"description": "The group's DID document couldn't be read."
}
]
}
}
}
lexicons/org/atgrp/internal/migrateComplete.json+11−1
@@ -32,7 +32,17 @@
}
}
}
}
},
"errors": [
{
"name": "NotController",
"description": "The group's DID is ended, or the PLC directory's last operation for it no longer lists this host's rotation key."
},
{
"name": "InvalidOperation",
"description": "The PLC directory refused the operation, as when another was made first: ask again."
}
]
}
}
}
lexicons/org/atgrp/internal/migratePrepare.json+7−1
@@ -42,7 +42,13 @@
}
}
}
}
},
"errors": [
{
"name": "NotController",
"description": "The PLC directory's last operation for the group no longer lists this host's rotation key."
}
]
}
}
}
lexicons/org/atgrp/internal/migrateReceive.json+23−1
@@ -56,7 +56,29 @@
}
}
}
}
},
"errors": [
{
"name": "NotAllowed",
"description": "This host doesn't start groups for the caller."
},
{
"name": "AlreadyHere",
"description": "The group is on this host already."
},
{
"name": "BadServiceJwt",
"description": "serviceJwt isn't one the group signed, by its current key, for this host's migrateReceive."
},
{
"name": "HandleNotAvailable",
"description": "The group's address or handle is taken on this host."
},
{
"name": "SourceUnreadable",
"description": "The group's DID document, or the host it's leaving, couldn't be read, or answered with a failure or more than this host reads."
}
]
}
}
}
lexicons/org/atgrp/internal/revokeGroupToken.json+7−1
@@ -31,7 +31,13 @@
"type": "object",
"properties": {}
}
}
},
"errors": [
{
"name": "NotFound",
"description": "The group has no grant by that tokenId."
}
]
}
}
}