1
0
Fork 0
mirror of synced 2024-06-26 18:20:43 +12:00

Merge remote-tracking branch 'origin/feat-expire-key' into feat-expire-key

# Conflicts:
#	app/controllers/api/projects.php
This commit is contained in:
shimon 2022-06-01 13:11:24 +03:00
commit 0c435b9c3b
2 changed files with 2 additions and 2 deletions

View file

@ -885,7 +885,7 @@ App::put('/v1/projects/:projectId/keys/:keyId')
->param('keyId', null, new UID(), 'Key unique ID.')
->param('name', null, new Text(128), 'Key name. Max length: 128 chars.')
->param('scopes', null, new ArrayList(new WhiteList(array_keys(Config::getParam('scopes')), true), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Key scopes list. Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' events are allowed.')
->param('expire', 0, new Integer() , 'Key expiration timestamp' ,true)
->param('expire', null, new Integer() , 'Key expiration timestamp', true)
->inject('response')
->inject('dbForConsole')
->action(function (string $projectId, string $keyId, string $name, array $scopes, int $expire, Response $response, Database $dbForConsole) {

View file

@ -29,7 +29,7 @@ class Key extends Model
])
->addRule('expire', [
'type' => self::TYPE_INTEGER,
'description' => 'Key expiration .',
'description' => 'Key expiration timestamp.',
'default' => 0,
'example' => '1653990687',
])