{ "lexicon": 1, "id": "sh.tangled.repo.checkPushAllowed", "defs": { "main": { "type": "query", "description": "Check whether the holder of a public key is allowed to push to a repo.", "parameters": { "type": "params", "required": ["repo", "key"], "properties": { "repo": { "type": "string", "description": "A repo DID." }, "key": { "type": "string", "maxLength": 4096, "description": "Public key in OpenSSH authorized_keys format." } } }, "output": { "encoding": "application/json", "schema": { "type": "object", "required": ["allowed"], "properties": { "allowed": { "type": "boolean", "description": "Whether the key's owner may push to the repo." }, "did": { "type": "string", "format": "did", "description": "DID the key resolved to, if a match was found." } } } }, "errors": [ { "name": "RepoNotFound", "description": "The repo could not be resolved on this knot." }, { "name": "InvalidRequest", "description": "Missing or malformed parameters." } ] } } }