moons-ta-client 1.3.2 → 1.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/constants.d.ts +2 -2
- package/dist/constants.js +2 -2
- package/dist/custom-event-emitter.js +1 -1
- package/dist/index.d.ts +416 -5
- package/dist/index.esm.js +3368 -2083
- package/dist/models/models.d.ts +90 -0
- package/dist/models/models.js +199 -1
- package/dist/models/requests.d.ts +206 -0
- package/dist/models/requests.js +452 -1
- package/dist/models/responses.d.ts +113 -0
- package/dist/models/responses.js +250 -1
- package/dist/scraper.js +3 -4
- package/dist/tournament-assistant-client.d.ts +4 -1
- package/dist/tournament-assistant-client.js +42 -0
- package/package.json +4 -10
package/dist/models/requests.js
CHANGED
|
@@ -2,6 +2,7 @@ import { WireType } from "@protobuf-ts/runtime";
|
|
|
2
2
|
import { UnknownFieldHandler } from "@protobuf-ts/runtime";
|
|
3
3
|
import { reflectionMergePartial } from "@protobuf-ts/runtime";
|
|
4
4
|
import { MessageType } from "@protobuf-ts/runtime";
|
|
5
|
+
import { GlobalConfiguration } from './models.js';
|
|
5
6
|
import { GameplayParameters } from './models.js';
|
|
6
7
|
import { LeaderboardEntry } from './models.js';
|
|
7
8
|
import { CoreServer } from './models.js';
|
|
@@ -90,7 +91,10 @@ class Request$Type extends MessageType {
|
|
|
90
91
|
{ no: 69, name: "get_webhooks", kind: "message", oneof: "type", T: () => Request_GetWebhooks },
|
|
91
92
|
{ no: 70, name: "create_webhook", kind: "message", oneof: "type", T: () => Request_CreateWebhook },
|
|
92
93
|
{ no: 71, name: "update_webhook", kind: "message", oneof: "type", T: () => Request_UpdateWebhook },
|
|
93
|
-
{ no: 72, name: "delete_webhook", kind: "message", oneof: "type", T: () => Request_DeleteWebhook }
|
|
94
|
+
{ no: 72, name: "delete_webhook", kind: "message", oneof: "type", T: () => Request_DeleteWebhook },
|
|
95
|
+
{ no: 73, name: "get_global_configuration", kind: "message", oneof: "type", T: () => Request_GetGlobalConfiguration },
|
|
96
|
+
{ no: 74, name: "update_global_configuration", kind: "message", oneof: "type", T: () => Request_UpdateGlobalConfiguration },
|
|
97
|
+
{ no: 75, name: "set_bk_tournament_link", kind: "message", oneof: "type", T: () => Request_SetBKTournamentLink }
|
|
94
98
|
]);
|
|
95
99
|
}
|
|
96
100
|
create(value) {
|
|
@@ -525,6 +529,24 @@ class Request$Type extends MessageType {
|
|
|
525
529
|
deleteWebhook: Request_DeleteWebhook.internalBinaryRead(reader, reader.uint32(), options, message.type.deleteWebhook)
|
|
526
530
|
};
|
|
527
531
|
break;
|
|
532
|
+
case /* proto.packets.Request.GetGlobalConfiguration get_global_configuration */ 73:
|
|
533
|
+
message.type = {
|
|
534
|
+
oneofKind: "getGlobalConfiguration",
|
|
535
|
+
getGlobalConfiguration: Request_GetGlobalConfiguration.internalBinaryRead(reader, reader.uint32(), options, message.type.getGlobalConfiguration)
|
|
536
|
+
};
|
|
537
|
+
break;
|
|
538
|
+
case /* proto.packets.Request.UpdateGlobalConfiguration update_global_configuration */ 74:
|
|
539
|
+
message.type = {
|
|
540
|
+
oneofKind: "updateGlobalConfiguration",
|
|
541
|
+
updateGlobalConfiguration: Request_UpdateGlobalConfiguration.internalBinaryRead(reader, reader.uint32(), options, message.type.updateGlobalConfiguration)
|
|
542
|
+
};
|
|
543
|
+
break;
|
|
544
|
+
case /* proto.packets.Request.SetBKTournamentLink set_bk_tournament_link */ 75:
|
|
545
|
+
message.type = {
|
|
546
|
+
oneofKind: "setBkTournamentLink",
|
|
547
|
+
setBkTournamentLink: Request_SetBKTournamentLink.internalBinaryRead(reader, reader.uint32(), options, message.type.setBkTournamentLink)
|
|
548
|
+
};
|
|
549
|
+
break;
|
|
528
550
|
default:
|
|
529
551
|
let u = options.readUnknownField;
|
|
530
552
|
if (u === "throw")
|
|
@@ -747,6 +769,15 @@ class Request$Type extends MessageType {
|
|
|
747
769
|
/* proto.packets.Request.DeleteWebhook delete_webhook = 72; */
|
|
748
770
|
if (message.type.oneofKind === "deleteWebhook")
|
|
749
771
|
Request_DeleteWebhook.internalBinaryWrite(message.type.deleteWebhook, writer.tag(72, WireType.LengthDelimited).fork(), options).join();
|
|
772
|
+
/* proto.packets.Request.GetGlobalConfiguration get_global_configuration = 73; */
|
|
773
|
+
if (message.type.oneofKind === "getGlobalConfiguration")
|
|
774
|
+
Request_GetGlobalConfiguration.internalBinaryWrite(message.type.getGlobalConfiguration, writer.tag(73, WireType.LengthDelimited).fork(), options).join();
|
|
775
|
+
/* proto.packets.Request.UpdateGlobalConfiguration update_global_configuration = 74; */
|
|
776
|
+
if (message.type.oneofKind === "updateGlobalConfiguration")
|
|
777
|
+
Request_UpdateGlobalConfiguration.internalBinaryWrite(message.type.updateGlobalConfiguration, writer.tag(74, WireType.LengthDelimited).fork(), options).join();
|
|
778
|
+
/* proto.packets.Request.SetBKTournamentLink set_bk_tournament_link = 75; */
|
|
779
|
+
if (message.type.oneofKind === "setBkTournamentLink")
|
|
780
|
+
Request_SetBKTournamentLink.internalBinaryWrite(message.type.setBkTournamentLink, writer.tag(75, WireType.LengthDelimited).fork(), options).join();
|
|
750
781
|
let u = options.writeUnknownFields;
|
|
751
782
|
if (u !== false)
|
|
752
783
|
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
@@ -4982,3 +5013,423 @@ class Request_DeleteWebhook$Type extends MessageType {
|
|
|
4982
5013
|
* @generated MessageType for protobuf message proto.packets.Request.DeleteWebhook
|
|
4983
5014
|
*/
|
|
4984
5015
|
export const Request_DeleteWebhook = new Request_DeleteWebhook$Type();
|
|
5016
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
5017
|
+
class Request_GetGlobalConfiguration$Type extends MessageType {
|
|
5018
|
+
constructor() {
|
|
5019
|
+
super("proto.packets.Request.GetGlobalConfiguration", []);
|
|
5020
|
+
}
|
|
5021
|
+
create(value) {
|
|
5022
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
5023
|
+
if (value !== undefined)
|
|
5024
|
+
reflectionMergePartial(this, message, value);
|
|
5025
|
+
return message;
|
|
5026
|
+
}
|
|
5027
|
+
internalBinaryRead(reader, length, options, target) {
|
|
5028
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
5029
|
+
while (reader.pos < end) {
|
|
5030
|
+
let [fieldNo, wireType] = reader.tag();
|
|
5031
|
+
switch (fieldNo) {
|
|
5032
|
+
default:
|
|
5033
|
+
let u = options.readUnknownField;
|
|
5034
|
+
if (u === "throw")
|
|
5035
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
5036
|
+
let d = reader.skip(wireType);
|
|
5037
|
+
if (u !== false)
|
|
5038
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
5039
|
+
}
|
|
5040
|
+
}
|
|
5041
|
+
return message;
|
|
5042
|
+
}
|
|
5043
|
+
internalBinaryWrite(message, writer, options) {
|
|
5044
|
+
let u = options.writeUnknownFields;
|
|
5045
|
+
if (u !== false)
|
|
5046
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
5047
|
+
return writer;
|
|
5048
|
+
}
|
|
5049
|
+
}
|
|
5050
|
+
/**
|
|
5051
|
+
* @generated MessageType for protobuf message proto.packets.Request.GetGlobalConfiguration
|
|
5052
|
+
*/
|
|
5053
|
+
export const Request_GetGlobalConfiguration = new Request_GetGlobalConfiguration$Type();
|
|
5054
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
5055
|
+
class Request_UpdateGlobalConfiguration$Type extends MessageType {
|
|
5056
|
+
constructor() {
|
|
5057
|
+
super("proto.packets.Request.UpdateGlobalConfiguration", [
|
|
5058
|
+
{ no: 1, name: "configuration", kind: "message", T: () => GlobalConfiguration }
|
|
5059
|
+
]);
|
|
5060
|
+
}
|
|
5061
|
+
create(value) {
|
|
5062
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
5063
|
+
if (value !== undefined)
|
|
5064
|
+
reflectionMergePartial(this, message, value);
|
|
5065
|
+
return message;
|
|
5066
|
+
}
|
|
5067
|
+
internalBinaryRead(reader, length, options, target) {
|
|
5068
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
5069
|
+
while (reader.pos < end) {
|
|
5070
|
+
let [fieldNo, wireType] = reader.tag();
|
|
5071
|
+
switch (fieldNo) {
|
|
5072
|
+
case /* proto.models.GlobalConfiguration configuration */ 1:
|
|
5073
|
+
message.configuration = GlobalConfiguration.internalBinaryRead(reader, reader.uint32(), options, message.configuration);
|
|
5074
|
+
break;
|
|
5075
|
+
default:
|
|
5076
|
+
let u = options.readUnknownField;
|
|
5077
|
+
if (u === "throw")
|
|
5078
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
5079
|
+
let d = reader.skip(wireType);
|
|
5080
|
+
if (u !== false)
|
|
5081
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
5082
|
+
}
|
|
5083
|
+
}
|
|
5084
|
+
return message;
|
|
5085
|
+
}
|
|
5086
|
+
internalBinaryWrite(message, writer, options) {
|
|
5087
|
+
/* proto.models.GlobalConfiguration configuration = 1; */
|
|
5088
|
+
if (message.configuration)
|
|
5089
|
+
GlobalConfiguration.internalBinaryWrite(message.configuration, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
5090
|
+
let u = options.writeUnknownFields;
|
|
5091
|
+
if (u !== false)
|
|
5092
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
5093
|
+
return writer;
|
|
5094
|
+
}
|
|
5095
|
+
}
|
|
5096
|
+
/**
|
|
5097
|
+
* @generated MessageType for protobuf message proto.packets.Request.UpdateGlobalConfiguration
|
|
5098
|
+
*/
|
|
5099
|
+
export const Request_UpdateGlobalConfiguration = new Request_UpdateGlobalConfiguration$Type();
|
|
5100
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
5101
|
+
class Request_SetBKTournamentLink$Type extends MessageType {
|
|
5102
|
+
constructor() {
|
|
5103
|
+
super("proto.packets.Request.SetBKTournamentLink", [
|
|
5104
|
+
{ no: 1, name: "tournament_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
5105
|
+
{ no: 2, name: "is_bk_tournament", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
|
|
5106
|
+
{ no: 3, name: "beat_khana_tournament_guid", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
5107
|
+
]);
|
|
5108
|
+
}
|
|
5109
|
+
create(value) {
|
|
5110
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
5111
|
+
message.tournamentId = "";
|
|
5112
|
+
message.isBkTournament = false;
|
|
5113
|
+
message.beatKhanaTournamentGuid = "";
|
|
5114
|
+
if (value !== undefined)
|
|
5115
|
+
reflectionMergePartial(this, message, value);
|
|
5116
|
+
return message;
|
|
5117
|
+
}
|
|
5118
|
+
internalBinaryRead(reader, length, options, target) {
|
|
5119
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
5120
|
+
while (reader.pos < end) {
|
|
5121
|
+
let [fieldNo, wireType] = reader.tag();
|
|
5122
|
+
switch (fieldNo) {
|
|
5123
|
+
case /* string tournament_id */ 1:
|
|
5124
|
+
message.tournamentId = reader.string();
|
|
5125
|
+
break;
|
|
5126
|
+
case /* bool is_bk_tournament */ 2:
|
|
5127
|
+
message.isBkTournament = reader.bool();
|
|
5128
|
+
break;
|
|
5129
|
+
case /* string beat_khana_tournament_guid */ 3:
|
|
5130
|
+
message.beatKhanaTournamentGuid = reader.string();
|
|
5131
|
+
break;
|
|
5132
|
+
default:
|
|
5133
|
+
let u = options.readUnknownField;
|
|
5134
|
+
if (u === "throw")
|
|
5135
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
5136
|
+
let d = reader.skip(wireType);
|
|
5137
|
+
if (u !== false)
|
|
5138
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
5139
|
+
}
|
|
5140
|
+
}
|
|
5141
|
+
return message;
|
|
5142
|
+
}
|
|
5143
|
+
internalBinaryWrite(message, writer, options) {
|
|
5144
|
+
/* string tournament_id = 1; */
|
|
5145
|
+
if (message.tournamentId !== "")
|
|
5146
|
+
writer.tag(1, WireType.LengthDelimited).string(message.tournamentId);
|
|
5147
|
+
/* bool is_bk_tournament = 2; */
|
|
5148
|
+
if (message.isBkTournament !== false)
|
|
5149
|
+
writer.tag(2, WireType.Varint).bool(message.isBkTournament);
|
|
5150
|
+
/* string beat_khana_tournament_guid = 3; */
|
|
5151
|
+
if (message.beatKhanaTournamentGuid !== "")
|
|
5152
|
+
writer.tag(3, WireType.LengthDelimited).string(message.beatKhanaTournamentGuid);
|
|
5153
|
+
let u = options.writeUnknownFields;
|
|
5154
|
+
if (u !== false)
|
|
5155
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
5156
|
+
return writer;
|
|
5157
|
+
}
|
|
5158
|
+
}
|
|
5159
|
+
/**
|
|
5160
|
+
* @generated MessageType for protobuf message proto.packets.Request.SetBKTournamentLink
|
|
5161
|
+
*/
|
|
5162
|
+
export const Request_SetBKTournamentLink = new Request_SetBKTournamentLink$Type();
|
|
5163
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
5164
|
+
class Request_CreateBKTournament$Type extends MessageType {
|
|
5165
|
+
constructor() {
|
|
5166
|
+
super("proto.packets.Request.CreateBKTournament", [
|
|
5167
|
+
{ no: 1, name: "beat_khana_tournament_guid", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
5168
|
+
{ no: 2, name: "tournament", kind: "message", T: () => Tournament },
|
|
5169
|
+
{ no: 3, name: "organizer", kind: "message", T: () => Request_CreateBKTournament_BeatKhanaUser },
|
|
5170
|
+
{ no: 4, name: "organizer_permissions", kind: "scalar", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ },
|
|
5171
|
+
{ no: 5, name: "roles", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Role },
|
|
5172
|
+
{ no: 6, name: "authorized_users", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Request_CreateBKTournament_AuthorizedUser },
|
|
5173
|
+
{ no: 7, name: "webhooks", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Request_CreateBKTournament_WebhookRegistration }
|
|
5174
|
+
]);
|
|
5175
|
+
}
|
|
5176
|
+
create(value) {
|
|
5177
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
5178
|
+
message.beatKhanaTournamentGuid = "";
|
|
5179
|
+
message.organizerPermissions = [];
|
|
5180
|
+
message.roles = [];
|
|
5181
|
+
message.authorizedUsers = [];
|
|
5182
|
+
message.webhooks = [];
|
|
5183
|
+
if (value !== undefined)
|
|
5184
|
+
reflectionMergePartial(this, message, value);
|
|
5185
|
+
return message;
|
|
5186
|
+
}
|
|
5187
|
+
internalBinaryRead(reader, length, options, target) {
|
|
5188
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
5189
|
+
while (reader.pos < end) {
|
|
5190
|
+
let [fieldNo, wireType] = reader.tag();
|
|
5191
|
+
switch (fieldNo) {
|
|
5192
|
+
case /* string beat_khana_tournament_guid */ 1:
|
|
5193
|
+
message.beatKhanaTournamentGuid = reader.string();
|
|
5194
|
+
break;
|
|
5195
|
+
case /* proto.models.Tournament tournament */ 2:
|
|
5196
|
+
message.tournament = Tournament.internalBinaryRead(reader, reader.uint32(), options, message.tournament);
|
|
5197
|
+
break;
|
|
5198
|
+
case /* proto.packets.Request.CreateBKTournament.BeatKhanaUser organizer */ 3:
|
|
5199
|
+
message.organizer = Request_CreateBKTournament_BeatKhanaUser.internalBinaryRead(reader, reader.uint32(), options, message.organizer);
|
|
5200
|
+
break;
|
|
5201
|
+
case /* repeated string organizer_permissions */ 4:
|
|
5202
|
+
message.organizerPermissions.push(reader.string());
|
|
5203
|
+
break;
|
|
5204
|
+
case /* repeated proto.models.Role roles */ 5:
|
|
5205
|
+
message.roles.push(Role.internalBinaryRead(reader, reader.uint32(), options));
|
|
5206
|
+
break;
|
|
5207
|
+
case /* repeated proto.packets.Request.CreateBKTournament.AuthorizedUser authorized_users */ 6:
|
|
5208
|
+
message.authorizedUsers.push(Request_CreateBKTournament_AuthorizedUser.internalBinaryRead(reader, reader.uint32(), options));
|
|
5209
|
+
break;
|
|
5210
|
+
case /* repeated proto.packets.Request.CreateBKTournament.WebhookRegistration webhooks */ 7:
|
|
5211
|
+
message.webhooks.push(Request_CreateBKTournament_WebhookRegistration.internalBinaryRead(reader, reader.uint32(), options));
|
|
5212
|
+
break;
|
|
5213
|
+
default:
|
|
5214
|
+
let u = options.readUnknownField;
|
|
5215
|
+
if (u === "throw")
|
|
5216
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
5217
|
+
let d = reader.skip(wireType);
|
|
5218
|
+
if (u !== false)
|
|
5219
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
5220
|
+
}
|
|
5221
|
+
}
|
|
5222
|
+
return message;
|
|
5223
|
+
}
|
|
5224
|
+
internalBinaryWrite(message, writer, options) {
|
|
5225
|
+
/* string beat_khana_tournament_guid = 1; */
|
|
5226
|
+
if (message.beatKhanaTournamentGuid !== "")
|
|
5227
|
+
writer.tag(1, WireType.LengthDelimited).string(message.beatKhanaTournamentGuid);
|
|
5228
|
+
/* proto.models.Tournament tournament = 2; */
|
|
5229
|
+
if (message.tournament)
|
|
5230
|
+
Tournament.internalBinaryWrite(message.tournament, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
|
|
5231
|
+
/* proto.packets.Request.CreateBKTournament.BeatKhanaUser organizer = 3; */
|
|
5232
|
+
if (message.organizer)
|
|
5233
|
+
Request_CreateBKTournament_BeatKhanaUser.internalBinaryWrite(message.organizer, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
5234
|
+
/* repeated string organizer_permissions = 4; */
|
|
5235
|
+
for (let i = 0; i < message.organizerPermissions.length; i++)
|
|
5236
|
+
writer.tag(4, WireType.LengthDelimited).string(message.organizerPermissions[i]);
|
|
5237
|
+
/* repeated proto.models.Role roles = 5; */
|
|
5238
|
+
for (let i = 0; i < message.roles.length; i++)
|
|
5239
|
+
Role.internalBinaryWrite(message.roles[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
|
5240
|
+
/* repeated proto.packets.Request.CreateBKTournament.AuthorizedUser authorized_users = 6; */
|
|
5241
|
+
for (let i = 0; i < message.authorizedUsers.length; i++)
|
|
5242
|
+
Request_CreateBKTournament_AuthorizedUser.internalBinaryWrite(message.authorizedUsers[i], writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
|
5243
|
+
/* repeated proto.packets.Request.CreateBKTournament.WebhookRegistration webhooks = 7; */
|
|
5244
|
+
for (let i = 0; i < message.webhooks.length; i++)
|
|
5245
|
+
Request_CreateBKTournament_WebhookRegistration.internalBinaryWrite(message.webhooks[i], writer.tag(7, WireType.LengthDelimited).fork(), options).join();
|
|
5246
|
+
let u = options.writeUnknownFields;
|
|
5247
|
+
if (u !== false)
|
|
5248
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
5249
|
+
return writer;
|
|
5250
|
+
}
|
|
5251
|
+
}
|
|
5252
|
+
/**
|
|
5253
|
+
* @generated MessageType for protobuf message proto.packets.Request.CreateBKTournament
|
|
5254
|
+
*/
|
|
5255
|
+
export const Request_CreateBKTournament = new Request_CreateBKTournament$Type();
|
|
5256
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
5257
|
+
class Request_CreateBKTournament_BeatKhanaUser$Type extends MessageType {
|
|
5258
|
+
constructor() {
|
|
5259
|
+
super("proto.packets.Request.CreateBKTournament.BeatKhanaUser", [
|
|
5260
|
+
{ no: 1, name: "discord_id", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
5261
|
+
{ no: 2, name: "preferred_name", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
5262
|
+
{ no: 3, name: "avatar_url", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
5263
|
+
]);
|
|
5264
|
+
}
|
|
5265
|
+
create(value) {
|
|
5266
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
5267
|
+
message.discordId = "";
|
|
5268
|
+
message.preferredName = "";
|
|
5269
|
+
message.avatarUrl = "";
|
|
5270
|
+
if (value !== undefined)
|
|
5271
|
+
reflectionMergePartial(this, message, value);
|
|
5272
|
+
return message;
|
|
5273
|
+
}
|
|
5274
|
+
internalBinaryRead(reader, length, options, target) {
|
|
5275
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
5276
|
+
while (reader.pos < end) {
|
|
5277
|
+
let [fieldNo, wireType] = reader.tag();
|
|
5278
|
+
switch (fieldNo) {
|
|
5279
|
+
case /* string discord_id */ 1:
|
|
5280
|
+
message.discordId = reader.string();
|
|
5281
|
+
break;
|
|
5282
|
+
case /* string preferred_name */ 2:
|
|
5283
|
+
message.preferredName = reader.string();
|
|
5284
|
+
break;
|
|
5285
|
+
case /* string avatar_url */ 3:
|
|
5286
|
+
message.avatarUrl = reader.string();
|
|
5287
|
+
break;
|
|
5288
|
+
default:
|
|
5289
|
+
let u = options.readUnknownField;
|
|
5290
|
+
if (u === "throw")
|
|
5291
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
5292
|
+
let d = reader.skip(wireType);
|
|
5293
|
+
if (u !== false)
|
|
5294
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
5295
|
+
}
|
|
5296
|
+
}
|
|
5297
|
+
return message;
|
|
5298
|
+
}
|
|
5299
|
+
internalBinaryWrite(message, writer, options) {
|
|
5300
|
+
/* string discord_id = 1; */
|
|
5301
|
+
if (message.discordId !== "")
|
|
5302
|
+
writer.tag(1, WireType.LengthDelimited).string(message.discordId);
|
|
5303
|
+
/* string preferred_name = 2; */
|
|
5304
|
+
if (message.preferredName !== "")
|
|
5305
|
+
writer.tag(2, WireType.LengthDelimited).string(message.preferredName);
|
|
5306
|
+
/* string avatar_url = 3; */
|
|
5307
|
+
if (message.avatarUrl !== "")
|
|
5308
|
+
writer.tag(3, WireType.LengthDelimited).string(message.avatarUrl);
|
|
5309
|
+
let u = options.writeUnknownFields;
|
|
5310
|
+
if (u !== false)
|
|
5311
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
5312
|
+
return writer;
|
|
5313
|
+
}
|
|
5314
|
+
}
|
|
5315
|
+
/**
|
|
5316
|
+
* @generated MessageType for protobuf message proto.packets.Request.CreateBKTournament.BeatKhanaUser
|
|
5317
|
+
*/
|
|
5318
|
+
export const Request_CreateBKTournament_BeatKhanaUser = new Request_CreateBKTournament_BeatKhanaUser$Type();
|
|
5319
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
5320
|
+
class Request_CreateBKTournament_AuthorizedUser$Type extends MessageType {
|
|
5321
|
+
constructor() {
|
|
5322
|
+
super("proto.packets.Request.CreateBKTournament.AuthorizedUser", [
|
|
5323
|
+
{ no: 1, name: "user", kind: "message", T: () => Request_CreateBKTournament_BeatKhanaUser },
|
|
5324
|
+
{ no: 2, name: "role_ids", kind: "scalar", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ }
|
|
5325
|
+
]);
|
|
5326
|
+
}
|
|
5327
|
+
create(value) {
|
|
5328
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
5329
|
+
message.roleIds = [];
|
|
5330
|
+
if (value !== undefined)
|
|
5331
|
+
reflectionMergePartial(this, message, value);
|
|
5332
|
+
return message;
|
|
5333
|
+
}
|
|
5334
|
+
internalBinaryRead(reader, length, options, target) {
|
|
5335
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
5336
|
+
while (reader.pos < end) {
|
|
5337
|
+
let [fieldNo, wireType] = reader.tag();
|
|
5338
|
+
switch (fieldNo) {
|
|
5339
|
+
case /* proto.packets.Request.CreateBKTournament.BeatKhanaUser user */ 1:
|
|
5340
|
+
message.user = Request_CreateBKTournament_BeatKhanaUser.internalBinaryRead(reader, reader.uint32(), options, message.user);
|
|
5341
|
+
break;
|
|
5342
|
+
case /* repeated string role_ids */ 2:
|
|
5343
|
+
message.roleIds.push(reader.string());
|
|
5344
|
+
break;
|
|
5345
|
+
default:
|
|
5346
|
+
let u = options.readUnknownField;
|
|
5347
|
+
if (u === "throw")
|
|
5348
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
5349
|
+
let d = reader.skip(wireType);
|
|
5350
|
+
if (u !== false)
|
|
5351
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
5352
|
+
}
|
|
5353
|
+
}
|
|
5354
|
+
return message;
|
|
5355
|
+
}
|
|
5356
|
+
internalBinaryWrite(message, writer, options) {
|
|
5357
|
+
/* proto.packets.Request.CreateBKTournament.BeatKhanaUser user = 1; */
|
|
5358
|
+
if (message.user)
|
|
5359
|
+
Request_CreateBKTournament_BeatKhanaUser.internalBinaryWrite(message.user, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
5360
|
+
/* repeated string role_ids = 2; */
|
|
5361
|
+
for (let i = 0; i < message.roleIds.length; i++)
|
|
5362
|
+
writer.tag(2, WireType.LengthDelimited).string(message.roleIds[i]);
|
|
5363
|
+
let u = options.writeUnknownFields;
|
|
5364
|
+
if (u !== false)
|
|
5365
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
5366
|
+
return writer;
|
|
5367
|
+
}
|
|
5368
|
+
}
|
|
5369
|
+
/**
|
|
5370
|
+
* @generated MessageType for protobuf message proto.packets.Request.CreateBKTournament.AuthorizedUser
|
|
5371
|
+
*/
|
|
5372
|
+
export const Request_CreateBKTournament_AuthorizedUser = new Request_CreateBKTournament_AuthorizedUser$Type();
|
|
5373
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
5374
|
+
class Request_CreateBKTournament_WebhookRegistration$Type extends MessageType {
|
|
5375
|
+
constructor() {
|
|
5376
|
+
super("proto.packets.Request.CreateBKTournament.WebhookRegistration", [
|
|
5377
|
+
{ no: 1, name: "url", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
5378
|
+
{ no: 2, name: "triggers", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 0 /*LongType.BIGINT*/ },
|
|
5379
|
+
{ no: 3, name: "signing_secret", kind: "scalar", T: 9 /*ScalarType.STRING*/ }
|
|
5380
|
+
]);
|
|
5381
|
+
}
|
|
5382
|
+
create(value) {
|
|
5383
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
5384
|
+
message.url = "";
|
|
5385
|
+
message.triggers = 0n;
|
|
5386
|
+
message.signingSecret = "";
|
|
5387
|
+
if (value !== undefined)
|
|
5388
|
+
reflectionMergePartial(this, message, value);
|
|
5389
|
+
return message;
|
|
5390
|
+
}
|
|
5391
|
+
internalBinaryRead(reader, length, options, target) {
|
|
5392
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
5393
|
+
while (reader.pos < end) {
|
|
5394
|
+
let [fieldNo, wireType] = reader.tag();
|
|
5395
|
+
switch (fieldNo) {
|
|
5396
|
+
case /* string url */ 1:
|
|
5397
|
+
message.url = reader.string();
|
|
5398
|
+
break;
|
|
5399
|
+
case /* int64 triggers */ 2:
|
|
5400
|
+
message.triggers = reader.int64().toBigInt();
|
|
5401
|
+
break;
|
|
5402
|
+
case /* string signing_secret */ 3:
|
|
5403
|
+
message.signingSecret = reader.string();
|
|
5404
|
+
break;
|
|
5405
|
+
default:
|
|
5406
|
+
let u = options.readUnknownField;
|
|
5407
|
+
if (u === "throw")
|
|
5408
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
5409
|
+
let d = reader.skip(wireType);
|
|
5410
|
+
if (u !== false)
|
|
5411
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
5412
|
+
}
|
|
5413
|
+
}
|
|
5414
|
+
return message;
|
|
5415
|
+
}
|
|
5416
|
+
internalBinaryWrite(message, writer, options) {
|
|
5417
|
+
/* string url = 1; */
|
|
5418
|
+
if (message.url !== "")
|
|
5419
|
+
writer.tag(1, WireType.LengthDelimited).string(message.url);
|
|
5420
|
+
/* int64 triggers = 2; */
|
|
5421
|
+
if (message.triggers !== 0n)
|
|
5422
|
+
writer.tag(2, WireType.Varint).int64(message.triggers);
|
|
5423
|
+
/* string signing_secret = 3; */
|
|
5424
|
+
if (message.signingSecret !== "")
|
|
5425
|
+
writer.tag(3, WireType.LengthDelimited).string(message.signingSecret);
|
|
5426
|
+
let u = options.writeUnknownFields;
|
|
5427
|
+
if (u !== false)
|
|
5428
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
5429
|
+
return writer;
|
|
5430
|
+
}
|
|
5431
|
+
}
|
|
5432
|
+
/**
|
|
5433
|
+
* @generated MessageType for protobuf message proto.packets.Request.CreateBKTournament.WebhookRegistration
|
|
5434
|
+
*/
|
|
5435
|
+
export const Request_CreateBKTournament_WebhookRegistration = new Request_CreateBKTournament_WebhookRegistration$Type();
|
|
@@ -4,6 +4,7 @@ import type { BinaryReadOptions } from "@protobuf-ts/runtime";
|
|
|
4
4
|
import type { IBinaryReader } from "@protobuf-ts/runtime";
|
|
5
5
|
import type { PartialMessage } from "@protobuf-ts/runtime";
|
|
6
6
|
import { MessageType } from "@protobuf-ts/runtime";
|
|
7
|
+
import { GlobalConfiguration } from './models.js';
|
|
7
8
|
import { Webhook } from './models.js';
|
|
8
9
|
import { LeaderboardEntry } from './models.js';
|
|
9
10
|
import { State } from './models.js';
|
|
@@ -227,6 +228,30 @@ export interface Response {
|
|
|
227
228
|
* @generated from protobuf field: proto.packets.Response.DeleteWebhook delete_webhook = 35
|
|
228
229
|
*/
|
|
229
230
|
deleteWebhook: Response_DeleteWebhook;
|
|
231
|
+
} | {
|
|
232
|
+
oneofKind: "getGlobalConfiguration";
|
|
233
|
+
/**
|
|
234
|
+
* @generated from protobuf field: proto.packets.Response.GetGlobalConfiguration get_global_configuration = 36
|
|
235
|
+
*/
|
|
236
|
+
getGlobalConfiguration: Response_GetGlobalConfiguration;
|
|
237
|
+
} | {
|
|
238
|
+
oneofKind: "updateGlobalConfiguration";
|
|
239
|
+
/**
|
|
240
|
+
* @generated from protobuf field: proto.packets.Response.UpdateGlobalConfiguration update_global_configuration = 37
|
|
241
|
+
*/
|
|
242
|
+
updateGlobalConfiguration: Response_UpdateGlobalConfiguration;
|
|
243
|
+
} | {
|
|
244
|
+
oneofKind: "createBkTournament";
|
|
245
|
+
/**
|
|
246
|
+
* @generated from protobuf field: proto.packets.Response.CreateBKTournament create_bk_tournament = 38
|
|
247
|
+
*/
|
|
248
|
+
createBkTournament: Response_CreateBKTournament;
|
|
249
|
+
} | {
|
|
250
|
+
oneofKind: "setBkTournamentLink";
|
|
251
|
+
/**
|
|
252
|
+
* @generated from protobuf field: proto.packets.Response.SetBKTournamentLink set_bk_tournament_link = 39
|
|
253
|
+
*/
|
|
254
|
+
setBkTournamentLink: Response_SetBKTournamentLink;
|
|
230
255
|
} | {
|
|
231
256
|
oneofKind: undefined;
|
|
232
257
|
};
|
|
@@ -724,6 +749,54 @@ export interface Response_DeleteWebhook {
|
|
|
724
749
|
*/
|
|
725
750
|
message: string;
|
|
726
751
|
}
|
|
752
|
+
/**
|
|
753
|
+
* @generated from protobuf message proto.packets.Response.GetGlobalConfiguration
|
|
754
|
+
*/
|
|
755
|
+
export interface Response_GetGlobalConfiguration {
|
|
756
|
+
/**
|
|
757
|
+
* @generated from protobuf field: proto.models.GlobalConfiguration configuration = 1
|
|
758
|
+
*/
|
|
759
|
+
configuration?: GlobalConfiguration;
|
|
760
|
+
}
|
|
761
|
+
/**
|
|
762
|
+
* @generated from protobuf message proto.packets.Response.UpdateGlobalConfiguration
|
|
763
|
+
*/
|
|
764
|
+
export interface Response_UpdateGlobalConfiguration {
|
|
765
|
+
/**
|
|
766
|
+
* @generated from protobuf field: proto.models.GlobalConfiguration configuration = 1
|
|
767
|
+
*/
|
|
768
|
+
configuration?: GlobalConfiguration;
|
|
769
|
+
/**
|
|
770
|
+
* @generated from protobuf field: string message = 2
|
|
771
|
+
*/
|
|
772
|
+
message: string;
|
|
773
|
+
}
|
|
774
|
+
/**
|
|
775
|
+
* @generated from protobuf message proto.packets.Response.SetBKTournamentLink
|
|
776
|
+
*/
|
|
777
|
+
export interface Response_SetBKTournamentLink {
|
|
778
|
+
/**
|
|
779
|
+
* @generated from protobuf field: proto.models.Tournament tournament = 1
|
|
780
|
+
*/
|
|
781
|
+
tournament?: Tournament;
|
|
782
|
+
/**
|
|
783
|
+
* @generated from protobuf field: string message = 2
|
|
784
|
+
*/
|
|
785
|
+
message: string;
|
|
786
|
+
}
|
|
787
|
+
/**
|
|
788
|
+
* @generated from protobuf message proto.packets.Response.CreateBKTournament
|
|
789
|
+
*/
|
|
790
|
+
export interface Response_CreateBKTournament {
|
|
791
|
+
/**
|
|
792
|
+
* @generated from protobuf field: string beat_khana_tournament_guid = 1
|
|
793
|
+
*/
|
|
794
|
+
beatKhanaTournamentGuid: string;
|
|
795
|
+
/**
|
|
796
|
+
* @generated from protobuf field: proto.models.Tournament tournament = 2
|
|
797
|
+
*/
|
|
798
|
+
tournament?: Tournament;
|
|
799
|
+
}
|
|
727
800
|
/**
|
|
728
801
|
* @generated from protobuf enum proto.packets.Response.ResponseType
|
|
729
802
|
*/
|
|
@@ -1097,4 +1170,44 @@ declare class Response_DeleteWebhook$Type extends MessageType<Response_DeleteWeb
|
|
|
1097
1170
|
* @generated MessageType for protobuf message proto.packets.Response.DeleteWebhook
|
|
1098
1171
|
*/
|
|
1099
1172
|
export declare const Response_DeleteWebhook: Response_DeleteWebhook$Type;
|
|
1173
|
+
declare class Response_GetGlobalConfiguration$Type extends MessageType<Response_GetGlobalConfiguration> {
|
|
1174
|
+
constructor();
|
|
1175
|
+
create(value?: PartialMessage<Response_GetGlobalConfiguration>): Response_GetGlobalConfiguration;
|
|
1176
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Response_GetGlobalConfiguration): Response_GetGlobalConfiguration;
|
|
1177
|
+
internalBinaryWrite(message: Response_GetGlobalConfiguration, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
1178
|
+
}
|
|
1179
|
+
/**
|
|
1180
|
+
* @generated MessageType for protobuf message proto.packets.Response.GetGlobalConfiguration
|
|
1181
|
+
*/
|
|
1182
|
+
export declare const Response_GetGlobalConfiguration: Response_GetGlobalConfiguration$Type;
|
|
1183
|
+
declare class Response_UpdateGlobalConfiguration$Type extends MessageType<Response_UpdateGlobalConfiguration> {
|
|
1184
|
+
constructor();
|
|
1185
|
+
create(value?: PartialMessage<Response_UpdateGlobalConfiguration>): Response_UpdateGlobalConfiguration;
|
|
1186
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Response_UpdateGlobalConfiguration): Response_UpdateGlobalConfiguration;
|
|
1187
|
+
internalBinaryWrite(message: Response_UpdateGlobalConfiguration, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
1188
|
+
}
|
|
1189
|
+
/**
|
|
1190
|
+
* @generated MessageType for protobuf message proto.packets.Response.UpdateGlobalConfiguration
|
|
1191
|
+
*/
|
|
1192
|
+
export declare const Response_UpdateGlobalConfiguration: Response_UpdateGlobalConfiguration$Type;
|
|
1193
|
+
declare class Response_SetBKTournamentLink$Type extends MessageType<Response_SetBKTournamentLink> {
|
|
1194
|
+
constructor();
|
|
1195
|
+
create(value?: PartialMessage<Response_SetBKTournamentLink>): Response_SetBKTournamentLink;
|
|
1196
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Response_SetBKTournamentLink): Response_SetBKTournamentLink;
|
|
1197
|
+
internalBinaryWrite(message: Response_SetBKTournamentLink, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
1198
|
+
}
|
|
1199
|
+
/**
|
|
1200
|
+
* @generated MessageType for protobuf message proto.packets.Response.SetBKTournamentLink
|
|
1201
|
+
*/
|
|
1202
|
+
export declare const Response_SetBKTournamentLink: Response_SetBKTournamentLink$Type;
|
|
1203
|
+
declare class Response_CreateBKTournament$Type extends MessageType<Response_CreateBKTournament> {
|
|
1204
|
+
constructor();
|
|
1205
|
+
create(value?: PartialMessage<Response_CreateBKTournament>): Response_CreateBKTournament;
|
|
1206
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Response_CreateBKTournament): Response_CreateBKTournament;
|
|
1207
|
+
internalBinaryWrite(message: Response_CreateBKTournament, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
1208
|
+
}
|
|
1209
|
+
/**
|
|
1210
|
+
* @generated MessageType for protobuf message proto.packets.Response.CreateBKTournament
|
|
1211
|
+
*/
|
|
1212
|
+
export declare const Response_CreateBKTournament: Response_CreateBKTournament$Type;
|
|
1100
1213
|
export {};
|