Allow services to have multiple api keys.

/service/<service_id>/api-key/renew has been renamed to /service/<service_id>/api-key
/service/<service_id>/api-key now creates a token and no longer expires the existing api key.
Moved test for this endpoint to it's own file.
This commit is contained in:
Rebecca Law
2016-01-20 10:57:46 +00:00
parent 1db57dca8c
commit 27a381c3e9
5 changed files with 180 additions and 103 deletions

View File

@@ -57,7 +57,7 @@ def fetch_client(client):
if client == current_app.config.get('ADMIN_CLIENT_USER_NAME'):
return {
"client": client,
"secret": current_app.config.get('ADMIN_CLIENT_SECRET')
"secret": [current_app.config.get('ADMIN_CLIENT_SECRET')]
}
else:
return {