@gitpod/sdk
Version:
Public TypeScript SDK for Ona.
202 lines (201 loc) • 13 kB
JavaScript
"use strict";
// @generated by protoc-gen-es v2.11.0 with parameter "target=ts"
// @generated from file gitpod/v1/insights.proto (package gitpod.v1, syntax proto3)
/* eslint-disable */
Object.defineProperty(exports, "__esModule", { value: true });
exports.InsightsService = exports.CollectionOutcomeSchema = exports.CollectionOutcome = exports.ScmProviderSchema = exports.ScmProvider = exports.GetInsightsSummaryResponseSchema = exports.GetInsightsSummaryRequestSchema = exports.PullRequestStatSchema = exports.GetProjectInsightsStatusResponseSchema = exports.GetProjectInsightsStatusRequestSchema = exports.DisableProjectInsightsResponseSchema = exports.DisableProjectInsightsRequestSchema = exports.InsightsHealthIssue_CategorySchema = exports.InsightsHealthIssue_Category = exports.InsightsHealthIssueSchema = exports.EnableProjectInsightsResponseSchema = exports.EnableProjectInsightsRequestSchema = exports.CommitCoAuthorStatSchema = exports.file_gitpod_v1_insights = void 0;
const codegenv2_1 = require("@bufbuild/protobuf/codegenv2");
const validate_pb_1 = require("../../buf/validate/validate_pb");
const usage_pb_1 = require("./usage_pb");
const wkt_1 = require("@bufbuild/protobuf/wkt");
/**
* Describes the file gitpod/v1/insights.proto.
*/
exports.file_gitpod_v1_insights = (0, codegenv2_1.fileDesc)("ChhnaXRwb2QvdjEvaW5zaWdodHMucHJvdG8SCWdpdHBvZC52MSLAAgoSQ29tbWl0Q29BdXRob3JTdGF0Eh4KC2NvbW1pdF9oYXNoGAEgASgJQgm6SAZyBBABGEASNwoLY29tbWl0X2RhdGUYAiABKAsyGi5nb29nbGUucHJvdG9idWYuVGltZXN0YW1wQga6SAPIAQESMQoEdG9vbBgDIAEoDjIXLmdpdHBvZC52MS5Db0F1dGhvclRvb2xCCrpIB4IBBBABIAASHAoLbGluZXNfYWRkZWQYBCABKANCB7pIBCICKAASHgoNbGluZXNfcmVtb3ZlZBgFIAEoA0IHukgEIgIoABIfCgthdXRob3JfaGFzaBgGIAEoCUIKukgHcgUQARiAARI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gitpod_v1_usage, wkt_1.file_google_protobuf_timestamp]);
/**
* Describes the message gitpod.v1.CommitCoAuthorStat.
* Use `create(CommitCoAuthorStatSchema)` to create a new message.
*/
exports.CommitCoAuthorStatSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 0);
/**
* Describes the message gitpod.v1.EnableProjectInsightsRequest.
* Use `create(EnableProjectInsightsRequestSchema)` to create a new message.
*/
exports.EnableProjectInsightsRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 1);
/**
* Describes the message gitpod.v1.EnableProjectInsightsResponse.
* Use `create(EnableProjectInsightsResponseSchema)` to create a new message.
*/
exports.EnableProjectInsightsResponseSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 2);
/**
* Describes the message gitpod.v1.InsightsHealthIssue.
* Use `create(InsightsHealthIssueSchema)` to create a new message.
*/
exports.InsightsHealthIssueSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 3);
/**
* Category distinguishes the source of the issue. The frontend may use
* this to choose copy ("Insights can't run yet…" vs "Last insights run
* failed…").
*
* @generated from enum gitpod.v1.InsightsHealthIssue.Category
*/
var InsightsHealthIssue_Category;
(function (InsightsHealthIssue_Category) {
/**
* @generated from enum value: CATEGORY_UNSPECIFIED = 0;
*/
InsightsHealthIssue_Category[InsightsHealthIssue_Category["UNSPECIFIED"] = 0] = "UNSPECIFIED";
/**
* The issue is a prerequisite that has not been met. Prerequisites are
* deterministic, derived from project/org configuration, and checked
* synchronously before a workflow execution is attempted.
*
* @generated from enum value: CATEGORY_PREREQUISITE = 1;
*/
InsightsHealthIssue_Category[InsightsHealthIssue_Category["PREREQUISITE"] = 1] = "PREREQUISITE";
/**
* The issue is a runtime failure observed after a workflow execution
* was attempted. Runtime errors depend on runner-side state.
*
* @generated from enum value: CATEGORY_RUNTIME = 2;
*/
InsightsHealthIssue_Category[InsightsHealthIssue_Category["RUNTIME"] = 2] = "RUNTIME";
})(InsightsHealthIssue_Category || (exports.InsightsHealthIssue_Category = InsightsHealthIssue_Category = {}));
/**
* Describes the enum gitpod.v1.InsightsHealthIssue.Category.
*/
exports.InsightsHealthIssue_CategorySchema = (0, codegenv2_1.enumDesc)(exports.file_gitpod_v1_insights, 3, 0);
/**
* Describes the message gitpod.v1.DisableProjectInsightsRequest.
* Use `create(DisableProjectInsightsRequestSchema)` to create a new message.
*/
exports.DisableProjectInsightsRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 4);
/**
* Describes the message gitpod.v1.DisableProjectInsightsResponse.
* Use `create(DisableProjectInsightsResponseSchema)` to create a new message.
*/
exports.DisableProjectInsightsResponseSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 5);
/**
* Describes the message gitpod.v1.GetProjectInsightsStatusRequest.
* Use `create(GetProjectInsightsStatusRequestSchema)` to create a new message.
*/
exports.GetProjectInsightsStatusRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 6);
/**
* Describes the message gitpod.v1.GetProjectInsightsStatusResponse.
* Use `create(GetProjectInsightsStatusResponseSchema)` to create a new message.
*/
exports.GetProjectInsightsStatusResponseSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 7);
/**
* Describes the message gitpod.v1.PullRequestStat.
* Use `create(PullRequestStatSchema)` to create a new message.
*/
exports.PullRequestStatSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 8);
/**
* Describes the message gitpod.v1.GetInsightsSummaryRequest.
* Use `create(GetInsightsSummaryRequestSchema)` to create a new message.
*/
exports.GetInsightsSummaryRequestSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 9);
/**
* Describes the message gitpod.v1.GetInsightsSummaryResponse.
* Use `create(GetInsightsSummaryResponseSchema)` to create a new message.
*/
exports.GetInsightsSummaryResponseSchema = (0, codegenv2_1.messageDesc)(exports.file_gitpod_v1_insights, 10);
/**
* ScmProvider identifies the SCM platform a pull request was fetched from.
*
* @generated from enum gitpod.v1.ScmProvider
*/
var ScmProvider;
(function (ScmProvider) {
/**
* @generated from enum value: SCM_PROVIDER_UNSPECIFIED = 0;
*/
ScmProvider[ScmProvider["UNSPECIFIED"] = 0] = "UNSPECIFIED";
/**
* GitHub.
*
* @generated from enum value: SCM_PROVIDER_GITHUB = 1;
*/
ScmProvider[ScmProvider["GITHUB"] = 1] = "GITHUB";
/**
* GitLab.
*
* @generated from enum value: SCM_PROVIDER_GITLAB = 2;
*/
ScmProvider[ScmProvider["GITLAB"] = 2] = "GITLAB";
/**
* Bitbucket.
*
* @generated from enum value: SCM_PROVIDER_BITBUCKET = 3;
*/
ScmProvider[ScmProvider["BITBUCKET"] = 3] = "BITBUCKET";
})(ScmProvider || (exports.ScmProvider = ScmProvider = {}));
/**
* Describes the enum gitpod.v1.ScmProvider.
*/
exports.ScmProviderSchema = (0, codegenv2_1.enumDesc)(exports.file_gitpod_v1_insights, 0);
/**
* CollectionOutcome describes the result of a single CLI collection batch.
* Persisted in project_insights_settings so operators can diagnose NULL
* watermarks from the DB alone.
*
* @generated from enum gitpod.v1.CollectionOutcome
*/
var CollectionOutcome;
(function (CollectionOutcome) {
/**
* @generated from enum value: COLLECTION_OUTCOME_UNSPECIFIED = 0;
*/
CollectionOutcome[CollectionOutcome["UNSPECIFIED"] = 0] = "UNSPECIFIED";
/**
* Data collected and reported normally.
*
* @generated from enum value: COLLECTION_OUTCOME_SUCCESS = 1;
*/
CollectionOutcome[CollectionOutcome["SUCCESS"] = 1] = "SUCCESS";
/**
* No commits or PRs found in the collection window. The watermark still
* advances so the empty window is not re-fetched.
*
* @generated from enum value: COLLECTION_OUTCOME_EMPTY_WINDOW = 2;
*/
CollectionOutcome[CollectionOutcome["EMPTY_WINDOW"] = 2] = "EMPTY_WINDOW";
/**
* The CLI failed to read git log (e.g. corrupt repo, missing branch).
*
* @generated from enum value: COLLECTION_OUTCOME_GIT_LOG_ERROR = 3;
*/
CollectionOutcome[CollectionOutcome["GIT_LOG_ERROR"] = 3] = "GIT_LOG_ERROR";
/**
* The CLI failed to fetch PR data from the SCM API (e.g. auth failure,
* rate limit, network error).
*
* @generated from enum value: COLLECTION_OUTCOME_PR_FETCH_ERROR = 4;
*/
CollectionOutcome[CollectionOutcome["PR_FETCH_ERROR"] = 4] = "PR_FETCH_ERROR";
/**
* The CLI failed during setup before the collection loop started
* (e.g. credential resolution, project resolution, git remote parsing).
*
* @generated from enum value: COLLECTION_OUTCOME_SETUP_ERROR = 5;
*/
CollectionOutcome[CollectionOutcome["SETUP_ERROR"] = 5] = "SETUP_ERROR";
/**
* Catch-all for unexpected errors not covered by a specific variant.
*
* @generated from enum value: COLLECTION_OUTCOME_UNKNOWN_ERROR = 6;
*/
CollectionOutcome[CollectionOutcome["UNKNOWN_ERROR"] = 6] = "UNKNOWN_ERROR";
})(CollectionOutcome || (exports.CollectionOutcome = CollectionOutcome = {}));
/**
* Describes the enum gitpod.v1.CollectionOutcome.
*/
exports.CollectionOutcomeSchema = (0, codegenv2_1.enumDesc)(exports.file_gitpod_v1_insights, 1);
/**
* InsightsService provides AI code attribution analytics for projects.
* The CLI reports per-commit co-author data from git history, and the
* dashboard reads aggregated stats.
*
* @generated from service gitpod.v1.InsightsService
*/
exports.InsightsService = (0, codegenv2_1.serviceDesc)(exports.file_gitpod_v1_insights, 0);