diff --git a/.changeset/thick-guests-shout.md b/.changeset/thick-guests-shout.md new file mode 100644 index 0000000000..bbe29399a7 --- /dev/null +++ b/.changeset/thick-guests-shout.md @@ -0,0 +1,5 @@ +--- +'@nhost/docs': patch +--- + +update fqdn format for nhost run diff --git a/dashboard/CHANGELOG.md b/dashboard/CHANGELOG.md index 26130de60d..ac901c2371 100644 --- a/dashboard/CHANGELOG.md +++ b/dashboard/CHANGELOG.md @@ -1,5 +1,11 @@ # @nhost/dashboard +## 0.20.12 + +### Patch Changes + +- b7c799d62: feat(run): add dialog to copy registry and URLs + ## 0.20.11 ### Patch Changes diff --git a/dashboard/package.json b/dashboard/package.json index 1de38be9f2..fb507d59a3 100644 --- a/dashboard/package.json +++ b/dashboard/package.json @@ -1,6 +1,6 @@ { "name": "@nhost/dashboard", - "version": "0.20.11", + "version": "0.20.12", "private": true, "scripts": { "preinstall": "npx only-allow pnpm", diff --git a/dashboard/src/features/services/components/ServiceForm/ServiceForm.tsx b/dashboard/src/features/services/components/ServiceForm/ServiceForm.tsx index 11bb1590c5..faee75f35c 100644 --- a/dashboard/src/features/services/components/ServiceForm/ServiceForm.tsx +++ b/dashboard/src/features/services/components/ServiceForm/ServiceForm.tsx @@ -43,6 +43,7 @@ import { toast } from 'react-hot-toast'; import { parse } from 'shell-quote'; import * as Yup from 'yup'; import { ServiceConfirmationDialog } from './components/ServiceConfirmationDialog'; +import { ServiceDetailsDialog } from './components/ServiceDetailsDialog'; export enum PortTypes { HTTP = 'http', @@ -94,7 +95,7 @@ export interface ServiceFormProps extends DialogFormProps { /** * if there is initialData then it's an update operation */ - initialData?: ServiceFormValues; + initialData?: ServiceFormValues & { subdomain?: string }; // subdomain is only set on the backend /** * Function to be called when the operation is cancelled. @@ -119,6 +120,10 @@ export default function ServiceForm({ const { currentProject } = useCurrentWorkspaceAndProject(); const [insertRunServiceConfig] = useInsertRunServiceConfigMutation(); const [replaceRunServiceConfig] = useReplaceRunServiceConfigMutation(); + const [detailsServiceId, setDetailsServiceId] = useState(''); + const [detailsServiceSubdomain, setDetailsServiceSubdomain] = useState( + initialData.subdomain, + ); const [createServiceFormError, setCreateServiceFormError] = useState(null); @@ -196,11 +201,13 @@ export default function ServiceForm({ config, }, }); + + setDetailsServiceId(serviceID); } else { // Insert service config const { data: { - insertRunService: { id: newServiceID }, + insertRunService: { id: newServiceID, subdomain }, }, } = await insertRunService({ variables: { @@ -227,6 +234,9 @@ export default function ServiceForm({ }, }, }); + + setDetailsServiceId(newServiceID); + setDetailsServiceSubdomain(subdomain); } }; @@ -254,8 +264,6 @@ export default function ServiceForm({ getToastStyleProps(), ); - // await refetchWorkspaceAndProject(); - // refestch the services onSubmit?.(); } catch { // Note: The toast will handle the error. @@ -277,6 +285,29 @@ export default function ServiceForm({ }); }; + useEffect(() => { + (async () => { + if (detailsServiceId) { + openDialog({ + title: 'Service Details', + component: ( + + ), + props: { + PaperProps: { + className: 'max-w-2xl', + }, + }, + }); + } + })(); + }, [detailsServiceId, detailsServiceSubdomain, formValues, openDialog]); + const pricingExplanation = () => { const vCPUs = `${formValues.compute.cpu / RESOURCE_VCPU_MULTIPLIER} vCPUs`; const mem = `${formValues.compute.memory} MiB Mem`; diff --git a/dashboard/src/features/services/components/ServiceForm/components/PortsFormSection/PortsFormSection.tsx b/dashboard/src/features/services/components/ServiceForm/components/PortsFormSection/PortsFormSection.tsx index 323b25bb16..6c6a7006fe 100644 --- a/dashboard/src/features/services/components/ServiceForm/components/PortsFormSection/PortsFormSection.tsx +++ b/dashboard/src/features/services/components/ServiceForm/components/PortsFormSection/PortsFormSection.tsx @@ -32,20 +32,20 @@ export default function PortsFormSection() { name: 'ports', }); - const formValues = useWatch(); + const formValues = useWatch(); const onChangePortType = (value: string | undefined, index: number) => setValue(`ports.${index}.type`, value as PortTypes); const showURL = (index: number) => + formValues.subdomain && formValues.ports[index]?.type === PortTypes.HTTP && formValues.ports[index]?.publish; - const getPortURL = (_port: string | number, _name: string) => { + const getPortURL = (_port: string | number, subdomain: string) => { const port = Number(_port) > 0 ? Number(_port) : '[port]'; - const name = _name && _name.length > 0 ? _name : '[name]'; - return `https://${currentProject?.subdomain}-${name}-${port}.svc.${currentProject?.region.awsName}.${currentProject?.region.domain}`; + return `https://${subdomain}-${port}.svc.${currentProject?.region.awsName}.${currentProject?.region.domain}`; }; return ( @@ -144,7 +144,7 @@ export default function PortsFormSection() { title="URL" value={getPortURL( formValues.ports[index]?.port, - formValues.name, + formValues.subdomain, )} /> )} diff --git a/dashboard/src/features/services/components/ServiceForm/components/ServiceDetailsDialog/ServiceDetailsDialog.tsx b/dashboard/src/features/services/components/ServiceForm/components/ServiceDetailsDialog/ServiceDetailsDialog.tsx new file mode 100644 index 0000000000..70b702759f --- /dev/null +++ b/dashboard/src/features/services/components/ServiceForm/components/ServiceDetailsDialog/ServiceDetailsDialog.tsx @@ -0,0 +1,84 @@ +import { useDialog } from '@/components/common/DialogProvider'; +import { Button } from '@/components/ui/v2/Button'; +import { Text } from '@/components/ui/v2/Text'; +import { useCurrentWorkspaceAndProject } from '@/features/projects/common/hooks/useCurrentWorkspaceAndProject'; +import { InfoCard } from '@/features/projects/overview/components/InfoCard'; +import type { ConfigRunServicePort } from '@/utils/__generated__/graphql'; + +export interface ServiceDetailsDialogProps { + /** + * The id of the service + */ + serviceID: string; + + /** + * The subdomain of the service + */ + subdomain: string; + + /** + * The image of the service + */ + image: string; + + /** + * The image of the service + * We use partial here because `port` is set as required in ConfigRunServicePort + */ + ports: Partial[]; +} + +export default function ServiceDetailsDialog({ + serviceID, + subdomain, + image, + ports, +}: ServiceDetailsDialogProps) { + const { currentProject } = useCurrentWorkspaceAndProject(); + + const { closeDialog } = useDialog(); + + const getPortURL = (_port: string | number) => { + const port = Number(_port) > 0 ? Number(_port) : '[port]'; + + return `https://${subdomain}-${port}.svc.${currentProject?.region.awsName}.${currentProject?.region.domain}`; + }; + + return ( +
+
+ Private registry + +
+ + {ports?.length > 0 && ( +
+ Ports + {ports + .filter((port) => port.publish) + .map((port) => ( + + ))} +
+ )} + + +
+ ); +} diff --git a/dashboard/src/features/services/components/ServiceForm/components/ServiceDetailsDialog/index.ts b/dashboard/src/features/services/components/ServiceForm/components/ServiceDetailsDialog/index.ts new file mode 100644 index 0000000000..63bdb97bcd --- /dev/null +++ b/dashboard/src/features/services/components/ServiceForm/components/ServiceDetailsDialog/index.ts @@ -0,0 +1,2 @@ +export * from './ServiceDetailsDialog'; +export { default as ServiceDetailsDialog } from './ServiceDetailsDialog'; diff --git a/dashboard/src/features/services/components/ServicesList/ServicesList.tsx b/dashboard/src/features/services/components/ServicesList/ServicesList.tsx index 691dd5096c..3b27f8c9f3 100644 --- a/dashboard/src/features/services/components/ServicesList/ServicesList.tsx +++ b/dashboard/src/features/services/components/ServicesList/ServicesList.tsx @@ -76,6 +76,7 @@ export default function ServicesList({ initialData={{ ...service.config, image: service.config?.image?.image, + subdomain: service.subdomain, command: service.config?.command?.join(' '), ports: service.config?.ports?.map((item) => ({ port: item.port, diff --git a/dashboard/src/gql/services/getRunService.graphql b/dashboard/src/gql/services/getRunService.graphql index d4975ebbc7..d80b38135d 100644 --- a/dashboard/src/gql/services/getRunService.graphql +++ b/dashboard/src/gql/services/getRunService.graphql @@ -1,6 +1,7 @@ query getRunService($id: uuid!, $resolve: Boolean!) { runService(id: $id) { id + subdomain config(resolve: $resolve) { name image { diff --git a/dashboard/src/gql/services/getRunServices.graphql b/dashboard/src/gql/services/getRunServices.graphql index 2692480d6b..52c14bb162 100644 --- a/dashboard/src/gql/services/getRunServices.graphql +++ b/dashboard/src/gql/services/getRunServices.graphql @@ -9,6 +9,7 @@ query getRunServices( id createdAt updatedAt + subdomain config(resolve: $resolve) { name image { diff --git a/dashboard/src/gql/services/inserRunService.graphql b/dashboard/src/gql/services/inserRunService.graphql index b5d81a7d5e..b5eda64087 100644 --- a/dashboard/src/gql/services/inserRunService.graphql +++ b/dashboard/src/gql/services/inserRunService.graphql @@ -1,6 +1,6 @@ mutation insertRunService($object: run_service_insert_input!) { insertRunService(object: $object) { id - appID + subdomain } } diff --git a/dashboard/src/utils/__generated__/graphql.ts b/dashboard/src/utils/__generated__/graphql.ts index 5c2dace805..73fb044837 100644 --- a/dashboard/src/utils/__generated__/graphql.ts +++ b/dashboard/src/utils/__generated__/graphql.ts @@ -1271,6 +1271,26 @@ export type ConfigHasuraUpdateInput = { webhookSecret?: InputMaybe; }; +export type ConfigIngress = { + __typename?: 'ConfigIngress'; + fqdn?: Maybe>; +}; + +export type ConfigIngressComparisonExp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + fqdn?: InputMaybe; +}; + +export type ConfigIngressInsertInput = { + fqdn?: InputMaybe>; +}; + +export type ConfigIngressUpdateInput = { + fqdn?: InputMaybe>; +}; + export type ConfigInsertConfigResponse = { __typename?: 'ConfigInsertConfigResponse'; config: ConfigConfig; @@ -1353,6 +1373,26 @@ export type ConfigLocaleComparisonExp = { _nin?: InputMaybe>; }; +export type ConfigNetworking = { + __typename?: 'ConfigNetworking'; + ingresses?: Maybe>; +}; + +export type ConfigNetworkingComparisonExp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + ingresses?: InputMaybe; +}; + +export type ConfigNetworkingInsertInput = { + ingresses?: InputMaybe>; +}; + +export type ConfigNetworkingUpdateInput = { + ingresses?: InputMaybe>; +}; + export type ConfigObservability = { __typename?: 'ConfigObservability'; grafana: ConfigGrafana; @@ -1438,6 +1478,7 @@ export type ConfigProviderUpdateInput = { export type ConfigResources = { __typename?: 'ConfigResources'; compute: ConfigResourcesCompute; + networking?: Maybe; /** Number of replicas for a service */ replicas: Scalars['ConfigUint8']; }; @@ -1447,6 +1488,7 @@ export type ConfigResourcesComparisonExp = { _not?: InputMaybe; _or?: InputMaybe>; compute?: InputMaybe; + networking?: InputMaybe; replicas?: InputMaybe; }; @@ -1478,11 +1520,13 @@ export type ConfigResourcesComputeUpdateInput = { export type ConfigResourcesInsertInput = { compute: ConfigResourcesComputeInsertInput; + networking?: InputMaybe; replicas: Scalars['ConfigUint8']; }; export type ConfigResourcesUpdateInput = { compute?: InputMaybe; + networking?: InputMaybe; replicas?: InputMaybe; }; @@ -1554,6 +1598,7 @@ export type ConfigRunServiceImageUpdateInput = { export type ConfigRunServicePort = { __typename?: 'ConfigRunServicePort'; + ingress?: Maybe; port: Scalars['ConfigPort']; publish?: Maybe; type: Scalars['String']; @@ -1563,18 +1608,21 @@ export type ConfigRunServicePortComparisonExp = { _and?: InputMaybe>; _not?: InputMaybe; _or?: InputMaybe>; + ingress?: InputMaybe; port?: InputMaybe; publish?: InputMaybe; type?: InputMaybe; }; export type ConfigRunServicePortInsertInput = { + ingress?: InputMaybe; port: Scalars['ConfigPort']; publish?: InputMaybe; type: Scalars['String']; }; export type ConfigRunServicePortUpdateInput = { + ingress?: InputMaybe; port?: InputMaybe; publish?: InputMaybe; type?: InputMaybe; @@ -1806,7 +1854,10 @@ export type ConfigStandardOauthProviderWithScopeUpdateInput = { export type ConfigStorage = { __typename?: 'ConfigStorage'; antivirus?: Maybe; - /** Resources for the service */ + /** + * Networking (custom domains at the moment) are not allowed as we need to do further + * configurations in the CDN. We will enable it again in the future. + */ resources?: Maybe; /** * Version of storage service, you can see available versions in the URL below: @@ -2052,10 +2103,17 @@ export type Int_Comparison_Exp = { _nin?: InputMaybe>; }; +export type InvoiceItem = { + __typename?: 'InvoiceItem'; + Amount: Scalars['float64']; + Description: Scalars['String']; +}; + export type InvoiceSummary = { __typename?: 'InvoiceSummary'; AmountDue: Scalars['float64']; PeriodEnd: Scalars['Timestamp']; + items: Array; }; export type Log = { @@ -5965,11 +6023,11 @@ export type Billing_Dedicated_Compute = { __typename?: 'billing_dedicated_compute'; /** An object relationship */ app?: Maybe; - app_id: Scalars['uuid']; - created_at: Scalars['timestamptz']; + appID: Scalars['uuid']; + createdAt: Scalars['timestamptz']; id: Scalars['uuid']; - total_millicores: Scalars['Int']; - updated_at: Scalars['timestamptz']; + totalMillicores: Scalars['Int']; + updatedAt: Scalars['timestamptz']; }; /** aggregated selection of "billing.dedicated_compute" */ @@ -6005,7 +6063,7 @@ export type Billing_Dedicated_Compute_Aggregate_FieldsCountArgs = { /** aggregate avg on columns */ export type Billing_Dedicated_Compute_Avg_Fields = { __typename?: 'billing_dedicated_compute_avg_fields'; - total_millicores?: Maybe; + totalMillicores?: Maybe; }; /** Boolean expression to filter rows from the table "billing.dedicated_compute". All fields are combined with a logical 'AND'. */ @@ -6014,11 +6072,11 @@ export type Billing_Dedicated_Compute_Bool_Exp = { _not?: InputMaybe; _or?: InputMaybe>; app?: InputMaybe; - app_id?: InputMaybe; - created_at?: InputMaybe; + appID?: InputMaybe; + createdAt?: InputMaybe; id?: InputMaybe; - total_millicores?: InputMaybe; - updated_at?: InputMaybe; + totalMillicores?: InputMaybe; + updatedAt?: InputMaybe; }; /** unique or primary key constraints on table "billing.dedicated_compute" */ @@ -6031,37 +6089,37 @@ export enum Billing_Dedicated_Compute_Constraint { /** input type for incrementing numeric columns in table "billing.dedicated_compute" */ export type Billing_Dedicated_Compute_Inc_Input = { - total_millicores?: InputMaybe; + totalMillicores?: InputMaybe; }; /** input type for inserting data into table "billing.dedicated_compute" */ export type Billing_Dedicated_Compute_Insert_Input = { app?: InputMaybe; - app_id?: InputMaybe; - created_at?: InputMaybe; + appID?: InputMaybe; + createdAt?: InputMaybe; id?: InputMaybe; - total_millicores?: InputMaybe; - updated_at?: InputMaybe; + totalMillicores?: InputMaybe; + updatedAt?: InputMaybe; }; /** aggregate max on columns */ export type Billing_Dedicated_Compute_Max_Fields = { __typename?: 'billing_dedicated_compute_max_fields'; - app_id?: Maybe; - created_at?: Maybe; + appID?: Maybe; + createdAt?: Maybe; id?: Maybe; - total_millicores?: Maybe; - updated_at?: Maybe; + totalMillicores?: Maybe; + updatedAt?: Maybe; }; /** aggregate min on columns */ export type Billing_Dedicated_Compute_Min_Fields = { __typename?: 'billing_dedicated_compute_min_fields'; - app_id?: Maybe; - created_at?: Maybe; + appID?: Maybe; + createdAt?: Maybe; id?: Maybe; - total_millicores?: Maybe; - updated_at?: Maybe; + totalMillicores?: Maybe; + updatedAt?: Maybe; }; /** response of any mutation on the table "billing.dedicated_compute" */ @@ -6090,11 +6148,11 @@ export type Billing_Dedicated_Compute_On_Conflict = { /** Ordering options when selecting data from "billing.dedicated_compute". */ export type Billing_Dedicated_Compute_Order_By = { app?: InputMaybe; - app_id?: InputMaybe; - created_at?: InputMaybe; + appID?: InputMaybe; + createdAt?: InputMaybe; id?: InputMaybe; - total_millicores?: InputMaybe; - updated_at?: InputMaybe; + totalMillicores?: InputMaybe; + updatedAt?: InputMaybe; }; /** primary key columns input for table: billing.dedicated_compute */ @@ -6384,42 +6442,42 @@ export type Billing_Dedicated_Compute_Reports_Variance_Fields = { /** select columns of table "billing.dedicated_compute" */ export enum Billing_Dedicated_Compute_Select_Column { /** column name */ - AppId = 'app_id', + AppId = 'appID', /** column name */ - CreatedAt = 'created_at', + CreatedAt = 'createdAt', /** column name */ Id = 'id', /** column name */ - TotalMillicores = 'total_millicores', + TotalMillicores = 'totalMillicores', /** column name */ - UpdatedAt = 'updated_at' + UpdatedAt = 'updatedAt' } /** input type for updating data in table "billing.dedicated_compute" */ export type Billing_Dedicated_Compute_Set_Input = { - app_id?: InputMaybe; - created_at?: InputMaybe; + appID?: InputMaybe; + createdAt?: InputMaybe; id?: InputMaybe; - total_millicores?: InputMaybe; - updated_at?: InputMaybe; + totalMillicores?: InputMaybe; + updatedAt?: InputMaybe; }; /** aggregate stddev on columns */ export type Billing_Dedicated_Compute_Stddev_Fields = { __typename?: 'billing_dedicated_compute_stddev_fields'; - total_millicores?: Maybe; + totalMillicores?: Maybe; }; /** aggregate stddev_pop on columns */ export type Billing_Dedicated_Compute_Stddev_Pop_Fields = { __typename?: 'billing_dedicated_compute_stddev_pop_fields'; - total_millicores?: Maybe; + totalMillicores?: Maybe; }; /** aggregate stddev_samp on columns */ export type Billing_Dedicated_Compute_Stddev_Samp_Fields = { __typename?: 'billing_dedicated_compute_stddev_samp_fields'; - total_millicores?: Maybe; + totalMillicores?: Maybe; }; /** Streaming cursor of the table "billing_dedicated_compute" */ @@ -6432,31 +6490,31 @@ export type Billing_Dedicated_Compute_Stream_Cursor_Input = { /** Initial value of the column from where the streaming should start */ export type Billing_Dedicated_Compute_Stream_Cursor_Value_Input = { - app_id?: InputMaybe; - created_at?: InputMaybe; + appID?: InputMaybe; + createdAt?: InputMaybe; id?: InputMaybe; - total_millicores?: InputMaybe; - updated_at?: InputMaybe; + totalMillicores?: InputMaybe; + updatedAt?: InputMaybe; }; /** aggregate sum on columns */ export type Billing_Dedicated_Compute_Sum_Fields = { __typename?: 'billing_dedicated_compute_sum_fields'; - total_millicores?: Maybe; + totalMillicores?: Maybe; }; /** update columns of table "billing.dedicated_compute" */ export enum Billing_Dedicated_Compute_Update_Column { /** column name */ - AppId = 'app_id', + AppId = 'appID', /** column name */ - CreatedAt = 'created_at', + CreatedAt = 'createdAt', /** column name */ Id = 'id', /** column name */ - TotalMillicores = 'total_millicores', + TotalMillicores = 'totalMillicores', /** column name */ - UpdatedAt = 'updated_at' + UpdatedAt = 'updatedAt' } export type Billing_Dedicated_Compute_Updates = { @@ -6471,218 +6529,798 @@ export type Billing_Dedicated_Compute_Updates = { /** aggregate var_pop on columns */ export type Billing_Dedicated_Compute_Var_Pop_Fields = { __typename?: 'billing_dedicated_compute_var_pop_fields'; - total_millicores?: Maybe; + totalMillicores?: Maybe; }; /** aggregate var_samp on columns */ export type Billing_Dedicated_Compute_Var_Samp_Fields = { __typename?: 'billing_dedicated_compute_var_samp_fields'; - total_millicores?: Maybe; + totalMillicores?: Maybe; }; /** aggregate variance on columns */ export type Billing_Dedicated_Compute_Variance_Fields = { __typename?: 'billing_dedicated_compute_variance_fields'; - total_millicores?: Maybe; + totalMillicores?: Maybe; }; -/** columns and relationships of "billing.subscriptions" */ -export type Billing_Subscriptions = { - __typename?: 'billing_subscriptions'; - /** An object relationship */ - app?: Maybe; - app_id: Scalars['uuid']; - created_at: Scalars['timestamptz']; - dedicated_compute?: Maybe; - egress?: Maybe; - functions?: Maybe; - id: Scalars['uuid']; - updated_at: Scalars['timestamptz']; +/** columns and relationships of "billing.report_type" */ +export type Billing_Report_Type = { + __typename?: 'billing_report_type'; + comment?: Maybe; + value: Scalars['String']; }; -/** aggregated selection of "billing.subscriptions" */ -export type Billing_Subscriptions_Aggregate = { - __typename?: 'billing_subscriptions_aggregate'; - aggregate?: Maybe; - nodes: Array; +/** aggregated selection of "billing.report_type" */ +export type Billing_Report_Type_Aggregate = { + __typename?: 'billing_report_type_aggregate'; + aggregate?: Maybe; + nodes: Array; }; -/** aggregate fields of "billing.subscriptions" */ -export type Billing_Subscriptions_Aggregate_Fields = { - __typename?: 'billing_subscriptions_aggregate_fields'; +/** aggregate fields of "billing.report_type" */ +export type Billing_Report_Type_Aggregate_Fields = { + __typename?: 'billing_report_type_aggregate_fields'; count: Scalars['Int']; - max?: Maybe; - min?: Maybe; + max?: Maybe; + min?: Maybe; }; -/** aggregate fields of "billing.subscriptions" */ -export type Billing_Subscriptions_Aggregate_FieldsCountArgs = { - columns?: InputMaybe>; +/** aggregate fields of "billing.report_type" */ +export type Billing_Report_Type_Aggregate_FieldsCountArgs = { + columns?: InputMaybe>; distinct?: InputMaybe; }; -/** Boolean expression to filter rows from the table "billing.subscriptions". All fields are combined with a logical 'AND'. */ -export type Billing_Subscriptions_Bool_Exp = { - _and?: InputMaybe>; - _not?: InputMaybe; - _or?: InputMaybe>; - app?: InputMaybe; - app_id?: InputMaybe; - created_at?: InputMaybe; - dedicated_compute?: InputMaybe; - egress?: InputMaybe; - functions?: InputMaybe; - id?: InputMaybe; - updated_at?: InputMaybe; +/** Boolean expression to filter rows from the table "billing.report_type". All fields are combined with a logical 'AND'. */ +export type Billing_Report_Type_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + comment?: InputMaybe; + value?: InputMaybe; }; -/** unique or primary key constraints on table "billing.subscriptions" */ -export enum Billing_Subscriptions_Constraint { - /** unique or primary key constraint on columns "app_id" */ - SubscriptionsAppIdKey = 'subscriptions_app_id_key', - /** unique or primary key constraint on columns "dedicated_compute" */ - SubscriptionsDedicatedComputeKey = 'subscriptions_dedicated_compute_key', - /** unique or primary key constraint on columns "egress" */ - SubscriptionsEgressKey = 'subscriptions_egress_key', - /** unique or primary key constraint on columns "functions" */ - SubscriptionsFunctionsKey = 'subscriptions_functions_key', - /** unique or primary key constraint on columns "id" */ - SubscriptionsPkey = 'subscriptions_pkey' +/** unique or primary key constraints on table "billing.report_type" */ +export enum Billing_Report_Type_Constraint { + /** unique or primary key constraint on columns "value" */ + ReportTypePkey = 'report_type_pkey' } -/** input type for inserting data into table "billing.subscriptions" */ -export type Billing_Subscriptions_Insert_Input = { - app?: InputMaybe; - app_id?: InputMaybe; - created_at?: InputMaybe; - dedicated_compute?: InputMaybe; - egress?: InputMaybe; - functions?: InputMaybe; - id?: InputMaybe; - updated_at?: InputMaybe; +export enum Billing_Report_Type_Enum { + /** Dedicated compute */ + DedicatedCompute = 'dedicated_compute', + /** Egress usage in MB */ + Egress = 'egress', + /** Functions usage in seconds */ + Functions = 'functions' +} + +/** Boolean expression to compare columns of type "billing_report_type_enum". All fields are combined with logical 'AND'. */ +export type Billing_Report_Type_Enum_Comparison_Exp = { + _eq?: InputMaybe; + _in?: InputMaybe>; + _is_null?: InputMaybe; + _neq?: InputMaybe; + _nin?: InputMaybe>; +}; + +/** input type for inserting data into table "billing.report_type" */ +export type Billing_Report_Type_Insert_Input = { + comment?: InputMaybe; + value?: InputMaybe; }; /** aggregate max on columns */ -export type Billing_Subscriptions_Max_Fields = { - __typename?: 'billing_subscriptions_max_fields'; - app_id?: Maybe; - created_at?: Maybe; - dedicated_compute?: Maybe; - egress?: Maybe; - functions?: Maybe; - id?: Maybe; - updated_at?: Maybe; +export type Billing_Report_Type_Max_Fields = { + __typename?: 'billing_report_type_max_fields'; + comment?: Maybe; + value?: Maybe; }; /** aggregate min on columns */ -export type Billing_Subscriptions_Min_Fields = { - __typename?: 'billing_subscriptions_min_fields'; - app_id?: Maybe; - created_at?: Maybe; - dedicated_compute?: Maybe; - egress?: Maybe; - functions?: Maybe; - id?: Maybe; - updated_at?: Maybe; +export type Billing_Report_Type_Min_Fields = { + __typename?: 'billing_report_type_min_fields'; + comment?: Maybe; + value?: Maybe; }; -/** response of any mutation on the table "billing.subscriptions" */ -export type Billing_Subscriptions_Mutation_Response = { - __typename?: 'billing_subscriptions_mutation_response'; +/** response of any mutation on the table "billing.report_type" */ +export type Billing_Report_Type_Mutation_Response = { + __typename?: 'billing_report_type_mutation_response'; /** number of rows affected by the mutation */ affected_rows: Scalars['Int']; /** data from the rows affected by the mutation */ - returning: Array; -}; - -/** input type for inserting object relation for remote table "billing.subscriptions" */ -export type Billing_Subscriptions_Obj_Rel_Insert_Input = { - data: Billing_Subscriptions_Insert_Input; - /** upsert condition */ - on_conflict?: InputMaybe; + returning: Array; }; -/** on_conflict condition type for table "billing.subscriptions" */ -export type Billing_Subscriptions_On_Conflict = { - constraint: Billing_Subscriptions_Constraint; - update_columns?: Array; - where?: InputMaybe; +/** on_conflict condition type for table "billing.report_type" */ +export type Billing_Report_Type_On_Conflict = { + constraint: Billing_Report_Type_Constraint; + update_columns?: Array; + where?: InputMaybe; }; -/** Ordering options when selecting data from "billing.subscriptions". */ -export type Billing_Subscriptions_Order_By = { - app?: InputMaybe; - app_id?: InputMaybe; - created_at?: InputMaybe; - dedicated_compute?: InputMaybe; - egress?: InputMaybe; - functions?: InputMaybe; - id?: InputMaybe; - updated_at?: InputMaybe; +/** Ordering options when selecting data from "billing.report_type". */ +export type Billing_Report_Type_Order_By = { + comment?: InputMaybe; + value?: InputMaybe; }; -/** primary key columns input for table: billing.subscriptions */ -export type Billing_Subscriptions_Pk_Columns_Input = { - id: Scalars['uuid']; +/** primary key columns input for table: billing.report_type */ +export type Billing_Report_Type_Pk_Columns_Input = { + value: Scalars['String']; }; -/** select columns of table "billing.subscriptions" */ -export enum Billing_Subscriptions_Select_Column { - /** column name */ - AppId = 'app_id', - /** column name */ - CreatedAt = 'created_at', - /** column name */ - DedicatedCompute = 'dedicated_compute', - /** column name */ - Egress = 'egress', - /** column name */ - Functions = 'functions', +/** select columns of table "billing.report_type" */ +export enum Billing_Report_Type_Select_Column { /** column name */ - Id = 'id', + Comment = 'comment', /** column name */ - UpdatedAt = 'updated_at' + Value = 'value' } -/** input type for updating data in table "billing.subscriptions" */ -export type Billing_Subscriptions_Set_Input = { - app_id?: InputMaybe; - created_at?: InputMaybe; - dedicated_compute?: InputMaybe; - egress?: InputMaybe; - functions?: InputMaybe; - id?: InputMaybe; - updated_at?: InputMaybe; +/** input type for updating data in table "billing.report_type" */ +export type Billing_Report_Type_Set_Input = { + comment?: InputMaybe; + value?: InputMaybe; }; -/** Streaming cursor of the table "billing_subscriptions" */ -export type Billing_Subscriptions_Stream_Cursor_Input = { +/** Streaming cursor of the table "billing_report_type" */ +export type Billing_Report_Type_Stream_Cursor_Input = { /** Stream column input with initial value */ - initial_value: Billing_Subscriptions_Stream_Cursor_Value_Input; + initial_value: Billing_Report_Type_Stream_Cursor_Value_Input; /** cursor ordering */ ordering?: InputMaybe; }; /** Initial value of the column from where the streaming should start */ -export type Billing_Subscriptions_Stream_Cursor_Value_Input = { - app_id?: InputMaybe; - created_at?: InputMaybe; - dedicated_compute?: InputMaybe; - egress?: InputMaybe; +export type Billing_Report_Type_Stream_Cursor_Value_Input = { + comment?: InputMaybe; + value?: InputMaybe; +}; + +/** update columns of table "billing.report_type" */ +export enum Billing_Report_Type_Update_Column { + /** column name */ + Comment = 'comment', + /** column name */ + Value = 'value' +} + +export type Billing_Report_Type_Updates = { + /** sets the columns of the filtered rows to the given values */ + _set?: InputMaybe; + /** filter the rows which have to be updated */ + where: Billing_Report_Type_Bool_Exp; +}; + +/** columns and relationships of "billing.reports" */ +export type Billing_Reports = { + __typename?: 'billing_reports'; + appID: Scalars['uuid']; + createdAt: Scalars['timestamptz']; + id: Scalars['uuid']; + pending: Scalars['Boolean']; + reportEnds: Scalars['timestamptz']; + reportStarts: Scalars['timestamptz']; + type: Billing_Report_Type_Enum; + updatedAt: Scalars['timestamptz']; + value: Scalars['Int']; +}; + +/** aggregated selection of "billing.reports" */ +export type Billing_Reports_Aggregate = { + __typename?: 'billing_reports_aggregate'; + aggregate?: Maybe; + nodes: Array; +}; + +export type Billing_Reports_Aggregate_Bool_Exp = { + bool_and?: InputMaybe; + bool_or?: InputMaybe; + count?: InputMaybe; +}; + +export type Billing_Reports_Aggregate_Bool_Exp_Bool_And = { + arguments: Billing_Reports_Select_Column_Billing_Reports_Aggregate_Bool_Exp_Bool_And_Arguments_Columns; + distinct?: InputMaybe; + filter?: InputMaybe; + predicate: Boolean_Comparison_Exp; +}; + +export type Billing_Reports_Aggregate_Bool_Exp_Bool_Or = { + arguments: Billing_Reports_Select_Column_Billing_Reports_Aggregate_Bool_Exp_Bool_Or_Arguments_Columns; + distinct?: InputMaybe; + filter?: InputMaybe; + predicate: Boolean_Comparison_Exp; +}; + +export type Billing_Reports_Aggregate_Bool_Exp_Count = { + arguments?: InputMaybe>; + distinct?: InputMaybe; + filter?: InputMaybe; + predicate: Int_Comparison_Exp; +}; + +/** aggregate fields of "billing.reports" */ +export type Billing_Reports_Aggregate_Fields = { + __typename?: 'billing_reports_aggregate_fields'; + avg?: Maybe; + count: Scalars['Int']; + max?: Maybe; + min?: Maybe; + stddev?: Maybe; + stddev_pop?: Maybe; + stddev_samp?: Maybe; + sum?: Maybe; + var_pop?: Maybe; + var_samp?: Maybe; + variance?: Maybe; +}; + + +/** aggregate fields of "billing.reports" */ +export type Billing_Reports_Aggregate_FieldsCountArgs = { + columns?: InputMaybe>; + distinct?: InputMaybe; +}; + +/** order by aggregate values of table "billing.reports" */ +export type Billing_Reports_Aggregate_Order_By = { + avg?: InputMaybe; + count?: InputMaybe; + max?: InputMaybe; + min?: InputMaybe; + stddev?: InputMaybe; + stddev_pop?: InputMaybe; + stddev_samp?: InputMaybe; + sum?: InputMaybe; + var_pop?: InputMaybe; + var_samp?: InputMaybe; + variance?: InputMaybe; +}; + +/** input type for inserting array relation for remote table "billing.reports" */ +export type Billing_Reports_Arr_Rel_Insert_Input = { + data: Array; + /** upsert condition */ + on_conflict?: InputMaybe; +}; + +/** aggregate avg on columns */ +export type Billing_Reports_Avg_Fields = { + __typename?: 'billing_reports_avg_fields'; + value?: Maybe; +}; + +/** order by avg() on columns of table "billing.reports" */ +export type Billing_Reports_Avg_Order_By = { + value?: InputMaybe; +}; + +/** Boolean expression to filter rows from the table "billing.reports". All fields are combined with a logical 'AND'. */ +export type Billing_Reports_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + appID?: InputMaybe; + createdAt?: InputMaybe; + id?: InputMaybe; + pending?: InputMaybe; + reportEnds?: InputMaybe; + reportStarts?: InputMaybe; + type?: InputMaybe; + updatedAt?: InputMaybe; + value?: InputMaybe; +}; + +/** unique or primary key constraints on table "billing.reports" */ +export enum Billing_Reports_Constraint { + /** unique or primary key constraint on columns "id" */ + ReportsPkey = 'reports_pkey' +} + +/** input type for incrementing numeric columns in table "billing.reports" */ +export type Billing_Reports_Inc_Input = { + value?: InputMaybe; +}; + +/** input type for inserting data into table "billing.reports" */ +export type Billing_Reports_Insert_Input = { + appID?: InputMaybe; + createdAt?: InputMaybe; + id?: InputMaybe; + pending?: InputMaybe; + reportEnds?: InputMaybe; + reportStarts?: InputMaybe; + type?: InputMaybe; + updatedAt?: InputMaybe; + value?: InputMaybe; +}; + +/** aggregate max on columns */ +export type Billing_Reports_Max_Fields = { + __typename?: 'billing_reports_max_fields'; + appID?: Maybe; + createdAt?: Maybe; + id?: Maybe; + reportEnds?: Maybe; + reportStarts?: Maybe; + updatedAt?: Maybe; + value?: Maybe; +}; + +/** order by max() on columns of table "billing.reports" */ +export type Billing_Reports_Max_Order_By = { + appID?: InputMaybe; + createdAt?: InputMaybe; + id?: InputMaybe; + reportEnds?: InputMaybe; + reportStarts?: InputMaybe; + updatedAt?: InputMaybe; + value?: InputMaybe; +}; + +/** aggregate min on columns */ +export type Billing_Reports_Min_Fields = { + __typename?: 'billing_reports_min_fields'; + appID?: Maybe; + createdAt?: Maybe; + id?: Maybe; + reportEnds?: Maybe; + reportStarts?: Maybe; + updatedAt?: Maybe; + value?: Maybe; +}; + +/** order by min() on columns of table "billing.reports" */ +export type Billing_Reports_Min_Order_By = { + appID?: InputMaybe; + createdAt?: InputMaybe; + id?: InputMaybe; + reportEnds?: InputMaybe; + reportStarts?: InputMaybe; + updatedAt?: InputMaybe; + value?: InputMaybe; +}; + +/** response of any mutation on the table "billing.reports" */ +export type Billing_Reports_Mutation_Response = { + __typename?: 'billing_reports_mutation_response'; + /** number of rows affected by the mutation */ + affected_rows: Scalars['Int']; + /** data from the rows affected by the mutation */ + returning: Array; +}; + +/** on_conflict condition type for table "billing.reports" */ +export type Billing_Reports_On_Conflict = { + constraint: Billing_Reports_Constraint; + update_columns?: Array; + where?: InputMaybe; +}; + +/** Ordering options when selecting data from "billing.reports". */ +export type Billing_Reports_Order_By = { + appID?: InputMaybe; + createdAt?: InputMaybe; + id?: InputMaybe; + pending?: InputMaybe; + reportEnds?: InputMaybe; + reportStarts?: InputMaybe; + type?: InputMaybe; + updatedAt?: InputMaybe; + value?: InputMaybe; +}; + +/** primary key columns input for table: billing.reports */ +export type Billing_Reports_Pk_Columns_Input = { + id: Scalars['uuid']; +}; + +/** select columns of table "billing.reports" */ +export enum Billing_Reports_Select_Column { + /** column name */ + AppId = 'appID', + /** column name */ + CreatedAt = 'createdAt', + /** column name */ + Id = 'id', + /** column name */ + Pending = 'pending', + /** column name */ + ReportEnds = 'reportEnds', + /** column name */ + ReportStarts = 'reportStarts', + /** column name */ + Type = 'type', + /** column name */ + UpdatedAt = 'updatedAt', + /** column name */ + Value = 'value' +} + +/** select "billing_reports_aggregate_bool_exp_bool_and_arguments_columns" columns of table "billing.reports" */ +export enum Billing_Reports_Select_Column_Billing_Reports_Aggregate_Bool_Exp_Bool_And_Arguments_Columns { + /** column name */ + Pending = 'pending' +} + +/** select "billing_reports_aggregate_bool_exp_bool_or_arguments_columns" columns of table "billing.reports" */ +export enum Billing_Reports_Select_Column_Billing_Reports_Aggregate_Bool_Exp_Bool_Or_Arguments_Columns { + /** column name */ + Pending = 'pending' +} + +/** input type for updating data in table "billing.reports" */ +export type Billing_Reports_Set_Input = { + appID?: InputMaybe; + createdAt?: InputMaybe; + id?: InputMaybe; + pending?: InputMaybe; + reportEnds?: InputMaybe; + reportStarts?: InputMaybe; + type?: InputMaybe; + updatedAt?: InputMaybe; + value?: InputMaybe; +}; + +/** aggregate stddev on columns */ +export type Billing_Reports_Stddev_Fields = { + __typename?: 'billing_reports_stddev_fields'; + value?: Maybe; +}; + +/** order by stddev() on columns of table "billing.reports" */ +export type Billing_Reports_Stddev_Order_By = { + value?: InputMaybe; +}; + +/** aggregate stddev_pop on columns */ +export type Billing_Reports_Stddev_Pop_Fields = { + __typename?: 'billing_reports_stddev_pop_fields'; + value?: Maybe; +}; + +/** order by stddev_pop() on columns of table "billing.reports" */ +export type Billing_Reports_Stddev_Pop_Order_By = { + value?: InputMaybe; +}; + +/** aggregate stddev_samp on columns */ +export type Billing_Reports_Stddev_Samp_Fields = { + __typename?: 'billing_reports_stddev_samp_fields'; + value?: Maybe; +}; + +/** order by stddev_samp() on columns of table "billing.reports" */ +export type Billing_Reports_Stddev_Samp_Order_By = { + value?: InputMaybe; +}; + +/** Streaming cursor of the table "billing_reports" */ +export type Billing_Reports_Stream_Cursor_Input = { + /** Stream column input with initial value */ + initial_value: Billing_Reports_Stream_Cursor_Value_Input; + /** cursor ordering */ + ordering?: InputMaybe; +}; + +/** Initial value of the column from where the streaming should start */ +export type Billing_Reports_Stream_Cursor_Value_Input = { + appID?: InputMaybe; + createdAt?: InputMaybe; + id?: InputMaybe; + pending?: InputMaybe; + reportEnds?: InputMaybe; + reportStarts?: InputMaybe; + type?: InputMaybe; + updatedAt?: InputMaybe; + value?: InputMaybe; +}; + +/** aggregate sum on columns */ +export type Billing_Reports_Sum_Fields = { + __typename?: 'billing_reports_sum_fields'; + value?: Maybe; +}; + +/** order by sum() on columns of table "billing.reports" */ +export type Billing_Reports_Sum_Order_By = { + value?: InputMaybe; +}; + +/** update columns of table "billing.reports" */ +export enum Billing_Reports_Update_Column { + /** column name */ + AppId = 'appID', + /** column name */ + CreatedAt = 'createdAt', + /** column name */ + Id = 'id', + /** column name */ + Pending = 'pending', + /** column name */ + ReportEnds = 'reportEnds', + /** column name */ + ReportStarts = 'reportStarts', + /** column name */ + Type = 'type', + /** column name */ + UpdatedAt = 'updatedAt', + /** column name */ + Value = 'value' +} + +export type Billing_Reports_Updates = { + /** increments the numeric columns with given value of the filtered values */ + _inc?: InputMaybe; + /** sets the columns of the filtered rows to the given values */ + _set?: InputMaybe; + /** filter the rows which have to be updated */ + where: Billing_Reports_Bool_Exp; +}; + +/** aggregate var_pop on columns */ +export type Billing_Reports_Var_Pop_Fields = { + __typename?: 'billing_reports_var_pop_fields'; + value?: Maybe; +}; + +/** order by var_pop() on columns of table "billing.reports" */ +export type Billing_Reports_Var_Pop_Order_By = { + value?: InputMaybe; +}; + +/** aggregate var_samp on columns */ +export type Billing_Reports_Var_Samp_Fields = { + __typename?: 'billing_reports_var_samp_fields'; + value?: Maybe; +}; + +/** order by var_samp() on columns of table "billing.reports" */ +export type Billing_Reports_Var_Samp_Order_By = { + value?: InputMaybe; +}; + +/** aggregate variance on columns */ +export type Billing_Reports_Variance_Fields = { + __typename?: 'billing_reports_variance_fields'; + value?: Maybe; +}; + +/** order by variance() on columns of table "billing.reports" */ +export type Billing_Reports_Variance_Order_By = { + value?: InputMaybe; +}; + +/** columns and relationships of "billing.subscriptions" */ +export type Billing_Subscriptions = { + __typename?: 'billing_subscriptions'; + /** An object relationship */ + app?: Maybe; + appID: Scalars['uuid']; + createdAt: Scalars['timestamptz']; + dedicatedCompute?: Maybe; + egress?: Maybe; + functions?: Maybe; + id: Scalars['uuid']; + /** An array relationship */ + reports: Array; + /** An aggregate relationship */ + reports_aggregate: Billing_Reports_Aggregate; + updatedAt: Scalars['timestamptz']; +}; + + +/** columns and relationships of "billing.subscriptions" */ +export type Billing_SubscriptionsReportsArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +/** columns and relationships of "billing.subscriptions" */ +export type Billing_SubscriptionsReports_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + +/** aggregated selection of "billing.subscriptions" */ +export type Billing_Subscriptions_Aggregate = { + __typename?: 'billing_subscriptions_aggregate'; + aggregate?: Maybe; + nodes: Array; +}; + +/** aggregate fields of "billing.subscriptions" */ +export type Billing_Subscriptions_Aggregate_Fields = { + __typename?: 'billing_subscriptions_aggregate_fields'; + count: Scalars['Int']; + max?: Maybe; + min?: Maybe; +}; + + +/** aggregate fields of "billing.subscriptions" */ +export type Billing_Subscriptions_Aggregate_FieldsCountArgs = { + columns?: InputMaybe>; + distinct?: InputMaybe; +}; + +/** Boolean expression to filter rows from the table "billing.subscriptions". All fields are combined with a logical 'AND'. */ +export type Billing_Subscriptions_Bool_Exp = { + _and?: InputMaybe>; + _not?: InputMaybe; + _or?: InputMaybe>; + app?: InputMaybe; + appID?: InputMaybe; + createdAt?: InputMaybe; + dedicatedCompute?: InputMaybe; + egress?: InputMaybe; + functions?: InputMaybe; + id?: InputMaybe; + reports?: InputMaybe; + reports_aggregate?: InputMaybe; + updatedAt?: InputMaybe; +}; + +/** unique or primary key constraints on table "billing.subscriptions" */ +export enum Billing_Subscriptions_Constraint { + /** unique or primary key constraint on columns "app_id" */ + SubscriptionsAppIdKey = 'subscriptions_app_id_key', + /** unique or primary key constraint on columns "dedicated_compute" */ + SubscriptionsDedicatedComputeKey = 'subscriptions_dedicated_compute_key', + /** unique or primary key constraint on columns "egress" */ + SubscriptionsEgressKey = 'subscriptions_egress_key', + /** unique or primary key constraint on columns "functions" */ + SubscriptionsFunctionsKey = 'subscriptions_functions_key', + /** unique or primary key constraint on columns "id" */ + SubscriptionsPkey = 'subscriptions_pkey' +} + +/** input type for inserting data into table "billing.subscriptions" */ +export type Billing_Subscriptions_Insert_Input = { + app?: InputMaybe; + appID?: InputMaybe; + createdAt?: InputMaybe; + dedicatedCompute?: InputMaybe; + egress?: InputMaybe; functions?: InputMaybe; id?: InputMaybe; - updated_at?: InputMaybe; + reports?: InputMaybe; + updatedAt?: InputMaybe; +}; + +/** aggregate max on columns */ +export type Billing_Subscriptions_Max_Fields = { + __typename?: 'billing_subscriptions_max_fields'; + appID?: Maybe; + createdAt?: Maybe; + dedicatedCompute?: Maybe; + egress?: Maybe; + functions?: Maybe; + id?: Maybe; + updatedAt?: Maybe; +}; + +/** aggregate min on columns */ +export type Billing_Subscriptions_Min_Fields = { + __typename?: 'billing_subscriptions_min_fields'; + appID?: Maybe; + createdAt?: Maybe; + dedicatedCompute?: Maybe; + egress?: Maybe; + functions?: Maybe; + id?: Maybe; + updatedAt?: Maybe; +}; + +/** response of any mutation on the table "billing.subscriptions" */ +export type Billing_Subscriptions_Mutation_Response = { + __typename?: 'billing_subscriptions_mutation_response'; + /** number of rows affected by the mutation */ + affected_rows: Scalars['Int']; + /** data from the rows affected by the mutation */ + returning: Array; +}; + +/** input type for inserting object relation for remote table "billing.subscriptions" */ +export type Billing_Subscriptions_Obj_Rel_Insert_Input = { + data: Billing_Subscriptions_Insert_Input; + /** upsert condition */ + on_conflict?: InputMaybe; +}; + +/** on_conflict condition type for table "billing.subscriptions" */ +export type Billing_Subscriptions_On_Conflict = { + constraint: Billing_Subscriptions_Constraint; + update_columns?: Array; + where?: InputMaybe; +}; + +/** Ordering options when selecting data from "billing.subscriptions". */ +export type Billing_Subscriptions_Order_By = { + app?: InputMaybe; + appID?: InputMaybe; + createdAt?: InputMaybe; + dedicatedCompute?: InputMaybe; + egress?: InputMaybe; + functions?: InputMaybe; + id?: InputMaybe; + reports_aggregate?: InputMaybe; + updatedAt?: InputMaybe; +}; + +/** primary key columns input for table: billing.subscriptions */ +export type Billing_Subscriptions_Pk_Columns_Input = { + id: Scalars['uuid']; +}; + +/** select columns of table "billing.subscriptions" */ +export enum Billing_Subscriptions_Select_Column { + /** column name */ + AppId = 'appID', + /** column name */ + CreatedAt = 'createdAt', + /** column name */ + DedicatedCompute = 'dedicatedCompute', + /** column name */ + Egress = 'egress', + /** column name */ + Functions = 'functions', + /** column name */ + Id = 'id', + /** column name */ + UpdatedAt = 'updatedAt' +} + +/** input type for updating data in table "billing.subscriptions" */ +export type Billing_Subscriptions_Set_Input = { + appID?: InputMaybe; + createdAt?: InputMaybe; + dedicatedCompute?: InputMaybe; + egress?: InputMaybe; + functions?: InputMaybe; + id?: InputMaybe; + updatedAt?: InputMaybe; +}; + +/** Streaming cursor of the table "billing_subscriptions" */ +export type Billing_Subscriptions_Stream_Cursor_Input = { + /** Stream column input with initial value */ + initial_value: Billing_Subscriptions_Stream_Cursor_Value_Input; + /** cursor ordering */ + ordering?: InputMaybe; +}; + +/** Initial value of the column from where the streaming should start */ +export type Billing_Subscriptions_Stream_Cursor_Value_Input = { + appID?: InputMaybe; + createdAt?: InputMaybe; + dedicatedCompute?: InputMaybe; + egress?: InputMaybe; + functions?: InputMaybe; + id?: InputMaybe; + updatedAt?: InputMaybe; }; /** update columns of table "billing.subscriptions" */ export enum Billing_Subscriptions_Update_Column { /** column name */ - AppId = 'app_id', + AppId = 'appID', /** column name */ - CreatedAt = 'created_at', + CreatedAt = 'createdAt', /** column name */ - DedicatedCompute = 'dedicated_compute', + DedicatedCompute = 'dedicatedCompute', /** column name */ Egress = 'egress', /** column name */ @@ -6690,7 +7328,7 @@ export enum Billing_Subscriptions_Update_Column { /** column name */ Id = 'id', /** column name */ - UpdatedAt = 'updated_at' + UpdatedAt = 'updatedAt' } export type Billing_Subscriptions_Updates = { @@ -10407,10 +11045,10 @@ export type Mutation_Root = { backupApplicationDatabase: BackupResult; billingFinishSubscription: Scalars['Boolean']; billingFixSubscriptions: Scalars['Boolean']; - billingReportDedicatedCompute: Scalars['Boolean']; - billingUpdateAndReportDedicatedComputeReports: Scalars['Boolean']; + billingFullReportWorkflow: Scalars['Boolean']; billingUpdateDedicatedCompute: Scalars['Boolean']; - billingUpdateDedicatedComputeReports: Scalars['Boolean']; + billingUpdateReports: Scalars['Boolean']; + billingUploadReports: Scalars['Boolean']; /** delete single row from the table: "apps" */ deleteApp?: Maybe; /** delete single row from the table: "app_states" */ @@ -10459,6 +11097,18 @@ export type Mutation_Root = { deleteBackup?: Maybe; /** delete data from the table: "backups" */ deleteBackups?: Maybe; + /** delete single row from the table: "billing.dedicated_compute" */ + deleteBillingDedicatedCompute?: Maybe; + /** delete data from the table: "billing.dedicated_compute" */ + deleteBillingDedicatedComputes?: Maybe; + /** delete single row from the table: "billing.reports" */ + deleteBillingReport?: Maybe; + /** delete data from the table: "billing.reports" */ + deleteBillingReports?: Maybe; + /** delete data from the table: "billing.subscriptions" */ + deleteBillingSubscription?: Maybe; + /** delete single row from the table: "billing.subscriptions" */ + deleteBillingSubscriptions?: Maybe; /** delete single row from the table: "storage.buckets" */ deleteBucket?: Maybe; /** delete data from the table: "storage.buckets" */ @@ -10538,6 +11188,10 @@ export type Mutation_Root = { delete_auth_migrations?: Maybe; /** delete single row from the table: "auth.migrations" */ delete_auth_migrations_by_pk?: Maybe; + /** delete data from the table: "billing.report_type" */ + delete_billing_report_type?: Maybe; + /** delete single row from the table: "billing.report_type" */ + delete_billing_report_type_by_pk?: Maybe; /** delete data from the table: "continents" */ delete_continents?: Maybe; /** delete single row from the table: "continents" */ @@ -10602,6 +11256,18 @@ export type Mutation_Root = { insertBackup?: Maybe; /** insert data into the table: "backups" */ insertBackups?: Maybe; + /** insert a single row into the table: "billing.dedicated_compute" */ + insertBillingDedicatedCompute?: Maybe; + /** insert data into the table: "billing.dedicated_compute" */ + insertBillingDedicatedComputes?: Maybe; + /** insert a single row into the table: "billing.reports" */ + insertBillingReport?: Maybe; + /** insert data into the table: "billing.reports" */ + insertBillingReports?: Maybe; + /** insert data into the table: "billing.subscriptions" */ + insertBillingSubscription?: Maybe; + /** insert a single row into the table: "billing.subscriptions" */ + insertBillingSubscriptions?: Maybe; /** insert a single row into the table: "storage.buckets" */ insertBucket?: Maybe; /** insert data into the table: "storage.buckets" */ @@ -10681,6 +11347,10 @@ export type Mutation_Root = { insert_auth_migrations?: Maybe; /** insert a single row into the table: "auth.migrations" */ insert_auth_migrations_one?: Maybe; + /** insert data into the table: "billing.report_type" */ + insert_billing_report_type?: Maybe; + /** insert a single row into the table: "billing.report_type" */ + insert_billing_report_type_one?: Maybe; /** insert data into the table: "continents" */ insert_continents?: Maybe; /** insert a single row into the table: "continents" */ @@ -10752,6 +11422,18 @@ export type Mutation_Root = { updateBackup?: Maybe; /** update data of the table: "backups" */ updateBackups?: Maybe; + /** update single row of the table: "billing.dedicated_compute" */ + updateBillingDedicatedCompute?: Maybe; + /** update data of the table: "billing.dedicated_compute" */ + updateBillingDedicatedComputes?: Maybe; + /** update single row of the table: "billing.reports" */ + updateBillingReport?: Maybe; + /** update data of the table: "billing.reports" */ + updateBillingReports?: Maybe; + /** update single row of the table: "billing.subscriptions" */ + updateBillingSubscription?: Maybe; + /** update data of the table: "billing.subscriptions" */ + updateBillingSubscriptions?: Maybe; /** update single row of the table: "storage.buckets" */ updateBucket?: Maybe; /** update data of the table: "storage.buckets" */ @@ -10789,6 +11471,8 @@ export type Mutation_Root = { updateGithubRepositories?: Maybe; /** update single row of the table: "github_repositories" */ updateGithubRepository?: Maybe; + /** update multiples rows of table: "billing.reports" */ + updateManyBillingReports?: Maybe>>; /** update single row of the table: "payment_methods" */ updatePaymentMethod?: Maybe; /** update data of the table: "payment_methods" */ @@ -10858,6 +11542,14 @@ export type Mutation_Root = { update_auth_migrations_many?: Maybe>>; /** update multiples rows of table: "backups" */ update_backups_many?: Maybe>>; + /** update multiples rows of table: "billing.dedicated_compute" */ + update_billing_dedicated_compute_many?: Maybe>>; + /** update data of the table: "billing.report_type" */ + update_billing_report_type?: Maybe; + /** update single row of the table: "billing.report_type" */ + update_billing_report_type_by_pk?: Maybe; + /** update multiples rows of table: "billing.report_type" */ + update_billing_report_type_many?: Maybe>>; /** update multiples rows of table: "storage.buckets" */ update_buckets_many?: Maybe>>; /** update multiples rows of table: "cli_tokens" */ @@ -10888,6 +11580,8 @@ export type Mutation_Root = { update_githubAppInstallations_many?: Maybe>>; /** update multiples rows of table: "github_repositories" */ update_githubRepositories_many?: Maybe>>; + /** update multiples rows of table: "billing.subscriptions" */ + update_many_billing_subscriptions?: Maybe>>; /** update multiples rows of table: "payment_methods" */ update_paymentMethods_many?: Maybe>>; /** update multiples rows of table: "plans" */ @@ -10918,48 +11612,20 @@ export type Mutation_Root = { update_workspaceMembers_many?: Maybe>>; /** update multiples rows of table: "workspaces" */ update_workspaces_many?: Maybe>>; - /** delete single row from the table: "billing.dedicated_compute" */ - zzzDONOTUSE_delete_billing_dedicated_compute?: Maybe; /** delete single row from the table: "billing.dedicated_compute_reports" */ zzzDONOTUSE_delete_billing_dedicated_compute_report?: Maybe; /** delete data from the table: "billing.dedicated_compute_reports" */ zzzDONOTUSE_delete_billing_dedicated_compute_reports?: Maybe; - /** delete data from the table: "billing.dedicated_compute" */ - zzzDONOTUSE_delete_billing_dedicated_computes?: Maybe; - /** delete single row from the table: "billing.subscriptions" */ - zzzDONOTUSE_delete_billing_subscription?: Maybe; - /** delete data from the table: "billing.subscriptions" */ - zzzDONOTUSE_delete_billing_subscriptions?: Maybe; - /** insert a single row into the table: "billing.dedicated_compute" */ - zzzDONOTUSE_insert_billing_dedicated_compute?: Maybe; /** insert a single row into the table: "billing.dedicated_compute_reports" */ zzzDONOTUSE_insert_billing_dedicated_compute_report?: Maybe; /** insert data into the table: "billing.dedicated_compute_reports" */ zzzDONOTUSE_insert_billing_dedicated_compute_reports?: Maybe; - /** insert data into the table: "billing.dedicated_compute" */ - zzzDONOTUSE_insert_billing_dedicated_computes?: Maybe; - /** insert a single row into the table: "billing.subscriptions" */ - zzzDONOTUSE_insert_billing_subscription?: Maybe; - /** insert data into the table: "billing.subscriptions" */ - zzzDONOTUSE_insert_billing_subscriptions?: Maybe; - /** update single row of the table: "billing.dedicated_compute" */ - zzzDONOTUSE_update_billing_dedicated_compute?: Maybe; /** update single row of the table: "billing.dedicated_compute_reports" */ zzzDONOTUSE_update_billing_dedicated_compute_report?: Maybe; /** update data of the table: "billing.dedicated_compute_reports" */ zzzDONOTUSE_update_billing_dedicated_compute_reports?: Maybe; - /** update data of the table: "billing.dedicated_compute" */ - zzzDONOTUSE_update_billing_dedicated_computes?: Maybe; - /** update single row of the table: "billing.subscriptions" */ - zzzDONOTUSE_update_billing_subscription?: Maybe; - /** update data of the table: "billing.subscriptions" */ - zzzDONOTUSE_update_billing_subscriptions?: Maybe; - /** update multiples rows of table: "billing.dedicated_compute" */ - zzzDONOTUSE_update_many_billing_dedicated_compute?: Maybe>>; /** update multiples rows of table: "billing.dedicated_compute_reports" */ zzzDONOTUSE_update_many_billing_dedicated_compute_reports?: Maybe>>; - /** update multiples rows of table: "billing.subscriptions" */ - zzzDONOTUSE_update_many_billing_subscriptions?: Maybe>>; }; @@ -10986,13 +11652,7 @@ export type Mutation_RootBillingFinishSubscriptionArgs = { /** mutation root */ -export type Mutation_RootBillingReportDedicatedComputeArgs = { - reportTime: Scalars['Timestamp']; -}; - - -/** mutation root */ -export type Mutation_RootBillingUpdateAndReportDedicatedComputeReportsArgs = { +export type Mutation_RootBillingFullReportWorkflowArgs = { reportTime?: InputMaybe; }; @@ -11005,8 +11665,8 @@ export type Mutation_RootBillingUpdateDedicatedComputeArgs = { /** mutation root */ -export type Mutation_RootBillingUpdateDedicatedComputeReportsArgs = { - reportTime: Scalars['Timestamp']; +export type Mutation_RootBillingUpdateReportsArgs = { + reportTime?: InputMaybe; }; @@ -11154,6 +11814,42 @@ export type Mutation_RootDeleteBackupsArgs = { }; +/** mutation root */ +export type Mutation_RootDeleteBillingDedicatedComputeArgs = { + id: Scalars['uuid']; +}; + + +/** mutation root */ +export type Mutation_RootDeleteBillingDedicatedComputesArgs = { + where: Billing_Dedicated_Compute_Bool_Exp; +}; + + +/** mutation root */ +export type Mutation_RootDeleteBillingReportArgs = { + id: Scalars['uuid']; +}; + + +/** mutation root */ +export type Mutation_RootDeleteBillingReportsArgs = { + where: Billing_Reports_Bool_Exp; +}; + + +/** mutation root */ +export type Mutation_RootDeleteBillingSubscriptionArgs = { + where: Billing_Subscriptions_Bool_Exp; +}; + + +/** mutation root */ +export type Mutation_RootDeleteBillingSubscriptionsArgs = { + id: Scalars['uuid']; +}; + + /** mutation root */ export type Mutation_RootDeleteBucketArgs = { id: Scalars['String']; @@ -11402,6 +12098,18 @@ export type Mutation_RootDelete_Auth_Migrations_By_PkArgs = { }; +/** mutation root */ +export type Mutation_RootDelete_Billing_Report_TypeArgs = { + where: Billing_Report_Type_Bool_Exp; +}; + + +/** mutation root */ +export type Mutation_RootDelete_Billing_Report_Type_By_PkArgs = { + value: Scalars['String']; +}; + + /** mutation root */ export type Mutation_RootDelete_ContinentsArgs = { where: Continents_Bool_Exp; @@ -11577,44 +12285,86 @@ export type Mutation_RootInsertAuthUserProvidersArgs = { /** mutation root */ -export type Mutation_RootInsertAuthUserRoleArgs = { - object: AuthUserRoles_Insert_Input; - on_conflict?: InputMaybe; +export type Mutation_RootInsertAuthUserRoleArgs = { + object: AuthUserRoles_Insert_Input; + on_conflict?: InputMaybe; +}; + + +/** mutation root */ +export type Mutation_RootInsertAuthUserRolesArgs = { + objects: Array; + on_conflict?: InputMaybe; +}; + + +/** mutation root */ +export type Mutation_RootInsertAuthUserSecurityKeyArgs = { + object: AuthUserSecurityKeys_Insert_Input; + on_conflict?: InputMaybe; +}; + + +/** mutation root */ +export type Mutation_RootInsertAuthUserSecurityKeysArgs = { + objects: Array; + on_conflict?: InputMaybe; +}; + + +/** mutation root */ +export type Mutation_RootInsertBackupArgs = { + object: Backups_Insert_Input; + on_conflict?: InputMaybe; +}; + + +/** mutation root */ +export type Mutation_RootInsertBackupsArgs = { + objects: Array; + on_conflict?: InputMaybe; +}; + + +/** mutation root */ +export type Mutation_RootInsertBillingDedicatedComputeArgs = { + object: Billing_Dedicated_Compute_Insert_Input; + on_conflict?: InputMaybe; }; /** mutation root */ -export type Mutation_RootInsertAuthUserRolesArgs = { - objects: Array; - on_conflict?: InputMaybe; +export type Mutation_RootInsertBillingDedicatedComputesArgs = { + objects: Array; + on_conflict?: InputMaybe; }; /** mutation root */ -export type Mutation_RootInsertAuthUserSecurityKeyArgs = { - object: AuthUserSecurityKeys_Insert_Input; - on_conflict?: InputMaybe; +export type Mutation_RootInsertBillingReportArgs = { + object: Billing_Reports_Insert_Input; + on_conflict?: InputMaybe; }; /** mutation root */ -export type Mutation_RootInsertAuthUserSecurityKeysArgs = { - objects: Array; - on_conflict?: InputMaybe; +export type Mutation_RootInsertBillingReportsArgs = { + objects: Array; + on_conflict?: InputMaybe; }; /** mutation root */ -export type Mutation_RootInsertBackupArgs = { - object: Backups_Insert_Input; - on_conflict?: InputMaybe; +export type Mutation_RootInsertBillingSubscriptionArgs = { + objects: Array; + on_conflict?: InputMaybe; }; /** mutation root */ -export type Mutation_RootInsertBackupsArgs = { - objects: Array; - on_conflict?: InputMaybe; +export type Mutation_RootInsertBillingSubscriptionsArgs = { + object: Billing_Subscriptions_Insert_Input; + on_conflict?: InputMaybe; }; @@ -11908,6 +12658,20 @@ export type Mutation_RootInsert_Auth_Migrations_OneArgs = { }; +/** mutation root */ +export type Mutation_RootInsert_Billing_Report_TypeArgs = { + objects: Array; + on_conflict?: InputMaybe; +}; + + +/** mutation root */ +export type Mutation_RootInsert_Billing_Report_Type_OneArgs = { + object: Billing_Report_Type_Insert_Input; + on_conflict?: InputMaybe; +}; + + /** mutation root */ export type Mutation_RootInsert_ContinentsArgs = { objects: Array; @@ -12210,6 +12974,52 @@ export type Mutation_RootUpdateBackupsArgs = { }; +/** mutation root */ +export type Mutation_RootUpdateBillingDedicatedComputeArgs = { + _inc?: InputMaybe; + _set?: InputMaybe; + pk_columns: Billing_Dedicated_Compute_Pk_Columns_Input; +}; + + +/** mutation root */ +export type Mutation_RootUpdateBillingDedicatedComputesArgs = { + _inc?: InputMaybe; + _set?: InputMaybe; + where: Billing_Dedicated_Compute_Bool_Exp; +}; + + +/** mutation root */ +export type Mutation_RootUpdateBillingReportArgs = { + _inc?: InputMaybe; + _set?: InputMaybe; + pk_columns: Billing_Reports_Pk_Columns_Input; +}; + + +/** mutation root */ +export type Mutation_RootUpdateBillingReportsArgs = { + _inc?: InputMaybe; + _set?: InputMaybe; + where: Billing_Reports_Bool_Exp; +}; + + +/** mutation root */ +export type Mutation_RootUpdateBillingSubscriptionArgs = { + _set?: InputMaybe; + pk_columns: Billing_Subscriptions_Pk_Columns_Input; +}; + + +/** mutation root */ +export type Mutation_RootUpdateBillingSubscriptionsArgs = { + _set?: InputMaybe; + where: Billing_Subscriptions_Bool_Exp; +}; + + /** mutation root */ export type Mutation_RootUpdateBucketArgs = { _inc?: InputMaybe; @@ -12361,6 +13171,12 @@ export type Mutation_RootUpdateGithubRepositoryArgs = { }; +/** mutation root */ +export type Mutation_RootUpdateManyBillingReportsArgs = { + updates: Array; +}; + + /** mutation root */ export type Mutation_RootUpdatePaymentMethodArgs = { _inc?: InputMaybe; @@ -12617,6 +13433,32 @@ export type Mutation_RootUpdate_Backups_ManyArgs = { }; +/** mutation root */ +export type Mutation_RootUpdate_Billing_Dedicated_Compute_ManyArgs = { + updates: Array; +}; + + +/** mutation root */ +export type Mutation_RootUpdate_Billing_Report_TypeArgs = { + _set?: InputMaybe; + where: Billing_Report_Type_Bool_Exp; +}; + + +/** mutation root */ +export type Mutation_RootUpdate_Billing_Report_Type_By_PkArgs = { + _set?: InputMaybe; + pk_columns: Billing_Report_Type_Pk_Columns_Input; +}; + + +/** mutation root */ +export type Mutation_RootUpdate_Billing_Report_Type_ManyArgs = { + updates: Array; +}; + + /** mutation root */ export type Mutation_RootUpdate_Buckets_ManyArgs = { updates: Array; @@ -12713,6 +13555,12 @@ export type Mutation_RootUpdate_GithubRepositories_ManyArgs = { }; +/** mutation root */ +export type Mutation_RootUpdate_Many_Billing_SubscriptionsArgs = { + updates: Array; +}; + + /** mutation root */ export type Mutation_RootUpdate_PaymentMethods_ManyArgs = { updates: Array; @@ -12807,12 +13655,6 @@ export type Mutation_RootUpdate_Workspaces_ManyArgs = { }; -/** mutation root */ -export type Mutation_RootZzzDonotuse_Delete_Billing_Dedicated_ComputeArgs = { - id: Scalars['uuid']; -}; - - /** mutation root */ export type Mutation_RootZzzDonotuse_Delete_Billing_Dedicated_Compute_ReportArgs = { id: Scalars['uuid']; @@ -12825,31 +13667,6 @@ export type Mutation_RootZzzDonotuse_Delete_Billing_Dedicated_Compute_ReportsArg }; -/** mutation root */ -export type Mutation_RootZzzDonotuse_Delete_Billing_Dedicated_ComputesArgs = { - where: Billing_Dedicated_Compute_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Delete_Billing_SubscriptionArgs = { - id: Scalars['uuid']; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Delete_Billing_SubscriptionsArgs = { - where: Billing_Subscriptions_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Insert_Billing_Dedicated_ComputeArgs = { - object: Billing_Dedicated_Compute_Insert_Input; - on_conflict?: InputMaybe; -}; - - /** mutation root */ export type Mutation_RootZzzDonotuse_Insert_Billing_Dedicated_Compute_ReportArgs = { object: Billing_Dedicated_Compute_Reports_Insert_Input; @@ -12864,35 +13681,6 @@ export type Mutation_RootZzzDonotuse_Insert_Billing_Dedicated_Compute_ReportsArg }; -/** mutation root */ -export type Mutation_RootZzzDonotuse_Insert_Billing_Dedicated_ComputesArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Insert_Billing_SubscriptionArgs = { - object: Billing_Subscriptions_Insert_Input; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Insert_Billing_SubscriptionsArgs = { - objects: Array; - on_conflict?: InputMaybe; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Update_Billing_Dedicated_ComputeArgs = { - _inc?: InputMaybe; - _set?: InputMaybe; - pk_columns: Billing_Dedicated_Compute_Pk_Columns_Input; -}; - - /** mutation root */ export type Mutation_RootZzzDonotuse_Update_Billing_Dedicated_Compute_ReportArgs = { _inc?: InputMaybe; @@ -12909,45 +13697,11 @@ export type Mutation_RootZzzDonotuse_Update_Billing_Dedicated_Compute_ReportsArg }; -/** mutation root */ -export type Mutation_RootZzzDonotuse_Update_Billing_Dedicated_ComputesArgs = { - _inc?: InputMaybe; - _set?: InputMaybe; - where: Billing_Dedicated_Compute_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Update_Billing_SubscriptionArgs = { - _set?: InputMaybe; - pk_columns: Billing_Subscriptions_Pk_Columns_Input; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Update_Billing_SubscriptionsArgs = { - _set?: InputMaybe; - where: Billing_Subscriptions_Bool_Exp; -}; - - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Update_Many_Billing_Dedicated_ComputeArgs = { - updates: Array; -}; - - /** mutation root */ export type Mutation_RootZzzDonotuse_Update_Many_Billing_Dedicated_Compute_ReportsArgs = { updates: Array; }; - -/** mutation root */ -export type Mutation_RootZzzDonotuse_Update_Many_Billing_SubscriptionsArgs = { - updates: Array; -}; - /** column ordering options */ export enum Order_By { /** in ascending order, nulls last */ @@ -14010,12 +14764,24 @@ export type Query_Root = { /** fetch data from the table: "billing.dedicated_compute" */ billingDedicatedComputes: Array; billingGetNextInvoice?: Maybe; + /** fetch data from the table: "billing.reports" using primary key columns */ + billingReport?: Maybe; + /** fetch data from the table: "billing.reports" */ + billingReports: Array; + /** fetch aggregated fields from the table: "billing.reports" */ + billingReportsAggregate: Billing_Reports_Aggregate; /** fetch data from the table: "billing.subscriptions" using primary key columns */ billingSubscription?: Maybe; /** fetch data from the table: "billing.subscriptions" */ billingSubscriptions: Array; /** fetch aggregated fields from the table: "billing.subscriptions" */ billingSubscriptionsAggregate: Billing_Subscriptions_Aggregate; + /** fetch data from the table: "billing.report_type" */ + billing_report_type: Array; + /** fetch aggregated fields from the table: "billing.report_type" */ + billing_report_type_aggregate: Billing_Report_Type_Aggregate; + /** fetch data from the table: "billing.report_type" using primary key columns */ + billing_report_type_by_pk?: Maybe; /** fetch data from the table: "storage.buckets" using primary key columns */ bucket?: Maybe; /** fetch data from the table: "storage.buckets" */ @@ -14536,6 +15302,29 @@ export type Query_RootBillingGetNextInvoiceArgs = { }; +export type Query_RootBillingReportArgs = { + id: Scalars['uuid']; +}; + + +export type Query_RootBillingReportsArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Query_RootBillingReportsAggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + export type Query_RootBillingSubscriptionArgs = { id: Scalars['uuid']; }; @@ -14559,6 +15348,29 @@ export type Query_RootBillingSubscriptionsAggregateArgs = { }; +export type Query_RootBilling_Report_TypeArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Query_RootBilling_Report_Type_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Query_RootBilling_Report_Type_By_PkArgs = { + value: Scalars['String']; +}; + + export type Query_RootBucketArgs = { id: Scalars['String']; }; @@ -16033,6 +16845,7 @@ export type Run_Service = { creatorUserId: Scalars['uuid']; id: Scalars['uuid']; mimirConfigEnc?: Maybe; + subdomain: Scalars['String']; updatedAt: Scalars['timestamptz']; }; @@ -16101,13 +16914,16 @@ export type Run_Service_Bool_Exp = { creatorUserId?: InputMaybe; id?: InputMaybe; mimirConfigEnc?: InputMaybe; + subdomain?: InputMaybe; updatedAt?: InputMaybe; }; /** unique or primary key constraints on table "run_service" */ export enum Run_Service_Constraint { /** unique or primary key constraint on columns "id" */ - RunServicePkey = 'run_service_pkey' + RunServicePkey = 'run_service_pkey', + /** unique or primary key constraint on columns "subdomain" */ + RunServiceSubdomainKey = 'run_service_subdomain_key' } /** input type for inserting data into table "run_service" */ @@ -16119,6 +16935,7 @@ export type Run_Service_Insert_Input = { creatorUserId?: InputMaybe; id?: InputMaybe; mimirConfigEnc?: InputMaybe; + subdomain?: InputMaybe; updatedAt?: InputMaybe; }; @@ -16130,6 +16947,7 @@ export type Run_Service_Max_Fields = { creatorUserId?: Maybe; id?: Maybe; mimirConfigEnc?: Maybe; + subdomain?: Maybe; updatedAt?: Maybe; }; @@ -16140,6 +16958,7 @@ export type Run_Service_Max_Order_By = { creatorUserId?: InputMaybe; id?: InputMaybe; mimirConfigEnc?: InputMaybe; + subdomain?: InputMaybe; updatedAt?: InputMaybe; }; @@ -16151,6 +16970,7 @@ export type Run_Service_Min_Fields = { creatorUserId?: Maybe; id?: Maybe; mimirConfigEnc?: Maybe; + subdomain?: Maybe; updatedAt?: Maybe; }; @@ -16161,6 +16981,7 @@ export type Run_Service_Min_Order_By = { creatorUserId?: InputMaybe; id?: InputMaybe; mimirConfigEnc?: InputMaybe; + subdomain?: InputMaybe; updatedAt?: InputMaybe; }; @@ -16189,6 +17010,7 @@ export type Run_Service_Order_By = { creatorUserId?: InputMaybe; id?: InputMaybe; mimirConfigEnc?: InputMaybe; + subdomain?: InputMaybe; updatedAt?: InputMaybe; }; @@ -16210,6 +17032,8 @@ export enum Run_Service_Select_Column { /** column name */ MimirConfigEnc = 'mimirConfigEnc', /** column name */ + Subdomain = 'subdomain', + /** column name */ UpdatedAt = 'updatedAt' } @@ -16220,6 +17044,7 @@ export type Run_Service_Set_Input = { creatorUserId?: InputMaybe; id?: InputMaybe; mimirConfigEnc?: InputMaybe; + subdomain?: InputMaybe; updatedAt?: InputMaybe; }; @@ -16238,6 +17063,7 @@ export type Run_Service_Stream_Cursor_Value_Input = { creatorUserId?: InputMaybe; id?: InputMaybe; mimirConfigEnc?: InputMaybe; + subdomain?: InputMaybe; updatedAt?: InputMaybe; }; @@ -16254,6 +17080,8 @@ export enum Run_Service_Update_Column { /** column name */ MimirConfigEnc = 'mimirConfigEnc', /** column name */ + Subdomain = 'subdomain', + /** column name */ UpdatedAt = 'updatedAt' } @@ -16395,6 +17223,14 @@ export type Subscription_Root = { billingDedicatedComputeReportsAggregate: Billing_Dedicated_Compute_Reports_Aggregate; /** fetch data from the table: "billing.dedicated_compute" */ billingDedicatedComputes: Array; + /** fetch data from the table: "billing.reports" using primary key columns */ + billingReport?: Maybe; + /** fetch data from the table: "billing.reports" */ + billingReports: Array; + /** fetch aggregated fields from the table: "billing.reports" */ + billingReportsAggregate: Billing_Reports_Aggregate; + /** fetch data from the table in a streaming manner: "billing.reports" */ + billingReportsStream: Array; /** fetch data from the table: "billing.subscriptions" using primary key columns */ billingSubscription?: Maybe; /** fetch data from the table: "billing.subscriptions" */ @@ -16405,6 +17241,14 @@ export type Subscription_Root = { billing_dedicated_compute_reports_stream: Array; /** fetch data from the table in a streaming manner: "billing.dedicated_compute" */ billing_dedicated_compute_stream: Array; + /** fetch data from the table: "billing.report_type" */ + billing_report_type: Array; + /** fetch aggregated fields from the table: "billing.report_type" */ + billing_report_type_aggregate: Billing_Report_Type_Aggregate; + /** fetch data from the table: "billing.report_type" using primary key columns */ + billing_report_type_by_pk?: Maybe; + /** fetch data from the table in a streaming manner: "billing.report_type" */ + billing_report_type_stream: Array; /** fetch data from the table in a streaming manner: "billing.subscriptions" */ billing_subscriptions_stream: Array; /** fetch data from the table: "storage.buckets" using primary key columns */ @@ -17027,6 +17871,36 @@ export type Subscription_RootBillingDedicatedComputesArgs = { }; +export type Subscription_RootBillingReportArgs = { + id: Scalars['uuid']; +}; + + +export type Subscription_RootBillingReportsArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootBillingReportsAggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootBillingReportsStreamArgs = { + batch_size: Scalars['Int']; + cursor: Array>; + where?: InputMaybe; +}; + + export type Subscription_RootBillingSubscriptionArgs = { id: Scalars['uuid']; }; @@ -17064,6 +17938,36 @@ export type Subscription_RootBilling_Dedicated_Compute_StreamArgs = { }; +export type Subscription_RootBilling_Report_TypeArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootBilling_Report_Type_AggregateArgs = { + distinct_on?: InputMaybe>; + limit?: InputMaybe; + offset?: InputMaybe; + order_by?: InputMaybe>; + where?: InputMaybe; +}; + + +export type Subscription_RootBilling_Report_Type_By_PkArgs = { + value: Scalars['String']; +}; + + +export type Subscription_RootBilling_Report_Type_StreamArgs = { + batch_size: Scalars['Int']; + cursor: Array>; + where?: InputMaybe; +}; + + export type Subscription_RootBilling_Subscriptions_StreamArgs = { batch_size: Scalars['Int']; cursor: Array>; @@ -20569,7 +21473,7 @@ export type GetRunServiceQueryVariables = Exact<{ }>; -export type GetRunServiceQuery = { __typename?: 'query_root', runService?: { __typename?: 'run_service', id: any, config?: { __typename?: 'ConfigRunServiceConfig', name: string, command?: Array | null, image: { __typename?: 'ConfigRunServiceImage', image: string }, resources: { __typename?: 'ConfigRunServiceResources', replicas: any, compute: { __typename?: 'ConfigRunServiceResourcesCompute', cpu: any, memory: any }, storage?: Array<{ __typename?: 'ConfigRunServiceResourcesStorage', name: string, path: string, capacity: any }> | null }, environment?: Array<{ __typename?: 'ConfigEnvironmentVariable', name: string, value: string }> | null, ports?: Array<{ __typename?: 'ConfigRunServicePort', port: any, type: string, publish?: boolean | null }> | null } | null } | null }; +export type GetRunServiceQuery = { __typename?: 'query_root', runService?: { __typename?: 'run_service', id: any, subdomain: string, config?: { __typename?: 'ConfigRunServiceConfig', name: string, command?: Array | null, image: { __typename?: 'ConfigRunServiceImage', image: string }, resources: { __typename?: 'ConfigRunServiceResources', replicas: any, compute: { __typename?: 'ConfigRunServiceResourcesCompute', cpu: any, memory: any }, storage?: Array<{ __typename?: 'ConfigRunServiceResourcesStorage', name: string, path: string, capacity: any }> | null }, environment?: Array<{ __typename?: 'ConfigEnvironmentVariable', name: string, value: string }> | null, ports?: Array<{ __typename?: 'ConfigRunServicePort', port: any, type: string, publish?: boolean | null }> | null } | null } | null }; export type GetRunServicesQueryVariables = Exact<{ appID: Scalars['uuid']; @@ -20579,14 +21483,14 @@ export type GetRunServicesQueryVariables = Exact<{ }>; -export type GetRunServicesQuery = { __typename?: 'query_root', app?: { __typename?: 'apps', runServices: Array<{ __typename?: 'run_service', id: any, createdAt: any, updatedAt: any, config?: { __typename?: 'ConfigRunServiceConfig', name: string, command?: Array | null, image: { __typename?: 'ConfigRunServiceImage', image: string }, resources: { __typename?: 'ConfigRunServiceResources', replicas: any, compute: { __typename?: 'ConfigRunServiceResourcesCompute', cpu: any, memory: any }, storage?: Array<{ __typename?: 'ConfigRunServiceResourcesStorage', name: string, path: string, capacity: any }> | null }, environment?: Array<{ __typename?: 'ConfigEnvironmentVariable', name: string, value: string }> | null, ports?: Array<{ __typename?: 'ConfigRunServicePort', port: any, type: string, publish?: boolean | null }> | null } | null }>, runServices_aggregate: { __typename?: 'run_service_aggregate', aggregate?: { __typename?: 'run_service_aggregate_fields', count: number } | null } } | null }; +export type GetRunServicesQuery = { __typename?: 'query_root', app?: { __typename?: 'apps', runServices: Array<{ __typename?: 'run_service', id: any, createdAt: any, updatedAt: any, subdomain: string, config?: { __typename?: 'ConfigRunServiceConfig', name: string, command?: Array | null, image: { __typename?: 'ConfigRunServiceImage', image: string }, resources: { __typename?: 'ConfigRunServiceResources', replicas: any, compute: { __typename?: 'ConfigRunServiceResourcesCompute', cpu: any, memory: any }, storage?: Array<{ __typename?: 'ConfigRunServiceResourcesStorage', name: string, path: string, capacity: any }> | null }, environment?: Array<{ __typename?: 'ConfigEnvironmentVariable', name: string, value: string }> | null, ports?: Array<{ __typename?: 'ConfigRunServicePort', port: any, type: string, publish?: boolean | null }> | null } | null }>, runServices_aggregate: { __typename?: 'run_service_aggregate', aggregate?: { __typename?: 'run_service_aggregate_fields', count: number } | null } } | null }; export type InsertRunServiceMutationVariables = Exact<{ object: Run_Service_Insert_Input; }>; -export type InsertRunServiceMutation = { __typename?: 'mutation_root', insertRunService?: { __typename?: 'run_service', id: any, appID: any } | null }; +export type InsertRunServiceMutation = { __typename?: 'mutation_root', insertRunService?: { __typename?: 'run_service', id: any, subdomain: string } | null }; export type InsertRunServiceConfigMutationVariables = Exact<{ appID: Scalars['uuid']; @@ -23803,6 +24707,7 @@ export const GetRunServiceDocument = gql` query getRunService($id: uuid!, $resolve: Boolean!) { runService(id: $id) { id + subdomain config(resolve: $resolve) { name image { @@ -23873,6 +24778,7 @@ export const GetRunServicesDocument = gql` id createdAt updatedAt + subdomain config(resolve: $resolve) { name image { @@ -23948,7 +24854,7 @@ export const InsertRunServiceDocument = gql` mutation insertRunService($object: run_service_insert_input!) { insertRunService(object: $object) { id - appID + subdomain } } `; diff --git a/docs/docs/run/4_networking.mdx b/docs/docs/run/4_networking.mdx index a4ddcae8bf..c2add4af48 100644 --- a/docs/docs/run/4_networking.mdx +++ b/docs/docs/run/4_networking.mdx @@ -112,8 +112,8 @@ Currently, only services of type `http` can be exposed to the internet. 2. Once the service of type `http` is published, you can connect to it using a URL with the following format: - `https://--.svc..nhost.run` + `https://-.svc..nhost.run` For example: - `https://zlbmqjfczuwqvsquujno-mysvc-3000.svc.eu-central-1.nhost.run` + `https://zlbmqjfczuwqvsquujno-3000.svc.eu-central-1.nhost.run`