Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
chore: vcs connector API (#11347)
Danny Xud4289737d9c5
diff --git a/frontend/src/types/proto/v1/vcs_connector_service.ts b/frontend/src/types/proto/v1/vcs_connector_service.tsnew file mode 100644index 0000000000..e025d2e350--- /dev/null+++ b/frontend/src/types/proto/v1/vcs_connector_service.ts@@ -0,0 +1,1267 @@+/* eslint-disable */+import Long from "long";+import _m0 from "protobufjs/minimal";+import { Empty } from "../google/protobuf/empty";+import { FieldMask } from "../google/protobuf/field_mask";+import { Timestamp } from "../google/protobuf/timestamp";++export const protobufPackage = "bytebase.v1";++export interface CreateVCSConnectorRequest {+ /**+ * The parent resource where this vcsConnector will be created.+ * Format: projects/{project}+ */+ parent: string;+ /** The vcsConnector to create. */+ vcsConnector:+ | VCSConnector+ | undefined;+ /**+ * The ID to use for the vcsConnector, which will become the final component of+ * the vcsConnector's resource name.+ *+ * This value should be 4-63 characters, and valid characters+ * are /[a-z][0-9]-/.+ */+ vcsConnectorId: string;+}++export interface GetVCSConnectorRequest {+ /**+ * The name of the vcsConnector to retrieve.+ * Format: projects/{project}/vcsConnectors/{vcsConnector}+ */+ name: string;+}++export interface ListVCSConnectorsRequest {+ /**+ * The parent, which owns this collection of vcsConnectors.+ * Format: projects/{project}+ * Use "projects/-" to list all vcsConnectors.+ */+ parent: string;+ /**+ * The maximum number of databases to return. The service may return fewer than+ * this value.+ * If unspecified, at most 50 databases will be returned.+ * The maximum value is 1000; values above 1000 will be coerced to 1000.+ */+ pageSize: number;+ /**+ * A page token, received from a previous `ListDatabases` call.+ * Provide this to retrieve the subsequent page.+ *+ * When paginating, all other parameters provided to `ListDatabases` must match+ * the call that provided the page token.+ */+ pageToken: string;+}++export interface ListVCSConnectorsResponse {+ /** The vcsConnectors from the specified request. */+ vcsConnectors: VCSConnector[];+ /**+ * A token, which can be sent as `page_token` to retrieve the next page.+ * If this field is omitted, there are no subsequent pages.+ */+ nextPageToken: string;+}++export interface UpdateVCSConnectorRequest {+ /**+ * The vcsConnector to update.+ *+ * The vcsConnector's `name` field is used to identify the vcsConnector to update.+ * Format: projects/{project}/vcsConnectors/{vcsConnector}+ */+ vcsConnector:+ | VCSConnector+ | undefined;+ /** The list of fields to be updated. */+ updateMask: string[] | undefined;+}++export interface DeleteVCSConnectorRequest {+ /**+ * The name of the vcsConnector to delete.+ * Format: projects/{project}/vcsConnectors/{vcsConnector}+ */+ name: string;+}++export interface VCSConnector {+ /**+ * The name of the vcsConnector resource.+ * Canonical parent is project.+ * Format: projects/{project}/vcsConnectors/{vcsConnector}+ */+ name: string;+ /** The title of the vcs connector. */+ title: string;+ /**+ * The creator of the vcsConnector.+ * Format: users/{email}+ */+ creator: string;+ /**+ * The updater of the vcsConnector.+ * Format: users/{email}+ */+ updater: string;+ /** The create time of the vcsConnector. */+ createTime:+ | Date+ | undefined;+ /** The last update time of the vcsConnector. */+ updateTime:+ | Date+ | undefined;+ /**+ * The name of the VCS.+ * Format: vcsProviders/{vcsProvider}+ */+ vcsProvider: string;+ /** The reposition external id in target VCS. */+ externalId: string;+ /** The root directory where Bytebase observes the file change. If empty, then it observes the entire repository. */+ baseDirectory: string;+ /** The branch Bytebase listens to for changes. For example: main. */+ branch: string;+ /** The webhook endpoint ID of the repository. */+ webhookEndpointId: string;+ /**+ * TODO(d): move these to create VCS connector API.+ * The full_path of the repository. For example: bytebase/sample.+ */+ fullPath: string;+ /** The web url of the repository. For axample: https://gitlab.bytebase.com/bytebase/sample. */+ webUrl: string;+}++function createBaseCreateVCSConnectorRequest(): CreateVCSConnectorRequest {+ return { parent: "", vcsConnector: undefined, vcsConnectorId: "" };+}++export const CreateVCSConnectorRequest = {+ encode(message: CreateVCSConnectorRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {+ if (message.parent !== "") {+ writer.uint32(10).string(message.parent);+ }+ if (message.vcsConnector !== undefined) {+ VCSConnector.encode(message.vcsConnector, writer.uint32(18).fork()).ldelim();+ }+ if (message.vcsConnectorId !== "") {+ writer.uint32(26).string(message.vcsConnectorId);+ }+ return writer;+ },++ decode(input: _m0.Reader | Uint8Array, length?: number): CreateVCSConnectorRequest {+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);+ let end = length === undefined ? reader.len : reader.pos + length;+ const message = createBaseCreateVCSConnectorRequest();+ while (reader.pos < end) {+ const tag = reader.uint32();+ switch (tag >>> 3) {+ case 1:+ if (tag !== 10) {+ break;+ }++ message.parent = reader.string();+ continue;+ case 2:+ if (tag !== 18) {+ break;+ }++ message.vcsConnector = VCSConnector.decode(reader, reader.uint32());+ continue;+ case 3:+ if (tag !== 26) {+ break;+ }++ message.vcsConnectorId = reader.string();+ continue;+ }+ if ((tag & 7) === 4 || tag === 0) {+ break;+ }+ reader.skipType(tag & 7);+ }+ return message;+ },++ fromJSON(object: any): CreateVCSConnectorRequest {+ return {+ parent: isSet(object.parent) ? globalThis.String(object.parent) : "",+ vcsConnector: isSet(object.vcsConnector) ? VCSConnector.fromJSON(object.vcsConnector) : undefined,+ vcsConnectorId: isSet(object.vcsConnectorId) ? globalThis.String(object.vcsConnectorId) : "",+ };+ },++ toJSON(message: CreateVCSConnectorRequest): unknown {+ const obj: any = {};+ if (message.parent !== "") {+ obj.parent = message.parent;+ }+ if (message.vcsConnector !== undefined) {+ obj.vcsConnector = VCSConnector.toJSON(message.vcsConnector);+ }+ if (message.vcsConnectorId !== "") {+ obj.vcsConnectorId = message.vcsConnectorId;+ }+ return obj;+ },++ create(base?: DeepPartial<CreateVCSConnectorRequest>): CreateVCSConnectorRequest {+ return CreateVCSConnectorRequest.fromPartial(base ?? {});+ },+ fromPartial(object: DeepPartial<CreateVCSConnectorRequest>): CreateVCSConnectorRequest {+ const message = createBaseCreateVCSConnectorRequest();+ message.parent = object.parent ?? "";+ message.vcsConnector = (object.vcsConnector !== undefined && object.vcsConnector !== null)+ ? VCSConnector.fromPartial(object.vcsConnector)+ : undefined;+ message.vcsConnectorId = object.vcsConnectorId ?? "";+ return message;+ },+};++function createBaseGetVCSConnectorRequest(): GetVCSConnectorRequest {+ return { name: "" };+}++export const GetVCSConnectorRequest = {+ encode(message: GetVCSConnectorRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {+ if (message.name !== "") {+ writer.uint32(10).string(message.name);+ }+ return writer;+ },++ decode(input: _m0.Reader | Uint8Array, length?: number): GetVCSConnectorRequest {+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);+ let end = length === undefined ? reader.len : reader.pos + length;+ const message = createBaseGetVCSConnectorRequest();+ while (reader.pos < end) {+ const tag = reader.uint32();+ switch (tag >>> 3) {+ case 1:+ if (tag !== 10) {+ break;+ }++ message.name = reader.string();+ continue;+ }+ if ((tag & 7) === 4 || tag === 0) {+ break;+ }+ reader.skipType(tag & 7);+ }+ return message;+ },++ fromJSON(object: any): GetVCSConnectorRequest {+ return { name: isSet(object.name) ? globalThis.String(object.name) : "" };+ },++ toJSON(message: GetVCSConnectorRequest): unknown {+ const obj: any = {};+ if (message.name !== "") {+ obj.name = message.name;+ }+ return obj;+ },++ create(base?: DeepPartial<GetVCSConnectorRequest>): GetVCSConnectorRequest {+ return GetVCSConnectorRequest.fromPartial(base ?? {});+ },+ fromPartial(object: DeepPartial<GetVCSConnectorRequest>): GetVCSConnectorRequest {+ const message = createBaseGetVCSConnectorRequest();+ message.name = object.name ?? "";+ return message;+ },+};++function createBaseListVCSConnectorsRequest(): ListVCSConnectorsRequest {+ return { parent: "", pageSize: 0, pageToken: "" };+}++export const ListVCSConnectorsRequest = {+ encode(message: ListVCSConnectorsRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {+ if (message.parent !== "") {+ writer.uint32(10).string(message.parent);+ }+ if (message.pageSize !== 0) {+ writer.uint32(16).int32(message.pageSize);+ }+ if (message.pageToken !== "") {+ writer.uint32(26).string(message.pageToken);+ }+ return writer;+ },++ decode(input: _m0.Reader | Uint8Array, length?: number): ListVCSConnectorsRequest {+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);+ let end = length === undefined ? reader.len : reader.pos + length;+ const message = createBaseListVCSConnectorsRequest();+ while (reader.pos < end) {+ const tag = reader.uint32();+ switch (tag >>> 3) {+ case 1:+ if (tag !== 10) {+ break;+ }++ message.parent = reader.string();+ continue;+ case 2:+ if (tag !== 16) {+ break;+ }++ message.pageSize = reader.int32();+ continue;+ case 3:+ if (tag !== 26) {+ break;+ }++ message.pageToken = reader.string();+ continue;+ }+ if ((tag & 7) === 4 || tag === 0) {+ break;+ }+ reader.skipType(tag & 7);+ }+ return message;+ },++ fromJSON(object: any): ListVCSConnectorsRequest {+ return {+ parent: isSet(object.parent) ? globalThis.String(object.parent) : "",+ pageSize: isSet(object.pageSize) ? globalThis.Number(object.pageSize) : 0,+ pageToken: isSet(object.pageToken) ? globalThis.String(object.pageToken) : "",+ };+ },++ toJSON(message: ListVCSConnectorsRequest): unknown {+ const obj: any = {};+ if (message.parent !== "") {+ obj.parent = message.parent;+ }+ if (message.pageSize !== 0) {+ obj.pageSize = Math.round(message.pageSize);+ }+ if (message.pageToken !== "") {+ obj.pageToken = message.pageToken;+ }+ return obj;+ },++ create(base?: DeepPartial<ListVCSConnectorsRequest>): ListVCSConnectorsRequest {+ return ListVCSConnectorsRequest.fromPartial(base ?? {});+ },+ fromPartial(object: DeepPartial<ListVCSConnectorsRequest>): ListVCSConnectorsRequest {+ const message = createBaseListVCSConnectorsRequest();+ message.parent = object.parent ?? "";+ message.pageSize = object.pageSize ?? 0;+ message.pageToken = object.pageToken ?? "";+ return message;+ },+};++function createBaseListVCSConnectorsResponse(): ListVCSConnectorsResponse {+ return { vcsConnectors: [], nextPageToken: "" };+}++export const ListVCSConnectorsResponse = {+ encode(message: ListVCSConnectorsResponse, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {+ for (const v of message.vcsConnectors) {+ VCSConnector.encode(v!, writer.uint32(10).fork()).ldelim();+ }+ if (message.nextPageToken !== "") {+ writer.uint32(18).string(message.nextPageToken);+ }+ return writer;+ },++ decode(input: _m0.Reader | Uint8Array, length?: number): ListVCSConnectorsResponse {+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);+ let end = length === undefined ? reader.len : reader.pos + length;+ const message = createBaseListVCSConnectorsResponse();+ while (reader.pos < end) {+ const tag = reader.uint32();+ switch (tag >>> 3) {+ case 1:+ if (tag !== 10) {+ break;+ }++ message.vcsConnectors.push(VCSConnector.decode(reader, reader.uint32()));+ continue;+ case 2:+ if (tag !== 18) {+ break;+ }++ message.nextPageToken = reader.string();+ continue;+ }+ if ((tag & 7) === 4 || tag === 0) {+ break;+ }+ reader.skipType(tag & 7);+ }+ return message;+ },++ fromJSON(object: any): ListVCSConnectorsResponse {+ return {+ vcsConnectors: globalThis.Array.isArray(object?.vcsConnectors)+ ? object.vcsConnectors.map((e: any) => VCSConnector.fromJSON(e))+ : [],+ nextPageToken: isSet(object.nextPageToken) ? globalThis.String(object.nextPageToken) : "",+ };+ },++ toJSON(message: ListVCSConnectorsResponse): unknown {+ const obj: any = {};+ if (message.vcsConnectors?.length) {+ obj.vcsConnectors = message.vcsConnectors.map((e) => VCSConnector.toJSON(e));+ }+ if (message.nextPageToken !== "") {+ obj.nextPageToken = message.nextPageToken;+ }+ return obj;+ },++ create(base?: DeepPartial<ListVCSConnectorsResponse>): ListVCSConnectorsResponse {+ return ListVCSConnectorsResponse.fromPartial(base ?? {});+ },+ fromPartial(object: DeepPartial<ListVCSConnectorsResponse>): ListVCSConnectorsResponse {+ const message = createBaseListVCSConnectorsResponse();+ message.vcsConnectors = object.vcsConnectors?.map((e) => VCSConnector.fromPartial(e)) || [];+ message.nextPageToken = object.nextPageToken ?? "";+ return message;+ },+};++function createBaseUpdateVCSConnectorRequest(): UpdateVCSConnectorRequest {+ return { vcsConnector: undefined, updateMask: undefined };+}++export const UpdateVCSConnectorRequest = {+ encode(message: UpdateVCSConnectorRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {+ if (message.vcsConnector !== undefined) {+ VCSConnector.encode(message.vcsConnector, writer.uint32(10).fork()).ldelim();+ }+ if (message.updateMask !== undefined) {+ FieldMask.encode(FieldMask.wrap(message.updateMask), writer.uint32(18).fork()).ldelim();+ }+ return writer;+ },++ decode(input: _m0.Reader | Uint8Array, length?: number): UpdateVCSConnectorRequest {+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);+ let end = length === undefined ? reader.len : reader.pos + length;+ const message = createBaseUpdateVCSConnectorRequest();+ while (reader.pos < end) {+ const tag = reader.uint32();+ switch (tag >>> 3) {+ case 1:+ if (tag !== 10) {+ break;+ }++ message.vcsConnector = VCSConnector.decode(reader, reader.uint32());+ continue;+ case 2:+ if (tag !== 18) {+ break;+ }++ message.updateMask = FieldMask.unwrap(FieldMask.decode(reader, reader.uint32()));+ continue;+ }+ if ((tag & 7) === 4 || tag === 0) {+ break;+ }+ reader.skipType(tag & 7);+ }+ return message;+ },++ fromJSON(object: any): UpdateVCSConnectorRequest {+ return {+ vcsConnector: isSet(object.vcsConnector) ? VCSConnector.fromJSON(object.vcsConnector) : undefined,+ updateMask: isSet(object.updateMask) ? FieldMask.unwrap(FieldMask.fromJSON(object.updateMask)) : undefined,+ };+ },++ toJSON(message: UpdateVCSConnectorRequest): unknown {+ const obj: any = {};+ if (message.vcsConnector !== undefined) {+ obj.vcsConnector = VCSConnector.toJSON(message.vcsConnector);+ }+ if (message.updateMask !== undefined) {+ obj.updateMask = FieldMask.toJSON(FieldMask.wrap(message.updateMask));+ }+ return obj;+ },++ create(base?: DeepPartial<UpdateVCSConnectorRequest>): UpdateVCSConnectorRequest {+ return UpdateVCSConnectorRequest.fromPartial(base ?? {});+ },+ fromPartial(object: DeepPartial<UpdateVCSConnectorRequest>): UpdateVCSConnectorRequest {+ const message = createBaseUpdateVCSConnectorRequest();+ message.vcsConnector = (object.vcsConnector !== undefined && object.vcsConnector !== null)+ ? VCSConnector.fromPartial(object.vcsConnector)+ : undefined;+ message.updateMask = object.updateMask ?? undefined;+ return message;+ },+};++function createBaseDeleteVCSConnectorRequest(): DeleteVCSConnectorRequest {+ return { name: "" };+}++export const DeleteVCSConnectorRequest = {+ encode(message: DeleteVCSConnectorRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {+ if (message.name !== "") {+ writer.uint32(10).string(message.name);+ }+ return writer;+ },++ decode(input: _m0.Reader | Uint8Array, length?: number): DeleteVCSConnectorRequest {+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);+ let end = length === undefined ? reader.len : reader.pos + length;+ const message = createBaseDeleteVCSConnectorRequest();+ while (reader.pos < end) {+ const tag = reader.uint32();+ switch (tag >>> 3) {+ case 1:+ if (tag !== 10) {+ break;+ }++ message.name = reader.string();+ continue;+ }+ if ((tag & 7) === 4 || tag === 0) {+ break;+ }+ reader.skipType(tag & 7);+ }+ return message;+ },++ fromJSON(object: any): DeleteVCSConnectorRequest {+ return { name: isSet(object.name) ? globalThis.String(object.name) : "" };+ },++ toJSON(message: DeleteVCSConnectorRequest): unknown {+ const obj: any = {};+ if (message.name !== "") {+ obj.name = message.name;+ }+ return obj;+ },++ create(base?: DeepPartial<DeleteVCSConnectorRequest>): DeleteVCSConnectorRequest {+ return DeleteVCSConnectorRequest.fromPartial(base ?? {});+ },+ fromPartial(object: DeepPartial<DeleteVCSConnectorRequest>): DeleteVCSConnectorRequest {+ const message = createBaseDeleteVCSConnectorRequest();+ message.name = object.name ?? "";+ return message;+ },+};++function createBaseVCSConnector(): VCSConnector {+ return {+ name: "",+ title: "",+ creator: "",+ updater: "",+ createTime: undefined,+ updateTime: undefined,+ vcsProvider: "",+ externalId: "",+ baseDirectory: "",+ branch: "",+ webhookEndpointId: "",+ fullPath: "",+ webUrl: "",+ };+}++export const VCSConnector = {+ encode(message: VCSConnector, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {+ if (message.name !== "") {+ writer.uint32(10).string(message.name);+ }+ if (message.title !== "") {+ writer.uint32(18).string(message.title);+ }+ if (message.creator !== "") {+ writer.uint32(26).string(message.creator);+ }+ if (message.updater !== "") {+ writer.uint32(34).string(message.updater);+ }+ if (message.createTime !== undefined) {+ Timestamp.encode(toTimestamp(message.createTime), writer.uint32(42).fork()).ldelim();+ }+ if (message.updateTime !== undefined) {+ Timestamp.encode(toTimestamp(message.updateTime), writer.uint32(50).fork()).ldelim();+ }+ if (message.vcsProvider !== "") {+ writer.uint32(58).string(message.vcsProvider);+ }+ if (message.externalId !== "") {+ writer.uint32(66).string(message.externalId);+ }+ if (message.baseDirectory !== "") {+ writer.uint32(74).string(message.baseDirectory);+ }+ if (message.branch !== "") {+ writer.uint32(82).string(message.branch);+ }+ if (message.webhookEndpointId !== "") {+ writer.uint32(90).string(message.webhookEndpointId);+ }+ if (message.fullPath !== "") {+ writer.uint32(98).string(message.fullPath);+ }+ if (message.webUrl !== "") {+ writer.uint32(106).string(message.webUrl);+ }+ return writer;+ },++ decode(input: _m0.Reader | Uint8Array, length?: number): VCSConnector {+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);+ let end = length === undefined ? reader.len : reader.pos + length;+ const message = createBaseVCSConnector();+ while (reader.pos < end) {+ const tag = reader.uint32();+ switch (tag >>> 3) {+ case 1:+ if (tag !== 10) {+ break;+ }++ message.name = reader.string();+ continue;+ case 2:+ if (tag !== 18) {+ break;+ }++ message.title = reader.string();+ continue;+ case 3:+ if (tag !== 26) {+ break;+ }++ message.creator = reader.string();+ continue;+ case 4:+ if (tag !== 34) {+ break;+ }++ message.updater = reader.string();+ continue;+ case 5:+ if (tag !== 42) {+ break;+ }++ message.createTime = fromTimestamp(Timestamp.decode(reader, reader.uint32()));+ continue;+ case 6:+ if (tag !== 50) {+ break;+ }++ message.updateTime = fromTimestamp(Timestamp.decode(reader, reader.uint32()));+ continue;+ case 7:+ if (tag !== 58) {+ break;+ }++ message.vcsProvider = reader.string();+ continue;+ case 8:+ if (tag !== 66) {+ break;+ }++ message.externalId = reader.string();+ continue;+ case 9:+ if (tag !== 74) {+ break;+ }++ message.baseDirectory = reader.string();+ continue;+ case 10:+ if (tag !== 82) {+ break;+ }++ message.branch = reader.string();+ continue;+ case 11:+ if (tag !== 90) {+ break;+ }++ message.webhookEndpointId = reader.string();+ continue;+ case 12:+ if (tag !== 98) {+ break;+ }++ message.fullPath = reader.string();+ continue;+ case 13:+ if (tag !== 106) {+ break;+ }++ message.webUrl = reader.string();+ continue;+ }+ if ((tag & 7) === 4 || tag === 0) {+ break;+ }+ reader.skipType(tag & 7);+ }+ return message;+ },++ fromJSON(object: any): VCSConnector {+ return {+ name: isSet(object.name) ? globalThis.String(object.name) : "",+ title: isSet(object.title) ? globalThis.String(object.title) : "",+ creator: isSet(object.creator) ? globalThis.String(object.creator) : "",+ updater: isSet(object.updater) ? globalThis.String(object.updater) : "",+ createTime: isSet(object.createTime) ? fromJsonTimestamp(object.createTime) : undefined,+ updateTime: isSet(object.updateTime) ? fromJsonTimestamp(object.updateTime) : undefined,+ vcsProvider: isSet(object.vcsProvider) ? globalThis.String(object.vcsProvider) : "",+ externalId: isSet(object.externalId) ? globalThis.String(object.externalId) : "",+ baseDirectory: isSet(object.baseDirectory) ? globalThis.String(object.baseDirectory) : "",+ branch: isSet(object.branch) ? globalThis.String(object.branch) : "",+ webhookEndpointId: isSet(object.webhookEndpointId) ? globalThis.String(object.webhookEndpointId) : "",+ fullPath: isSet(object.fullPath) ? globalThis.String(object.fullPath) : "",+ webUrl: isSet(object.webUrl) ? globalThis.String(object.webUrl) : "",+ };+ },++ toJSON(message: VCSConnector): unknown {+ const obj: any = {};+ if (message.name !== "") {+ obj.name = message.name;+ }+ if (message.title !== "") {+ obj.title = message.title;+ }+ if (message.creator !== "") {+ obj.creator = message.creator;+ }+ if (message.updater !== "") {+ obj.updater = message.updater;+ }+ if (message.createTime !== undefined) {+ obj.createTime = message.createTime.toISOString();+ }+ if (message.updateTime !== undefined) {+ obj.updateTime = message.updateTime.toISOString();+ }+ if (message.vcsProvider !== "") {+ obj.vcsProvider = message.vcsProvider;+ }+ if (message.externalId !== "") {+ obj.externalId = message.externalId;+ }+ if (message.baseDirectory !== "") {+ obj.baseDirectory = message.baseDirectory;+ }+ if (message.branch !== "") {+ obj.branch = message.branch;+ }+ if (message.webhookEndpointId !== "") {+ obj.webhookEndpointId = message.webhookEndpointId;+ }+ if (message.fullPath !== "") {+ obj.fullPath = message.fullPath;+ }+ if (message.webUrl !== "") {+ obj.webUrl = message.webUrl;+ }+ return obj;+ },++ create(base?: DeepPartial<VCSConnector>): VCSConnector {+ return VCSConnector.fromPartial(base ?? {});+ },+ fromPartial(object: DeepPartial<VCSConnector>): VCSConnector {+ const message = createBaseVCSConnector();+ message.name = object.name ?? "";+ message.title = object.title ?? "";+ message.creator = object.creator ?? "";+ message.updater = object.updater ?? "";+ message.createTime = object.createTime ?? undefined;+ message.updateTime = object.updateTime ?? undefined;+ message.vcsProvider = object.vcsProvider ?? "";+ message.externalId = object.externalId ?? "";+ message.baseDirectory = object.baseDirectory ?? "";+ message.branch = object.branch ?? "";+ message.webhookEndpointId = object.webhookEndpointId ?? "";+ message.fullPath = object.fullPath ?? "";+ message.webUrl = object.webUrl ?? "";+ return message;+ },+};++export type VCSConnectorServiceDefinition = typeof VCSConnectorServiceDefinition;+export const VCSConnectorServiceDefinition = {+ name: "VCSConnectorService",+ fullName: "bytebase.v1.VCSConnectorService",+ methods: {+ createVCSConnector: {+ name: "CreateVCSConnector",+ requestType: CreateVCSConnectorRequest,+ requestStream: false,+ responseType: VCSConnector,+ responseStream: false,+ options: {+ _unknownFields: {+ 8410: [+ new Uint8Array([+ 19,+ 112,+ 97,+ 114,+ 101,+ 110,+ 116,+ 44,+ 118,+ 99,+ 115,+ 67,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ ]),+ ],+ 578365826: [+ new Uint8Array([+ 54,+ 58,+ 13,+ 118,+ 99,+ 115,+ 95,+ 99,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 34,+ 37,+ 47,+ 118,+ 49,+ 47,+ 123,+ 112,+ 97,+ 114,+ 101,+ 110,+ 116,+ 61,+ 112,+ 114,+ 111,+ 106,+ 101,+ 99,+ 116,+ 115,+ 47,+ 42,+ 125,+ 47,+ 118,+ 99,+ 115,+ 67,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 115,+ ]),+ ],+ },+ },+ },+ getVCSConnector: {+ name: "GetVCSConnector",+ requestType: GetVCSConnectorRequest,+ requestStream: false,+ responseType: VCSConnector,+ responseStream: false,+ options: {+ _unknownFields: {+ 8410: [new Uint8Array([4, 110, 97, 109, 101])],+ 578365826: [+ new Uint8Array([+ 39,+ 18,+ 37,+ 47,+ 118,+ 49,+ 47,+ 123,+ 110,+ 97,+ 109,+ 101,+ 61,+ 112,+ 114,+ 111,+ 106,+ 101,+ 99,+ 116,+ 115,+ 47,+ 42,+ 47,+ 118,+ 99,+ 115,+ 67,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 115,+ 47,+ 42,+ 125,+ ]),+ ],+ },+ },+ },+ listVCSConnectors: {+ name: "ListVCSConnectors",+ requestType: ListVCSConnectorsRequest,+ requestStream: false,+ responseType: ListVCSConnectorsResponse,+ responseStream: false,+ options: {+ _unknownFields: {+ 8410: [new Uint8Array([6, 112, 97, 114, 101, 110, 116])],+ 578365826: [+ new Uint8Array([+ 39,+ 18,+ 37,+ 47,+ 118,+ 49,+ 47,+ 123,+ 112,+ 97,+ 114,+ 101,+ 110,+ 116,+ 61,+ 112,+ 114,+ 111,+ 106,+ 101,+ 99,+ 116,+ 115,+ 47,+ 42,+ 125,+ 47,+ 118,+ 99,+ 115,+ 67,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 115,+ ]),+ ],+ },+ },+ },+ updateVCSConnector: {+ name: "UpdateVCSConnector",+ requestType: UpdateVCSConnectorRequest,+ requestStream: false,+ responseType: VCSConnector,+ responseStream: false,+ options: {+ _unknownFields: {+ 8410: [+ new Uint8Array([+ 25,+ 118,+ 99,+ 115,+ 95,+ 99,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 44,+ 117,+ 112,+ 100,+ 97,+ 116,+ 101,+ 95,+ 109,+ 97,+ 115,+ 107,+ ]),+ ],+ 578365826: [+ new Uint8Array([+ 68,+ 58,+ 13,+ 118,+ 99,+ 115,+ 95,+ 99,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 50,+ 51,+ 47,+ 118,+ 49,+ 47,+ 123,+ 118,+ 99,+ 115,+ 95,+ 99,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 46,+ 110,+ 97,+ 109,+ 101,+ 61,+ 112,+ 114,+ 111,+ 106,+ 101,+ 99,+ 116,+ 115,+ 47,+ 42,+ 47,+ 118,+ 99,+ 115,+ 67,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 115,+ 47,+ 42,+ 125,+ ]),+ ],+ },+ },+ },+ deleteVCSConnector: {+ name: "DeleteVCSConnector",+ requestType: DeleteVCSConnectorRequest,+ requestStream: false,+ responseType: Empty,+ responseStream: false,+ options: {+ _unknownFields: {+ 8410: [new Uint8Array([4, 110, 97, 109, 101])],+ 578365826: [+ new Uint8Array([+ 39,+ 42,+ 37,+ 47,+ 118,+ 49,+ 47,+ 123,+ 110,+ 97,+ 109,+ 101,+ 61,+ 112,+ 114,+ 111,+ 106,+ 101,+ 99,+ 116,+ 115,+ 47,+ 42,+ 47,+ 118,+ 99,+ 115,+ 67,+ 111,+ 110,+ 110,+ 101,+ 99,+ 116,+ 111,+ 114,+ 115,+ 47,+ 42,+ 125,+ ]),+ ],+ },+ },+ },+ },+} as const;++type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;++export type DeepPartial<T> = T extends Builtin ? T+ : T extends Long ? string | number | Long : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>>+ : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>+ : T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }+ : Partial<T>;++function toTimestamp(date: Date): Timestamp {+ const seconds = numberToLong(date.getTime() / 1_000);+ const nanos = (date.getTime() % 1_000) * 1_000_000;+ return { seconds, nanos };+}++function fromTimestamp(t: Timestamp): Date {+ let millis = (t.seconds.toNumber() || 0) * 1_000;+ millis += (t.nanos || 0) / 1_000_000;+ return new globalThis.Date(millis);+}++function fromJsonTimestamp(o: any): Date {+ if (o instanceof globalThis.Date) {+ return o;+ } else if (typeof o === "string") {+ return new globalThis.Date(o);+ } else {+ return fromTimestamp(Timestamp.fromJSON(o));+ }+}++function numberToLong(number: number) {+ return Long.fromNumber(number);+}++if (_m0.util.Long !== Long) {+ _m0.util.Long = Long as any;+ _m0.configure();+}++function isSet(value: any): boolean {+ return value !== null && value !== undefined;+}diff --git a/proto/gen/grpc-doc/v1/README.md b/proto/gen/grpc-doc/v1/README.mdindex 2dbba39962..93e53e9c10 100644--- a/proto/gen/grpc-doc/v1/README.md+++ b/proto/gen/grpc-doc/v1/README.md@@ -602,6 +602,17 @@- [SQLService](#bytebase-v1-SQLService)+- [v1/vcs_connector_service.proto](#v1_vcs_connector_service-proto)+ - [CreateVCSConnectorRequest](#bytebase-v1-CreateVCSConnectorRequest)+ - [DeleteVCSConnectorRequest](#bytebase-v1-DeleteVCSConnectorRequest)+ - [GetVCSConnectorRequest](#bytebase-v1-GetVCSConnectorRequest)+ - [ListVCSConnectorsRequest](#bytebase-v1-ListVCSConnectorsRequest)+ - [ListVCSConnectorsResponse](#bytebase-v1-ListVCSConnectorsResponse)+ - [UpdateVCSConnectorRequest](#bytebase-v1-UpdateVCSConnectorRequest)+ - [VCSConnector](#bytebase-v1-VCSConnector)++ - [VCSConnectorService](#bytebase-v1-VCSConnectorService)+- [v1/worksheet_service.proto](#v1_worksheet_service-proto)- [CreateWorksheetRequest](#bytebase-v1-CreateWorksheetRequest)- [DeleteWorksheetRequest](#bytebase-v1-DeleteWorksheetRequest)@@ -9676,6 +9687,165 @@ Type of the SheetPayload.+<a name="v1_vcs_connector_service-proto"></a>+<p align="right"><a href="#top">Top</a></p>++## v1/vcs_connector_service.proto++++<a name="bytebase-v1-CreateVCSConnectorRequest"></a>++### CreateVCSConnectorRequest++++| Field | Type | Label | Description |+| ----- | ---- | ----- | ----------- |+| parent | [string](#string) | | The parent resource where this vcsConnector will be created. Format: projects/{project} |+| vcs_connector | [VCSConnector](#bytebase-v1-VCSConnector) | | The vcsConnector to create. |+| vcs_connector_id | [string](#string) | | The ID to use for the vcsConnector, which will become the final component of the vcsConnector's resource name.++This value should be 4-63 characters, and valid characters are /[a-z][0-9]-/. |+++++++<a name="bytebase-v1-DeleteVCSConnectorRequest"></a>++### DeleteVCSConnectorRequest++++| Field | Type | Label | Description |+| ----- | ---- | ----- | ----------- |+| name | [string](#string) | | The name of the vcsConnector to delete. Format: projects/{project}/vcsConnectors/{vcsConnector} |+++++++<a name="bytebase-v1-GetVCSConnectorRequest"></a>++### GetVCSConnectorRequest++++| Field | Type | Label | Description |+| ----- | ---- | ----- | ----------- |+| name | [string](#string) | | The name of the vcsConnector to retrieve. Format: projects/{project}/vcsConnectors/{vcsConnector} |+++++++<a name="bytebase-v1-ListVCSConnectorsRequest"></a>++### ListVCSConnectorsRequest++++| Field | Type | Label | Description |+| ----- | ---- | ----- | ----------- |+| parent | [string](#string) | | The parent, which owns this collection of vcsConnectors. Format: projects/{project} Use "projects/-" to list all vcsConnectors. |+| page_size | [int32](#int32) | | The maximum number of databases to return. The service may return fewer than this value. If unspecified, at most 50 databases will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000. |+| page_token | [string](#string) | | A page token, received from a previous `ListDatabases` call. Provide this to retrieve the subsequent page.++When paginating, all other parameters provided to `ListDatabases` must match the call that provided the page token. |+++++++<a name="bytebase-v1-ListVCSConnectorsResponse"></a>++### ListVCSConnectorsResponse++++| Field | Type | Label | Description |+| ----- | ---- | ----- | ----------- |+| vcs_connectors | [VCSConnector](#bytebase-v1-VCSConnector) | repeated | The vcsConnectors from the specified request. |+| next_page_token | [string](#string) | | A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages. |+++++++<a name="bytebase-v1-UpdateVCSConnectorRequest"></a>++### UpdateVCSConnectorRequest++++| Field | Type | Label | Description |+| ----- | ---- | ----- | ----------- |+| vcs_connector | [VCSConnector](#bytebase-v1-VCSConnector) | | The vcsConnector to update.++The vcsConnector's `name` field is used to identify the vcsConnector to update. Format: projects/{project}/vcsConnectors/{vcsConnector} |+| update_mask | [google.protobuf.FieldMask](#google-protobuf-FieldMask) | | The list of fields to be updated. |+++++++<a name="bytebase-v1-VCSConnector"></a>++### VCSConnector++++| Field | Type | Label | Description |+| ----- | ---- | ----- | ----------- |+| name | [string](#string) | | The name of the vcsConnector resource. Canonical parent is project. Format: projects/{project}/vcsConnectors/{vcsConnector} |+| title | [string](#string) | | The title of the vcs connector. |+| creator | [string](#string) | | The creator of the vcsConnector. Format: users/{email} |+| updater | [string](#string) | | The updater of the vcsConnector. Format: users/{email} |+| create_time | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | The create time of the vcsConnector. |+| update_time | [google.protobuf.Timestamp](#google-protobuf-Timestamp) | | The last update time of the vcsConnector. |+| vcs_provider | [string](#string) | | The name of the VCS. Format: vcsProviders/{vcsProvider} |+| external_id | [string](#string) | | The reposition external id in target VCS. |+| base_directory | [string](#string) | | The root directory where Bytebase observes the file change. If empty, then it observes the entire repository. |+| branch | [string](#string) | | The branch Bytebase listens to for changes. For example: main. |+| webhook_endpoint_id | [string](#string) | | The webhook endpoint ID of the repository. |+| full_path | [string](#string) | | TODO(d): move these to create VCS connector API. The full_path of the repository. For example: bytebase/sample. |+| web_url | [string](#string) | | The web url of the repository. For axample: https://gitlab.bytebase.com/bytebase/sample. |+++++++++++++<a name="bytebase-v1-VCSConnectorService"></a>++### VCSConnectorService+++| Method Name | Request Type | Response Type | Description |+| ----------- | ------------ | ------------- | ------------|+| CreateVCSConnector | [CreateVCSConnectorRequest](#bytebase-v1-CreateVCSConnectorRequest) | [VCSConnector](#bytebase-v1-VCSConnector) | |+| GetVCSConnector | [GetVCSConnectorRequest](#bytebase-v1-GetVCSConnectorRequest) | [VCSConnector](#bytebase-v1-VCSConnector) | |+| ListVCSConnectors | [ListVCSConnectorsRequest](#bytebase-v1-ListVCSConnectorsRequest) | [ListVCSConnectorsResponse](#bytebase-v1-ListVCSConnectorsResponse) | |+| UpdateVCSConnector | [UpdateVCSConnectorRequest](#bytebase-v1-UpdateVCSConnectorRequest) | [VCSConnector](#bytebase-v1-VCSConnector) | |+| DeleteVCSConnector | [DeleteVCSConnectorRequest](#bytebase-v1-DeleteVCSConnectorRequest) | [.google.protobuf.Empty](#google-protobuf-Empty) | |+++++<a name="v1_worksheet_service-proto"></a><p align="right"><a href="#top">Top</a></p>diff --git a/proto/gen/grpc-doc/v1/index.html b/proto/gen/grpc-doc/v1/index.htmlindex 7f34b2e8b3..3952c4944b 100644--- a/proto/gen/grpc-doc/v1/index.html+++ b/proto/gen/grpc-doc/v1/index.html@@ -2480,6 +2480,49 @@</li>+ <li>+ <a href="#v1%2fvcs_connector_service.proto">v1/vcs_connector_service.proto</a>+ <ul>++ <li>+ <a href="#bytebase.v1.CreateVCSConnectorRequest"><span class="badge">M</span>CreateVCSConnectorRequest</a>+ </li>++ <li>+ <a href="#bytebase.v1.DeleteVCSConnectorRequest"><span class="badge">M</span>DeleteVCSConnectorRequest</a>+ </li>++ <li>+ <a href="#bytebase.v1.GetVCSConnectorRequest"><span class="badge">M</span>GetVCSConnectorRequest</a>+ </li>++ <li>+ <a href="#bytebase.v1.ListVCSConnectorsRequest"><span class="badge">M</span>ListVCSConnectorsRequest</a>+ </li>++ <li>+ <a href="#bytebase.v1.ListVCSConnectorsResponse"><span class="badge">M</span>ListVCSConnectorsResponse</a>+ </li>++ <li>+ <a href="#bytebase.v1.UpdateVCSConnectorRequest"><span class="badge">M</span>UpdateVCSConnectorRequest</a>+ </li>++ <li>+ <a href="#bytebase.v1.VCSConnector"><span class="badge">M</span>VCSConnector</a>+ </li>+++++ <li>+ <a href="#bytebase.v1.VCSConnectorService"><span class="badge">S</span>VCSConnectorService</a>+ </li>++ </ul>+ </li>++<li><a href="#v1%2fworksheet_service.proto">v1/worksheet_service.proto</a><ul>@@ -26701,6 +26744,455 @@ The types come from the Golang SQL driver. </p></td>+ <div class="file-heading">+ <h2 id="v1/vcs_connector_service.proto">v1/vcs_connector_service.proto</h2><a href="#title">Top</a>+ </div>+ <p></p>+++ <h3 id="bytebase.v1.CreateVCSConnectorRequest">CreateVCSConnectorRequest</h3>+ <p></p>+++ <table class="field-table">+ <thead>+ <tr><td>Field</td><td>Type</td><td>Label</td><td>Description</td></tr>+ </thead>+ <tbody>++ <tr>+ <td>parent</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The parent resource where this vcsConnector will be created.+Format: projects/{project} </p></td>+ </tr>++ <tr>+ <td>vcs_connector</td>+ <td><a href="#bytebase.v1.VCSConnector">VCSConnector</a></td>+ <td></td>+ <td><p>The vcsConnector to create. </p></td>+ </tr>++ <tr>+ <td>vcs_connector_id</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The ID to use for the vcsConnector, which will become the final component of+the vcsConnector's resource name.++This value should be 4-63 characters, and valid characters+are /[a-z][0-9]-/. </p></td>+ </tr>++ </tbody>+ </table>++++++ <h3 id="bytebase.v1.DeleteVCSConnectorRequest">DeleteVCSConnectorRequest</h3>+ <p></p>+++ <table class="field-table">+ <thead>+ <tr><td>Field</td><td>Type</td><td>Label</td><td>Description</td></tr>+ </thead>+ <tbody>++ <tr>+ <td>name</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The name of the vcsConnector to delete.+Format: projects/{project}/vcsConnectors/{vcsConnector} </p></td>+ </tr>++ </tbody>+ </table>++++++ <h3 id="bytebase.v1.GetVCSConnectorRequest">GetVCSConnectorRequest</h3>+ <p></p>+++ <table class="field-table">+ <thead>+ <tr><td>Field</td><td>Type</td><td>Label</td><td>Description</td></tr>+ </thead>+ <tbody>++ <tr>+ <td>name</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The name of the vcsConnector to retrieve.+Format: projects/{project}/vcsConnectors/{vcsConnector} </p></td>+ </tr>++ </tbody>+ </table>++++++ <h3 id="bytebase.v1.ListVCSConnectorsRequest">ListVCSConnectorsRequest</h3>+ <p></p>+++ <table class="field-table">+ <thead>+ <tr><td>Field</td><td>Type</td><td>Label</td><td>Description</td></tr>+ </thead>+ <tbody>++ <tr>+ <td>parent</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The parent, which owns this collection of vcsConnectors.+Format: projects/{project}+Use "projects/-" to list all vcsConnectors. </p></td>+ </tr>++ <tr>+ <td>page_size</td>+ <td><a href="#int32">int32</a></td>+ <td></td>+ <td><p>The maximum number of databases to return. The service may return fewer than+this value.+If unspecified, at most 50 databases will be returned.+The maximum value is 1000; values above 1000 will be coerced to 1000. </p></td>+ </tr>++ <tr>+ <td>page_token</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>A page token, received from a previous `ListDatabases` call.+Provide this to retrieve the subsequent page.++When paginating, all other parameters provided to `ListDatabases` must match+the call that provided the page token. </p></td>+ </tr>++ </tbody>+ </table>++++++ <h3 id="bytebase.v1.ListVCSConnectorsResponse">ListVCSConnectorsResponse</h3>+ <p></p>+++ <table class="field-table">+ <thead>+ <tr><td>Field</td><td>Type</td><td>Label</td><td>Description</td></tr>+ </thead>+ <tbody>++ <tr>+ <td>vcs_connectors</td>+ <td><a href="#bytebase.v1.VCSConnector">VCSConnector</a></td>+ <td>repeated</td>+ <td><p>The vcsConnectors from the specified request. </p></td>+ </tr>++ <tr>+ <td>next_page_token</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>A token, which can be sent as `page_token` to retrieve the next page.+If this field is omitted, there are no subsequent pages. </p></td>+ </tr>++ </tbody>+ </table>++++++ <h3 id="bytebase.v1.UpdateVCSConnectorRequest">UpdateVCSConnectorRequest</h3>+ <p></p>+++ <table class="field-table">+ <thead>+ <tr><td>Field</td><td>Type</td><td>Label</td><td>Description</td></tr>+ </thead>+ <tbody>++ <tr>+ <td>vcs_connector</td>+ <td><a href="#bytebase.v1.VCSConnector">VCSConnector</a></td>+ <td></td>+ <td><p>The vcsConnector to update.++The vcsConnector's `name` field is used to identify the vcsConnector to update.+Format: projects/{project}/vcsConnectors/{vcsConnector} </p></td>+ </tr>++ <tr>+ <td>update_mask</td>+ <td><a href="#google.protobuf.FieldMask">google.protobuf.FieldMask</a></td>+ <td></td>+ <td><p>The list of fields to be updated. </p></td>+ </tr>++ </tbody>+ </table>++++++ <h3 id="bytebase.v1.VCSConnector">VCSConnector</h3>+ <p></p>+++ <table class="field-table">+ <thead>+ <tr><td>Field</td><td>Type</td><td>Label</td><td>Description</td></tr>+ </thead>+ <tbody>++ <tr>+ <td>name</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The name of the vcsConnector resource.+Canonical parent is project.+Format: projects/{project}/vcsConnectors/{vcsConnector} </p></td>+ </tr>++ <tr>+ <td>title</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The title of the vcs connector. </p></td>+ </tr>++ <tr>+ <td>creator</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The creator of the vcsConnector.+Format: users/{email} </p></td>+ </tr>++ <tr>+ <td>updater</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The updater of the vcsConnector.+Format: users/{email} </p></td>+ </tr>++ <tr>+ <td>create_time</td>+ <td><a href="#google.protobuf.Timestamp">google.protobuf.Timestamp</a></td>+ <td></td>+ <td><p>The create time of the vcsConnector. </p></td>+ </tr>++ <tr>+ <td>update_time</td>+ <td><a href="#google.protobuf.Timestamp">google.protobuf.Timestamp</a></td>+ <td></td>+ <td><p>The last update time of the vcsConnector. </p></td>+ </tr>++ <tr>+ <td>vcs_provider</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The name of the VCS.+Format: vcsProviders/{vcsProvider} </p></td>+ </tr>++ <tr>+ <td>external_id</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The reposition external id in target VCS. </p></td>+ </tr>++ <tr>+ <td>base_directory</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The root directory where Bytebase observes the file change. If empty, then it observes the entire repository. </p></td>+ </tr>++ <tr>+ <td>branch</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The branch Bytebase listens to for changes. For example: main. </p></td>+ </tr>++ <tr>+ <td>webhook_endpoint_id</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The webhook endpoint ID of the repository. </p></td>+ </tr>++ <tr>+ <td>full_path</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>TODO(d): move these to create VCS connector API.+The full_path of the repository. For example: bytebase/sample. </p></td>+ </tr>++ <tr>+ <td>web_url</td>+ <td><a href="#string">string</a></td>+ <td></td>+ <td><p>The web url of the repository. For axample: https://gitlab.bytebase.com/bytebase/sample. </p></td>+ </tr>++ </tbody>+ </table>++++++++++++ <h3 id="bytebase.v1.VCSConnectorService">VCSConnectorService</h3>+ <p></p>+ <table class="enum-table">+ <thead>+ <tr><td>Method Name</td><td>Request Type</td><td>Response Type</td><td>Description</td></tr>+ </thead>+ <tbody>++ <tr>+ <td>CreateVCSConnector</td>+ <td><a href="#bytebase.v1.CreateVCSConnectorRequest">CreateVCSConnectorRequest</a></td>+ <td><a href="#bytebase.v1.VCSConnector">VCSConnector</a></td>+ <td><p></p></td>+ </tr>++ <tr>+ <td>GetVCSConnector</td>+ <td><a href="#bytebase.v1.GetVCSConnectorRequest">GetVCSConnectorRequest</a></td>+ <td><a href="#bytebase.v1.VCSConnector">VCSConnector</a></td>+ <td><p></p></td>+ </tr>++ <tr>+ <td>ListVCSConnectors</td>+ <td><a href="#bytebase.v1.ListVCSConnectorsRequest">ListVCSConnectorsRequest</a></td>+ <td><a href="#bytebase.v1.ListVCSConnectorsResponse">ListVCSConnectorsResponse</a></td>+ <td><p></p></td>+ </tr>++ <tr>+ <td>UpdateVCSConnector</td>+ <td><a href="#bytebase.v1.UpdateVCSConnectorRequest">UpdateVCSConnectorRequest</a></td>+ <td><a href="#bytebase.v1.VCSConnector">VCSConnector</a></td>+ <td><p></p></td>+ </tr>++ <tr>+ <td>DeleteVCSConnector</td>+ <td><a href="#bytebase.v1.DeleteVCSConnectorRequest">DeleteVCSConnectorRequest</a></td>+ <td><a href="#google.protobuf.Empty">.google.protobuf.Empty</a></td>+ <td><p></p></td>+ </tr>++ </tbody>+ </table>+++++ <h4>Methods with HTTP bindings</h4>+ <table>+ <thead>+ <tr>+ <td>Method Name</td>+ <td>Method</td>+ <td>Pattern</td>+ <td>Body</td>+ </tr>+ </thead>+ <tbody>++++ <tr>+ <td>CreateVCSConnector</td>+ <td>POST</td>+ <td>/v1/{parent=projects/*}/vcsConnectors</td>+ <td>vcs_connector</td>+ </tr>+++++ <tr>+ <td>GetVCSConnector</td>+ <td>GET</td>+ <td>/v1/{name=projects/*/vcsConnectors/*}</td>+ <td></td>+ </tr>+++++ <tr>+ <td>ListVCSConnectors</td>+ <td>GET</td>+ <td>/v1/{parent=projects/*}/vcsConnectors</td>+ <td></td>+ </tr>+++++ <tr>+ <td>UpdateVCSConnector</td>+ <td>PATCH</td>+ <td>/v1/{vcs_connector.name=projects/*/vcsConnectors/*}</td>+ <td>vcs_connector</td>+ </tr>+++++ <tr>+ <td>DeleteVCSConnector</td>+ <td>DELETE</td>+ <td>/v1/{name=projects/*/vcsConnectors/*}</td>+ <td></td>+ </tr>+++ </tbody>+ </table>++++<div class="file-heading"><h2 id="v1/worksheet_service.proto">v1/worksheet_service.proto</h2><a href="#title">Top</a></div>diff --git a/proto/generated-go/v1/vcs_connector_service.pb.go b/proto/generated-go/v1/vcs_connector_service.pb.gonew file mode 100644index 0000000000..c150d1db3c--- /dev/null+++ b/proto/generated-go/v1/vcs_connector_service.pb.go@@ -0,0 +1,857 @@+// Code generated by protoc-gen-go. DO NOT EDIT.+// versions:+// protoc-gen-go v1.33.0+// protoc (unknown)+// source: v1/vcs_connector_service.proto++package v1++import (+ _ "google.golang.org/genproto/googleapis/api/annotations"+ protoreflect "google.golang.org/protobuf/reflect/protoreflect"+ protoimpl "google.golang.org/protobuf/runtime/protoimpl"+ emptypb "google.golang.org/protobuf/types/known/emptypb"+ fieldmaskpb "google.golang.org/protobuf/types/known/fieldmaskpb"+ timestamppb "google.golang.org/protobuf/types/known/timestamppb"+ reflect "reflect"+ sync "sync"+)++const (+ // Verify that this generated code is sufficiently up-to-date.+ _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)+ // Verify that runtime/protoimpl is sufficiently up-to-date.+ _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)+)++type CreateVCSConnectorRequest struct {+ state protoimpl.MessageState+ sizeCache protoimpl.SizeCache+ unknownFields protoimpl.UnknownFields++ // The parent resource where this vcsConnector will be created.+ // Format: projects/{project}+ Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`+ // The vcsConnector to create.+ VcsConnector *VCSConnector `protobuf:"bytes,2,opt,name=vcs_connector,json=vcsConnector,proto3" json:"vcs_connector,omitempty"`+ // The ID to use for the vcsConnector, which will become the final component of+ // the vcsConnector's resource name.+ //+ // This value should be 4-63 characters, and valid characters+ // are /[a-z][0-9]-/.+ VcsConnectorId string `protobuf:"bytes,3,opt,name=vcs_connector_id,json=vcsConnectorId,proto3" json:"vcs_connector_id,omitempty"`+}++func (x *CreateVCSConnectorRequest) Reset() {+ *x = CreateVCSConnectorRequest{}+ if protoimpl.UnsafeEnabled {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[0]+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ ms.StoreMessageInfo(mi)+ }+}++func (x *CreateVCSConnectorRequest) String() string {+ return protoimpl.X.MessageStringOf(x)+}++func (*CreateVCSConnectorRequest) ProtoMessage() {}++func (x *CreateVCSConnectorRequest) ProtoReflect() protoreflect.Message {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[0]+ if protoimpl.UnsafeEnabled && x != nil {+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ if ms.LoadMessageInfo() == nil {+ ms.StoreMessageInfo(mi)+ }+ return ms+ }+ return mi.MessageOf(x)+}++// Deprecated: Use CreateVCSConnectorRequest.ProtoReflect.Descriptor instead.+func (*CreateVCSConnectorRequest) Descriptor() ([]byte, []int) {+ return file_v1_vcs_connector_service_proto_rawDescGZIP(), []int{0}+}++func (x *CreateVCSConnectorRequest) GetParent() string {+ if x != nil {+ return x.Parent+ }+ return ""+}++func (x *CreateVCSConnectorRequest) GetVcsConnector() *VCSConnector {+ if x != nil {+ return x.VcsConnector+ }+ return nil+}++func (x *CreateVCSConnectorRequest) GetVcsConnectorId() string {+ if x != nil {+ return x.VcsConnectorId+ }+ return ""+}++type GetVCSConnectorRequest struct {+ state protoimpl.MessageState+ sizeCache protoimpl.SizeCache+ unknownFields protoimpl.UnknownFields++ // The name of the vcsConnector to retrieve.+ // Format: projects/{project}/vcsConnectors/{vcsConnector}+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`+}++func (x *GetVCSConnectorRequest) Reset() {+ *x = GetVCSConnectorRequest{}+ if protoimpl.UnsafeEnabled {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[1]+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ ms.StoreMessageInfo(mi)+ }+}++func (x *GetVCSConnectorRequest) String() string {+ return protoimpl.X.MessageStringOf(x)+}++func (*GetVCSConnectorRequest) ProtoMessage() {}++func (x *GetVCSConnectorRequest) ProtoReflect() protoreflect.Message {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[1]+ if protoimpl.UnsafeEnabled && x != nil {+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ if ms.LoadMessageInfo() == nil {+ ms.StoreMessageInfo(mi)+ }+ return ms+ }+ return mi.MessageOf(x)+}++// Deprecated: Use GetVCSConnectorRequest.ProtoReflect.Descriptor instead.+func (*GetVCSConnectorRequest) Descriptor() ([]byte, []int) {+ return file_v1_vcs_connector_service_proto_rawDescGZIP(), []int{1}+}++func (x *GetVCSConnectorRequest) GetName() string {+ if x != nil {+ return x.Name+ }+ return ""+}++type ListVCSConnectorsRequest struct {+ state protoimpl.MessageState+ sizeCache protoimpl.SizeCache+ unknownFields protoimpl.UnknownFields++ // The parent, which owns this collection of vcsConnectors.+ // Format: projects/{project}+ // Use "projects/-" to list all vcsConnectors.+ Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`+ // The maximum number of databases to return. The service may return fewer than+ // this value.+ // If unspecified, at most 50 databases will be returned.+ // The maximum value is 1000; values above 1000 will be coerced to 1000.+ PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`+ // A page token, received from a previous `ListDatabases` call.+ // Provide this to retrieve the subsequent page.+ //+ // When paginating, all other parameters provided to `ListDatabases` must match+ // the call that provided the page token.+ PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`+}++func (x *ListVCSConnectorsRequest) Reset() {+ *x = ListVCSConnectorsRequest{}+ if protoimpl.UnsafeEnabled {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[2]+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ ms.StoreMessageInfo(mi)+ }+}++func (x *ListVCSConnectorsRequest) String() string {+ return protoimpl.X.MessageStringOf(x)+}++func (*ListVCSConnectorsRequest) ProtoMessage() {}++func (x *ListVCSConnectorsRequest) ProtoReflect() protoreflect.Message {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[2]+ if protoimpl.UnsafeEnabled && x != nil {+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ if ms.LoadMessageInfo() == nil {+ ms.StoreMessageInfo(mi)+ }+ return ms+ }+ return mi.MessageOf(x)+}++// Deprecated: Use ListVCSConnectorsRequest.ProtoReflect.Descriptor instead.+func (*ListVCSConnectorsRequest) Descriptor() ([]byte, []int) {+ return file_v1_vcs_connector_service_proto_rawDescGZIP(), []int{2}+}++func (x *ListVCSConnectorsRequest) GetParent() string {+ if x != nil {+ return x.Parent+ }+ return ""+}++func (x *ListVCSConnectorsRequest) GetPageSize() int32 {+ if x != nil {+ return x.PageSize+ }+ return 0+}++func (x *ListVCSConnectorsRequest) GetPageToken() string {+ if x != nil {+ return x.PageToken+ }+ return ""+}++type ListVCSConnectorsResponse struct {+ state protoimpl.MessageState+ sizeCache protoimpl.SizeCache+ unknownFields protoimpl.UnknownFields++ // The vcsConnectors from the specified request.+ VcsConnectors []*VCSConnector `protobuf:"bytes,1,rep,name=vcs_connectors,json=vcsConnectors,proto3" json:"vcs_connectors,omitempty"`+ // A token, which can be sent as `page_token` to retrieve the next page.+ // If this field is omitted, there are no subsequent pages.+ NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`+}++func (x *ListVCSConnectorsResponse) Reset() {+ *x = ListVCSConnectorsResponse{}+ if protoimpl.UnsafeEnabled {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[3]+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ ms.StoreMessageInfo(mi)+ }+}++func (x *ListVCSConnectorsResponse) String() string {+ return protoimpl.X.MessageStringOf(x)+}++func (*ListVCSConnectorsResponse) ProtoMessage() {}++func (x *ListVCSConnectorsResponse) ProtoReflect() protoreflect.Message {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[3]+ if protoimpl.UnsafeEnabled && x != nil {+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ if ms.LoadMessageInfo() == nil {+ ms.StoreMessageInfo(mi)+ }+ return ms+ }+ return mi.MessageOf(x)+}++// Deprecated: Use ListVCSConnectorsResponse.ProtoReflect.Descriptor instead.+func (*ListVCSConnectorsResponse) Descriptor() ([]byte, []int) {+ return file_v1_vcs_connector_service_proto_rawDescGZIP(), []int{3}+}++func (x *ListVCSConnectorsResponse) GetVcsConnectors() []*VCSConnector {+ if x != nil {+ return x.VcsConnectors+ }+ return nil+}++func (x *ListVCSConnectorsResponse) GetNextPageToken() string {+ if x != nil {+ return x.NextPageToken+ }+ return ""+}++type UpdateVCSConnectorRequest struct {+ state protoimpl.MessageState+ sizeCache protoimpl.SizeCache+ unknownFields protoimpl.UnknownFields++ // The vcsConnector to update.+ //+ // The vcsConnector's `name` field is used to identify the vcsConnector to update.+ // Format: projects/{project}/vcsConnectors/{vcsConnector}+ VcsConnector *VCSConnector `protobuf:"bytes,1,opt,name=vcs_connector,json=vcsConnector,proto3" json:"vcs_connector,omitempty"`+ // The list of fields to be updated.+ UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,2,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`+}++func (x *UpdateVCSConnectorRequest) Reset() {+ *x = UpdateVCSConnectorRequest{}+ if protoimpl.UnsafeEnabled {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[4]+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ ms.StoreMessageInfo(mi)+ }+}++func (x *UpdateVCSConnectorRequest) String() string {+ return protoimpl.X.MessageStringOf(x)+}++func (*UpdateVCSConnectorRequest) ProtoMessage() {}++func (x *UpdateVCSConnectorRequest) ProtoReflect() protoreflect.Message {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[4]+ if protoimpl.UnsafeEnabled && x != nil {+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ if ms.LoadMessageInfo() == nil {+ ms.StoreMessageInfo(mi)+ }+ return ms+ }+ return mi.MessageOf(x)+}++// Deprecated: Use UpdateVCSConnectorRequest.ProtoReflect.Descriptor instead.+func (*UpdateVCSConnectorRequest) Descriptor() ([]byte, []int) {+ return file_v1_vcs_connector_service_proto_rawDescGZIP(), []int{4}+}++func (x *UpdateVCSConnectorRequest) GetVcsConnector() *VCSConnector {+ if x != nil {+ return x.VcsConnector+ }+ return nil+}++func (x *UpdateVCSConnectorRequest) GetUpdateMask() *fieldmaskpb.FieldMask {+ if x != nil {+ return x.UpdateMask+ }+ return nil+}++type DeleteVCSConnectorRequest struct {+ state protoimpl.MessageState+ sizeCache protoimpl.SizeCache+ unknownFields protoimpl.UnknownFields++ // The name of the vcsConnector to delete.+ // Format: projects/{project}/vcsConnectors/{vcsConnector}+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`+}++func (x *DeleteVCSConnectorRequest) Reset() {+ *x = DeleteVCSConnectorRequest{}+ if protoimpl.UnsafeEnabled {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[5]+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ ms.StoreMessageInfo(mi)+ }+}++func (x *DeleteVCSConnectorRequest) String() string {+ return protoimpl.X.MessageStringOf(x)+}++func (*DeleteVCSConnectorRequest) ProtoMessage() {}++func (x *DeleteVCSConnectorRequest) ProtoReflect() protoreflect.Message {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[5]+ if protoimpl.UnsafeEnabled && x != nil {+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ if ms.LoadMessageInfo() == nil {+ ms.StoreMessageInfo(mi)+ }+ return ms+ }+ return mi.MessageOf(x)+}++// Deprecated: Use DeleteVCSConnectorRequest.ProtoReflect.Descriptor instead.+func (*DeleteVCSConnectorRequest) Descriptor() ([]byte, []int) {+ return file_v1_vcs_connector_service_proto_rawDescGZIP(), []int{5}+}++func (x *DeleteVCSConnectorRequest) GetName() string {+ if x != nil {+ return x.Name+ }+ return ""+}++type VCSConnector struct {+ state protoimpl.MessageState+ sizeCache protoimpl.SizeCache+ unknownFields protoimpl.UnknownFields++ // The name of the vcsConnector resource.+ // Canonical parent is project.+ // Format: projects/{project}/vcsConnectors/{vcsConnector}+ Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`+ // The title of the vcs connector.+ Title string `protobuf:"bytes,2,opt,name=title,proto3" json:"title,omitempty"`+ // The creator of the vcsConnector.+ // Format: users/{email}+ Creator string `protobuf:"bytes,3,opt,name=creator,proto3" json:"creator,omitempty"`+ // The updater of the vcsConnector.+ // Format: users/{email}+ Updater string `protobuf:"bytes,4,opt,name=updater,proto3" json:"updater,omitempty"`+ // The create time of the vcsConnector.+ CreateTime *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`+ // The last update time of the vcsConnector.+ UpdateTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"`+ // The name of the VCS.+ // Format: vcsProviders/{vcsProvider}+ VcsProvider string `protobuf:"bytes,7,opt,name=vcs_provider,json=vcsProvider,proto3" json:"vcs_provider,omitempty"`+ // The reposition external id in target VCS.+ ExternalId string `protobuf:"bytes,8,opt,name=external_id,json=externalId,proto3" json:"external_id,omitempty"`+ // The root directory where Bytebase observes the file change. If empty, then it observes the entire repository.+ BaseDirectory string `protobuf:"bytes,9,opt,name=base_directory,json=baseDirectory,proto3" json:"base_directory,omitempty"`+ // The branch Bytebase listens to for changes. For example: main.+ Branch string `protobuf:"bytes,10,opt,name=branch,proto3" json:"branch,omitempty"`+ // The webhook endpoint ID of the repository.+ WebhookEndpointId string `protobuf:"bytes,11,opt,name=webhook_endpoint_id,json=webhookEndpointId,proto3" json:"webhook_endpoint_id,omitempty"`+ // TODO(d): move these to create VCS connector API.+ // The full_path of the repository. For example: bytebase/sample.+ FullPath string `protobuf:"bytes,12,opt,name=full_path,json=fullPath,proto3" json:"full_path,omitempty"`+ // The web url of the repository. For axample: https://gitlab.bytebase.com/bytebase/sample.+ WebUrl string `protobuf:"bytes,13,opt,name=web_url,json=webUrl,proto3" json:"web_url,omitempty"`+}++func (x *VCSConnector) Reset() {+ *x = VCSConnector{}+ if protoimpl.UnsafeEnabled {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[6]+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ ms.StoreMessageInfo(mi)+ }+}++func (x *VCSConnector) String() string {+ return protoimpl.X.MessageStringOf(x)+}++func (*VCSConnector) ProtoMessage() {}++func (x *VCSConnector) ProtoReflect() protoreflect.Message {+ mi := &file_v1_vcs_connector_service_proto_msgTypes[6]+ if protoimpl.UnsafeEnabled && x != nil {+ ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))+ if ms.LoadMessageInfo() == nil {+ ms.StoreMessageInfo(mi)+ }+ return ms+ }+ return mi.MessageOf(x)+}++// Deprecated: Use VCSConnector.ProtoReflect.Descriptor instead.+func (*VCSConnector) Descriptor() ([]byte, []int) {+ return file_v1_vcs_connector_service_proto_rawDescGZIP(), []int{6}+}++func (x *VCSConnector) GetName() string {+ if x != nil {+ return x.Name+ }+ return ""+}++func (x *VCSConnector) GetTitle() string {+ if x != nil {+ return x.Title+ }+ return ""+}++func (x *VCSConnector) GetCreator() string {+ if x != nil {+ return x.Creator+ }+ return ""+}++func (x *VCSConnector) GetUpdater() string {+ if x != nil {+ return x.Updater+ }+ return ""+}++func (x *VCSConnector) GetCreateTime() *timestamppb.Timestamp {+ if x != nil {+ return x.CreateTime+ }+ return nil+}++func (x *VCSConnector) GetUpdateTime() *timestamppb.Timestamp {+ if x != nil {+ return x.UpdateTime+ }+ return nil+}++func (x *VCSConnector) GetVcsProvider() string {+ if x != nil {+ return x.VcsProvider+ }+ return ""+}++func (x *VCSConnector) GetExternalId() string {+ if x != nil {+ return x.ExternalId+ }+ return ""+}++func (x *VCSConnector) GetBaseDirectory() string {+ if x != nil {+ return x.BaseDirectory+ }+ return ""+}++func (x *VCSConnector) GetBranch() string {+ if x != nil {+ return x.Branch+ }+ return ""+}++func (x *VCSConnector) GetWebhookEndpointId() string {+ if x != nil {+ return x.WebhookEndpointId+ }+ return ""+}++func (x *VCSConnector) GetFullPath() string {+ if x != nil {+ return x.FullPath+ }+ return ""+}++func (x *VCSConnector) GetWebUrl() string {+ if x != nil {+ return x.WebUrl+ }+ return ""+}++var File_v1_vcs_connector_service_proto protoreflect.FileDescriptor++var file_v1_vcs_connector_service_proto_rawDesc = []byte{+ 0x0a, 0x1e, 0x76, 0x31, 0x2f, 0x76, 0x63, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74,+ 0x6f, 0x72, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,+ 0x12, 0x0b, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x1a, 0x1c, 0x67,+ 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61,+ 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x67, 0x6f, 0x6f,+ 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x2e, 0x70,+ 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69,+ 0x2f, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x62, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x2e,+ 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1b, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72,+ 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2e, 0x70, 0x72, 0x6f,+ 0x74, 0x6f, 0x1a, 0x20, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f,+ 0x62, 0x75, 0x66, 0x2f, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x2e, 0x70,+ 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f,+ 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e,+ 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xac, 0x01, 0x0a, 0x19, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65,+ 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75,+ 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20,+ 0x01, 0x28, 0x09, 0x42, 0x03, 0xe0, 0x41, 0x02, 0x52, 0x06, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74,+ 0x12, 0x43, 0x0a, 0x0d, 0x76, 0x63, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f,+ 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61,+ 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74,+ 0x6f, 0x72, 0x42, 0x03, 0xe0, 0x41, 0x02, 0x52, 0x0c, 0x76, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x6e,+ 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x2d, 0x0a, 0x10, 0x76, 0x63, 0x73, 0x5f, 0x63, 0x6f, 0x6e,+ 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42,+ 0x03, 0xe0, 0x41, 0x02, 0x52, 0x0e, 0x76, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74,+ 0x6f, 0x72, 0x49, 0x64, 0x22, 0x31, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x56, 0x43, 0x53, 0x43, 0x6f,+ 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x17,+ 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x03, 0xe0, 0x41,+ 0x02, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x73, 0x0a, 0x18, 0x4c, 0x69, 0x73, 0x74, 0x56,+ 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x52, 0x65, 0x71, 0x75,+ 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20,+ 0x01, 0x28, 0x09, 0x42, 0x03, 0xe0, 0x41, 0x02, 0x52, 0x06, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74,+ 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20,+ 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1d, 0x0a,+ 0x0a, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28,+ 0x09, 0x52, 0x09, 0x70, 0x61, 0x67, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x85, 0x01, 0x0a,+ 0x19, 0x4c, 0x69, 0x73, 0x74, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f,+ 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x0e, 0x76, 0x63,+ 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03,+ 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31,+ 0x2e, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x0d, 0x76,+ 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x12, 0x26, 0x0a, 0x0f,+ 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18,+ 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x6e, 0x65, 0x78, 0x74, 0x50, 0x61, 0x67, 0x65, 0x54,+ 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x9d, 0x01, 0x0a, 0x19, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x56,+ 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65,+ 0x73, 0x74, 0x12, 0x43, 0x0a, 0x0d, 0x76, 0x63, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63,+ 0x74, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x62, 0x79, 0x74, 0x65,+ 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65,+ 0x63, 0x74, 0x6f, 0x72, 0x42, 0x03, 0xe0, 0x41, 0x02, 0x52, 0x0c, 0x76, 0x63, 0x73, 0x43, 0x6f,+ 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x3b, 0x0a, 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74,+ 0x65, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67,+ 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x46,+ 0x69, 0x65, 0x6c, 0x64, 0x4d, 0x61, 0x73, 0x6b, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65,+ 0x4d, 0x61, 0x73, 0x6b, 0x22, 0x34, 0x0a, 0x19, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x56, 0x43,+ 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,+ 0x74, 0x12, 0x17, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42,+ 0x03, 0xe0, 0x41, 0x02, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0xf0, 0x03, 0x0a, 0x0c, 0x56,+ 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x1a, 0x0a, 0x04, 0x6e,+ 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xe0, 0x41, 0x02, 0xe0, 0x41,+ 0x05, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65,+ 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x1d, 0x0a,+ 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x03,+ 0xe0, 0x41, 0x03, 0x52, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x1d, 0x0a, 0x07,+ 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x03, 0xe0,+ 0x41, 0x03, 0x52, 0x07, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x12, 0x40, 0x0a, 0x0b, 0x63,+ 0x72, 0x65, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b,+ 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62,+ 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x03, 0xe0, 0x41,+ 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x40, 0x0a,+ 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01,+ 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74,+ 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x03,+ 0xe0, 0x41, 0x03, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12,+ 0x21, 0x0a, 0x0c, 0x76, 0x63, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x18,+ 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x76, 0x63, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64,+ 0x65, 0x72, 0x12, 0x1f, 0x0a, 0x0b, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x5f, 0x69,+ 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61,+ 0x6c, 0x49, 0x64, 0x12, 0x25, 0x0a, 0x0e, 0x62, 0x61, 0x73, 0x65, 0x5f, 0x64, 0x69, 0x72, 0x65,+ 0x63, 0x74, 0x6f, 0x72, 0x79, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x62, 0x61, 0x73,+ 0x65, 0x44, 0x69, 0x72, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x62, 0x72,+ 0x61, 0x6e, 0x63, 0x68, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x62, 0x72, 0x61, 0x6e,+ 0x63, 0x68, 0x12, 0x33, 0x0a, 0x13, 0x77, 0x65, 0x62, 0x68, 0x6f, 0x6f, 0x6b, 0x5f, 0x65, 0x6e,+ 0x64, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x42,+ 0x03, 0xe0, 0x41, 0x03, 0x52, 0x11, 0x77, 0x65, 0x62, 0x68, 0x6f, 0x6f, 0x6b, 0x45, 0x6e, 0x64,+ 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x66, 0x75, 0x6c, 0x6c, 0x5f,+ 0x70, 0x61, 0x74, 0x68, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x66, 0x75, 0x6c, 0x6c,+ 0x50, 0x61, 0x74, 0x68, 0x12, 0x17, 0x0a, 0x07, 0x77, 0x65, 0x62, 0x5f, 0x75, 0x72, 0x6c, 0x18,+ 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x77, 0x65, 0x62, 0x55, 0x72, 0x6c, 0x32, 0xb9, 0x06,+ 0x0a, 0x13, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x53, 0x65,+ 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0xab, 0x01, 0x0a, 0x12, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65,+ 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x26, 0x2e, 0x62,+ 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74,+ 0x65, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71,+ 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e,+ 0x76, 0x31, 0x2e, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x22,+ 0x52, 0xda, 0x41, 0x13, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x2c, 0x76, 0x63, 0x73, 0x43, 0x6f,+ 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x36, 0x3a, 0x0d, 0x76,+ 0x63, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x22, 0x25, 0x2f, 0x76,+ 0x31, 0x2f, 0x7b, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x3d, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63,+ 0x74, 0x73, 0x2f, 0x2a, 0x7d, 0x2f, 0x76, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74,+ 0x6f, 0x72, 0x73, 0x12, 0x87, 0x01, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x56, 0x43, 0x53, 0x43, 0x6f,+ 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x23, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61,+ 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e,+ 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x62,+ 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x56, 0x43, 0x53, 0x43, 0x6f,+ 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x22, 0x34, 0xda, 0x41, 0x04, 0x6e, 0x61, 0x6d, 0x65,+ 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x12, 0x25, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x6e, 0x61, 0x6d,+ 0x65, 0x3d, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x76, 0x63, 0x73,+ 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0x9a, 0x01,+ 0x0a, 0x11, 0x4c, 0x69, 0x73, 0x74, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74,+ 0x6f, 0x72, 0x73, 0x12, 0x25, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76,+ 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74,+ 0x6f, 0x72, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x26, 0x2e, 0x62, 0x79, 0x74,+ 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x56, 0x43, 0x53,+ 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,+ 0x73, 0x65, 0x22, 0x36, 0xda, 0x41, 0x06, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x82, 0xd3, 0xe4,+ 0x93, 0x02, 0x27, 0x12, 0x25, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74,+ 0x3d, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x2f, 0x2a, 0x7d, 0x2f, 0x76, 0x63, 0x73,+ 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x12, 0xbf, 0x01, 0x0a, 0x12, 0x55,+ 0x70, 0x64, 0x61, 0x74, 0x65, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f,+ 0x72, 0x12, 0x26, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e,+ 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74,+ 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x62, 0x79, 0x74, 0x65,+ 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65,+ 0x63, 0x74, 0x6f, 0x72, 0x22, 0x66, 0xda, 0x41, 0x19, 0x76, 0x63, 0x73, 0x5f, 0x63, 0x6f, 0x6e,+ 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x2c, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x6d, 0x61,+ 0x73, 0x6b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x44, 0x3a, 0x0d, 0x76, 0x63, 0x73, 0x5f, 0x63, 0x6f,+ 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x32, 0x33, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x76, 0x63,+ 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x2e, 0x6e, 0x61, 0x6d, 0x65,+ 0x3d, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x76, 0x63, 0x73, 0x43,+ 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0x8a, 0x01, 0x0a,+ 0x12, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65, 0x63,+ 0x74, 0x6f, 0x72, 0x12, 0x26, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76,+ 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x56, 0x43, 0x53, 0x43, 0x6f, 0x6e, 0x6e, 0x65,+ 0x63, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f,+ 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d,+ 0x70, 0x74, 0x79, 0x22, 0x34, 0xda, 0x41, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3, 0xe4, 0x93,+ 0x02, 0x27, 0x2a, 0x25, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x70, 0x72,+ 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x76, 0x63, 0x73, 0x43, 0x6f, 0x6e, 0x6e,+ 0x65, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x2f, 0x2a, 0x7d, 0x42, 0x11, 0x5a, 0x0f, 0x67, 0x65, 0x6e,+ 0x65, 0x72, 0x61, 0x74, 0x65, 0x64, 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72,+ 0x6f, 0x74, 0x6f, 0x33,+}++var (+ file_v1_vcs_connector_service_proto_rawDescOnce sync.Once+ file_v1_vcs_connector_service_proto_rawDescData = file_v1_vcs_connector_service_proto_rawDesc+)++func file_v1_vcs_connector_service_proto_rawDescGZIP() []byte {+ file_v1_vcs_connector_service_proto_rawDescOnce.Do(func() {+ file_v1_vcs_connector_service_proto_rawDescData = protoimpl.X.CompressGZIP(file_v1_vcs_connector_service_proto_rawDescData)+ })+ return file_v1_vcs_connector_service_proto_rawDescData+}++var file_v1_vcs_connector_service_proto_msgTypes = make([]protoimpl.MessageInfo, 7)+var file_v1_vcs_connector_service_proto_goTypes = []interface{}{+ (*CreateVCSConnectorRequest)(nil), // 0: bytebase.v1.CreateVCSConnectorRequest+ (*GetVCSConnectorRequest)(nil), // 1: bytebase.v1.GetVCSConnectorRequest+ (*ListVCSConnectorsRequest)(nil), // 2: bytebase.v1.ListVCSConnectorsRequest+ (*ListVCSConnectorsResponse)(nil), // 3: bytebase.v1.ListVCSConnectorsResponse+ (*UpdateVCSConnectorRequest)(nil), // 4: bytebase.v1.UpdateVCSConnectorRequest+ (*DeleteVCSConnectorRequest)(nil), // 5: bytebase.v1.DeleteVCSConnectorRequest+ (*VCSConnector)(nil), // 6: bytebase.v1.VCSConnector+ (*fieldmaskpb.FieldMask)(nil), // 7: google.protobuf.FieldMask+ (*timestamppb.Timestamp)(nil), // 8: google.protobuf.Timestamp+ (*emptypb.Empty)(nil), // 9: google.protobuf.Empty+}+var file_v1_vcs_connector_service_proto_depIdxs = []int32{+ 6, // 0: bytebase.v1.CreateVCSConnectorRequest.vcs_connector:type_name -> bytebase.v1.VCSConnector+ 6, // 1: bytebase.v1.ListVCSConnectorsResponse.vcs_connectors:type_name -> bytebase.v1.VCSConnector+ 6, // 2: bytebase.v1.UpdateVCSConnectorRequest.vcs_connector:type_name -> bytebase.v1.VCSConnector+ 7, // 3: bytebase.v1.UpdateVCSConnectorRequest.update_mask:type_name -> google.protobuf.FieldMask+ 8, // 4: bytebase.v1.VCSConnector.create_time:type_name -> google.protobuf.Timestamp+ 8, // 5: bytebase.v1.VCSConnector.update_time:type_name -> google.protobuf.Timestamp+ 0, // 6: bytebase.v1.VCSConnectorService.CreateVCSConnector:input_type -> bytebase.v1.CreateVCSConnectorRequest+ 1, // 7: bytebase.v1.VCSConnectorService.GetVCSConnector:input_type -> bytebase.v1.GetVCSConnectorRequest+ 2, // 8: bytebase.v1.VCSConnectorService.ListVCSConnectors:input_type -> bytebase.v1.ListVCSConnectorsRequest+ 4, // 9: bytebase.v1.VCSConnectorService.UpdateVCSConnector:input_type -> bytebase.v1.UpdateVCSConnectorRequest+ 5, // 10: bytebase.v1.VCSConnectorService.DeleteVCSConnector:input_type -> bytebase.v1.DeleteVCSConnectorRequest+ 6, // 11: bytebase.v1.VCSConnectorService.CreateVCSConnector:output_type -> bytebase.v1.VCSConnector+ 6, // 12: bytebase.v1.VCSConnectorService.GetVCSConnector:output_type -> bytebase.v1.VCSConnector+ 3, // 13: bytebase.v1.VCSConnectorService.ListVCSConnectors:output_type -> bytebase.v1.ListVCSConnectorsResponse+ 6, // 14: bytebase.v1.VCSConnectorService.UpdateVCSConnector:output_type -> bytebase.v1.VCSConnector+ 9, // 15: bytebase.v1.VCSConnectorService.DeleteVCSConnector:output_type -> google.protobuf.Empty+ 11, // [11:16] is the sub-list for method output_type+ 6, // [6:11] is the sub-list for method input_type+ 6, // [6:6] is the sub-list for extension type_name+ 6, // [6:6] is the sub-list for extension extendee+ 0, // [0:6] is the sub-list for field type_name+}++func init() { file_v1_vcs_connector_service_proto_init() }+func file_v1_vcs_connector_service_proto_init() {+ if File_v1_vcs_connector_service_proto != nil {+ return+ }+ if !protoimpl.UnsafeEnabled {+ file_v1_vcs_connector_service_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {+ switch v := v.(*CreateVCSConnectorRequest); i {+ case 0:+ return &v.state+ case 1:+ return &v.sizeCache+ case 2:+ return &v.unknownFields+ default:+ return nil+ }+ }+ file_v1_vcs_connector_service_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {+ switch v := v.(*GetVCSConnectorRequest); i {+ case 0:+ return &v.state+ case 1:+ return &v.sizeCache+ case 2:+ return &v.unknownFields+ default:+ return nil+ }+ }+ file_v1_vcs_connector_service_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {+ switch v := v.(*ListVCSConnectorsRequest); i {+ case 0:+ return &v.state+ case 1:+ return &v.sizeCache+ case 2:+ return &v.unknownFields+ default:+ return nil+ }+ }+ file_v1_vcs_connector_service_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {+ switch v := v.(*ListVCSConnectorsResponse); i {+ case 0:+ return &v.state+ case 1:+ return &v.sizeCache+ case 2:+ return &v.unknownFields+ default:+ return nil+ }+ }+ file_v1_vcs_connector_service_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {+ switch v := v.(*UpdateVCSConnectorRequest); i {+ case 0:+ return &v.state+ case 1:+ return &v.sizeCache+ case 2:+ return &v.unknownFields+ default:+ return nil+ }+ }+ file_v1_vcs_connector_service_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {+ switch v := v.(*DeleteVCSConnectorRequest); i {+ case 0:+ return &v.state+ case 1:+ return &v.sizeCache+ case 2:+ return &v.unknownFields+ default:+ return nil+ }+ }+ file_v1_vcs_connector_service_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {+ switch v := v.(*VCSConnector); i {+ case 0:+ return &v.state+ case 1:+ return &v.sizeCache+ case 2:+ return &v.unknownFields+ default:+ return nil+ }+ }+ }+ type x struct{}+ out := protoimpl.TypeBuilder{+ File: protoimpl.DescBuilder{+ GoPackagePath: reflect.TypeOf(x{}).PkgPath(),+ RawDescriptor: file_v1_vcs_connector_service_proto_rawDesc,+ NumEnums: 0,+ NumMessages: 7,+ NumExtensions: 0,+ NumServices: 1,+ },+ GoTypes: file_v1_vcs_connector_service_proto_goTypes,+ DependencyIndexes: file_v1_vcs_connector_service_proto_depIdxs,+ MessageInfos: file_v1_vcs_connector_service_proto_msgTypes,+ }.Build()+ File_v1_vcs_connector_service_proto = out.File+ file_v1_vcs_connector_service_proto_rawDesc = nil+ file_v1_vcs_connector_service_proto_goTypes = nil+ file_v1_vcs_connector_service_proto_depIdxs = nil+}diff --git a/proto/generated-go/v1/vcs_connector_service.pb.gw.go b/proto/generated-go/v1/vcs_connector_service.pb.gw.gonew file mode 100644index 0000000000..c59d5c7466--- /dev/null+++ b/proto/generated-go/v1/vcs_connector_service.pb.gw.go@@ -0,0 +1,693 @@+// Code generated by protoc-gen-grpc-gateway. DO NOT EDIT.+// source: v1/vcs_connector_service.proto++/*+Package v1 is a reverse proxy.++It translates gRPC into RESTful JSON APIs.+*/+package v1++import (+ "context"+ "io"+ "net/http"++ "github.com/grpc-ecosystem/grpc-gateway/v2/runtime"+ "github.com/grpc-ecosystem/grpc-gateway/v2/utilities"+ "google.golang.org/grpc"+ "google.golang.org/grpc/codes"+ "google.golang.org/grpc/grpclog"+ "google.golang.org/grpc/metadata"+ "google.golang.org/grpc/status"+ "google.golang.org/protobuf/proto"+)++// Suppress "imported and not used" errors+var _ codes.Code+var _ io.Reader+var _ status.Status+var _ = runtime.String+var _ = utilities.NewDoubleArray+var _ = metadata.Join++var (+ filter_VCSConnectorService_CreateVCSConnector_0 = &utilities.DoubleArray{Encoding: map[string]int{"vcs_connector": 0, "parent": 1}, Base: []int{1, 1, 2, 0, 0}, Check: []int{0, 1, 1, 2, 3}}+)++func request_VCSConnectorService_CreateVCSConnector_0(ctx context.Context, marshaler runtime.Marshaler, client VCSConnectorServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq CreateVCSConnectorRequest+ var metadata runtime.ServerMetadata++ if err := marshaler.NewDecoder(req.Body).Decode(&protoReq.VcsConnector); err != nil && err != io.EOF {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["parent"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "parent")+ }++ protoReq.Parent, err = runtime.String(val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "parent", err)+ }++ if err := req.ParseForm(); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }+ if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_VCSConnectorService_CreateVCSConnector_0); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }++ msg, err := client.CreateVCSConnector(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))+ return msg, metadata, err++}++func local_request_VCSConnectorService_CreateVCSConnector_0(ctx context.Context, marshaler runtime.Marshaler, server VCSConnectorServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq CreateVCSConnectorRequest+ var metadata runtime.ServerMetadata++ if err := marshaler.NewDecoder(req.Body).Decode(&protoReq.VcsConnector); err != nil && err != io.EOF {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["parent"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "parent")+ }++ protoReq.Parent, err = runtime.String(val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "parent", err)+ }++ if err := req.ParseForm(); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }+ if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_VCSConnectorService_CreateVCSConnector_0); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }++ msg, err := server.CreateVCSConnector(ctx, &protoReq)+ return msg, metadata, err++}++func request_VCSConnectorService_GetVCSConnector_0(ctx context.Context, marshaler runtime.Marshaler, client VCSConnectorServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq GetVCSConnectorRequest+ var metadata runtime.ServerMetadata++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["name"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "name")+ }++ protoReq.Name, err = runtime.String(val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "name", err)+ }++ msg, err := client.GetVCSConnector(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))+ return msg, metadata, err++}++func local_request_VCSConnectorService_GetVCSConnector_0(ctx context.Context, marshaler runtime.Marshaler, server VCSConnectorServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq GetVCSConnectorRequest+ var metadata runtime.ServerMetadata++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["name"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "name")+ }++ protoReq.Name, err = runtime.String(val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "name", err)+ }++ msg, err := server.GetVCSConnector(ctx, &protoReq)+ return msg, metadata, err++}++var (+ filter_VCSConnectorService_ListVCSConnectors_0 = &utilities.DoubleArray{Encoding: map[string]int{"parent": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}+)++func request_VCSConnectorService_ListVCSConnectors_0(ctx context.Context, marshaler runtime.Marshaler, client VCSConnectorServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq ListVCSConnectorsRequest+ var metadata runtime.ServerMetadata++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["parent"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "parent")+ }++ protoReq.Parent, err = runtime.String(val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "parent", err)+ }++ if err := req.ParseForm(); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }+ if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_VCSConnectorService_ListVCSConnectors_0); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }++ msg, err := client.ListVCSConnectors(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))+ return msg, metadata, err++}++func local_request_VCSConnectorService_ListVCSConnectors_0(ctx context.Context, marshaler runtime.Marshaler, server VCSConnectorServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq ListVCSConnectorsRequest+ var metadata runtime.ServerMetadata++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["parent"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "parent")+ }++ protoReq.Parent, err = runtime.String(val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "parent", err)+ }++ if err := req.ParseForm(); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }+ if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_VCSConnectorService_ListVCSConnectors_0); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }++ msg, err := server.ListVCSConnectors(ctx, &protoReq)+ return msg, metadata, err++}++var (+ filter_VCSConnectorService_UpdateVCSConnector_0 = &utilities.DoubleArray{Encoding: map[string]int{"vcs_connector": 0, "name": 1}, Base: []int{1, 2, 1, 0, 0}, Check: []int{0, 1, 2, 3, 2}}+)++func request_VCSConnectorService_UpdateVCSConnector_0(ctx context.Context, marshaler runtime.Marshaler, client VCSConnectorServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq UpdateVCSConnectorRequest+ var metadata runtime.ServerMetadata++ newReader, berr := utilities.IOReaderFactory(req.Body)+ if berr != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)+ }+ if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.VcsConnector); err != nil && err != io.EOF {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }+ if protoReq.UpdateMask == nil || len(protoReq.UpdateMask.GetPaths()) == 0 {+ if fieldMask, err := runtime.FieldMaskFromRequestBody(newReader(), protoReq.VcsConnector); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ } else {+ protoReq.UpdateMask = fieldMask+ }+ }++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["vcs_connector.name"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "vcs_connector.name")+ }++ err = runtime.PopulateFieldFromPath(&protoReq, "vcs_connector.name", val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "vcs_connector.name", err)+ }++ if err := req.ParseForm(); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }+ if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_VCSConnectorService_UpdateVCSConnector_0); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }++ msg, err := client.UpdateVCSConnector(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))+ return msg, metadata, err++}++func local_request_VCSConnectorService_UpdateVCSConnector_0(ctx context.Context, marshaler runtime.Marshaler, server VCSConnectorServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq UpdateVCSConnectorRequest+ var metadata runtime.ServerMetadata++ newReader, berr := utilities.IOReaderFactory(req.Body)+ if berr != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)+ }+ if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.VcsConnector); err != nil && err != io.EOF {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }+ if protoReq.UpdateMask == nil || len(protoReq.UpdateMask.GetPaths()) == 0 {+ if fieldMask, err := runtime.FieldMaskFromRequestBody(newReader(), protoReq.VcsConnector); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ } else {+ protoReq.UpdateMask = fieldMask+ }+ }++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["vcs_connector.name"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "vcs_connector.name")+ }++ err = runtime.PopulateFieldFromPath(&protoReq, "vcs_connector.name", val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "vcs_connector.name", err)+ }++ if err := req.ParseForm(); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }+ if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_VCSConnectorService_UpdateVCSConnector_0); err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)+ }++ msg, err := server.UpdateVCSConnector(ctx, &protoReq)+ return msg, metadata, err++}++func request_VCSConnectorService_DeleteVCSConnector_0(ctx context.Context, marshaler runtime.Marshaler, client VCSConnectorServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq DeleteVCSConnectorRequest+ var metadata runtime.ServerMetadata++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["name"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "name")+ }++ protoReq.Name, err = runtime.String(val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "name", err)+ }++ msg, err := client.DeleteVCSConnector(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))+ return msg, metadata, err++}++func local_request_VCSConnectorService_DeleteVCSConnector_0(ctx context.Context, marshaler runtime.Marshaler, server VCSConnectorServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {+ var protoReq DeleteVCSConnectorRequest+ var metadata runtime.ServerMetadata++ var (+ val string+ ok bool+ err error+ _ = err+ )++ val, ok = pathParams["name"]+ if !ok {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "name")+ }++ protoReq.Name, err = runtime.String(val)+ if err != nil {+ return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "name", err)+ }++ msg, err := server.DeleteVCSConnector(ctx, &protoReq)+ return msg, metadata, err++}++// RegisterVCSConnectorServiceHandlerServer registers the http handlers for service VCSConnectorService to "mux".+// UnaryRPC :call VCSConnectorServiceServer directly.+// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.+// Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterVCSConnectorServiceHandlerFromEndpoint instead.+func RegisterVCSConnectorServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server VCSConnectorServiceServer) error {++ mux.Handle("POST", pattern_VCSConnectorService_CreateVCSConnector_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ var stream runtime.ServerTransportStream+ ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateIncomingContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/CreateVCSConnector", runtime.WithHTTPPathPattern("/v1/{parent=projects/*}/vcsConnectors"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := local_request_VCSConnectorService_CreateVCSConnector_0(annotatedContext, inboundMarshaler, server, req, pathParams)+ md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_CreateVCSConnector_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ mux.Handle("GET", pattern_VCSConnectorService_GetVCSConnector_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ var stream runtime.ServerTransportStream+ ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateIncomingContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/GetVCSConnector", runtime.WithHTTPPathPattern("/v1/{name=projects/*/vcsConnectors/*}"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := local_request_VCSConnectorService_GetVCSConnector_0(annotatedContext, inboundMarshaler, server, req, pathParams)+ md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_GetVCSConnector_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ mux.Handle("GET", pattern_VCSConnectorService_ListVCSConnectors_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ var stream runtime.ServerTransportStream+ ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateIncomingContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/ListVCSConnectors", runtime.WithHTTPPathPattern("/v1/{parent=projects/*}/vcsConnectors"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := local_request_VCSConnectorService_ListVCSConnectors_0(annotatedContext, inboundMarshaler, server, req, pathParams)+ md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_ListVCSConnectors_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ mux.Handle("PATCH", pattern_VCSConnectorService_UpdateVCSConnector_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ var stream runtime.ServerTransportStream+ ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateIncomingContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/UpdateVCSConnector", runtime.WithHTTPPathPattern("/v1/{vcs_connector.name=projects/*/vcsConnectors/*}"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := local_request_VCSConnectorService_UpdateVCSConnector_0(annotatedContext, inboundMarshaler, server, req, pathParams)+ md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_UpdateVCSConnector_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ mux.Handle("DELETE", pattern_VCSConnectorService_DeleteVCSConnector_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ var stream runtime.ServerTransportStream+ ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateIncomingContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/DeleteVCSConnector", runtime.WithHTTPPathPattern("/v1/{name=projects/*/vcsConnectors/*}"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := local_request_VCSConnectorService_DeleteVCSConnector_0(annotatedContext, inboundMarshaler, server, req, pathParams)+ md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_DeleteVCSConnector_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ return nil+}++// RegisterVCSConnectorServiceHandlerFromEndpoint is same as RegisterVCSConnectorServiceHandler but+// automatically dials to "endpoint" and closes the connection when "ctx" gets done.+func RegisterVCSConnectorServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) {+ conn, err := grpc.DialContext(ctx, endpoint, opts...)+ if err != nil {+ return err+ }+ defer func() {+ if err != nil {+ if cerr := conn.Close(); cerr != nil {+ grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)+ }+ return+ }+ go func() {+ <-ctx.Done()+ if cerr := conn.Close(); cerr != nil {+ grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)+ }+ }()+ }()++ return RegisterVCSConnectorServiceHandler(ctx, mux, conn)+}++// RegisterVCSConnectorServiceHandler registers the http handlers for service VCSConnectorService to "mux".+// The handlers forward requests to the grpc endpoint over "conn".+func RegisterVCSConnectorServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error {+ return RegisterVCSConnectorServiceHandlerClient(ctx, mux, NewVCSConnectorServiceClient(conn))+}++// RegisterVCSConnectorServiceHandlerClient registers the http handlers for service VCSConnectorService+// to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "VCSConnectorServiceClient".+// Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "VCSConnectorServiceClient"+// doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in+// "VCSConnectorServiceClient" to call the correct interceptors.+func RegisterVCSConnectorServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client VCSConnectorServiceClient) error {++ mux.Handle("POST", pattern_VCSConnectorService_CreateVCSConnector_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/CreateVCSConnector", runtime.WithHTTPPathPattern("/v1/{parent=projects/*}/vcsConnectors"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := request_VCSConnectorService_CreateVCSConnector_0(annotatedContext, inboundMarshaler, client, req, pathParams)+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_CreateVCSConnector_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ mux.Handle("GET", pattern_VCSConnectorService_GetVCSConnector_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/GetVCSConnector", runtime.WithHTTPPathPattern("/v1/{name=projects/*/vcsConnectors/*}"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := request_VCSConnectorService_GetVCSConnector_0(annotatedContext, inboundMarshaler, client, req, pathParams)+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_GetVCSConnector_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ mux.Handle("GET", pattern_VCSConnectorService_ListVCSConnectors_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/ListVCSConnectors", runtime.WithHTTPPathPattern("/v1/{parent=projects/*}/vcsConnectors"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := request_VCSConnectorService_ListVCSConnectors_0(annotatedContext, inboundMarshaler, client, req, pathParams)+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_ListVCSConnectors_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ mux.Handle("PATCH", pattern_VCSConnectorService_UpdateVCSConnector_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/UpdateVCSConnector", runtime.WithHTTPPathPattern("/v1/{vcs_connector.name=projects/*/vcsConnectors/*}"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := request_VCSConnectorService_UpdateVCSConnector_0(annotatedContext, inboundMarshaler, client, req, pathParams)+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_UpdateVCSConnector_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ mux.Handle("DELETE", pattern_VCSConnectorService_DeleteVCSConnector_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {+ ctx, cancel := context.WithCancel(req.Context())+ defer cancel()+ inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)+ var err error+ var annotatedContext context.Context+ annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/bytebase.v1.VCSConnectorService/DeleteVCSConnector", runtime.WithHTTPPathPattern("/v1/{name=projects/*/vcsConnectors/*}"))+ if err != nil {+ runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)+ return+ }+ resp, md, err := request_VCSConnectorService_DeleteVCSConnector_0(annotatedContext, inboundMarshaler, client, req, pathParams)+ annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)+ if err != nil {+ runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)+ return+ }++ forward_VCSConnectorService_DeleteVCSConnector_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)++ })++ return nil+}++var (+ pattern_VCSConnectorService_CreateVCSConnector_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 2, 5, 2, 2, 3}, []string{"v1", "projects", "parent", "vcsConnectors"}, ""))++ pattern_VCSConnectorService_GetVCSConnector_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 2, 2, 1, 0, 4, 4, 5, 3}, []string{"v1", "projects", "vcsConnectors", "name"}, ""))++ pattern_VCSConnectorService_ListVCSConnectors_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 2, 5, 2, 2, 3}, []string{"v1", "projects", "parent", "vcsConnectors"}, ""))++ pattern_VCSConnectorService_UpdateVCSConnector_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 2, 2, 1, 0, 4, 4, 5, 3}, []string{"v1", "projects", "vcsConnectors", "vcs_connector.name"}, ""))++ pattern_VCSConnectorService_DeleteVCSConnector_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 2, 2, 1, 0, 4, 4, 5, 3}, []string{"v1", "projects", "vcsConnectors", "name"}, ""))+)++var (+ forward_VCSConnectorService_CreateVCSConnector_0 = runtime.ForwardResponseMessage++ forward_VCSConnectorService_GetVCSConnector_0 = runtime.ForwardResponseMessage++ forward_VCSConnectorService_ListVCSConnectors_0 = runtime.ForwardResponseMessage++ forward_VCSConnectorService_UpdateVCSConnector_0 = runtime.ForwardResponseMessage++ forward_VCSConnectorService_DeleteVCSConnector_0 = runtime.ForwardResponseMessage+)diff --git a/proto/generated-go/v1/vcs_connector_service_grpc.pb.go b/proto/generated-go/v1/vcs_connector_service_grpc.pb.gonew file mode 100644index 0000000000..3a05b7e3a5--- /dev/null+++ b/proto/generated-go/v1/vcs_connector_service_grpc.pb.go@@ -0,0 +1,258 @@+// Code generated by protoc-gen-go-grpc. DO NOT EDIT.+// versions:+// - protoc-gen-go-grpc v1.3.0+// - protoc (unknown)+// source: v1/vcs_connector_service.proto++package v1++import (+ context "context"+ grpc "google.golang.org/grpc"+ codes "google.golang.org/grpc/codes"+ status "google.golang.org/grpc/status"+ emptypb "google.golang.org/protobuf/types/known/emptypb"+)++// This is a compile-time assertion to ensure that this generated file+// is compatible with the grpc package it is being compiled against.+// Requires gRPC-Go v1.32.0 or later.+const _ = grpc.SupportPackageIsVersion7++const (+ VCSConnectorService_CreateVCSConnector_FullMethodName = "/bytebase.v1.VCSConnectorService/CreateVCSConnector"+ VCSConnectorService_GetVCSConnector_FullMethodName = "/bytebase.v1.VCSConnectorService/GetVCSConnector"+ VCSConnectorService_ListVCSConnectors_FullMethodName = "/bytebase.v1.VCSConnectorService/ListVCSConnectors"+ VCSConnectorService_UpdateVCSConnector_FullMethodName = "/bytebase.v1.VCSConnectorService/UpdateVCSConnector"+ VCSConnectorService_DeleteVCSConnector_FullMethodName = "/bytebase.v1.VCSConnectorService/DeleteVCSConnector"+)++// VCSConnectorServiceClient is the client API for VCSConnectorService service.+//+// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.+type VCSConnectorServiceClient interface {+ CreateVCSConnector(ctx context.Context, in *CreateVCSConnectorRequest, opts ...grpc.CallOption) (*VCSConnector, error)+ GetVCSConnector(ctx context.Context, in *GetVCSConnectorRequest, opts ...grpc.CallOption) (*VCSConnector, error)+ ListVCSConnectors(ctx context.Context, in *ListVCSConnectorsRequest, opts ...grpc.CallOption) (*ListVCSConnectorsResponse, error)+ UpdateVCSConnector(ctx context.Context, in *UpdateVCSConnectorRequest, opts ...grpc.CallOption) (*VCSConnector, error)+ DeleteVCSConnector(ctx context.Context, in *DeleteVCSConnectorRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)+}++type vCSConnectorServiceClient struct {+ cc grpc.ClientConnInterface+}++func NewVCSConnectorServiceClient(cc grpc.ClientConnInterface) VCSConnectorServiceClient {+ return &vCSConnectorServiceClient{cc}+}++func (c *vCSConnectorServiceClient) CreateVCSConnector(ctx context.Context, in *CreateVCSConnectorRequest, opts ...grpc.CallOption) (*VCSConnector, error) {+ out := new(VCSConnector)+ err := c.cc.Invoke(ctx, VCSConnectorService_CreateVCSConnector_FullMethodName, in, out, opts...)+ if err != nil {+ return nil, err+ }+ return out, nil+}++func (c *vCSConnectorServiceClient) GetVCSConnector(ctx context.Context, in *GetVCSConnectorRequest, opts ...grpc.CallOption) (*VCSConnector, error) {+ out := new(VCSConnector)+ err := c.cc.Invoke(ctx, VCSConnectorService_GetVCSConnector_FullMethodName, in, out, opts...)+ if err != nil {+ return nil, err+ }+ return out, nil+}++func (c *vCSConnectorServiceClient) ListVCSConnectors(ctx context.Context, in *ListVCSConnectorsRequest, opts ...grpc.CallOption) (*ListVCSConnectorsResponse, error) {+ out := new(ListVCSConnectorsResponse)+ err := c.cc.Invoke(ctx, VCSConnectorService_ListVCSConnectors_FullMethodName, in, out, opts...)+ if err != nil {+ return nil, err+ }+ return out, nil+}++func (c *vCSConnectorServiceClient) UpdateVCSConnector(ctx context.Context, in *UpdateVCSConnectorRequest, opts ...grpc.CallOption) (*VCSConnector, error) {+ out := new(VCSConnector)+ err := c.cc.Invoke(ctx, VCSConnectorService_UpdateVCSConnector_FullMethodName, in, out, opts...)+ if err != nil {+ return nil, err+ }+ return out, nil+}++func (c *vCSConnectorServiceClient) DeleteVCSConnector(ctx context.Context, in *DeleteVCSConnectorRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {+ out := new(emptypb.Empty)+ err := c.cc.Invoke(ctx, VCSConnectorService_DeleteVCSConnector_FullMethodName, in, out, opts...)+ if err != nil {+ return nil, err+ }+ return out, nil+}++// VCSConnectorServiceServer is the server API for VCSConnectorService service.+// All implementations must embed UnimplementedVCSConnectorServiceServer+// for forward compatibility+type VCSConnectorServiceServer interface {+ CreateVCSConnector(context.Context, *CreateVCSConnectorRequest) (*VCSConnector, error)+ GetVCSConnector(context.Context, *GetVCSConnectorRequest) (*VCSConnector, error)+ ListVCSConnectors(context.Context, *ListVCSConnectorsRequest) (*ListVCSConnectorsResponse, error)+ UpdateVCSConnector(context.Context, *UpdateVCSConnectorRequest) (*VCSConnector, error)+ DeleteVCSConnector(context.Context, *DeleteVCSConnectorRequest) (*emptypb.Empty, error)+ mustEmbedUnimplementedVCSConnectorServiceServer()+}++// UnimplementedVCSConnectorServiceServer must be embedded to have forward compatible implementations.+type UnimplementedVCSConnectorServiceServer struct {+}++func (UnimplementedVCSConnectorServiceServer) CreateVCSConnector(context.Context, *CreateVCSConnectorRequest) (*VCSConnector, error) {+ return nil, status.Errorf(codes.Unimplemented, "method CreateVCSConnector not implemented")+}+func (UnimplementedVCSConnectorServiceServer) GetVCSConnector(context.Context, *GetVCSConnectorRequest) (*VCSConnector, error) {+ return nil, status.Errorf(codes.Unimplemented, "method GetVCSConnector not implemented")+}+func (UnimplementedVCSConnectorServiceServer) ListVCSConnectors(context.Context, *ListVCSConnectorsRequest) (*ListVCSConnectorsResponse, error) {+ return nil, status.Errorf(codes.Unimplemented, "method ListVCSConnectors not implemented")+}+func (UnimplementedVCSConnectorServiceServer) UpdateVCSConnector(context.Context, *UpdateVCSConnectorRequest) (*VCSConnector, error) {+ return nil, status.Errorf(codes.Unimplemented, "method UpdateVCSConnector not implemented")+}+func (UnimplementedVCSConnectorServiceServer) DeleteVCSConnector(context.Context, *DeleteVCSConnectorRequest) (*emptypb.Empty, error) {+ return nil, status.Errorf(codes.Unimplemented, "method DeleteVCSConnector not implemented")+}+func (UnimplementedVCSConnectorServiceServer) mustEmbedUnimplementedVCSConnectorServiceServer() {}++// UnsafeVCSConnectorServiceServer may be embedded to opt out of forward compatibility for this service.+// Use of this interface is not recommended, as added methods to VCSConnectorServiceServer will+// result in compilation errors.+type UnsafeVCSConnectorServiceServer interface {+ mustEmbedUnimplementedVCSConnectorServiceServer()+}++func RegisterVCSConnectorServiceServer(s grpc.ServiceRegistrar, srv VCSConnectorServiceServer) {+ s.RegisterService(&VCSConnectorService_ServiceDesc, srv)+}++func _VCSConnectorService_CreateVCSConnector_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {+ in := new(CreateVCSConnectorRequest)+ if err := dec(in); err != nil {+ return nil, err+ }+ if interceptor == nil {+ return srv.(VCSConnectorServiceServer).CreateVCSConnector(ctx, in)+ }+ info := &grpc.UnaryServerInfo{+ Server: srv,+ FullMethod: VCSConnectorService_CreateVCSConnector_FullMethodName,+ }+ handler := func(ctx context.Context, req interface{}) (interface{}, error) {+ return srv.(VCSConnectorServiceServer).CreateVCSConnector(ctx, req.(*CreateVCSConnectorRequest))+ }+ return interceptor(ctx, in, info, handler)+}++func _VCSConnectorService_GetVCSConnector_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {+ in := new(GetVCSConnectorRequest)+ if err := dec(in); err != nil {+ return nil, err+ }+ if interceptor == nil {+ return srv.(VCSConnectorServiceServer).GetVCSConnector(ctx, in)+ }+ info := &grpc.UnaryServerInfo{+ Server: srv,+ FullMethod: VCSConnectorService_GetVCSConnector_FullMethodName,+ }+ handler := func(ctx context.Context, req interface{}) (interface{}, error) {+ return srv.(VCSConnectorServiceServer).GetVCSConnector(ctx, req.(*GetVCSConnectorRequest))+ }+ return interceptor(ctx, in, info, handler)+}++func _VCSConnectorService_ListVCSConnectors_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {+ in := new(ListVCSConnectorsRequest)+ if err := dec(in); err != nil {+ return nil, err+ }+ if interceptor == nil {+ return srv.(VCSConnectorServiceServer).ListVCSConnectors(ctx, in)+ }+ info := &grpc.UnaryServerInfo{+ Server: srv,+ FullMethod: VCSConnectorService_ListVCSConnectors_FullMethodName,+ }+ handler := func(ctx context.Context, req interface{}) (interface{}, error) {+ return srv.(VCSConnectorServiceServer).ListVCSConnectors(ctx, req.(*ListVCSConnectorsRequest))+ }+ return interceptor(ctx, in, info, handler)+}++func _VCSConnectorService_UpdateVCSConnector_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {+ in := new(UpdateVCSConnectorRequest)+ if err := dec(in); err != nil {+ return nil, err+ }+ if interceptor == nil {+ return srv.(VCSConnectorServiceServer).UpdateVCSConnector(ctx, in)+ }+ info := &grpc.UnaryServerInfo{+ Server: srv,+ FullMethod: VCSConnectorService_UpdateVCSConnector_FullMethodName,+ }+ handler := func(ctx context.Context, req interface{}) (interface{}, error) {+ return srv.(VCSConnectorServiceServer).UpdateVCSConnector(ctx, req.(*UpdateVCSConnectorRequest))+ }+ return interceptor(ctx, in, info, handler)+}++func _VCSConnectorService_DeleteVCSConnector_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {+ in := new(DeleteVCSConnectorRequest)+ if err := dec(in); err != nil {+ return nil, err+ }+ if interceptor == nil {+ return srv.(VCSConnectorServiceServer).DeleteVCSConnector(ctx, in)+ }+ info := &grpc.UnaryServerInfo{+ Server: srv,+ FullMethod: VCSConnectorService_DeleteVCSConnector_FullMethodName,+ }+ handler := func(ctx context.Context, req interface{}) (interface{}, error) {+ return srv.(VCSConnectorServiceServer).DeleteVCSConnector(ctx, req.(*DeleteVCSConnectorRequest))+ }+ return interceptor(ctx, in, info, handler)+}++// VCSConnectorService_ServiceDesc is the grpc.ServiceDesc for VCSConnectorService service.+// It's only intended for direct use with grpc.RegisterService,+// and not to be introspected or modified (even as a copy)+var VCSConnectorService_ServiceDesc = grpc.ServiceDesc{+ ServiceName: "bytebase.v1.VCSConnectorService",+ HandlerType: (*VCSConnectorServiceServer)(nil),+ Methods: []grpc.MethodDesc{+ {+ MethodName: "CreateVCSConnector",+ Handler: _VCSConnectorService_CreateVCSConnector_Handler,+ },+ {+ MethodName: "GetVCSConnector",+ Handler: _VCSConnectorService_GetVCSConnector_Handler,+ },+ {+ MethodName: "ListVCSConnectors",+ Handler: _VCSConnectorService_ListVCSConnectors_Handler,+ },+ {+ MethodName: "UpdateVCSConnector",+ Handler: _VCSConnectorService_UpdateVCSConnector_Handler,+ },+ {+ MethodName: "DeleteVCSConnector",+ Handler: _VCSConnectorService_DeleteVCSConnector_Handler,+ },+ },+ Streams: []grpc.StreamDesc{},+ Metadata: "v1/vcs_connector_service.proto",+}diff --git a/proto/v1/vcs_connector_service.proto b/proto/v1/vcs_connector_service.protonew file mode 100644index 0000000000..2a9e6ec2e2--- /dev/null+++ b/proto/v1/vcs_connector_service.proto@@ -0,0 +1,163 @@+syntax = "proto3";++package bytebase.v1;++import "google/api/annotations.proto";+import "google/api/client.proto";+import "google/api/field_behavior.proto";+import "google/protobuf/empty.proto";+import "google/protobuf/field_mask.proto";+import "google/protobuf/timestamp.proto";++option go_package = "generated-go/v1";++service VCSConnectorService {+ rpc CreateVCSConnector(CreateVCSConnectorRequest) returns (VCSConnector) {+ option (google.api.http) = {+ post: "/v1/{parent=projects/*}/vcsConnectors"+ body: "vcs_connector"+ };+ option (google.api.method_signature) = "parent,vcsConnector";+ }++ rpc GetVCSConnector(GetVCSConnectorRequest) returns (VCSConnector) {+ option (google.api.http) = {get: "/v1/{name=projects/*/vcsConnectors/*}"};+ option (google.api.method_signature) = "name";+ }++ rpc ListVCSConnectors(ListVCSConnectorsRequest) returns (ListVCSConnectorsResponse) {+ option (google.api.http) = {get: "/v1/{parent=projects/*}/vcsConnectors"};+ option (google.api.method_signature) = "parent";+ }++ rpc UpdateVCSConnector(UpdateVCSConnectorRequest) returns (VCSConnector) {+ option (google.api.http) = {+ patch: "/v1/{vcs_connector.name=projects/*/vcsConnectors/*}"+ body: "vcs_connector"+ };+ option (google.api.method_signature) = "vcs_connector,update_mask";+ }++ rpc DeleteVCSConnector(DeleteVCSConnectorRequest) returns (google.protobuf.Empty) {+ option (google.api.http) = {delete: "/v1/{name=projects/*/vcsConnectors/*}"};+ option (google.api.method_signature) = "name";+ }+}++message CreateVCSConnectorRequest {+ // The parent resource where this vcsConnector will be created.+ // Format: projects/{project}+ string parent = 1 [(google.api.field_behavior) = REQUIRED];++ // The vcsConnector to create.+ VCSConnector vcs_connector = 2 [(google.api.field_behavior) = REQUIRED];++ // The ID to use for the vcsConnector, which will become the final component of+ // the vcsConnector's resource name.+ //+ // This value should be 4-63 characters, and valid characters+ // are /[a-z][0-9]-/.+ string vcs_connector_id = 3 [(google.api.field_behavior) = REQUIRED];+}++message GetVCSConnectorRequest {+ // The name of the vcsConnector to retrieve.+ // Format: projects/{project}/vcsConnectors/{vcsConnector}+ string name = 1 [(google.api.field_behavior) = REQUIRED];+}++message ListVCSConnectorsRequest {+ // The parent, which owns this collection of vcsConnectors.+ // Format: projects/{project}+ // Use "projects/-" to list all vcsConnectors.+ string parent = 1 [(google.api.field_behavior) = REQUIRED];++ // The maximum number of databases to return. The service may return fewer than+ // this value.+ // If unspecified, at most 50 databases will be returned.+ // The maximum value is 1000; values above 1000 will be coerced to 1000.+ int32 page_size = 2;++ // A page token, received from a previous `ListDatabases` call.+ // Provide this to retrieve the subsequent page.+ //+ // When paginating, all other parameters provided to `ListDatabases` must match+ // the call that provided the page token.+ string page_token = 3;+}++message ListVCSConnectorsResponse {+ // The vcsConnectors from the specified request.+ repeated VCSConnector vcs_connectors = 1;++ // A token, which can be sent as `page_token` to retrieve the next page.+ // If this field is omitted, there are no subsequent pages.+ string next_page_token = 2;+}++message UpdateVCSConnectorRequest {+ // The vcsConnector to update.+ //+ // The vcsConnector's `name` field is used to identify the vcsConnector to update.+ // Format: projects/{project}/vcsConnectors/{vcsConnector}+ VCSConnector vcs_connector = 1 [(google.api.field_behavior) = REQUIRED];++ // The list of fields to be updated.+ google.protobuf.FieldMask update_mask = 2;+}++message DeleteVCSConnectorRequest {+ // The name of the vcsConnector to delete.+ // Format: projects/{project}/vcsConnectors/{vcsConnector}+ string name = 1 [(google.api.field_behavior) = REQUIRED];+}++message VCSConnector {+ // The name of the vcsConnector resource.+ // Canonical parent is project.+ // Format: projects/{project}/vcsConnectors/{vcsConnector}+ string name = 1 [+ (google.api.field_behavior) = REQUIRED,+ (google.api.field_behavior) = IMMUTABLE+ ];++ // The title of the vcs connector.+ string title = 2;++ // The creator of the vcsConnector.+ // Format: users/{email}+ string creator = 3 [(google.api.field_behavior) = OUTPUT_ONLY];++ // The updater of the vcsConnector.+ // Format: users/{email}+ string updater = 4 [(google.api.field_behavior) = OUTPUT_ONLY];++ // The create time of the vcsConnector.+ google.protobuf.Timestamp create_time = 5 [(google.api.field_behavior) = OUTPUT_ONLY];++ // The last update time of the vcsConnector.+ google.protobuf.Timestamp update_time = 6 [(google.api.field_behavior) = OUTPUT_ONLY];++ // The name of the VCS.+ // Format: vcsProviders/{vcsProvider}+ string vcs_provider = 7;++ // The reposition external id in target VCS.+ string external_id = 8;++ // The root directory where Bytebase observes the file change. If empty, then it observes the entire repository.+ string base_directory = 9;++ // The branch Bytebase listens to for changes. For example: main.+ string branch = 10;++ // The webhook endpoint ID of the repository.+ string webhook_endpoint_id = 11 [(google.api.field_behavior) = OUTPUT_ONLY];++ // TODO(d): move these to create VCS connector API.+ // The full_path of the repository. For example: bytebase/sample.+ string full_path = 12;++ // The web url of the repository. For axample: https://gitlab.bytebase.com/bytebase/sample.+ string web_url = 13;+}