@keboola/api-fixtures 34.0.0 → 36.0.0

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.
package/dist/index.d.cts CHANGED
@@ -1,6 +1,7 @@
1
1
  import { App, AppRun, Deployment } from "@keboola/api-client/apps/types";
2
2
  import { BusinessWorkspaceDashboard, BusinessWorkspaceDashboardSummary, DashboardInput } from "@keboola/api-client/businessWorkspaceApi/types";
3
3
  import { AdminVendor, App as App$1, AppChange, ServiceAccount, User, Vendor, VendorListItem } from "@keboola/api-client/developerPortal/types";
4
+ import { ApplicationToken, CreatedApplicationToken, UiApp, UiAppDetail } from "@keboola/api-client/management/types";
4
5
  import { ServiceId } from "@keboola/api-client/constants";
5
6
  import { DevBranch, StackInfo, StorageToken, Table, TableDetail } from "@keboola/api-client/storage/types";
6
7
  //#region src/clients/apps/apps.d.ts
@@ -153,16 +154,10 @@ declare const deploymentFixtures: {
153
154
  };
154
155
  declare const getDeployment: () => Deployment;
155
156
  /**
156
- * One continuous history: the oldest deleted, the next serving, then one staged, one that failed to
157
- * build and one that built but whose run failed.
157
+ * All deployments as one history.
158
158
  *
159
- * All five, because `runFixtures.failed` names the last one as its deployment — a list that left
160
- * the failed ones out could not be joined to the runs, which is the join a timeline is built from.
161
- *
162
- * Returned oldest first. The endpoint does not specify an order, so consumers must sort for
163
- * themselves — this order is a fixture convention, not a contract to rely on, and it is oldest
164
- * first on purpose: a consumer that assumes newest-first gets the wrong answer here rather than in
165
- * production.
159
+ * - Includes the failed ones: `runFixtures.failed` joins to the last.
160
+ * - Oldest first on purpose: the endpoint specifies no order, so consumers must sort.
166
161
  */
167
162
  declare const listDeployments: () => Deployment[];
168
163
  //#endregion
@@ -597,6 +592,124 @@ declare const developerPortalFixtures: {
597
592
  };
598
593
  };
599
594
  //#endregion
595
+ //#region src/clients/management/applicationTokens.d.ts
596
+ /** A token that has been used and never expires. */
597
+ declare const getApplicationToken: () => ApplicationToken;
598
+ /** Used, never-used and expiring tokens — the three states the list must render. */
599
+ declare const getApplicationTokens: () => ApplicationToken[];
600
+ declare const applicationTokenFixtures: {
601
+ used: {
602
+ id: number;
603
+ description: string;
604
+ created: string;
605
+ lastUsed: string;
606
+ expires: null;
607
+ isDisabled: false;
608
+ isExpired: false;
609
+ scopes: string[];
610
+ creator: {
611
+ id: number;
612
+ name: string;
613
+ };
614
+ };
615
+ neverUsed: {
616
+ id: number;
617
+ description: string;
618
+ created: string;
619
+ lastUsed: null;
620
+ expires: null;
621
+ isDisabled: false;
622
+ isExpired: false;
623
+ scopes: never[];
624
+ creator: {
625
+ id: null;
626
+ name: null;
627
+ };
628
+ };
629
+ expiring: {
630
+ id: number;
631
+ description: string;
632
+ created: string;
633
+ lastUsed: string;
634
+ expires: string;
635
+ isDisabled: false;
636
+ isExpired: false;
637
+ scopes: string[];
638
+ creator: {
639
+ id: number;
640
+ name: string;
641
+ };
642
+ };
643
+ created: {
644
+ created: string;
645
+ expires: null;
646
+ isDisabled: false;
647
+ isExpired: false;
648
+ scopes: string[];
649
+ creator: {
650
+ id: number;
651
+ name: string;
652
+ };
653
+ id: number;
654
+ description: string;
655
+ lastUsed: null;
656
+ token: string;
657
+ };
658
+ };
659
+ //#endregion
660
+ //#region src/clients/management/uiApps.d.ts
661
+ /** One UI application detail with an active and a superseded version. */
662
+ declare const getUiApp: () => UiAppDetail;
663
+ /** An active application and one with no active version, as `includeInactive` returns them. */
664
+ declare const getUiApps: () => UiApp[];
665
+ declare const uiAppFixtures: {
666
+ active: {
667
+ stringId: string;
668
+ name: string;
669
+ version: string;
670
+ basePath: string;
671
+ type: string;
672
+ scripts: string[];
673
+ styles: string[];
674
+ isCritical: false;
675
+ commitSha: string;
676
+ };
677
+ inactive: {
678
+ stringId: string;
679
+ name: string;
680
+ version: null;
681
+ basePath: null;
682
+ type: null;
683
+ scripts: never[];
684
+ styles: never[];
685
+ isCritical: false;
686
+ commitSha: null;
687
+ };
688
+ detail: {
689
+ id: number;
690
+ stringId: string;
691
+ name: string;
692
+ created: string;
693
+ versions: ({
694
+ id: number;
695
+ version: string;
696
+ created: string;
697
+ isActive: true;
698
+ isCritical: false;
699
+ buildUrl: string;
700
+ commitSha: string;
701
+ } | {
702
+ id: number;
703
+ version: string;
704
+ created: string;
705
+ isActive: false;
706
+ isCritical: true;
707
+ buildUrl: null;
708
+ commitSha: null;
709
+ })[];
710
+ };
711
+ };
712
+ //#endregion
600
713
  //#region src/clients/storage/bootstrap.d.ts
601
714
  /** The stack an MSW-backed test points its client at, unless a caller passes its own. */
602
715
  declare const DEFAULT_BASE_URL = "https://connection.test";
@@ -809,6 +922,122 @@ declare const tableFixtures: {
809
922
  //#endregion
810
923
  //#region src/fixtures.d.ts
811
924
  declare const fixtures: {
925
+ management: {
926
+ applicationTokens: {
927
+ getApplicationToken: typeof getApplicationToken;
928
+ getApplicationTokens: typeof getApplicationTokens;
929
+ fixtures: {
930
+ used: {
931
+ id: number;
932
+ description: string;
933
+ created: string;
934
+ lastUsed: string;
935
+ expires: null;
936
+ isDisabled: false;
937
+ isExpired: false;
938
+ scopes: string[];
939
+ creator: {
940
+ id: number;
941
+ name: string;
942
+ };
943
+ };
944
+ neverUsed: {
945
+ id: number;
946
+ description: string;
947
+ created: string;
948
+ lastUsed: null;
949
+ expires: null;
950
+ isDisabled: false;
951
+ isExpired: false;
952
+ scopes: never[];
953
+ creator: {
954
+ id: null;
955
+ name: null;
956
+ };
957
+ };
958
+ expiring: {
959
+ id: number;
960
+ description: string;
961
+ created: string;
962
+ lastUsed: string;
963
+ expires: string;
964
+ isDisabled: false;
965
+ isExpired: false;
966
+ scopes: string[];
967
+ creator: {
968
+ id: number;
969
+ name: string;
970
+ };
971
+ };
972
+ created: {
973
+ created: string;
974
+ expires: null;
975
+ isDisabled: false;
976
+ isExpired: false;
977
+ scopes: string[];
978
+ creator: {
979
+ id: number;
980
+ name: string;
981
+ };
982
+ id: number;
983
+ description: string;
984
+ lastUsed: null;
985
+ token: string;
986
+ };
987
+ };
988
+ };
989
+ uiApps: {
990
+ getUiApp: typeof getUiApp;
991
+ getUiApps: typeof getUiApps;
992
+ fixtures: {
993
+ active: {
994
+ stringId: string;
995
+ name: string;
996
+ version: string;
997
+ basePath: string;
998
+ type: string;
999
+ scripts: string[];
1000
+ styles: string[];
1001
+ isCritical: false;
1002
+ commitSha: string;
1003
+ };
1004
+ inactive: {
1005
+ stringId: string;
1006
+ name: string;
1007
+ version: null;
1008
+ basePath: null;
1009
+ type: null;
1010
+ scripts: never[];
1011
+ styles: never[];
1012
+ isCritical: false;
1013
+ commitSha: null;
1014
+ };
1015
+ detail: {
1016
+ id: number;
1017
+ stringId: string;
1018
+ name: string;
1019
+ created: string;
1020
+ versions: ({
1021
+ id: number;
1022
+ version: string;
1023
+ created: string;
1024
+ isActive: true;
1025
+ isCritical: false;
1026
+ buildUrl: string;
1027
+ commitSha: string;
1028
+ } | {
1029
+ id: number;
1030
+ version: string;
1031
+ created: string;
1032
+ isActive: false;
1033
+ isCritical: true;
1034
+ buildUrl: null;
1035
+ commitSha: null;
1036
+ })[];
1037
+ };
1038
+ };
1039
+ };
1040
+ };
812
1041
  storage: {
813
1042
  bootstrap: {
814
1043
  getStackInfo: typeof getStackInfo;
@@ -1541,5 +1770,5 @@ declare const fixtures: {
1541
1770
  };
1542
1771
  };
1543
1772
  //#endregion
1544
- export { DEFAULT_BASE_URL, type Table, type TableDetail, appFixtures, deploymentFixtures, developerPortalFixtures, fixtures, getApp, getAppRun, getBusinessWorkspaceDashboard, getBusinessWorkspaceDashboardInput, getDeployment, getDevBranches, getStackInfo, getTable, getVendor, listAllApps, listAllVendors, listAppChanges, listAppRuns, listApps, listBusinessWorkspaceDashboards, listDeployments, listPublishedApps, listServiceAccounts, listTables, listUsers, listVendorApps, listVendors, runFixtures, tableFixtures, verifyStorageToken };
1773
+ export { type ApplicationToken, type CreatedApplicationToken, DEFAULT_BASE_URL, type Table, type TableDetail, type UiApp, type UiAppDetail, appFixtures, applicationTokenFixtures, deploymentFixtures, developerPortalFixtures, fixtures, getApp, getAppRun, getApplicationToken, getApplicationTokens, getBusinessWorkspaceDashboard, getBusinessWorkspaceDashboardInput, getDeployment, getDevBranches, getStackInfo, getTable, getUiApp, getUiApps, getVendor, listAllApps, listAllVendors, listAppChanges, listAppRuns, listApps, listBusinessWorkspaceDashboards, listDeployments, listPublishedApps, listServiceAccounts, listTables, listUsers, listVendorApps, listVendors, runFixtures, tableFixtures, uiAppFixtures, verifyStorageToken };
1545
1774
  //# sourceMappingURL=index.d.cts.map
package/dist/index.d.ts CHANGED
@@ -2,6 +2,7 @@ import { ServiceId } from "@keboola/api-client/constants";
2
2
  import { App, AppRun, Deployment } from "@keboola/api-client/apps/types";
3
3
  import { BusinessWorkspaceDashboard, BusinessWorkspaceDashboardSummary, DashboardInput } from "@keboola/api-client/businessWorkspaceApi/types";
4
4
  import { AdminVendor, App as App$1, AppChange, ServiceAccount, User, Vendor, VendorListItem } from "@keboola/api-client/developerPortal/types";
5
+ import { ApplicationToken, CreatedApplicationToken, UiApp, UiAppDetail } from "@keboola/api-client/management/types";
5
6
  import { DevBranch, StackInfo, StorageToken, Table, TableDetail } from "@keboola/api-client/storage/types";
6
7
  //#region src/clients/apps/apps.d.ts
7
8
  declare const appFixtures: {
@@ -153,16 +154,10 @@ declare const deploymentFixtures: {
153
154
  };
154
155
  declare const getDeployment: () => Deployment;
155
156
  /**
156
- * One continuous history: the oldest deleted, the next serving, then one staged, one that failed to
157
- * build and one that built but whose run failed.
157
+ * All deployments as one history.
158
158
  *
159
- * All five, because `runFixtures.failed` names the last one as its deployment — a list that left
160
- * the failed ones out could not be joined to the runs, which is the join a timeline is built from.
161
- *
162
- * Returned oldest first. The endpoint does not specify an order, so consumers must sort for
163
- * themselves — this order is a fixture convention, not a contract to rely on, and it is oldest
164
- * first on purpose: a consumer that assumes newest-first gets the wrong answer here rather than in
165
- * production.
159
+ * - Includes the failed ones: `runFixtures.failed` joins to the last.
160
+ * - Oldest first on purpose: the endpoint specifies no order, so consumers must sort.
166
161
  */
167
162
  declare const listDeployments: () => Deployment[];
168
163
  //#endregion
@@ -597,6 +592,124 @@ declare const developerPortalFixtures: {
597
592
  };
598
593
  };
599
594
  //#endregion
595
+ //#region src/clients/management/applicationTokens.d.ts
596
+ /** A token that has been used and never expires. */
597
+ declare const getApplicationToken: () => ApplicationToken;
598
+ /** Used, never-used and expiring tokens — the three states the list must render. */
599
+ declare const getApplicationTokens: () => ApplicationToken[];
600
+ declare const applicationTokenFixtures: {
601
+ used: {
602
+ id: number;
603
+ description: string;
604
+ created: string;
605
+ lastUsed: string;
606
+ expires: null;
607
+ isDisabled: false;
608
+ isExpired: false;
609
+ scopes: string[];
610
+ creator: {
611
+ id: number;
612
+ name: string;
613
+ };
614
+ };
615
+ neverUsed: {
616
+ id: number;
617
+ description: string;
618
+ created: string;
619
+ lastUsed: null;
620
+ expires: null;
621
+ isDisabled: false;
622
+ isExpired: false;
623
+ scopes: never[];
624
+ creator: {
625
+ id: null;
626
+ name: null;
627
+ };
628
+ };
629
+ expiring: {
630
+ id: number;
631
+ description: string;
632
+ created: string;
633
+ lastUsed: string;
634
+ expires: string;
635
+ isDisabled: false;
636
+ isExpired: false;
637
+ scopes: string[];
638
+ creator: {
639
+ id: number;
640
+ name: string;
641
+ };
642
+ };
643
+ created: {
644
+ created: string;
645
+ expires: null;
646
+ isDisabled: false;
647
+ isExpired: false;
648
+ scopes: string[];
649
+ creator: {
650
+ id: number;
651
+ name: string;
652
+ };
653
+ id: number;
654
+ description: string;
655
+ lastUsed: null;
656
+ token: string;
657
+ };
658
+ };
659
+ //#endregion
660
+ //#region src/clients/management/uiApps.d.ts
661
+ /** One UI application detail with an active and a superseded version. */
662
+ declare const getUiApp: () => UiAppDetail;
663
+ /** An active application and one with no active version, as `includeInactive` returns them. */
664
+ declare const getUiApps: () => UiApp[];
665
+ declare const uiAppFixtures: {
666
+ active: {
667
+ stringId: string;
668
+ name: string;
669
+ version: string;
670
+ basePath: string;
671
+ type: string;
672
+ scripts: string[];
673
+ styles: string[];
674
+ isCritical: false;
675
+ commitSha: string;
676
+ };
677
+ inactive: {
678
+ stringId: string;
679
+ name: string;
680
+ version: null;
681
+ basePath: null;
682
+ type: null;
683
+ scripts: never[];
684
+ styles: never[];
685
+ isCritical: false;
686
+ commitSha: null;
687
+ };
688
+ detail: {
689
+ id: number;
690
+ stringId: string;
691
+ name: string;
692
+ created: string;
693
+ versions: ({
694
+ id: number;
695
+ version: string;
696
+ created: string;
697
+ isActive: true;
698
+ isCritical: false;
699
+ buildUrl: string;
700
+ commitSha: string;
701
+ } | {
702
+ id: number;
703
+ version: string;
704
+ created: string;
705
+ isActive: false;
706
+ isCritical: true;
707
+ buildUrl: null;
708
+ commitSha: null;
709
+ })[];
710
+ };
711
+ };
712
+ //#endregion
600
713
  //#region src/clients/storage/bootstrap.d.ts
601
714
  /** The stack an MSW-backed test points its client at, unless a caller passes its own. */
602
715
  declare const DEFAULT_BASE_URL = "https://connection.test";
@@ -809,6 +922,122 @@ declare const tableFixtures: {
809
922
  //#endregion
810
923
  //#region src/fixtures.d.ts
811
924
  declare const fixtures: {
925
+ management: {
926
+ applicationTokens: {
927
+ getApplicationToken: typeof getApplicationToken;
928
+ getApplicationTokens: typeof getApplicationTokens;
929
+ fixtures: {
930
+ used: {
931
+ id: number;
932
+ description: string;
933
+ created: string;
934
+ lastUsed: string;
935
+ expires: null;
936
+ isDisabled: false;
937
+ isExpired: false;
938
+ scopes: string[];
939
+ creator: {
940
+ id: number;
941
+ name: string;
942
+ };
943
+ };
944
+ neverUsed: {
945
+ id: number;
946
+ description: string;
947
+ created: string;
948
+ lastUsed: null;
949
+ expires: null;
950
+ isDisabled: false;
951
+ isExpired: false;
952
+ scopes: never[];
953
+ creator: {
954
+ id: null;
955
+ name: null;
956
+ };
957
+ };
958
+ expiring: {
959
+ id: number;
960
+ description: string;
961
+ created: string;
962
+ lastUsed: string;
963
+ expires: string;
964
+ isDisabled: false;
965
+ isExpired: false;
966
+ scopes: string[];
967
+ creator: {
968
+ id: number;
969
+ name: string;
970
+ };
971
+ };
972
+ created: {
973
+ created: string;
974
+ expires: null;
975
+ isDisabled: false;
976
+ isExpired: false;
977
+ scopes: string[];
978
+ creator: {
979
+ id: number;
980
+ name: string;
981
+ };
982
+ id: number;
983
+ description: string;
984
+ lastUsed: null;
985
+ token: string;
986
+ };
987
+ };
988
+ };
989
+ uiApps: {
990
+ getUiApp: typeof getUiApp;
991
+ getUiApps: typeof getUiApps;
992
+ fixtures: {
993
+ active: {
994
+ stringId: string;
995
+ name: string;
996
+ version: string;
997
+ basePath: string;
998
+ type: string;
999
+ scripts: string[];
1000
+ styles: string[];
1001
+ isCritical: false;
1002
+ commitSha: string;
1003
+ };
1004
+ inactive: {
1005
+ stringId: string;
1006
+ name: string;
1007
+ version: null;
1008
+ basePath: null;
1009
+ type: null;
1010
+ scripts: never[];
1011
+ styles: never[];
1012
+ isCritical: false;
1013
+ commitSha: null;
1014
+ };
1015
+ detail: {
1016
+ id: number;
1017
+ stringId: string;
1018
+ name: string;
1019
+ created: string;
1020
+ versions: ({
1021
+ id: number;
1022
+ version: string;
1023
+ created: string;
1024
+ isActive: true;
1025
+ isCritical: false;
1026
+ buildUrl: string;
1027
+ commitSha: string;
1028
+ } | {
1029
+ id: number;
1030
+ version: string;
1031
+ created: string;
1032
+ isActive: false;
1033
+ isCritical: true;
1034
+ buildUrl: null;
1035
+ commitSha: null;
1036
+ })[];
1037
+ };
1038
+ };
1039
+ };
1040
+ };
812
1041
  storage: {
813
1042
  bootstrap: {
814
1043
  getStackInfo: typeof getStackInfo;
@@ -1541,5 +1770,5 @@ declare const fixtures: {
1541
1770
  };
1542
1771
  };
1543
1772
  //#endregion
1544
- export { DEFAULT_BASE_URL, type Table, type TableDetail, appFixtures, deploymentFixtures, developerPortalFixtures, fixtures, getApp, getAppRun, getBusinessWorkspaceDashboard, getBusinessWorkspaceDashboardInput, getDeployment, getDevBranches, getStackInfo, getTable, getVendor, listAllApps, listAllVendors, listAppChanges, listAppRuns, listApps, listBusinessWorkspaceDashboards, listDeployments, listPublishedApps, listServiceAccounts, listTables, listUsers, listVendorApps, listVendors, runFixtures, tableFixtures, verifyStorageToken };
1773
+ export { type ApplicationToken, type CreatedApplicationToken, DEFAULT_BASE_URL, type Table, type TableDetail, type UiApp, type UiAppDetail, appFixtures, applicationTokenFixtures, deploymentFixtures, developerPortalFixtures, fixtures, getApp, getAppRun, getApplicationToken, getApplicationTokens, getBusinessWorkspaceDashboard, getBusinessWorkspaceDashboardInput, getDeployment, getDevBranches, getStackInfo, getTable, getUiApp, getUiApps, getVendor, listAllApps, listAllVendors, listAppChanges, listAppRuns, listApps, listBusinessWorkspaceDashboards, listDeployments, listPublishedApps, listServiceAccounts, listTables, listUsers, listVendorApps, listVendors, runFixtures, tableFixtures, uiAppFixtures, verifyStorageToken };
1545
1774
  //# sourceMappingURL=index.d.ts.map