Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@gtsc/api-auth-entity-storage-models

Package Overview
Dependencies
Maintainers
0
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@gtsc/api-auth-entity-storage-models - npm Package Compare versions

Comparing version 0.0.3-next.63 to 0.0.3-next.64

dist/types/models/api/ILogoutRequest.d.ts

3

dist/types/index.d.ts
export * from "./models/api/ILoginRequest";
export * from "./models/api/ILoginResponse";
export * from "./models/api/ILogoutRequest";
export * from "./models/api/IRefreshTokenRequest";
export * from "./models/api/IRefreshTokenResponse";
export * from "./models/IAuthentication";

4

dist/types/models/api/ILoginResponse.d.ts

@@ -10,6 +10,6 @@ /**

/**
* The access token for future requests.
* The access token, if it uses a mechanism with public access.
*/
token: string;
token?: string;
};
}

@@ -11,5 +11,19 @@ import type { IService, IServiceRequestContext } from "@gtsc/services";

* @param requestContext The context for the request.
* @returns The authentication token for the user.
* @returns The authentication token for the user, if it uses a mechanism with public access.
*/
login(email: string, password: string, requestContext?: IServiceRequestContext): Promise<string>;
login(email: string, password: string, requestContext?: IServiceRequestContext): Promise<string | undefined>;
/**
* Logout the current user.
* @param token The token to logout, if it uses a mechanism with public access.
* @param requestContext The context for the request.
* @returns Nothing.
*/
logout(token?: string, requestContext?: IServiceRequestContext): Promise<void>;
/**
* Refresh the token.
* @param token The token to refresh, if it uses a mechanism with public access.
* @param requestContext The context for the request.
* @returns The refreshed token, if it uses a mechanism with public access.
*/
refresh(token?: string, requestContext?: IServiceRequestContext): Promise<string | undefined>;
}

@@ -8,1 +8,4 @@ # @gtsc/api-auth-entity-storage-models

- [ILoginResponse](interfaces/ILoginResponse.md)
- [ILogoutRequest](interfaces/ILogoutRequest.md)
- [IRefreshTokenRequest](interfaces/IRefreshTokenRequest.md)
- [IRefreshTokenResponse](interfaces/IRefreshTokenResponse.md)

@@ -105,3 +105,3 @@ # Interface: IAuthentication

> **login**(`email`, `password`, `requestContext`?): `Promise`\<`string`\>
> **login**(`email`, `password`, `requestContext`?): `Promise`\<`undefined` \| `string`\>

@@ -126,4 +126,52 @@ Perform a login for the user.

`Promise`\<`string`\>
`Promise`\<`undefined` \| `string`\>
The authentication token for the user.
The authentication token for the user, if it uses a mechanism with public access.
***
### logout()
> **logout**(`token`?, `requestContext`?): `Promise`\<`void`\>
Logout the current user.
#### Parameters
• **token?**: `string`
The token to logout, if it uses a mechanism with public access.
• **requestContext?**: `IServiceRequestContext`
The context for the request.
#### Returns
`Promise`\<`void`\>
Nothing.
***
### refresh()
> **refresh**(`token`?, `requestContext`?): `Promise`\<`undefined` \| `string`\>
Refresh the token.
#### Parameters
• **token?**: `string`
The token to refresh, if it uses a mechanism with public access.
• **requestContext?**: `IServiceRequestContext`
The context for the request.
#### Returns
`Promise`\<`undefined` \| `string`\>
The refreshed token, if it uses a mechanism with public access.

@@ -13,6 +13,6 @@ # Interface: ILoginResponse

#### token
#### token?
> **token**: `string`
> `optional` **token**: `string`
The access token for future requests.
The access token, if it uses a mechanism with public access.
{
"name": "@gtsc/api-auth-entity-storage-models",
"version": "0.0.3-next.63",
"version": "0.0.3-next.64",
"description": "Models which define the structure of the Auth Entity Storage contracts.",

@@ -5,0 +5,0 @@ "repository": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc