@mittwald/api-client 4.519.0 → 4.520.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.
@@ -2006,6 +2006,22 @@ export declare namespace MittwaldAPIV2 {
2006
2006
  type RequestData = InferredRequestData<typeof descriptors.verificationVerifyCompany>;
2007
2007
  type ResponseData<TStatus extends HttpStatus = 200> = InferredResponseData<typeof descriptors.verificationVerifyCompany, TStatus>;
2008
2008
  }
2009
+ namespace ProjectGetUsageMetricsBreakdown {
2010
+ type RequestData = InferredRequestData<typeof descriptors.projectGetUsageMetricsBreakdown>;
2011
+ type ResponseData<TStatus extends HttpStatus = 200> = InferredResponseData<typeof descriptors.projectGetUsageMetricsBreakdown, TStatus>;
2012
+ }
2013
+ namespace ProjectGetUsageMetrics {
2014
+ type RequestData = InferredRequestData<typeof descriptors.projectGetUsageMetrics>;
2015
+ type ResponseData<TStatus extends HttpStatus = 200> = InferredResponseData<typeof descriptors.projectGetUsageMetrics, TStatus>;
2016
+ }
2017
+ namespace ProjectGetServerUsageMetricsBreakdown {
2018
+ type RequestData = InferredRequestData<typeof descriptors.projectGetServerUsageMetricsBreakdown>;
2019
+ type ResponseData<TStatus extends HttpStatus = 200> = InferredResponseData<typeof descriptors.projectGetServerUsageMetricsBreakdown, TStatus>;
2020
+ }
2021
+ namespace ProjectGetServerUsageMetrics {
2022
+ type RequestData = InferredRequestData<typeof descriptors.projectGetServerUsageMetrics>;
2023
+ type ResponseData<TStatus extends HttpStatus = 200> = InferredResponseData<typeof descriptors.projectGetServerUsageMetrics, TStatus>;
2024
+ }
2009
2025
  }
2010
2026
  namespace Components {
2011
2027
  namespace Schemas {
@@ -9215,6 +9231,53 @@ export declare namespace MittwaldAPIV2 {
9215
9231
  }
9216
9232
  type VerificationEmailOrigin = "IS_MITTWALD" | "IS_NOT_MITTWALD" | "COULD_BE_MITTWALD";
9217
9233
  type ContainerVolumeSortOrder = "nameAsc" | "nameDesc" | "storageAsc" | "storageDesc";
9234
+ interface UsagemetricsGetProjectUsageBreakdownResponse {
9235
+ /**
9236
+ * Usage of all apps relative to the applicable limit.
9237
+ */
9238
+ apps: MittwaldAPIV2.Components.Schemas.UsagemetricsSeries[];
9239
+ /**
9240
+ * Usage per container relative to the applicable limit, labelled with `stack` and `container`.
9241
+ */
9242
+ containers: MittwaldAPIV2.Components.Schemas.UsagemetricsSeries[];
9243
+ /**
9244
+ * Usage of all databases relative to the applicable limit; empty for projects on a dedicated server or proSpace lite.
9245
+ */
9246
+ databases: MittwaldAPIV2.Components.Schemas.UsagemetricsSeries[];
9247
+ }
9248
+ interface UsagemetricsGetServerUsageBreakdownResponse {
9249
+ /**
9250
+ * Absolute database usage (CPU seconds per second or memory bytes), labelled with `database_type` and `database_version`.
9251
+ */
9252
+ databases: MittwaldAPIV2.Components.Schemas.UsagemetricsSeries[];
9253
+ /**
9254
+ * Current server limit in the unit of the requested metric (CPU seconds per second or memory bytes).
9255
+ */
9256
+ limit: number;
9257
+ /**
9258
+ * Usage per project relative to the server limit, labelled with `project`.
9259
+ */
9260
+ projects: MittwaldAPIV2.Components.Schemas.UsagemetricsSeries[];
9261
+ }
9262
+ interface UsagemetricsGetUsageResponse {
9263
+ /**
9264
+ * Usage relative to the applicable limit (1 = 100 %).
9265
+ */
9266
+ series: MittwaldAPIV2.Components.Schemas.UsagemetricsSeries[];
9267
+ }
9268
+ interface UsagemetricsSample {
9269
+ time: string;
9270
+ value: number;
9271
+ }
9272
+ interface UsagemetricsSeries {
9273
+ /**
9274
+ * Prometheus labels identifying the series, e.g. `project`, `stack`, `container`, `database_type` or `database_version`; empty for an aggregated series.
9275
+ */
9276
+ labels: {
9277
+ [k: string]: string;
9278
+ };
9279
+ samples: MittwaldAPIV2.Components.Schemas.UsagemetricsSample[];
9280
+ }
9218
9281
  interface CommonsAddress {
9219
9282
  street: string;
9220
9283
  houseNumber: string;
@@ -35702,5 +35765,289 @@ export declare namespace MittwaldAPIV2 {
35702
35765
  }
35703
35766
  }
35704
35767
  }
35768
+ namespace V2ProjectsProjectIdUsageMetricsBreakdown {
35769
+ namespace Get {
35770
+ namespace Parameters {
35771
+ type Path = {
35772
+ projectId: string;
35773
+ };
35774
+ type Header = {} & MittwaldAPIV2.Components.SecuritySchemes.CommonsAccessToken;
35775
+ type Query = {
35776
+ metric: "cpu" | "memory";
35777
+ from?: string | Date;
35778
+ to?: string | Date;
35779
+ };
35780
+ }
35781
+ namespace Responses {
35782
+ namespace $200 {
35783
+ namespace Content {
35784
+ type ApplicationJson = MittwaldAPIV2.Components.Schemas.UsagemetricsGetProjectUsageBreakdownResponse;
35785
+ }
35786
+ }
35787
+ namespace $400 {
35788
+ namespace Content {
35789
+ interface ApplicationJson {
35790
+ [k: string]: unknown;
35791
+ }
35792
+ }
35793
+ }
35794
+ namespace $403 {
35795
+ namespace Content {
35796
+ interface ApplicationJson {
35797
+ [k: string]: unknown;
35798
+ }
35799
+ }
35800
+ }
35801
+ namespace $404 {
35802
+ namespace Content {
35803
+ interface ApplicationJson {
35804
+ [k: string]: unknown;
35805
+ }
35806
+ }
35807
+ }
35808
+ namespace $429 {
35809
+ namespace Content {
35810
+ interface ApplicationJson {
35811
+ [k: string]: unknown;
35812
+ }
35813
+ }
35814
+ }
35815
+ namespace $500 {
35816
+ namespace Content {
35817
+ interface ApplicationJson {
35818
+ [k: string]: unknown;
35819
+ }
35820
+ }
35821
+ }
35822
+ namespace $503 {
35823
+ namespace Content {
35824
+ interface ApplicationJson {
35825
+ [k: string]: unknown;
35826
+ }
35827
+ }
35828
+ }
35829
+ namespace Default {
35830
+ namespace Content {
35831
+ interface ApplicationJson {
35832
+ [k: string]: unknown;
35833
+ }
35834
+ }
35835
+ }
35836
+ }
35837
+ }
35838
+ }
35839
+ namespace V2ProjectsProjectIdUsageMetrics {
35840
+ namespace Get {
35841
+ namespace Parameters {
35842
+ type Path = {
35843
+ projectId: string;
35844
+ };
35845
+ type Header = {} & MittwaldAPIV2.Components.SecuritySchemes.CommonsAccessToken;
35846
+ type Query = {
35847
+ metric: "cpu" | "memory";
35848
+ from?: string | Date;
35849
+ to?: string | Date;
35850
+ };
35851
+ }
35852
+ namespace Responses {
35853
+ namespace $200 {
35854
+ namespace Content {
35855
+ type ApplicationJson = MittwaldAPIV2.Components.Schemas.UsagemetricsGetUsageResponse;
35856
+ }
35857
+ }
35858
+ namespace $400 {
35859
+ namespace Content {
35860
+ interface ApplicationJson {
35861
+ [k: string]: unknown;
35862
+ }
35863
+ }
35864
+ }
35865
+ namespace $403 {
35866
+ namespace Content {
35867
+ interface ApplicationJson {
35868
+ [k: string]: unknown;
35869
+ }
35870
+ }
35871
+ }
35872
+ namespace $404 {
35873
+ namespace Content {
35874
+ interface ApplicationJson {
35875
+ [k: string]: unknown;
35876
+ }
35877
+ }
35878
+ }
35879
+ namespace $429 {
35880
+ namespace Content {
35881
+ interface ApplicationJson {
35882
+ [k: string]: unknown;
35883
+ }
35884
+ }
35885
+ }
35886
+ namespace $500 {
35887
+ namespace Content {
35888
+ interface ApplicationJson {
35889
+ [k: string]: unknown;
35890
+ }
35891
+ }
35892
+ }
35893
+ namespace $503 {
35894
+ namespace Content {
35895
+ interface ApplicationJson {
35896
+ [k: string]: unknown;
35897
+ }
35898
+ }
35899
+ }
35900
+ namespace Default {
35901
+ namespace Content {
35902
+ interface ApplicationJson {
35903
+ [k: string]: unknown;
35904
+ }
35905
+ }
35906
+ }
35907
+ }
35908
+ }
35909
+ }
35910
+ namespace V2ServersServerIdUsageMetricsBreakdown {
35911
+ namespace Get {
35912
+ namespace Parameters {
35913
+ type Path = {
35914
+ serverId: string;
35915
+ };
35916
+ type Header = {} & MittwaldAPIV2.Components.SecuritySchemes.CommonsAccessToken;
35917
+ type Query = {
35918
+ metric: "cpu" | "memory";
35919
+ from?: string | Date;
35920
+ to?: string | Date;
35921
+ };
35922
+ }
35923
+ namespace Responses {
35924
+ namespace $200 {
35925
+ namespace Content {
35926
+ type ApplicationJson = MittwaldAPIV2.Components.Schemas.UsagemetricsGetServerUsageBreakdownResponse;
35927
+ }
35928
+ }
35929
+ namespace $400 {
35930
+ namespace Content {
35931
+ interface ApplicationJson {
35932
+ [k: string]: unknown;
35933
+ }
35934
+ }
35935
+ }
35936
+ namespace $403 {
35937
+ namespace Content {
35938
+ interface ApplicationJson {
35939
+ [k: string]: unknown;
35940
+ }
35941
+ }
35942
+ }
35943
+ namespace $404 {
35944
+ namespace Content {
35945
+ interface ApplicationJson {
35946
+ [k: string]: unknown;
35947
+ }
35948
+ }
35949
+ }
35950
+ namespace $429 {
35951
+ namespace Content {
35952
+ interface ApplicationJson {
35953
+ [k: string]: unknown;
35954
+ }
35955
+ }
35956
+ }
35957
+ namespace $500 {
35958
+ namespace Content {
35959
+ interface ApplicationJson {
35960
+ [k: string]: unknown;
35961
+ }
35962
+ }
35963
+ }
35964
+ namespace $503 {
35965
+ namespace Content {
35966
+ interface ApplicationJson {
35967
+ [k: string]: unknown;
35968
+ }
35969
+ }
35970
+ }
35971
+ namespace Default {
35972
+ namespace Content {
35973
+ interface ApplicationJson {
35974
+ [k: string]: unknown;
35975
+ }
35976
+ }
35977
+ }
35978
+ }
35979
+ }
35980
+ }
35981
+ namespace V2ServersServerIdUsageMetrics {
35982
+ namespace Get {
35983
+ namespace Parameters {
35984
+ type Path = {
35985
+ serverId: string;
35986
+ };
35987
+ type Header = {} & MittwaldAPIV2.Components.SecuritySchemes.CommonsAccessToken;
35988
+ type Query = {
35989
+ metric: "cpu" | "memory";
35990
+ from?: string | Date;
35991
+ to?: string | Date;
35992
+ };
35993
+ }
35994
+ namespace Responses {
35995
+ namespace $200 {
35996
+ namespace Content {
35997
+ type ApplicationJson = MittwaldAPIV2.Components.Schemas.UsagemetricsGetUsageResponse;
35998
+ }
35999
+ }
36000
+ namespace $400 {
36001
+ namespace Content {
36002
+ interface ApplicationJson {
36003
+ [k: string]: unknown;
36004
+ }
36005
+ }
36006
+ }
36007
+ namespace $403 {
36008
+ namespace Content {
36009
+ interface ApplicationJson {
36010
+ [k: string]: unknown;
36011
+ }
36012
+ }
36013
+ }
36014
+ namespace $404 {
36015
+ namespace Content {
36016
+ interface ApplicationJson {
36017
+ [k: string]: unknown;
36018
+ }
36019
+ }
36020
+ }
36021
+ namespace $429 {
36022
+ namespace Content {
36023
+ interface ApplicationJson {
36024
+ [k: string]: unknown;
36025
+ }
36026
+ }
36027
+ }
36028
+ namespace $500 {
36029
+ namespace Content {
36030
+ interface ApplicationJson {
36031
+ [k: string]: unknown;
36032
+ }
36033
+ }
36034
+ }
36035
+ namespace $503 {
36036
+ namespace Content {
36037
+ interface ApplicationJson {
36038
+ [k: string]: unknown;
36039
+ }
36040
+ }
36041
+ }
36042
+ namespace Default {
36043
+ namespace Content {
36044
+ interface ApplicationJson {
36045
+ [k: string]: unknown;
36046
+ }
36047
+ }
36048
+ }
36049
+ }
36050
+ }
36051
+ }
35705
36052
  }
35706
36053
  }
@@ -3975,6 +3975,74 @@ declare const buildProjectApi: (baseClient: MittwaldAPIV3NextClient) => {
3975
3975
  notificationThresholdInBytes?: number | undefined;
3976
3976
  statisticCategories?: import("./types.js").MittwaldAPIV3Next.Components.Schemas.DeMittwaldStoragespaceStatisticsCategory[] | undefined;
3977
3977
  }>;
3978
+ /** Get a usage-metrics breakdown for a project. */
3979
+ getUsageMetricsBreakdown: (conf: {
3980
+ queryParameters: {
3981
+ [x: string]: (string | number | boolean | Date) | (string | number | boolean | Date)[] | undefined;
3982
+ metric: "cpu" | "memory";
3983
+ from?: (string | Date) | undefined;
3984
+ to?: (string | Date) | undefined;
3985
+ };
3986
+ projectId: string;
3987
+ headers?: {
3988
+ [x: string]: (string | number | boolean | Date) | (string | number | boolean | Date)[] | undefined;
3989
+ "x-access-token"?: string | undefined;
3990
+ } | undefined;
3991
+ }) => import("@mittwald/react-use-promise").AsyncResource<{
3992
+ apps: import("./types.js").MittwaldAPIV3Next.Components.Schemas.DeMittwaldUsagemetricsSeries[];
3993
+ containers: import("./types.js").MittwaldAPIV3Next.Components.Schemas.DeMittwaldUsagemetricsSeries[];
3994
+ databases: import("./types.js").MittwaldAPIV3Next.Components.Schemas.DeMittwaldUsagemetricsSeries[];
3995
+ }>;
3996
+ /** Get usage metrics for a project. */
3997
+ getUsageMetrics: (conf: {
3998
+ queryParameters: {
3999
+ [x: string]: (string | number | boolean | Date) | (string | number | boolean | Date)[] | undefined;
4000
+ metric: "cpu" | "memory";
4001
+ from?: (string | Date) | undefined;
4002
+ to?: (string | Date) | undefined;
4003
+ };
4004
+ projectId: string;
4005
+ headers?: {
4006
+ [x: string]: (string | number | boolean | Date) | (string | number | boolean | Date)[] | undefined;
4007
+ "x-access-token"?: string | undefined;
4008
+ } | undefined;
4009
+ }) => import("@mittwald/react-use-promise").AsyncResource<{
4010
+ series: import("./types.js").MittwaldAPIV3Next.Components.Schemas.DeMittwaldUsagemetricsSeries[];
4011
+ }>;
4012
+ /** Get a usage-metrics breakdown for a server. */
4013
+ getServerUsageMetricsBreakdown: (conf: {
4014
+ queryParameters: {
4015
+ [x: string]: (string | number | boolean | Date) | (string | number | boolean | Date)[] | undefined;
4016
+ metric: "cpu" | "memory";
4017
+ from?: (string | Date) | undefined;
4018
+ to?: (string | Date) | undefined;
4019
+ };
4020
+ serverId: string;
4021
+ headers?: {
4022
+ [x: string]: (string | number | boolean | Date) | (string | number | boolean | Date)[] | undefined;
4023
+ "x-access-token"?: string | undefined;
4024
+ } | undefined;
4025
+ }) => import("@mittwald/react-use-promise").AsyncResource<{
4026
+ databases: import("./types.js").MittwaldAPIV3Next.Components.Schemas.DeMittwaldUsagemetricsSeries[];
4027
+ limit: number;
4028
+ projects: import("./types.js").MittwaldAPIV3Next.Components.Schemas.DeMittwaldUsagemetricsSeries[];
4029
+ }>;
4030
+ /** Get usage metrics for a server. */
4031
+ getServerUsageMetrics: (conf: {
4032
+ queryParameters: {
4033
+ [x: string]: (string | number | boolean | Date) | (string | number | boolean | Date)[] | undefined;
4034
+ metric: "cpu" | "memory";
4035
+ from?: (string | Date) | undefined;
4036
+ to?: (string | Date) | undefined;
4037
+ };
4038
+ serverId: string;
4039
+ headers?: {
4040
+ [x: string]: (string | number | boolean | Date) | (string | number | boolean | Date)[] | undefined;
4041
+ "x-access-token"?: string | undefined;
4042
+ } | undefined;
4043
+ }) => import("@mittwald/react-use-promise").AsyncResource<{
4044
+ series: import("./types.js").MittwaldAPIV3Next.Components.Schemas.DeMittwaldUsagemetricsSeries[];
4045
+ }>;
3978
4046
  };
3979
4047
  declare const buildProjectFileSystemApi: (baseClient: MittwaldAPIV3NextClient) => {
3980
4048
  /** List directories belonging to a Project. */