schema/workerschema: add refresh token revocation endpoints to API

This commit is contained in:
Eric Chiang 2016-04-06 11:27:06 -07:00
parent ab4cbe7219
commit b7f663b520

View file

@ -49,6 +49,37 @@
} }
} }
}, },
"RefreshClient": {
"id": "Client",
"type": "object",
"description": "A client with associated public metadata.",
"properties": {
"clientID": {
"type": "string"
},
"clientName": {
"type": "string"
},
"logoURI": {
"type": "string"
},
"clientURI": {
"type": "string"
}
}
},
"RefreshClientList": {
"id": "RefreshClientList",
"type": "object",
"properties": {
"clients": {
"type": "array",
"items": {
"$ref": "RefreshClient"
}
}
}
},
"ClientWithSecret": { "ClientWithSecret": {
"id": "Client", "id": "Client",
"type": "object", "type": "object",
@ -235,6 +266,27 @@
"response": { "response": {
"$ref": "ClientWithSecret" "$ref": "ClientWithSecret"
} }
},
"Revoke": {
"id": "dex.Client.Revoke",
"description": "Revoke all refresh tokens issues to the client for the authenticated user.",
"httpMethod": "DELETE",
"path": "account/{userid}/refresh/{clientid}",
"parameterOrder": [
"userid","clientid"
],
"parameters": {
"clientid": {
"type": "string",
"required": true,
"location": "path"
},
"userid": {
"type": "string",
"required": true,
"location": "path"
}
}
} }
} }
}, },
@ -335,6 +387,29 @@
} }
} }
} }
},
"RefreshClient": {
"methods": {
"List": {
"id": "dex.Client.List",
"description": "List all clients that hold refresh tokens for the authenticated user.",
"httpMethod": "GET",
"path": "account/{userid}/refresh",
"parameters": {
"userid": {
"type": "string",
"required": true,
"location": "path"
}
},
"parameterOrder": [
"userid"
],
"response": {
"$ref": "RefreshClientList"
}
}
}
} }
} }
} }