New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@gtsc/api-models

Package Overview
Dependencies
Maintainers
2
Versions
85
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@gtsc/api-models - npm Package Compare versions

Comparing version 0.0.3-next.35 to 0.0.3-next.36

4

dist/types/models/server/IHttpRestRouteProcessor.d.ts

@@ -1,2 +0,2 @@

import type { IServiceRequestContext } from "@gtsc/services";
import type { IService, IServiceRequestContext } from "@gtsc/services";
import type { IHttpResponse } from "../protocol/IHttpResponse";

@@ -8,3 +8,3 @@ import type { IHttpServerRequest } from "../protocol/IHttpServerRequest";

*/
export interface IHttpRestRouteProcessor {
export interface IHttpRestRouteProcessor extends IService {
/**

@@ -11,0 +11,0 @@ * Process the REST request for the specified route.

@@ -7,4 +7,9 @@ import type { IHttpRestRouteProcessor } from "./IHttpRestRouteProcessor";

*/
export interface IWebServer {
export interface IWebServer<T> {
/**
* Get the web server instance.
* @returns The web server instance.
*/
getInstance(): T;
/**
* Build the server.

@@ -11,0 +16,0 @@ * @param restRouteProcessors The hooks to process the incoming requests.

@@ -9,4 +9,92 @@ [**@gtsc/api-models**](../overview.md) • **Docs**

## Extends
- `IService`
## Properties
### CLASS\_NAME
> `readonly` **CLASS\_NAME**: `string`
The name of the service.
#### Inherited from
`IService.CLASS_NAME`
## Methods
### bootstrap()?
> `optional` **bootstrap**(`systemPartitionId`): `Promise`\<`void`\>
Bootstrap the service by creating and initializing any resources it needs.
#### Parameters
• **systemPartitionId**: `string`
The system partition id.
#### Returns
`Promise`\<`void`\>
Nothing.
#### Inherited from
`IService.bootstrap`
***
### start()?
> `optional` **start**(`systemPartitionId`): `Promise`\<`void`\>
The service needs to be started when the application is initialized.
#### Parameters
• **systemPartitionId**: `string`
The system partition id.
#### Returns
`Promise`\<`void`\>
Nothing.
#### Inherited from
`IService.start`
***
### stop()?
> `optional` **stop**(`systemPartitionId`): `Promise`\<`void`\>
The service needs to be stopped when the application is closed.
#### Parameters
• **systemPartitionId**: `string`
The system partition id.
#### Returns
`Promise`\<`void`\>
Nothing.
#### Inherited from
`IService.stop`
***
### process()

@@ -13,0 +101,0 @@

@@ -29,3 +29,3 @@ [**@gtsc/api-models**](../overview.md) • **Docs**

> `optional` **bootstrap**(`requestContext`?): `Promise`\<`void`\>
> `optional` **bootstrap**(`systemPartitionId`): `Promise`\<`void`\>

@@ -36,5 +36,5 @@ Bootstrap the service by creating and initializing any resources it needs.

• **requestContext?**: `IServiceRequestContext`
• **systemPartitionId**: `string`
The request context for bootstrapping.
The system partition id.

@@ -55,6 +55,12 @@ #### Returns

> `optional` **start**(): `Promise`\<`void`\>
> `optional` **start**(`systemPartitionId`): `Promise`\<`void`\>
The service needs to be started when the application is initialized.
#### Parameters
• **systemPartitionId**: `string`
The system partition id.
#### Returns

@@ -74,6 +80,12 @@

> `optional` **stop**(): `Promise`\<`void`\>
> `optional` **stop**(`systemPartitionId`): `Promise`\<`void`\>
The service needs to be stopped when the application is closed.
#### Parameters
• **systemPartitionId**: `string`
The system partition id.
#### Returns

@@ -80,0 +92,0 @@

@@ -5,8 +5,26 @@ [**@gtsc/api-models**](../overview.md) • **Docs**

# Interface: IWebServer
# Interface: IWebServer\<T\>
Interface describing a web server.
## Type parameters
• **T**
## Methods
### getInstance()
> **getInstance**(): `T`
Get the web server instance.
#### Returns
`T`
The web server instance.
***
### build()

@@ -13,0 +31,0 @@

{
"name": "@gtsc/api-models",
"version": "0.0.3-next.35",
"version": "0.0.3-next.36",
"description": "Contains models and classes for use with APIs",

@@ -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