Code + comment cleanup for the response models

ref #39
This commit is contained in:
2020-12-20 19:38:22 +01:00
parent a85d52437b
commit 75332983c2
13 changed files with 83 additions and 91 deletions

View File

@@ -1,26 +1,29 @@
import { IsInt, IsString } from 'class-validator';
/**
* Defines a auth object
* Defines the repsonse auth.
*/
export class Auth {
/**
* access_token - JWT shortterm access token
* The access_token - JWT shortterm access token.
*/
@IsString()
access_token: string;
/**
* refresh_token - longterm refresh token (used for requesting new access tokens)
* The refresh_token - longterm refresh token (used for requesting new access tokens).
*/
@IsString()
refresh_token: string;
/**
* access_token_expires_at - unix timestamp of access token expiry
* The unix timestamp for access the token's expiry.
*/
@IsInt()
access_token_expires_at: number;
/**
* refresh_token_expires_at - unix timestamp of access token expiry
* The unix unix timestamp for the access token's expiry.
*/
@IsInt()
refresh_token_expires_at: number;