@gtsc/api-models
Advanced tools
Comparing version 0.0.5-next.1 to 0.0.5-next.2
@@ -28,5 +28,5 @@ import type { HttpMethod } from "@gtsc/web"; | ||
/** | ||
* The request context. | ||
* The http request context. | ||
*/ | ||
requestContext: IHttpRequestContext, | ||
httpRequestContext: IHttpRequestContext, | ||
/** | ||
@@ -33,0 +33,0 @@ * The request object, combined query param, path params and body. |
@@ -1,2 +0,2 @@ | ||
import type { IService, IServiceRequestContext } from "@gtsc/services"; | ||
import type { IService } from "@gtsc/services"; | ||
import type { HealthStatus } from "./healthStatus"; | ||
@@ -11,18 +11,15 @@ import type { IHealthInfo } from "./IHealthInfo"; | ||
* Get the server information. | ||
* @param requestContext The context of the service request. | ||
* @returns The service information. | ||
*/ | ||
info(requestContext?: IServiceRequestContext): Promise<IServerInfo>; | ||
info(): Promise<IServerInfo>; | ||
/** | ||
* Get the OpenAPI spec. | ||
* @param requestContext The context of the service request. | ||
* @returns The OpenAPI spec. | ||
*/ | ||
spec(requestContext?: IServiceRequestContext): Promise<unknown>; | ||
spec(): Promise<unknown>; | ||
/** | ||
* Get the server health. | ||
* @param requestContext The context of the service request. | ||
* @returns The service health. | ||
*/ | ||
health(requestContext?: IServiceRequestContext): Promise<IHealthInfo>; | ||
health(): Promise<IHealthInfo>; | ||
/** | ||
@@ -33,13 +30,11 @@ * Set the status of a component. | ||
* @param details The details for the status. | ||
* @param requestContext The context of the service request. | ||
* @returns Nothing. | ||
*/ | ||
setComponentHealth(name: string, status: HealthStatus, details?: string, requestContext?: IServiceRequestContext): Promise<void>; | ||
setComponentHealth(name: string, status: HealthStatus, details?: string): Promise<void>; | ||
/** | ||
* Remove the status of a component. | ||
* @param name The component name. | ||
* @param requestContext The context of the service request. | ||
* @returns Nothing. | ||
*/ | ||
removeComponentHealth(name: string, requestContext?: IServiceRequestContext): Promise<void>; | ||
removeComponentHealth(name: string): Promise<void>; | ||
} |
@@ -49,3 +49,3 @@ # Interface: IHttpRestRouteProcessor | ||
> `optional` **start**(`systemRequestContext`, `systemLoggingConnectorType`?): `Promise`\<`void`\> | ||
> `optional` **start**(`systemIdentity`, `systemLoggingConnectorType`?): `Promise`\<`void`\> | ||
@@ -56,5 +56,5 @@ The service needs to be started when the application is initialized. | ||
• **systemRequestContext**: `IServiceRequestContext` | ||
• **systemIdentity**: `string` | ||
The system request context. | ||
The identity of the system. | ||
@@ -79,3 +79,3 @@ • **systemLoggingConnectorType?**: `string` | ||
> `optional` **stop**(`systemRequestContext`, `systemLoggingConnectorType`?): `Promise`\<`void`\> | ||
> `optional` **stop**(`systemIdentity`, `systemLoggingConnectorType`?): `Promise`\<`void`\> | ||
@@ -86,5 +86,5 @@ The service needs to be stopped when the application is closed. | ||
• **systemRequestContext**: `IServiceRequestContext` | ||
• **systemIdentity**: `string` | ||
The system request context. | ||
The identity of the system. | ||
@@ -91,0 +91,0 @@ • **systemLoggingConnectorType?**: `string` |
@@ -49,3 +49,3 @@ # Interface: IInformation | ||
> `optional` **start**(`systemRequestContext`, `systemLoggingConnectorType`?): `Promise`\<`void`\> | ||
> `optional` **start**(`systemIdentity`, `systemLoggingConnectorType`?): `Promise`\<`void`\> | ||
@@ -56,5 +56,5 @@ The service needs to be started when the application is initialized. | ||
• **systemRequestContext**: `IServiceRequestContext` | ||
• **systemIdentity**: `string` | ||
The system request context. | ||
The identity of the system. | ||
@@ -79,3 +79,3 @@ • **systemLoggingConnectorType?**: `string` | ||
> `optional` **stop**(`systemRequestContext`, `systemLoggingConnectorType`?): `Promise`\<`void`\> | ||
> `optional` **stop**(`systemIdentity`, `systemLoggingConnectorType`?): `Promise`\<`void`\> | ||
@@ -86,5 +86,5 @@ The service needs to be stopped when the application is closed. | ||
• **systemRequestContext**: `IServiceRequestContext` | ||
• **systemIdentity**: `string` | ||
The system request context. | ||
The identity of the system. | ||
@@ -109,12 +109,6 @@ • **systemLoggingConnectorType?**: `string` | ||
> **info**(`requestContext`?): `Promise`\<[`IServerInfo`](IServerInfo.md)\> | ||
> **info**(): `Promise`\<[`IServerInfo`](IServerInfo.md)\> | ||
Get the server information. | ||
#### Parameters | ||
• **requestContext?**: `IServiceRequestContext` | ||
The context of the service request. | ||
#### Returns | ||
@@ -130,12 +124,6 @@ | ||
> **spec**(`requestContext`?): `Promise`\<`unknown`\> | ||
> **spec**(): `Promise`\<`unknown`\> | ||
Get the OpenAPI spec. | ||
#### Parameters | ||
• **requestContext?**: `IServiceRequestContext` | ||
The context of the service request. | ||
#### Returns | ||
@@ -151,12 +139,6 @@ | ||
> **health**(`requestContext`?): `Promise`\<[`IHealthInfo`](IHealthInfo.md)\> | ||
> **health**(): `Promise`\<[`IHealthInfo`](IHealthInfo.md)\> | ||
Get the server health. | ||
#### Parameters | ||
• **requestContext?**: `IServiceRequestContext` | ||
The context of the service request. | ||
#### Returns | ||
@@ -172,3 +154,3 @@ | ||
> **setComponentHealth**(`name`, `status`, `details`?, `requestContext`?): `Promise`\<`void`\> | ||
> **setComponentHealth**(`name`, `status`, `details`?): `Promise`\<`void`\> | ||
@@ -191,6 +173,2 @@ Set the status of a component. | ||
• **requestContext?**: `IServiceRequestContext` | ||
The context of the service request. | ||
#### Returns | ||
@@ -206,3 +184,3 @@ | ||
> **removeComponentHealth**(`name`, `requestContext`?): `Promise`\<`void`\> | ||
> **removeComponentHealth**(`name`): `Promise`\<`void`\> | ||
@@ -217,6 +195,2 @@ Remove the status of a component. | ||
• **requestContext?**: `IServiceRequestContext` | ||
The context of the service request. | ||
#### Returns | ||
@@ -223,0 +197,0 @@ |
@@ -79,3 +79,3 @@ # Interface: IRestRoute\<T, U\> | ||
> **handler**: (`requestContext`, `request`) => `Promise`\<`U`\> | ||
> **handler**: (`httpRequestContext`, `request`) => `Promise`\<`U`\> | ||
@@ -86,5 +86,5 @@ The handler module. | ||
• **requestContext**: [`IHttpRequestContext`](IHttpRequestContext.md) | ||
• **httpRequestContext**: [`IHttpRequestContext`](IHttpRequestContext.md) | ||
The request context. | ||
The http request context. | ||
@@ -91,0 +91,0 @@ • **request**: `T` |
{ | ||
"name": "@gtsc/api-models", | ||
"version": "0.0.5-next.1", | ||
"version": "0.0.5-next.2", | ||
"description": "Contains models and classes for use with APIs", | ||
@@ -5,0 +5,0 @@ "repository": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
63059
886