File tree Expand file tree Collapse file tree 2 files changed +10
-5
lines changed
Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Original file line number Diff line number Diff line change 1- import type { TokenCredential } from "@azure/core-auth" ;
21import { AzureIdentityAuthenticationProvider } from "@microsoft/kiota-authentication-azure" ;
32import { FetchRequestAdapter } from "@microsoft/kiota-http-fetchlibrary" ;
3+ import type { TokenCredential } from "@azure/core-auth" ;
4+ import { assert } from 'typia' ;
45import { createDataGatewayClient } from "./sdk/dataGatewayClient.js" ;
56
67// Export all of the SDK's types
@@ -11,7 +12,11 @@ export type * from './sdk/models/index.js';
1112 * @param credential Configured authentication session.
1213 * @returns Configured API client that is able to make requests against SHI Data Gateway.
1314 */
14- export function dataGatewayClientFactory ( credential : TokenCredential ) {
15+ export default function dataGatewayClientFactory ( credential : TokenCredential ) {
16+ // #region Input Validation
17+ assert ( credential ) ;
18+ // #endregion Input Validation
19+
1520 /** List of hosts that are allowed when making API calls, this is used to prevent token leaks to threat actors. */
1621 const allowedHostList = new Set ( [ 'https://api.shilab.com' ] ) ;
1722
Original file line number Diff line number Diff line change 1- import type { TokenCredential } from "@azure/core-auth" ;
1+ import { assert , assertGuardEquals , tags } from 'typia' ;
22import { AzureIdentityAuthenticationProvider } from "@microsoft/kiota-authentication-azure" ;
33import { FetchRequestAdapter } from "@microsoft/kiota-http-fetchlibrary" ;
4+ import type { TokenCredential } from "@azure/core-auth" ;
45import { createShieldClient } from "./sdk/shieldClient.js" ;
5- import { assert , assertGuardEquals , tags } from 'typia' ;
66
77// Export all of the SDK's types
88export type * from './sdk/models/index.js' ;
@@ -12,7 +12,7 @@ export type * from './sdk/models/index.js';
1212 * @param credential Configured authentication session from Entra ID.
1313 * @returns Configured API client that is able to make requests against the specified SHIELD instance.
1414 */
15- export function shieldClientFactory ( credential : TokenCredential , baseUrl : string & tags . Format < 'hostname' > ) {
15+ export default function shieldClientFactory ( credential : TokenCredential , baseUrl : string & tags . Format < 'hostname' > ) {
1616 // #region Input Validation
1717 assert ( credential ) ;
1818
You can’t perform that action at this time.
0 commit comments