Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions generated-sources/api/.openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,7 @@ src/models/Problem.ts
src/models/Project.ts
src/models/ProjectEntitlements.ts
src/models/ProjectEntitlementsBrandingRemoval.ts
src/models/ProjectEntitlementsLogRetentionDays.ts
src/models/ProviderApp.ts
src/models/ProviderAppMetadata.ts
src/models/ProviderAppMetadata1.ts
Expand Down
12 changes: 12 additions & 0 deletions generated-sources/api/src/apis/InstallationApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ export interface CreateInstallationOperationRequest {
projectIdOrName: string;
integrationId: string;
installation: CreateInstallationRequest;
skipSampling?: boolean;
}

export interface DeleteInstallationRequest {
Expand Down Expand Up @@ -78,6 +79,7 @@ export interface UpdateInstallationOperationRequest {
integrationId: string;
installationId: string;
installationUpdate: UpdateInstallationRequest;
skipSampling?: boolean;
}

/**
Expand All @@ -93,6 +95,7 @@ export interface InstallationApiInterface {
* @param {string} projectIdOrName The Ampersand project ID or project name.
* @param {string} integrationId The integration ID.
* @param {CreateInstallationRequest} installation
* @param {boolean} [skipSampling] When `true`, skips the sample read that validates the installation\'s read configuration against the provider before saving. Defaults to `false`.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof InstallationApiInterface
Expand Down Expand Up @@ -202,6 +205,7 @@ export interface InstallationApiInterface {
* @param {string} integrationId The ID of the integration that this installation belongs to.
* @param {string} installationId The Ampersand installation ID.
* @param {UpdateInstallationRequest} installationUpdate
* @param {boolean} [skipSampling] When `true`, skips the sample read that validates the installation\'s read configuration against the provider before saving. Defaults to `false`.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof InstallationApiInterface
Expand Down Expand Up @@ -240,6 +244,10 @@ export class InstallationApi extends runtime.BaseAPI implements InstallationApiI

const queryParameters: any = {};

if (requestParameters.skipSampling !== undefined) {
queryParameters['skipSampling'] = requestParameters.skipSampling;
}

const headerParameters: runtime.HTTPHeaders = {};

headerParameters['Content-Type'] = 'application/json';
Expand Down Expand Up @@ -561,6 +569,10 @@ export class InstallationApi extends runtime.BaseAPI implements InstallationApiI

const queryParameters: any = {};

if (requestParameters.skipSampling !== undefined) {
queryParameters['skipSampling'] = requestParameters.skipSampling;
}

const headerParameters: runtime.HTTPHeaders = {};

headerParameters['Content-Type'] = 'application/json';
Expand Down
8 changes: 4 additions & 4 deletions generated-sources/api/src/apis/OperationApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export interface OperationApiInterface {
getBackfillProgress(requestParameters: GetBackfillProgressRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<BackfillProgress>;

/**
* Retrieve a single operation by ID. An operation represents an async read, write, or subscribe action for an installation. Use this endpoint to poll for status, inspect the result summary, or fetch metadata such as backfill progress or write outcome details.
* Retrieve a single operation by ID. An operation represents an async read, write, or subscribe action for an installation. Use this endpoint to poll for status, inspect the result summary, or fetch metadata such as read progress or write outcome details.
* @summary Get an operation
* @param {string} projectIdOrName The Ampersand project ID or project name.
* @param {string} operationId Unique identifier for the operation. Obtain from the list operations API endpoint, the Ampersand dashboard, or webhook payloads.
Expand All @@ -100,7 +100,7 @@ export interface OperationApiInterface {
getOperationRaw(requestParameters: GetOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Operation>>;

/**
* Retrieve a single operation by ID. An operation represents an async read, write, or subscribe action for an installation. Use this endpoint to poll for status, inspect the result summary, or fetch metadata such as backfill progress or write outcome details.
* Retrieve a single operation by ID. An operation represents an async read, write, or subscribe action for an installation. Use this endpoint to poll for status, inspect the result summary, or fetch metadata such as read progress or write outcome details.
* Get an operation
*/
getOperation(requestParameters: GetOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Operation>;
Expand Down Expand Up @@ -204,7 +204,7 @@ export class OperationApi extends runtime.BaseAPI implements OperationApiInterfa
}

/**
* Retrieve a single operation by ID. An operation represents an async read, write, or subscribe action for an installation. Use this endpoint to poll for status, inspect the result summary, or fetch metadata such as backfill progress or write outcome details.
* Retrieve a single operation by ID. An operation represents an async read, write, or subscribe action for an installation. Use this endpoint to poll for status, inspect the result summary, or fetch metadata such as read progress or write outcome details.
* Get an operation
*/
async getOperationRaw(requestParameters: GetOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Operation>> {
Expand Down Expand Up @@ -243,7 +243,7 @@ export class OperationApi extends runtime.BaseAPI implements OperationApiInterfa
}

/**
* Retrieve a single operation by ID. An operation represents an async read, write, or subscribe action for an installation. Use this endpoint to poll for status, inspect the result summary, or fetch metadata such as backfill progress or write outcome details.
* Retrieve a single operation by ID. An operation represents an async read, write, or subscribe action for an installation. Use this endpoint to poll for status, inspect the result summary, or fetch metadata such as read progress or write outcome details.
* Get an operation
*/
async getOperation(requestParameters: GetOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Operation> {
Expand Down
37 changes: 12 additions & 25 deletions generated-sources/api/src/models/CreateEventTopicRouteRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,25 @@
*/

import { exists, mapValues } from '../runtime';
import type { NotificationEventType } from './NotificationEventType';
import {
NotificationEventTypeFromJSON,
NotificationEventTypeFromJSONTyped,
NotificationEventTypeToJSON,
} from './NotificationEventType';

/**
*
* @export
* @interface CreateEventTopicRouteRequest
*/
export interface CreateEventTopicRouteRequest {
/**
* The type of notification event.
* @type {string}
*
* @type {NotificationEventType}
* @memberof CreateEventTopicRouteRequest
*/
eventType: CreateEventTopicRouteRequestEventTypeEnum;
eventType: NotificationEventType;
/**
* The ID of the topic to route events to.
* @type {string}
Expand All @@ -33,26 +40,6 @@ export interface CreateEventTopicRouteRequest {
topicId: string;
}


/**
* @export
*/
export const CreateEventTopicRouteRequestEventTypeEnum = {
ReadBackfillDone: 'read.backfill.done',
ConnectionCreated: 'connection.created',
ConnectionError: 'connection.error',
ConnectionRefreshed: 'connection.refreshed',
ConnectionDeleted: 'connection.deleted',
InstallationCreated: 'installation.created',
InstallationUpdated: 'installation.updated',
InstallationDeleted: 'installation.deleted',
ReadSchedulePaused: 'read.schedule.paused',
WriteAsyncDone: 'write.async.done',
DestinationWebhookDisabled: 'destination.webhook.disabled'
} as const;
export type CreateEventTopicRouteRequestEventTypeEnum = typeof CreateEventTopicRouteRequestEventTypeEnum[keyof typeof CreateEventTopicRouteRequestEventTypeEnum];


/**
* Check if a given object implements the CreateEventTopicRouteRequest interface.
*/
Expand All @@ -74,7 +61,7 @@ export function CreateEventTopicRouteRequestFromJSONTyped(json: any, ignoreDiscr
}
return {

'eventType': json['eventType'],
'eventType': NotificationEventTypeFromJSON(json['eventType']),
'topicId': json['topicId'],
};
}
Expand All @@ -88,7 +75,7 @@ export function CreateEventTopicRouteRequestToJSON(value?: CreateEventTopicRoute
}
return {

'eventType': value.eventType,
'eventType': NotificationEventTypeToJSON(value.eventType),
'topicId': value.topicId,
};
}
Expand Down
14 changes: 14 additions & 0 deletions generated-sources/api/src/models/ModuleInfo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@
*/

import { exists, mapValues } from '../runtime';
import type { SubscribeRequirements } from './SubscribeRequirements';
import {
SubscribeRequirementsFromJSON,
SubscribeRequirementsFromJSONTyped,
SubscribeRequirementsToJSON,
} from './SubscribeRequirements';
import type { Support } from './Support';
import {
SupportFromJSON,
Expand Down Expand Up @@ -44,6 +50,12 @@ export interface ModuleInfo {
* @memberof ModuleInfo
*/
support: Support;
/**
*
* @type {SubscribeRequirements}
* @memberof ModuleInfo
*/
subscribeRequirements?: SubscribeRequirements;
}

/**
Expand Down Expand Up @@ -71,6 +83,7 @@ export function ModuleInfoFromJSONTyped(json: any, ignoreDiscriminator: boolean)
'displayName': json['displayName'],
'baseURL': json['baseURL'],
'support': SupportFromJSON(json['support']),
'subscribeRequirements': !exists(json, 'subscribeRequirements') ? undefined : SubscribeRequirementsFromJSON(json['subscribeRequirements']),
};
}

Expand All @@ -86,6 +99,7 @@ export function ModuleInfoToJSON(value?: ModuleInfo | null): any {
'displayName': value.displayName,
'baseURL': value.baseURL,
'support': SupportToJSON(value.support),
'subscribeRequirements': SubscribeRequirementsToJSON(value.subscribeRequirements),
};
}

1 change: 1 addition & 0 deletions generated-sources/api/src/models/NotificationEventType.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ export const NotificationEventType = {
ReadTriggeredDone: 'read.triggered.done',
ReadTriggeredError: 'read.triggered.error',
WriteAsyncDone: 'write.async.done',
SubscribeCreateError: 'subscribe.create.error',
DestinationWebhookDisabled: 'destination.webhook.disabled'
} as const;
export type NotificationEventType = typeof NotificationEventType[keyof typeof NotificationEventType];
Expand Down
2 changes: 1 addition & 1 deletion generated-sources/api/src/models/OperationMetadata.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import {
} from './OperationMetadataRetry';

/**
* Additional operation details (e.g. objects, retry info, backfill progress, successfulRecordIds).
* Additional operation details (e.g. objects, retry info, read progress, successfulRecordIds).
* @export
* @interface OperationMetadata
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

import { exists, mapValues } from '../runtime';
/**
* Only present for backfill read operations.
* Read progress for the operation, reporting records processed and, where available, the estimated total. Present for all read operations.
* @export
* @interface OperationMetadataProgress
*/
Expand Down
14 changes: 14 additions & 0 deletions generated-sources/api/src/models/ProjectEntitlements.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ import {
ProjectEntitlementsBrandingRemovalFromJSONTyped,
ProjectEntitlementsBrandingRemovalToJSON,
} from './ProjectEntitlementsBrandingRemoval';
import type { ProjectEntitlementsLogRetentionDays } from './ProjectEntitlementsLogRetentionDays';
import {
ProjectEntitlementsLogRetentionDaysFromJSON,
ProjectEntitlementsLogRetentionDaysFromJSONTyped,
ProjectEntitlementsLogRetentionDaysToJSON,
} from './ProjectEntitlementsLogRetentionDays';

/**
* Plan-based feature flags for the project. These are managed by Ampersand and cannot be set via the API.
Expand All @@ -32,6 +38,12 @@ export interface ProjectEntitlements {
* @memberof ProjectEntitlements
*/
brandingRemoval?: ProjectEntitlementsBrandingRemoval;
/**
*
* @type {ProjectEntitlementsLogRetentionDays}
* @memberof ProjectEntitlements
*/
logRetentionDays?: ProjectEntitlementsLogRetentionDays;
}

/**
Expand All @@ -54,6 +66,7 @@ export function ProjectEntitlementsFromJSONTyped(json: any, ignoreDiscriminator:
return {

'brandingRemoval': !exists(json, 'brandingRemoval') ? undefined : ProjectEntitlementsBrandingRemovalFromJSON(json['brandingRemoval']),
'logRetentionDays': !exists(json, 'logRetentionDays') ? undefined : ProjectEntitlementsLogRetentionDaysFromJSON(json['logRetentionDays']),
};
}

Expand All @@ -67,6 +80,7 @@ export function ProjectEntitlementsToJSON(value?: ProjectEntitlements | null): a
return {

'brandingRemoval': ProjectEntitlementsBrandingRemovalToJSON(value.brandingRemoval),
'logRetentionDays': ProjectEntitlementsLogRetentionDaysToJSON(value.logRetentionDays),
};
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
/* tslint:disable */
/* eslint-disable */
/**
* Ampersand public API
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/

import { exists, mapValues } from '../runtime';
/**
* The number of days that logs are retained for this project.
* @export
* @interface ProjectEntitlementsLogRetentionDays
*/
export interface ProjectEntitlementsLogRetentionDays {
/**
* The log retention period for this project, in days.
* @type {number}
* @memberof ProjectEntitlementsLogRetentionDays
*/
value: number;
}

/**
* Check if a given object implements the ProjectEntitlementsLogRetentionDays interface.
*/
export function instanceOfProjectEntitlementsLogRetentionDays(value: object): boolean {
let isInstance = true;
isInstance = isInstance && "value" in value;

return isInstance;
}

export function ProjectEntitlementsLogRetentionDaysFromJSON(json: any): ProjectEntitlementsLogRetentionDays {
return ProjectEntitlementsLogRetentionDaysFromJSONTyped(json, false);
}

export function ProjectEntitlementsLogRetentionDaysFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProjectEntitlementsLogRetentionDays {
if ((json === undefined) || (json === null)) {
return json;
}
return {

'value': json['value'],
};
}

export function ProjectEntitlementsLogRetentionDaysToJSON(value?: ProjectEntitlementsLogRetentionDays | null): any {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {

'value': value.value,
};
}

8 changes: 8 additions & 0 deletions generated-sources/api/src/models/SubscribeRequirements.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@ export interface SubscribeRequirements {
* @memberof SubscribeRequirements
*/
postProcess?: boolean;
/**
* Whether the provider supports programmatic subscription via API. If false, provider may still support webhooks via manual configuration in UI.
* @type {boolean}
* @memberof SubscribeRequirements
*/
subscribeByAPI?: boolean;
}

/**
Expand All @@ -61,6 +67,7 @@ export function SubscribeRequirementsFromJSONTyped(json: any, ignoreDiscriminato
'registration': !exists(json, 'registration') ? undefined : json['registration'],
'maintenance': !exists(json, 'maintenance') ? undefined : json['maintenance'],
'postProcess': !exists(json, 'postProcess') ? undefined : json['postProcess'],
'subscribeByAPI': !exists(json, 'subscribeByAPI') ? undefined : json['subscribeByAPI'],
};
}

Expand All @@ -76,6 +83,7 @@ export function SubscribeRequirementsToJSON(value?: SubscribeRequirements | null
'registration': value.registration,
'maintenance': value.maintenance,
'postProcess': value.postProcess,
'subscribeByAPI': value.subscribeByAPI,
};
}

1 change: 1 addition & 0 deletions generated-sources/api/src/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ export * from './Problem';
export * from './Project';
export * from './ProjectEntitlements';
export * from './ProjectEntitlementsBrandingRemoval';
export * from './ProjectEntitlementsLogRetentionDays';
export * from './ProviderApp';
export * from './ProviderAppMetadata';
export * from './ProviderAppMetadata1';
Expand Down
Loading