Skip to content

Commit

Permalink
chore: rebuild project due to codegen change (#511)
Browse files Browse the repository at this point in the history
  • Loading branch information
Stainless Bot committed Oct 31, 2024
1 parent e334267 commit 281b74c
Show file tree
Hide file tree
Showing 29 changed files with 731 additions and 426 deletions.
72 changes: 43 additions & 29 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,22 @@
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

import * as Errors from './error';
import * as Uploads from './uploads';
import { type Agent } from './_shims/index';
import * as qs from './internal/qs';
import * as Core from './core';
import * as Errors from './error';
import * as Pagination from './pagination';
import {
type BasePageParams,
BasePageResponse,
type PageWithTotalParams,
PageWithTotalResponse,
} from './pagination';
import * as Uploads from './uploads';
import * as API from './resources/index';
import { Webhooks } from './resources/webhooks';
import { Data } from './resources/data/data';
import { System } from './resources/system/system';
import { Video } from './resources/video/video';

export interface ClientOptions {
/**
Expand Down Expand Up @@ -222,48 +232,52 @@ export class Mux extends Core.APIClient {
static fileFromPath = Uploads.fileFromPath;
}

export const {
MuxError,
APIError,
APIConnectionError,
APIConnectionTimeoutError,
APIUserAbortError,
NotFoundError,
ConflictError,
RateLimitError,
BadRequestError,
AuthenticationError,
InternalServerError,
PermissionDeniedError,
UnprocessableEntityError,
} = Errors;
export const MuxError = Errors.MuxError;
export const APIError = Errors.APIError;
export const APIConnectionError = Errors.APIConnectionError;
export const APIConnectionTimeoutError = Errors.APIConnectionTimeoutError;
export const APIUserAbortError = Errors.APIUserAbortError;
export const NotFoundError = Errors.NotFoundError;
export const ConflictError = Errors.ConflictError;
export const RateLimitError = Errors.RateLimitError;
export const BadRequestError = Errors.BadRequestError;
export const AuthenticationError = Errors.AuthenticationError;
export const InternalServerError = Errors.InternalServerError;
export const PermissionDeniedError = Errors.PermissionDeniedError;
export const UnprocessableEntityError = Errors.UnprocessableEntityError;

export import toFile = Uploads.toFile;
export import fileFromPath = Uploads.fileFromPath;

export namespace Mux {
export import RequestOptions = Core.RequestOptions;
Mux.Video = Video;
Mux.Data = Data;
Mux.System = System;
Mux.Webhooks = Webhooks;

export declare namespace Mux {
export type RequestOptions = Core.RequestOptions;

export import PageWithTotal = Pagination.PageWithTotal;
export import PageWithTotalParams = Pagination.PageWithTotalParams;
export import PageWithTotalResponse = Pagination.PageWithTotalResponse;
export {
type PageWithTotalParams as PageWithTotalParams,
type PageWithTotalResponse as PageWithTotalResponse,
};

export import BasePage = Pagination.BasePage;
export import BasePageParams = Pagination.BasePageParams;
export import BasePageResponse = Pagination.BasePageResponse;
export { type BasePageParams as BasePageParams, type BasePageResponse as BasePageResponse };

export import Video = API.Video;
export { Video as Video };

export import Data = API.Data;
export { Data as Data };

export import System = API.System;
export { System as System };

export import Webhooks = API.Webhooks;
export { Webhooks as Webhooks };

export import Jwt = API.Jwt;

export import PlaybackID = API.PlaybackID;
export import PlaybackPolicy = API.PlaybackPolicy;
export type PlaybackID = API.PlaybackID;
export type PlaybackPolicy = API.PlaybackPolicy;
}

export default Mux;
196 changes: 145 additions & 51 deletions src/resources/data/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,71 @@

import { APIResource } from '../../resource';
import * as DimensionsAPI from './dimensions';
import {
DimensionListValuesParams,
DimensionValue,
DimensionValuesBasePage,
Dimensions,
DimensionsResponse,
} from './dimensions';
import * as ErrorsAPI from './errors';
import { ErrorListParams, Errors, ErrorsResponse } from './errors';
import * as ExportsAPI from './exports';
import { Exports, ExportsResponse, VideoViewExportsResponse } from './exports';
import * as FiltersAPI from './filters';
import {
FilterListValuesParams,
FilterValue,
FilterValuesBasePage,
Filters,
FiltersResponse,
} from './filters';
import * as IncidentsAPI from './incidents';
import {
Incident,
IncidentListParams,
IncidentListRelatedParams,
IncidentResponse,
Incidents,
IncidentsBasePage,
} from './incidents';
import * as MetricsAPI from './metrics';
import {
AllMetricValuesResponse,
BreakdownValue,
BreakdownValuesBasePage,
InsightsResponse,
MetricGetInsightsParams,
MetricGetOverallValuesParams,
MetricGetTimeseriesParams,
MetricListBreakdownValuesParams,
MetricListParams,
MetricTimeseriesDataResponse,
Metrics,
OverallValuesResponse,
} from './metrics';
import * as RealTimeAPI from './real-time';
import {
RealTime,
RealTimeBreakdownResponse,
RealTimeDimensionsResponse,
RealTimeHistogramTimeseriesResponse,
RealTimeMetricsResponse,
RealTimeRetrieveBreakdownParams,
RealTimeRetrieveHistogramTimeseriesParams,
RealTimeRetrieveTimeseriesParams,
RealTimeTimeseriesResponse,
} from './real-time';
import * as VideoViewsAPI from './video-views';
import {
AbridgedVideoView,
AbridgedVideoViewsBasePage,
VideoViewListParams,
VideoViewResponse,
VideoViews,
} from './video-views';
import * as MonitoringAPI from './monitoring/monitoring';
import { Monitoring, MonitoringListDimensionsResponse } from './monitoring/monitoring';

export class Data extends APIResource {
dimensions: DimensionsAPI.Dimensions = new DimensionsAPI.Dimensions(this._client);
Expand All @@ -23,55 +80,92 @@ export class Data extends APIResource {
videoViews: VideoViewsAPI.VideoViews = new VideoViewsAPI.VideoViews(this._client);
}

export namespace Data {
export import Dimensions = DimensionsAPI.Dimensions;
export import DimensionValue = DimensionsAPI.DimensionValue;
export import DimensionsResponse = DimensionsAPI.DimensionsResponse;
export import DimensionValuesBasePage = DimensionsAPI.DimensionValuesBasePage;
export import DimensionListValuesParams = DimensionsAPI.DimensionListValuesParams;
export import Monitoring = MonitoringAPI.Monitoring;
export import MonitoringListDimensionsResponse = MonitoringAPI.MonitoringListDimensionsResponse;
export import Errors = ErrorsAPI.Errors;
export import ErrorsResponse = ErrorsAPI.ErrorsResponse;
export import ErrorListParams = ErrorsAPI.ErrorListParams;
export import Exports = ExportsAPI.Exports;
export import ExportsResponse = ExportsAPI.ExportsResponse;
export import VideoViewExportsResponse = ExportsAPI.VideoViewExportsResponse;
export import Filters = FiltersAPI.Filters;
export import FilterValue = FiltersAPI.FilterValue;
export import FiltersResponse = FiltersAPI.FiltersResponse;
export import FilterValuesBasePage = FiltersAPI.FilterValuesBasePage;
export import FilterListValuesParams = FiltersAPI.FilterListValuesParams;
export import Incidents = IncidentsAPI.Incidents;
export import Incident = IncidentsAPI.Incident;
export import IncidentResponse = IncidentsAPI.IncidentResponse;
export import IncidentsBasePage = IncidentsAPI.IncidentsBasePage;
export import IncidentListParams = IncidentsAPI.IncidentListParams;
export import IncidentListRelatedParams = IncidentsAPI.IncidentListRelatedParams;
export import Metrics = MetricsAPI.Metrics;
export import AllMetricValuesResponse = MetricsAPI.AllMetricValuesResponse;
export import BreakdownValue = MetricsAPI.BreakdownValue;
export import InsightsResponse = MetricsAPI.InsightsResponse;
export import MetricTimeseriesDataResponse = MetricsAPI.MetricTimeseriesDataResponse;
export import OverallValuesResponse = MetricsAPI.OverallValuesResponse;
export import BreakdownValuesBasePage = MetricsAPI.BreakdownValuesBasePage;
export import MetricListParams = MetricsAPI.MetricListParams;
export import MetricGetInsightsParams = MetricsAPI.MetricGetInsightsParams;
export import MetricGetOverallValuesParams = MetricsAPI.MetricGetOverallValuesParams;
export import MetricGetTimeseriesParams = MetricsAPI.MetricGetTimeseriesParams;
export import MetricListBreakdownValuesParams = MetricsAPI.MetricListBreakdownValuesParams;
export import RealTime = RealTimeAPI.RealTime;
export import RealTimeBreakdownResponse = RealTimeAPI.RealTimeBreakdownResponse;
export import RealTimeDimensionsResponse = RealTimeAPI.RealTimeDimensionsResponse;
export import RealTimeHistogramTimeseriesResponse = RealTimeAPI.RealTimeHistogramTimeseriesResponse;
export import RealTimeMetricsResponse = RealTimeAPI.RealTimeMetricsResponse;
export import RealTimeTimeseriesResponse = RealTimeAPI.RealTimeTimeseriesResponse;
export import RealTimeRetrieveBreakdownParams = RealTimeAPI.RealTimeRetrieveBreakdownParams;
export import RealTimeRetrieveHistogramTimeseriesParams = RealTimeAPI.RealTimeRetrieveHistogramTimeseriesParams;
export import RealTimeRetrieveTimeseriesParams = RealTimeAPI.RealTimeRetrieveTimeseriesParams;
export import VideoViews = VideoViewsAPI.VideoViews;
export import AbridgedVideoView = VideoViewsAPI.AbridgedVideoView;
export import VideoViewResponse = VideoViewsAPI.VideoViewResponse;
export import AbridgedVideoViewsBasePage = VideoViewsAPI.AbridgedVideoViewsBasePage;
export import VideoViewListParams = VideoViewsAPI.VideoViewListParams;
Data.Dimensions = Dimensions;
Data.DimensionValuesBasePage = DimensionValuesBasePage;
Data.Monitoring = Monitoring;
Data.Errors = Errors;
Data.Exports = Exports;
Data.Filters = Filters;
Data.FilterValuesBasePage = FilterValuesBasePage;
Data.Incidents = Incidents;
Data.IncidentsBasePage = IncidentsBasePage;
Data.Metrics = Metrics;
Data.BreakdownValuesBasePage = BreakdownValuesBasePage;
Data.RealTime = RealTime;
Data.VideoViews = VideoViews;
Data.AbridgedVideoViewsBasePage = AbridgedVideoViewsBasePage;

export declare namespace Data {
export {
Dimensions as Dimensions,
type DimensionValue as DimensionValue,
type DimensionsResponse as DimensionsResponse,
DimensionValuesBasePage as DimensionValuesBasePage,
type DimensionListValuesParams as DimensionListValuesParams,
};

export {
Monitoring as Monitoring,
type MonitoringListDimensionsResponse as MonitoringListDimensionsResponse,
};

export { Errors as Errors, type ErrorsResponse as ErrorsResponse, type ErrorListParams as ErrorListParams };

export {
Exports as Exports,
type ExportsResponse as ExportsResponse,
type VideoViewExportsResponse as VideoViewExportsResponse,
};

export {
Filters as Filters,
type FilterValue as FilterValue,
type FiltersResponse as FiltersResponse,
FilterValuesBasePage as FilterValuesBasePage,
type FilterListValuesParams as FilterListValuesParams,
};

export {
Incidents as Incidents,
type Incident as Incident,
type IncidentResponse as IncidentResponse,
IncidentsBasePage as IncidentsBasePage,
type IncidentListParams as IncidentListParams,
type IncidentListRelatedParams as IncidentListRelatedParams,
};

export {
Metrics as Metrics,
type AllMetricValuesResponse as AllMetricValuesResponse,
type BreakdownValue as BreakdownValue,
type InsightsResponse as InsightsResponse,
type MetricTimeseriesDataResponse as MetricTimeseriesDataResponse,
type OverallValuesResponse as OverallValuesResponse,
BreakdownValuesBasePage as BreakdownValuesBasePage,
type MetricListParams as MetricListParams,
type MetricGetInsightsParams as MetricGetInsightsParams,
type MetricGetOverallValuesParams as MetricGetOverallValuesParams,
type MetricGetTimeseriesParams as MetricGetTimeseriesParams,
type MetricListBreakdownValuesParams as MetricListBreakdownValuesParams,
};

export {
RealTime as RealTime,
type RealTimeBreakdownResponse as RealTimeBreakdownResponse,
type RealTimeDimensionsResponse as RealTimeDimensionsResponse,
type RealTimeHistogramTimeseriesResponse as RealTimeHistogramTimeseriesResponse,
type RealTimeMetricsResponse as RealTimeMetricsResponse,
type RealTimeTimeseriesResponse as RealTimeTimeseriesResponse,
type RealTimeRetrieveBreakdownParams as RealTimeRetrieveBreakdownParams,
type RealTimeRetrieveHistogramTimeseriesParams as RealTimeRetrieveHistogramTimeseriesParams,
type RealTimeRetrieveTimeseriesParams as RealTimeRetrieveTimeseriesParams,
};

export {
VideoViews as VideoViews,
type AbridgedVideoView as AbridgedVideoView,
type VideoViewResponse as VideoViewResponse,
AbridgedVideoViewsBasePage as AbridgedVideoViewsBasePage,
type VideoViewListParams as VideoViewListParams,
};
}
15 changes: 9 additions & 6 deletions src/resources/data/dimensions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import { APIResource } from '../../resource';
import { isRequestOptions } from '../../core';
import * as Core from '../../core';
import * as DimensionsAPI from './dimensions';
import { BasePage, type BasePageParams } from '../../pagination';

export class Dimensions extends APIResource {
Expand Down Expand Up @@ -111,9 +110,13 @@ export interface DimensionListValuesParams extends BasePageParams {
timeframe?: Array<string>;
}

export namespace Dimensions {
export import DimensionValue = DimensionsAPI.DimensionValue;
export import DimensionsResponse = DimensionsAPI.DimensionsResponse;
export import DimensionValuesBasePage = DimensionsAPI.DimensionValuesBasePage;
export import DimensionListValuesParams = DimensionsAPI.DimensionListValuesParams;
Dimensions.DimensionValuesBasePage = DimensionValuesBasePage;

export declare namespace Dimensions {
export {
type DimensionValue as DimensionValue,
type DimensionsResponse as DimensionsResponse,
DimensionValuesBasePage as DimensionValuesBasePage,
type DimensionListValuesParams as DimensionListValuesParams,
};
}
6 changes: 2 additions & 4 deletions src/resources/data/errors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import { APIResource } from '../../resource';
import { isRequestOptions } from '../../core';
import * as Core from '../../core';
import * as ErrorsAPI from './errors';

export class Errors extends APIResource {
/**
Expand Down Expand Up @@ -121,7 +120,6 @@ export interface ErrorListParams {
timeframe?: Array<string>;
}

export namespace Errors {
export import ErrorsResponse = ErrorsAPI.ErrorsResponse;
export import ErrorListParams = ErrorsAPI.ErrorListParams;
export declare namespace Errors {
export { type ErrorsResponse as ErrorsResponse, type ErrorListParams as ErrorListParams };
}
9 changes: 5 additions & 4 deletions src/resources/data/exports.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import { APIResource } from '../../resource';
import * as Core from '../../core';
import * as ExportsAPI from './exports';

export class Exports extends APIResource {
/**
Expand Down Expand Up @@ -47,7 +46,9 @@ export namespace VideoViewExportsResponse {
}
}

export namespace Exports {
export import ExportsResponse = ExportsAPI.ExportsResponse;
export import VideoViewExportsResponse = ExportsAPI.VideoViewExportsResponse;
export declare namespace Exports {
export {
type ExportsResponse as ExportsResponse,
type VideoViewExportsResponse as VideoViewExportsResponse,
};
}
Loading

0 comments on commit 281b74c

Please sign in to comment.