@onylab/common-api 2.1.32 → 2.1.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1289,6 +1289,14 @@ declare module "api/hubrise/model/auth/HubriseAccessLevel" {
1289
1289
  PROFILE = "profile"
1290
1290
  }
1291
1291
  }
1292
+ declare module "api/hubrise/model/callback/HubriseCallbackContract" {
1293
+ import { HubriseResourceType } from "api/hubrise/model/callback/HubriseResourceType";
1294
+ import { HubriseEventType } from "api/hubrise/model/callback/HubriseEventType";
1295
+ export interface HubriseCallbackContract {
1296
+ url: string;
1297
+ events: Partial<Record<HubriseResourceType, HubriseEventType[]>>;
1298
+ }
1299
+ }
1292
1300
  declare module "api/hubrise/service/HubriseApiContract" {
1293
1301
  import { HubriseOrderContract } from "api/hubrise/model/order/HubriseOrderContract";
1294
1302
  import { HubriseOrderStatus } from "api/hubrise/model/order/HubriseOrderStatus";
@@ -1304,8 +1312,9 @@ declare module "api/hubrise/service/HubriseApiContract" {
1304
1312
  import { HubriseRightAccess } from "api/hubrise/model/auth/HubriseRightAccess";
1305
1313
  import { HubriseAccountContract } from "api/hubrise/model/account/HubriseAccountContract";
1306
1314
  import { HubriseAccessLevel } from "api/hubrise/model/auth/HubriseAccessLevel";
1315
+ import { HubriseCallbackContract } from "api/hubrise/model/callback/HubriseCallbackContract";
1307
1316
  export interface HubriseApiContract {
1308
- authorize(name: string, clientId: string, redirect: string, accessLevel: HubriseAccessLevel, rights?: Record<HubriseAuthResource, HubriseRightAccess>, profile?: boolean, appInstanceId?: string): Promise<string>;
1317
+ authorize(name: string, clientId: string, redirect: string, accessLevel: HubriseAccessLevel, rights?: Partial<Record<HubriseAuthResource, HubriseRightAccess>>, profile?: boolean, appInstanceId?: string): Promise<string>;
1309
1318
  getToken(clientId: string, clientSecret: string, code: string): Promise<HubriseAuthContract>;
1310
1319
  getUser(): Promise<HubriseUserContract>;
1311
1320
  getAccount(): Promise<HubriseAccountContract>;
@@ -1322,7 +1331,9 @@ declare module "api/hubrise/service/HubriseApiContract" {
1322
1331
  setOrderStatus(hubriseLocationId: string, hubriseOrderId: string, status: HubriseOrderStatus): Promise<void>;
1323
1332
  getCatalog(hubriseCatalogId: string): Promise<HubriseMenuCatalogContract>;
1324
1333
  getCatalogs(hubriseLocationId: string): Promise<HubriseMenuCatalogContract[]>;
1325
- createWebhook(url: string, events: Record<HubriseResourceType, HubriseEventType[]>): Promise<void>;
1334
+ updateWebhooks(url: string, events: Partial<Record<HubriseResourceType, HubriseEventType[]>>): Promise<void>;
1335
+ getWebhooks(): Promise<HubriseCallbackContract>;
1336
+ deleteWebhooks(): Promise<void>;
1326
1337
  }
1327
1338
  }
1328
1339
  declare module "exception/ExceptionContract" {
@@ -1442,13 +1453,14 @@ declare module "api/hubrise/service/HubriseApi" {
1442
1453
  import { HubriseAccountContract } from "api/hubrise/model/account/HubriseAccountContract";
1443
1454
  import { HubriseAccessTokenContract } from "api/hubrise/model/auth/HubriseAccessTokenContract";
1444
1455
  import { HubriseAccessLevel } from "api/hubrise/model/auth/HubriseAccessLevel";
1456
+ import { HubriseCallbackContract } from "api/hubrise/model/callback/HubriseCallbackContract";
1445
1457
  export class HubriseApi implements HubriseApiContract {
1446
1458
  static readonly BASE_URL: string;
1447
1459
  static readonly BASE_AUTH_URL: string;
1448
1460
  private static readonly TIMEOUT;
1449
1461
  private readonly accessToken;
1450
1462
  constructor(accessToken?: HubriseAccessTokenContract);
1451
- authorize(name: string, clientId: string, redirect: string, accessLevel: HubriseAccessLevel, rights?: Record<HubriseAuthResource, HubriseRightAccess>, profile?: boolean, appInstanceId?: string): Promise<string>;
1463
+ authorize(name: string, clientId: string, redirect: string, accessLevel: HubriseAccessLevel, rights?: Partial<Record<HubriseAuthResource, HubriseRightAccess>>, profile?: boolean, appInstanceId?: string): Promise<string>;
1452
1464
  getToken(clientId: string, clientSecret: string, code: string): Promise<HubriseAuthContract>;
1453
1465
  getUser(): Promise<HubriseUserContract>;
1454
1466
  getAccount(): Promise<HubriseAccountContract>;
@@ -1465,7 +1477,9 @@ declare module "api/hubrise/service/HubriseApi" {
1465
1477
  setOrderStatus(hubriseLocationId: string, hubriseOrderId: string, status: HubriseOrderStatus): Promise<void>;
1466
1478
  getCatalog(hubriseCatalogId: string): Promise<HubriseMenuCatalogContract>;
1467
1479
  getCatalogs(hubriseLocationId: string): Promise<HubriseMenuCatalogContract[]>;
1468
- createWebhook(url: string, events: Record<HubriseResourceType, HubriseEventType[]>): Promise<void>;
1480
+ updateWebhooks(url: string, events: Partial<Record<HubriseResourceType, HubriseEventType[]>>): Promise<void>;
1481
+ getWebhooks(): Promise<HubriseCallbackContract>;
1482
+ deleteWebhooks(): Promise<void>;
1469
1483
  }
1470
1484
  }
1471
1485
  declare module "api/hubrise/model/common/HubriseLanguageCode" {
@@ -1537,11 +1551,11 @@ declare module "api/hubrise/service/HubriseCatalogConverterContract" {
1537
1551
  import { HubriseOrderEditableOptionContract } from "api/hubrise/model/order/HubriseOrderEditableOptionContract";
1538
1552
  import { HubriseMenuVariantContract } from "api/hubrise/model/menu/HubriseMenuVariantContract";
1539
1553
  export interface HubriseCatalogConverterContract {
1540
- editableItems(catalog: HubriseMenuCatalogContract, variant?: HubriseMenuVariantContract): {
1554
+ editableItems(catalog: HubriseMenuCatalogContract, date: string, variant?: HubriseMenuVariantContract): {
1541
1555
  withRef: HubriseOrderEditableItemContract[];
1542
1556
  withName: HubriseOrderEditableItemContract[];
1543
1557
  };
1544
- editableItemOptions(catalog: HubriseMenuCatalogContract, variant?: HubriseMenuVariantContract): {
1558
+ editableItemOptions(catalog: HubriseMenuCatalogContract, date: string, variant?: HubriseMenuVariantContract): {
1545
1559
  withRef: Record<string, HubriseOrderEditableOptionContract[]>;
1546
1560
  withName: Record<string, HubriseOrderEditableOptionContract[]>;
1547
1561
  };
@@ -1586,11 +1600,11 @@ declare module "api/hubrise/service/HubriseCatalogConverter" {
1586
1600
  export class HubriseCatalogConverter implements HubriseCatalogConverterContract {
1587
1601
  private readonly hubriseRestrictionEnforcer;
1588
1602
  constructor();
1589
- editableItems(catalog: HubriseMenuCatalogContract, variant?: HubriseMenuVariantContract): {
1603
+ editableItems(catalog: HubriseMenuCatalogContract, date: string, variant?: HubriseMenuVariantContract): {
1590
1604
  withRef: HubriseOrderEditableItemContract[];
1591
1605
  withName: HubriseOrderEditableItemContract[];
1592
1606
  };
1593
- editableItemOptions(catalog: HubriseMenuCatalogContract, variant?: HubriseMenuVariantContract): {
1607
+ editableItemOptions(catalog: HubriseMenuCatalogContract, date: string, variant?: HubriseMenuVariantContract): {
1594
1608
  withRef: Record<string, HubriseOrderEditableOptionContract[]>;
1595
1609
  withName: Record<string, HubriseOrderEditableOptionContract[]>;
1596
1610
  };
@@ -1934,7 +1948,9 @@ declare module "mockup/HubriseApiMockup" {
1934
1948
  static setOrderStatus(times?: number): void;
1935
1949
  static getCatalog(times?: number): void;
1936
1950
  static getCatalogs(times?: number): void;
1937
- static createWebhook(times?: number): void;
1951
+ static updateWebhooks(times?: number): void;
1952
+ static getWebhooks(times?: number): void;
1953
+ static deleteWebhooks(times?: number): void;
1938
1954
  }
1939
1955
  }
1940
1956
  declare module "mockup/index" {