jr-common-micro 1.1.133 → 1.1.134

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.
@@ -95,6 +95,26 @@ export interface TaskInfo {
95
95
  reopened: boolean;
96
96
  requirement: string;
97
97
  last_done_at: string;
98
+ template: string;
99
+ description: string;
100
+ icon: string;
101
+ icon_image: string;
102
+ url: string;
103
+ target: string;
104
+ button_text: string;
105
+ blocks: TaskBlock[];
106
+ effect_days: number;
107
+ ends_at: string;
108
+ test: boolean;
109
+ }
110
+ export interface TaskBlock {
111
+ type: string;
112
+ title: string;
113
+ body: string;
114
+ button_text: string;
115
+ button_url: string;
116
+ button_target: string;
117
+ items: string[];
98
118
  }
99
119
  export interface TasksSummary {
100
120
  done: number;
@@ -360,14 +380,153 @@ export interface AdminTaskItem {
360
380
  titles: {
361
381
  [key: string]: string;
362
382
  };
383
+ completers: number;
384
+ template: string;
385
+ state: string;
386
+ descriptions: {
387
+ [key: string]: string;
388
+ };
389
+ button_texts: {
390
+ [key: string]: string;
391
+ };
392
+ icon: string;
393
+ icon_image: string;
394
+ url: string;
395
+ target: string;
396
+ blocks: AdminTaskBlock[];
397
+ effect_days: number;
398
+ starts_at: string;
399
+ ends_at: string;
400
+ published_at: string;
363
401
  }
364
402
  export interface AdminTaskItem_TitlesEntry {
365
403
  key: string;
366
404
  value: string;
367
405
  }
406
+ export interface AdminTaskItem_DescriptionsEntry {
407
+ key: string;
408
+ value: string;
409
+ }
410
+ export interface AdminTaskItem_ButtonTextsEntry {
411
+ key: string;
412
+ value: string;
413
+ }
414
+ export interface LocalizedText {
415
+ values: {
416
+ [key: string]: string;
417
+ };
418
+ }
419
+ export interface LocalizedText_ValuesEntry {
420
+ key: string;
421
+ value: string;
422
+ }
423
+ export interface AdminTaskBlock {
424
+ type: string;
425
+ title: {
426
+ [key: string]: string;
427
+ };
428
+ body: {
429
+ [key: string]: string;
430
+ };
431
+ button_text: {
432
+ [key: string]: string;
433
+ };
434
+ button_url: string;
435
+ button_target: string;
436
+ items: LocalizedText[];
437
+ }
438
+ export interface AdminTaskBlock_TitleEntry {
439
+ key: string;
440
+ value: string;
441
+ }
442
+ export interface AdminTaskBlock_BodyEntry {
443
+ key: string;
444
+ value: string;
445
+ }
446
+ export interface AdminTaskBlock_ButtonTextEntry {
447
+ key: string;
448
+ value: string;
449
+ }
368
450
  export interface AdminTasksResponse {
369
451
  status: ResponseStatus | undefined;
370
452
  data: AdminTaskItem[];
453
+ saved_id: string;
454
+ }
455
+ export interface AdminSaveTaskRequest {
456
+ id: string;
457
+ template: string;
458
+ kind: string;
459
+ multiplier: string;
460
+ titles: {
461
+ [key: string]: string;
462
+ };
463
+ descriptions: {
464
+ [key: string]: string;
465
+ };
466
+ button_texts: {
467
+ [key: string]: string;
468
+ };
469
+ icon: string;
470
+ icon_image: string;
471
+ url: string;
472
+ target: string;
473
+ blocks: AdminTaskBlock[];
474
+ effect_days: number;
475
+ starts_at: string;
476
+ ends_at: string;
477
+ }
478
+ export interface AdminSaveTaskRequest_TitlesEntry {
479
+ key: string;
480
+ value: string;
481
+ }
482
+ export interface AdminSaveTaskRequest_DescriptionsEntry {
483
+ key: string;
484
+ value: string;
485
+ }
486
+ export interface AdminSaveTaskRequest_ButtonTextsEntry {
487
+ key: string;
488
+ value: string;
489
+ }
490
+ export interface AdminTaskActionRequest {
491
+ id: string;
492
+ action: string;
493
+ }
494
+ export interface AdminTranslateItem {
495
+ key: string;
496
+ tr: string;
497
+ en: string;
498
+ max: number;
499
+ paragraph: boolean;
500
+ }
501
+ export interface AdminTranslateRequest {
502
+ items: AdminTranslateItem[];
503
+ }
504
+ export interface AdminTranslatedItem {
505
+ key: string;
506
+ values: {
507
+ [key: string]: string;
508
+ };
509
+ }
510
+ export interface AdminTranslatedItem_ValuesEntry {
511
+ key: string;
512
+ value: string;
513
+ }
514
+ export interface AdminTranslateResponse {
515
+ status: ResponseStatus | undefined;
516
+ data: AdminTranslatedItem[];
517
+ }
518
+ export interface AdminUploadTaskIconRequest {
519
+ data: Buffer;
520
+ mimetype: string;
521
+ }
522
+ export interface AdminUploadTaskIconResponse {
523
+ status: ResponseStatus | undefined;
524
+ id: string;
525
+ }
526
+ export interface TaskIconResponse {
527
+ status: ResponseStatus | undefined;
528
+ data: Buffer;
529
+ mimetype: string;
371
530
  }
372
531
  export interface AdminUsersRequest {
373
532
  query: string;
@@ -152,6 +152,17 @@ export declare class TaskInfo extends Message<TaskInfo> {
152
152
  reopened: boolean;
153
153
  requirement: string;
154
154
  lastDoneAt: string;
155
+ template: string;
156
+ description: string;
157
+ icon: string;
158
+ iconImage: string;
159
+ url: string;
160
+ target: string;
161
+ buttonText: string;
162
+ blocks: TaskBlock[];
163
+ effectDays: number;
164
+ endsAt: string;
165
+ test: boolean;
155
166
  constructor(data?: PartialMessage<TaskInfo>);
156
167
  static readonly runtime: typeof proto3;
157
168
  static readonly typeName = "micro.v1.mining.TaskInfo";
@@ -161,6 +172,23 @@ export declare class TaskInfo extends Message<TaskInfo> {
161
172
  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): TaskInfo;
162
173
  static equals(a: TaskInfo | PlainMessage<TaskInfo> | undefined, b: TaskInfo | PlainMessage<TaskInfo> | undefined): boolean;
163
174
  }
175
+ export declare class TaskBlock extends Message<TaskBlock> {
176
+ type: string;
177
+ title: string;
178
+ body: string;
179
+ buttonText: string;
180
+ buttonUrl: string;
181
+ buttonTarget: string;
182
+ items: string[];
183
+ constructor(data?: PartialMessage<TaskBlock>);
184
+ static readonly runtime: typeof proto3;
185
+ static readonly typeName = "micro.v1.mining.TaskBlock";
186
+ static readonly fields: FieldList;
187
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): TaskBlock;
188
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): TaskBlock;
189
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): TaskBlock;
190
+ static equals(a: TaskBlock | PlainMessage<TaskBlock> | undefined, b: TaskBlock | PlainMessage<TaskBlock> | undefined): boolean;
191
+ }
164
192
  export declare class TasksSummary extends Message<TasksSummary> {
165
193
  done: number;
166
194
  total: number;
@@ -729,6 +757,24 @@ export declare class AdminTaskItem extends Message<AdminTaskItem> {
729
757
  titles: {
730
758
  [key: string]: string;
731
759
  };
760
+ completers: number;
761
+ template: string;
762
+ state: string;
763
+ descriptions: {
764
+ [key: string]: string;
765
+ };
766
+ buttonTexts: {
767
+ [key: string]: string;
768
+ };
769
+ icon: string;
770
+ iconImage: string;
771
+ url: string;
772
+ target: string;
773
+ blocks: AdminTaskBlock[];
774
+ effectDays: number;
775
+ startsAt: string;
776
+ endsAt: string;
777
+ publishedAt: string;
732
778
  constructor(data?: PartialMessage<AdminTaskItem>);
733
779
  static readonly runtime: typeof proto3;
734
780
  static readonly typeName = "micro.v1.mining.AdminTaskItem";
@@ -738,9 +784,46 @@ export declare class AdminTaskItem extends Message<AdminTaskItem> {
738
784
  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminTaskItem;
739
785
  static equals(a: AdminTaskItem | PlainMessage<AdminTaskItem> | undefined, b: AdminTaskItem | PlainMessage<AdminTaskItem> | undefined): boolean;
740
786
  }
787
+ export declare class LocalizedText extends Message<LocalizedText> {
788
+ values: {
789
+ [key: string]: string;
790
+ };
791
+ constructor(data?: PartialMessage<LocalizedText>);
792
+ static readonly runtime: typeof proto3;
793
+ static readonly typeName = "micro.v1.mining.LocalizedText";
794
+ static readonly fields: FieldList;
795
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): LocalizedText;
796
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): LocalizedText;
797
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): LocalizedText;
798
+ static equals(a: LocalizedText | PlainMessage<LocalizedText> | undefined, b: LocalizedText | PlainMessage<LocalizedText> | undefined): boolean;
799
+ }
800
+ export declare class AdminTaskBlock extends Message<AdminTaskBlock> {
801
+ type: string;
802
+ title: {
803
+ [key: string]: string;
804
+ };
805
+ body: {
806
+ [key: string]: string;
807
+ };
808
+ buttonText: {
809
+ [key: string]: string;
810
+ };
811
+ buttonUrl: string;
812
+ buttonTarget: string;
813
+ items: LocalizedText[];
814
+ constructor(data?: PartialMessage<AdminTaskBlock>);
815
+ static readonly runtime: typeof proto3;
816
+ static readonly typeName = "micro.v1.mining.AdminTaskBlock";
817
+ static readonly fields: FieldList;
818
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminTaskBlock;
819
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminTaskBlock;
820
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminTaskBlock;
821
+ static equals(a: AdminTaskBlock | PlainMessage<AdminTaskBlock> | undefined, b: AdminTaskBlock | PlainMessage<AdminTaskBlock> | undefined): boolean;
822
+ }
741
823
  export declare class AdminTasksResponse extends Message<AdminTasksResponse> {
742
824
  status?: ResponseStatus;
743
825
  data: AdminTaskItem[];
826
+ savedId: string;
744
827
  constructor(data?: PartialMessage<AdminTasksResponse>);
745
828
  static readonly runtime: typeof proto3;
746
829
  static readonly typeName = "micro.v1.mining.AdminTasksResponse";
@@ -750,6 +833,138 @@ export declare class AdminTasksResponse extends Message<AdminTasksResponse> {
750
833
  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminTasksResponse;
751
834
  static equals(a: AdminTasksResponse | PlainMessage<AdminTasksResponse> | undefined, b: AdminTasksResponse | PlainMessage<AdminTasksResponse> | undefined): boolean;
752
835
  }
836
+ export declare class AdminSaveTaskRequest extends Message<AdminSaveTaskRequest> {
837
+ id: string;
838
+ template: string;
839
+ kind: string;
840
+ multiplier: string;
841
+ titles: {
842
+ [key: string]: string;
843
+ };
844
+ descriptions: {
845
+ [key: string]: string;
846
+ };
847
+ buttonTexts: {
848
+ [key: string]: string;
849
+ };
850
+ icon: string;
851
+ iconImage: string;
852
+ url: string;
853
+ target: string;
854
+ blocks: AdminTaskBlock[];
855
+ effectDays: number;
856
+ startsAt: string;
857
+ endsAt: string;
858
+ constructor(data?: PartialMessage<AdminSaveTaskRequest>);
859
+ static readonly runtime: typeof proto3;
860
+ static readonly typeName = "micro.v1.mining.AdminSaveTaskRequest";
861
+ static readonly fields: FieldList;
862
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminSaveTaskRequest;
863
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminSaveTaskRequest;
864
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminSaveTaskRequest;
865
+ static equals(a: AdminSaveTaskRequest | PlainMessage<AdminSaveTaskRequest> | undefined, b: AdminSaveTaskRequest | PlainMessage<AdminSaveTaskRequest> | undefined): boolean;
866
+ }
867
+ export declare class AdminTaskActionRequest extends Message<AdminTaskActionRequest> {
868
+ id: string;
869
+ action: string;
870
+ constructor(data?: PartialMessage<AdminTaskActionRequest>);
871
+ static readonly runtime: typeof proto3;
872
+ static readonly typeName = "micro.v1.mining.AdminTaskActionRequest";
873
+ static readonly fields: FieldList;
874
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminTaskActionRequest;
875
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminTaskActionRequest;
876
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminTaskActionRequest;
877
+ static equals(a: AdminTaskActionRequest | PlainMessage<AdminTaskActionRequest> | undefined, b: AdminTaskActionRequest | PlainMessage<AdminTaskActionRequest> | undefined): boolean;
878
+ }
879
+ export declare class AdminTranslateItem extends Message<AdminTranslateItem> {
880
+ key: string;
881
+ tr: string;
882
+ en: string;
883
+ max: number;
884
+ paragraph: boolean;
885
+ constructor(data?: PartialMessage<AdminTranslateItem>);
886
+ static readonly runtime: typeof proto3;
887
+ static readonly typeName = "micro.v1.mining.AdminTranslateItem";
888
+ static readonly fields: FieldList;
889
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminTranslateItem;
890
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminTranslateItem;
891
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminTranslateItem;
892
+ static equals(a: AdminTranslateItem | PlainMessage<AdminTranslateItem> | undefined, b: AdminTranslateItem | PlainMessage<AdminTranslateItem> | undefined): boolean;
893
+ }
894
+ export declare class AdminTranslateRequest extends Message<AdminTranslateRequest> {
895
+ items: AdminTranslateItem[];
896
+ constructor(data?: PartialMessage<AdminTranslateRequest>);
897
+ static readonly runtime: typeof proto3;
898
+ static readonly typeName = "micro.v1.mining.AdminTranslateRequest";
899
+ static readonly fields: FieldList;
900
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminTranslateRequest;
901
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminTranslateRequest;
902
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminTranslateRequest;
903
+ static equals(a: AdminTranslateRequest | PlainMessage<AdminTranslateRequest> | undefined, b: AdminTranslateRequest | PlainMessage<AdminTranslateRequest> | undefined): boolean;
904
+ }
905
+ export declare class AdminTranslatedItem extends Message<AdminTranslatedItem> {
906
+ key: string;
907
+ values: {
908
+ [key: string]: string;
909
+ };
910
+ constructor(data?: PartialMessage<AdminTranslatedItem>);
911
+ static readonly runtime: typeof proto3;
912
+ static readonly typeName = "micro.v1.mining.AdminTranslatedItem";
913
+ static readonly fields: FieldList;
914
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminTranslatedItem;
915
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminTranslatedItem;
916
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminTranslatedItem;
917
+ static equals(a: AdminTranslatedItem | PlainMessage<AdminTranslatedItem> | undefined, b: AdminTranslatedItem | PlainMessage<AdminTranslatedItem> | undefined): boolean;
918
+ }
919
+ export declare class AdminTranslateResponse extends Message<AdminTranslateResponse> {
920
+ status?: ResponseStatus;
921
+ data: AdminTranslatedItem[];
922
+ constructor(data?: PartialMessage<AdminTranslateResponse>);
923
+ static readonly runtime: typeof proto3;
924
+ static readonly typeName = "micro.v1.mining.AdminTranslateResponse";
925
+ static readonly fields: FieldList;
926
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminTranslateResponse;
927
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminTranslateResponse;
928
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminTranslateResponse;
929
+ static equals(a: AdminTranslateResponse | PlainMessage<AdminTranslateResponse> | undefined, b: AdminTranslateResponse | PlainMessage<AdminTranslateResponse> | undefined): boolean;
930
+ }
931
+ export declare class AdminUploadTaskIconRequest extends Message<AdminUploadTaskIconRequest> {
932
+ data: Uint8Array<ArrayBuffer>;
933
+ mimetype: string;
934
+ constructor(data?: PartialMessage<AdminUploadTaskIconRequest>);
935
+ static readonly runtime: typeof proto3;
936
+ static readonly typeName = "micro.v1.mining.AdminUploadTaskIconRequest";
937
+ static readonly fields: FieldList;
938
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminUploadTaskIconRequest;
939
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminUploadTaskIconRequest;
940
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminUploadTaskIconRequest;
941
+ static equals(a: AdminUploadTaskIconRequest | PlainMessage<AdminUploadTaskIconRequest> | undefined, b: AdminUploadTaskIconRequest | PlainMessage<AdminUploadTaskIconRequest> | undefined): boolean;
942
+ }
943
+ export declare class AdminUploadTaskIconResponse extends Message<AdminUploadTaskIconResponse> {
944
+ status?: ResponseStatus;
945
+ id: string;
946
+ constructor(data?: PartialMessage<AdminUploadTaskIconResponse>);
947
+ static readonly runtime: typeof proto3;
948
+ static readonly typeName = "micro.v1.mining.AdminUploadTaskIconResponse";
949
+ static readonly fields: FieldList;
950
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AdminUploadTaskIconResponse;
951
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AdminUploadTaskIconResponse;
952
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AdminUploadTaskIconResponse;
953
+ static equals(a: AdminUploadTaskIconResponse | PlainMessage<AdminUploadTaskIconResponse> | undefined, b: AdminUploadTaskIconResponse | PlainMessage<AdminUploadTaskIconResponse> | undefined): boolean;
954
+ }
955
+ export declare class TaskIconResponse extends Message<TaskIconResponse> {
956
+ status?: ResponseStatus;
957
+ data: Uint8Array<ArrayBuffer>;
958
+ mimetype: string;
959
+ constructor(data?: PartialMessage<TaskIconResponse>);
960
+ static readonly runtime: typeof proto3;
961
+ static readonly typeName = "micro.v1.mining.TaskIconResponse";
962
+ static readonly fields: FieldList;
963
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): TaskIconResponse;
964
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): TaskIconResponse;
965
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): TaskIconResponse;
966
+ static equals(a: TaskIconResponse | PlainMessage<TaskIconResponse> | undefined, b: TaskIconResponse | PlainMessage<TaskIconResponse> | undefined): boolean;
967
+ }
753
968
  export declare class AdminUsersRequest extends Message<AdminUsersRequest> {
754
969
  query: string;
755
970
  status: string;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.AdminUserItem = exports.AdminUsersRequest = exports.AdminTasksResponse = exports.AdminTaskItem = exports.SetParameterRequest = exports.ParametersResponse = exports.ParameterItem = exports.AdminSendReportResponse = exports.AdminOverviewResponse = exports.AdminTopEarnersResponse = exports.AdminTopEarner = exports.AdminTopReferrersResponse = exports.AdminTopReferrersRequest = exports.AdminTopReferrer = exports.AdminTaskStat = exports.AdminSeries = exports.AdminSeriesPoint = exports.AdminMetric = exports.AdminOverviewRequest = exports.ConfigResponse = exports.ResolveCodeResponse = exports.ResolveCodeRequest = exports.EnrollResponse = exports.EnrollRequest = exports.UpdateSettingsRequest = exports.HistoryResponse = exports.HistoryDay = exports.HistoryItem = exports.HistoryRequest = exports.TeamResponse = exports.SetTeamRequest = exports.ClaimResponse = exports.ReferralListResponse = exports.ReferralListRequest = exports.ReferralItem = exports.TaskEventResponse = exports.TaskEventRequest = exports.TasksResponse = exports.MiningMeResponse = exports.MiningState = exports.MiningSettings = exports.TasksSummary = exports.TaskInfo = exports.TeamInfo = exports.TeamWeek = exports.TeamMember = exports.ReferralInfo = exports.HalvingInfo = exports.RateInfo = exports.SessionInfo = void 0;
4
- exports.AdminGiftsResponse = exports.AdminGiftsRequest = exports.AdminGiftResponse = exports.AdminGift = exports.AdminGiftConfirmRequest = exports.AdminGiftPreviewResponse = exports.AdminGiftRecipient = exports.AdminGiftPreviewRequest = exports.AdminSetTaskRequest = exports.AdminDeviceClustersResponse = exports.AdminDeviceCluster = exports.AdminDeviceClustersRequest = exports.AdminModerateRequest = exports.AdminCreditSource = exports.AdminRiskQueueResponse = exports.AdminRiskQueueRequest = exports.AdminInviteTreeResponse = exports.AdminInviteTreeNode = exports.AdminRiskFlag = exports.AdminRiskSignalStat = exports.AdminRiskSignal = exports.AdminTeamSeat = exports.AdminUserResponse = exports.AdminActionItem = exports.AdminUsersResponse = void 0;
3
+ exports.AdminTaskBlock = exports.LocalizedText = exports.AdminTaskItem = exports.SetParameterRequest = exports.ParametersResponse = exports.ParameterItem = exports.AdminSendReportResponse = exports.AdminOverviewResponse = exports.AdminTopEarnersResponse = exports.AdminTopEarner = exports.AdminTopReferrersResponse = exports.AdminTopReferrersRequest = exports.AdminTopReferrer = exports.AdminTaskStat = exports.AdminSeries = exports.AdminSeriesPoint = exports.AdminMetric = exports.AdminOverviewRequest = exports.ConfigResponse = exports.ResolveCodeResponse = exports.ResolveCodeRequest = exports.EnrollResponse = exports.EnrollRequest = exports.UpdateSettingsRequest = exports.HistoryResponse = exports.HistoryDay = exports.HistoryItem = exports.HistoryRequest = exports.TeamResponse = exports.SetTeamRequest = exports.ClaimResponse = exports.ReferralListResponse = exports.ReferralListRequest = exports.ReferralItem = exports.TaskEventResponse = exports.TaskEventRequest = exports.TasksResponse = exports.MiningMeResponse = exports.MiningState = exports.MiningSettings = exports.TasksSummary = exports.TaskBlock = exports.TaskInfo = exports.TeamInfo = exports.TeamWeek = exports.TeamMember = exports.ReferralInfo = exports.HalvingInfo = exports.RateInfo = exports.SessionInfo = void 0;
4
+ exports.AdminGiftsResponse = exports.AdminGiftsRequest = exports.AdminGiftResponse = exports.AdminGift = exports.AdminGiftConfirmRequest = exports.AdminGiftPreviewResponse = exports.AdminGiftRecipient = exports.AdminGiftPreviewRequest = exports.AdminSetTaskRequest = exports.AdminDeviceClustersResponse = exports.AdminDeviceCluster = exports.AdminDeviceClustersRequest = exports.AdminModerateRequest = exports.AdminCreditSource = exports.AdminRiskQueueResponse = exports.AdminRiskQueueRequest = exports.AdminInviteTreeResponse = exports.AdminInviteTreeNode = exports.AdminRiskFlag = exports.AdminRiskSignalStat = exports.AdminRiskSignal = exports.AdminTeamSeat = exports.AdminUserResponse = exports.AdminActionItem = exports.AdminUsersResponse = exports.AdminUserItem = exports.AdminUsersRequest = exports.TaskIconResponse = exports.AdminUploadTaskIconResponse = exports.AdminUploadTaskIconRequest = exports.AdminTranslateResponse = exports.AdminTranslatedItem = exports.AdminTranslateRequest = exports.AdminTranslateItem = exports.AdminTaskActionRequest = exports.AdminSaveTaskRequest = exports.AdminTasksResponse = void 0;
5
5
  const protobuf_1 = require("@bufbuild/protobuf");
6
6
  const general_pb_js_1 = require("../general_pb.js");
7
7
  class SessionInfo extends protobuf_1.Message {
@@ -311,6 +311,17 @@ class TaskInfo extends protobuf_1.Message {
311
311
  reopened = false;
312
312
  requirement = "";
313
313
  lastDoneAt = "";
314
+ template = "";
315
+ description = "";
316
+ icon = "";
317
+ iconImage = "";
318
+ url = "";
319
+ target = "";
320
+ buttonText = "";
321
+ blocks = [];
322
+ effectDays = 0;
323
+ endsAt = "";
324
+ test = false;
314
325
  constructor(data) {
315
326
  super();
316
327
  protobuf_1.proto3.util.initPartial(data, this);
@@ -333,6 +344,17 @@ class TaskInfo extends protobuf_1.Message {
333
344
  { no: 13, name: "reopened", kind: "scalar", T: 8 },
334
345
  { no: 14, name: "requirement", kind: "scalar", T: 9 },
335
346
  { no: 15, name: "last_done_at", kind: "scalar", T: 9 },
347
+ { no: 16, name: "template", kind: "scalar", T: 9 },
348
+ { no: 17, name: "description", kind: "scalar", T: 9 },
349
+ { no: 18, name: "icon", kind: "scalar", T: 9 },
350
+ { no: 19, name: "icon_image", kind: "scalar", T: 9 },
351
+ { no: 20, name: "url", kind: "scalar", T: 9 },
352
+ { no: 21, name: "target", kind: "scalar", T: 9 },
353
+ { no: 22, name: "button_text", kind: "scalar", T: 9 },
354
+ { no: 23, name: "blocks", kind: "message", T: TaskBlock, repeated: true },
355
+ { no: 24, name: "effect_days", kind: "scalar", T: 5 },
356
+ { no: 25, name: "ends_at", kind: "scalar", T: 9 },
357
+ { no: 26, name: "test", kind: "scalar", T: 8 },
336
358
  ]);
337
359
  static fromBinary(bytes, options) {
338
360
  return new TaskInfo().fromBinary(bytes, options);
@@ -348,6 +370,43 @@ class TaskInfo extends protobuf_1.Message {
348
370
  }
349
371
  }
350
372
  exports.TaskInfo = TaskInfo;
373
+ class TaskBlock extends protobuf_1.Message {
374
+ type = "";
375
+ title = "";
376
+ body = "";
377
+ buttonText = "";
378
+ buttonUrl = "";
379
+ buttonTarget = "";
380
+ items = [];
381
+ constructor(data) {
382
+ super();
383
+ protobuf_1.proto3.util.initPartial(data, this);
384
+ }
385
+ static runtime = protobuf_1.proto3;
386
+ static typeName = "micro.v1.mining.TaskBlock";
387
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
388
+ { no: 1, name: "type", kind: "scalar", T: 9 },
389
+ { no: 2, name: "title", kind: "scalar", T: 9 },
390
+ { no: 3, name: "body", kind: "scalar", T: 9 },
391
+ { no: 4, name: "button_text", kind: "scalar", T: 9 },
392
+ { no: 5, name: "button_url", kind: "scalar", T: 9 },
393
+ { no: 6, name: "button_target", kind: "scalar", T: 9 },
394
+ { no: 7, name: "items", kind: "scalar", T: 9, repeated: true },
395
+ ]);
396
+ static fromBinary(bytes, options) {
397
+ return new TaskBlock().fromBinary(bytes, options);
398
+ }
399
+ static fromJson(jsonValue, options) {
400
+ return new TaskBlock().fromJson(jsonValue, options);
401
+ }
402
+ static fromJsonString(jsonString, options) {
403
+ return new TaskBlock().fromJsonString(jsonString, options);
404
+ }
405
+ static equals(a, b) {
406
+ return protobuf_1.proto3.util.equals(TaskBlock, a, b);
407
+ }
408
+ }
409
+ exports.TaskBlock = TaskBlock;
351
410
  class TasksSummary extends protobuf_1.Message {
352
411
  done = 0;
353
412
  total = 0;
@@ -1580,6 +1639,20 @@ class AdminTaskItem extends protobuf_1.Message {
1580
1639
  completions7d = 0;
1581
1640
  parentId = "";
1582
1641
  titles = {};
1642
+ completers = 0;
1643
+ template = "";
1644
+ state = "";
1645
+ descriptions = {};
1646
+ buttonTexts = {};
1647
+ icon = "";
1648
+ iconImage = "";
1649
+ url = "";
1650
+ target = "";
1651
+ blocks = [];
1652
+ effectDays = 0;
1653
+ startsAt = "";
1654
+ endsAt = "";
1655
+ publishedAt = "";
1583
1656
  constructor(data) {
1584
1657
  super();
1585
1658
  protobuf_1.proto3.util.initPartial(data, this);
@@ -1600,6 +1673,20 @@ class AdminTaskItem extends protobuf_1.Message {
1600
1673
  { no: 11, name: "completions_7d", kind: "scalar", T: 5 },
1601
1674
  { no: 13, name: "parent_id", kind: "scalar", T: 9 },
1602
1675
  { no: 12, name: "titles", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1676
+ { no: 14, name: "completers", kind: "scalar", T: 5 },
1677
+ { no: 15, name: "template", kind: "scalar", T: 9 },
1678
+ { no: 16, name: "state", kind: "scalar", T: 9 },
1679
+ { no: 17, name: "descriptions", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1680
+ { no: 18, name: "button_texts", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1681
+ { no: 19, name: "icon", kind: "scalar", T: 9 },
1682
+ { no: 20, name: "icon_image", kind: "scalar", T: 9 },
1683
+ { no: 21, name: "url", kind: "scalar", T: 9 },
1684
+ { no: 22, name: "target", kind: "scalar", T: 9 },
1685
+ { no: 23, name: "blocks", kind: "message", T: AdminTaskBlock, repeated: true },
1686
+ { no: 24, name: "effect_days", kind: "scalar", T: 5 },
1687
+ { no: 25, name: "starts_at", kind: "scalar", T: 9 },
1688
+ { no: 26, name: "ends_at", kind: "scalar", T: 9 },
1689
+ { no: 27, name: "published_at", kind: "scalar", T: 9 },
1603
1690
  ]);
1604
1691
  static fromBinary(bytes, options) {
1605
1692
  return new AdminTaskItem().fromBinary(bytes, options);
@@ -1615,9 +1702,72 @@ class AdminTaskItem extends protobuf_1.Message {
1615
1702
  }
1616
1703
  }
1617
1704
  exports.AdminTaskItem = AdminTaskItem;
1705
+ class LocalizedText extends protobuf_1.Message {
1706
+ values = {};
1707
+ constructor(data) {
1708
+ super();
1709
+ protobuf_1.proto3.util.initPartial(data, this);
1710
+ }
1711
+ static runtime = protobuf_1.proto3;
1712
+ static typeName = "micro.v1.mining.LocalizedText";
1713
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1714
+ { no: 1, name: "values", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1715
+ ]);
1716
+ static fromBinary(bytes, options) {
1717
+ return new LocalizedText().fromBinary(bytes, options);
1718
+ }
1719
+ static fromJson(jsonValue, options) {
1720
+ return new LocalizedText().fromJson(jsonValue, options);
1721
+ }
1722
+ static fromJsonString(jsonString, options) {
1723
+ return new LocalizedText().fromJsonString(jsonString, options);
1724
+ }
1725
+ static equals(a, b) {
1726
+ return protobuf_1.proto3.util.equals(LocalizedText, a, b);
1727
+ }
1728
+ }
1729
+ exports.LocalizedText = LocalizedText;
1730
+ class AdminTaskBlock extends protobuf_1.Message {
1731
+ type = "";
1732
+ title = {};
1733
+ body = {};
1734
+ buttonText = {};
1735
+ buttonUrl = "";
1736
+ buttonTarget = "";
1737
+ items = [];
1738
+ constructor(data) {
1739
+ super();
1740
+ protobuf_1.proto3.util.initPartial(data, this);
1741
+ }
1742
+ static runtime = protobuf_1.proto3;
1743
+ static typeName = "micro.v1.mining.AdminTaskBlock";
1744
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1745
+ { no: 1, name: "type", kind: "scalar", T: 9 },
1746
+ { no: 2, name: "title", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1747
+ { no: 3, name: "body", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1748
+ { no: 4, name: "button_text", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1749
+ { no: 5, name: "button_url", kind: "scalar", T: 9 },
1750
+ { no: 6, name: "button_target", kind: "scalar", T: 9 },
1751
+ { no: 7, name: "items", kind: "message", T: LocalizedText, repeated: true },
1752
+ ]);
1753
+ static fromBinary(bytes, options) {
1754
+ return new AdminTaskBlock().fromBinary(bytes, options);
1755
+ }
1756
+ static fromJson(jsonValue, options) {
1757
+ return new AdminTaskBlock().fromJson(jsonValue, options);
1758
+ }
1759
+ static fromJsonString(jsonString, options) {
1760
+ return new AdminTaskBlock().fromJsonString(jsonString, options);
1761
+ }
1762
+ static equals(a, b) {
1763
+ return protobuf_1.proto3.util.equals(AdminTaskBlock, a, b);
1764
+ }
1765
+ }
1766
+ exports.AdminTaskBlock = AdminTaskBlock;
1618
1767
  class AdminTasksResponse extends protobuf_1.Message {
1619
1768
  status;
1620
1769
  data = [];
1770
+ savedId = "";
1621
1771
  constructor(data) {
1622
1772
  super();
1623
1773
  protobuf_1.proto3.util.initPartial(data, this);
@@ -1627,6 +1777,7 @@ class AdminTasksResponse extends protobuf_1.Message {
1627
1777
  static fields = protobuf_1.proto3.util.newFieldList(() => [
1628
1778
  { no: 1, name: "status", kind: "message", T: general_pb_js_1.ResponseStatus },
1629
1779
  { no: 2, name: "data", kind: "message", T: AdminTaskItem, repeated: true },
1780
+ { no: 3, name: "saved_id", kind: "scalar", T: 9 },
1630
1781
  ]);
1631
1782
  static fromBinary(bytes, options) {
1632
1783
  return new AdminTasksResponse().fromBinary(bytes, options);
@@ -1642,6 +1793,281 @@ class AdminTasksResponse extends protobuf_1.Message {
1642
1793
  }
1643
1794
  }
1644
1795
  exports.AdminTasksResponse = AdminTasksResponse;
1796
+ class AdminSaveTaskRequest extends protobuf_1.Message {
1797
+ id = "";
1798
+ template = "";
1799
+ kind = "";
1800
+ multiplier = "";
1801
+ titles = {};
1802
+ descriptions = {};
1803
+ buttonTexts = {};
1804
+ icon = "";
1805
+ iconImage = "";
1806
+ url = "";
1807
+ target = "";
1808
+ blocks = [];
1809
+ effectDays = 0;
1810
+ startsAt = "";
1811
+ endsAt = "";
1812
+ constructor(data) {
1813
+ super();
1814
+ protobuf_1.proto3.util.initPartial(data, this);
1815
+ }
1816
+ static runtime = protobuf_1.proto3;
1817
+ static typeName = "micro.v1.mining.AdminSaveTaskRequest";
1818
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1819
+ { no: 1, name: "id", kind: "scalar", T: 9 },
1820
+ { no: 2, name: "template", kind: "scalar", T: 9 },
1821
+ { no: 3, name: "kind", kind: "scalar", T: 9 },
1822
+ { no: 4, name: "multiplier", kind: "scalar", T: 9 },
1823
+ { no: 5, name: "titles", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1824
+ { no: 6, name: "descriptions", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1825
+ { no: 7, name: "button_texts", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1826
+ { no: 8, name: "icon", kind: "scalar", T: 9 },
1827
+ { no: 9, name: "icon_image", kind: "scalar", T: 9 },
1828
+ { no: 10, name: "url", kind: "scalar", T: 9 },
1829
+ { no: 11, name: "target", kind: "scalar", T: 9 },
1830
+ { no: 12, name: "blocks", kind: "message", T: AdminTaskBlock, repeated: true },
1831
+ { no: 13, name: "effect_days", kind: "scalar", T: 5 },
1832
+ { no: 14, name: "starts_at", kind: "scalar", T: 9 },
1833
+ { no: 15, name: "ends_at", kind: "scalar", T: 9 },
1834
+ ]);
1835
+ static fromBinary(bytes, options) {
1836
+ return new AdminSaveTaskRequest().fromBinary(bytes, options);
1837
+ }
1838
+ static fromJson(jsonValue, options) {
1839
+ return new AdminSaveTaskRequest().fromJson(jsonValue, options);
1840
+ }
1841
+ static fromJsonString(jsonString, options) {
1842
+ return new AdminSaveTaskRequest().fromJsonString(jsonString, options);
1843
+ }
1844
+ static equals(a, b) {
1845
+ return protobuf_1.proto3.util.equals(AdminSaveTaskRequest, a, b);
1846
+ }
1847
+ }
1848
+ exports.AdminSaveTaskRequest = AdminSaveTaskRequest;
1849
+ class AdminTaskActionRequest extends protobuf_1.Message {
1850
+ id = "";
1851
+ action = "";
1852
+ constructor(data) {
1853
+ super();
1854
+ protobuf_1.proto3.util.initPartial(data, this);
1855
+ }
1856
+ static runtime = protobuf_1.proto3;
1857
+ static typeName = "micro.v1.mining.AdminTaskActionRequest";
1858
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1859
+ { no: 1, name: "id", kind: "scalar", T: 9 },
1860
+ { no: 2, name: "action", kind: "scalar", T: 9 },
1861
+ ]);
1862
+ static fromBinary(bytes, options) {
1863
+ return new AdminTaskActionRequest().fromBinary(bytes, options);
1864
+ }
1865
+ static fromJson(jsonValue, options) {
1866
+ return new AdminTaskActionRequest().fromJson(jsonValue, options);
1867
+ }
1868
+ static fromJsonString(jsonString, options) {
1869
+ return new AdminTaskActionRequest().fromJsonString(jsonString, options);
1870
+ }
1871
+ static equals(a, b) {
1872
+ return protobuf_1.proto3.util.equals(AdminTaskActionRequest, a, b);
1873
+ }
1874
+ }
1875
+ exports.AdminTaskActionRequest = AdminTaskActionRequest;
1876
+ class AdminTranslateItem extends protobuf_1.Message {
1877
+ key = "";
1878
+ tr = "";
1879
+ en = "";
1880
+ max = 0;
1881
+ paragraph = false;
1882
+ constructor(data) {
1883
+ super();
1884
+ protobuf_1.proto3.util.initPartial(data, this);
1885
+ }
1886
+ static runtime = protobuf_1.proto3;
1887
+ static typeName = "micro.v1.mining.AdminTranslateItem";
1888
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1889
+ { no: 1, name: "key", kind: "scalar", T: 9 },
1890
+ { no: 2, name: "tr", kind: "scalar", T: 9 },
1891
+ { no: 3, name: "en", kind: "scalar", T: 9 },
1892
+ { no: 4, name: "max", kind: "scalar", T: 5 },
1893
+ { no: 5, name: "paragraph", kind: "scalar", T: 8 },
1894
+ ]);
1895
+ static fromBinary(bytes, options) {
1896
+ return new AdminTranslateItem().fromBinary(bytes, options);
1897
+ }
1898
+ static fromJson(jsonValue, options) {
1899
+ return new AdminTranslateItem().fromJson(jsonValue, options);
1900
+ }
1901
+ static fromJsonString(jsonString, options) {
1902
+ return new AdminTranslateItem().fromJsonString(jsonString, options);
1903
+ }
1904
+ static equals(a, b) {
1905
+ return protobuf_1.proto3.util.equals(AdminTranslateItem, a, b);
1906
+ }
1907
+ }
1908
+ exports.AdminTranslateItem = AdminTranslateItem;
1909
+ class AdminTranslateRequest extends protobuf_1.Message {
1910
+ items = [];
1911
+ constructor(data) {
1912
+ super();
1913
+ protobuf_1.proto3.util.initPartial(data, this);
1914
+ }
1915
+ static runtime = protobuf_1.proto3;
1916
+ static typeName = "micro.v1.mining.AdminTranslateRequest";
1917
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1918
+ { no: 1, name: "items", kind: "message", T: AdminTranslateItem, repeated: true },
1919
+ ]);
1920
+ static fromBinary(bytes, options) {
1921
+ return new AdminTranslateRequest().fromBinary(bytes, options);
1922
+ }
1923
+ static fromJson(jsonValue, options) {
1924
+ return new AdminTranslateRequest().fromJson(jsonValue, options);
1925
+ }
1926
+ static fromJsonString(jsonString, options) {
1927
+ return new AdminTranslateRequest().fromJsonString(jsonString, options);
1928
+ }
1929
+ static equals(a, b) {
1930
+ return protobuf_1.proto3.util.equals(AdminTranslateRequest, a, b);
1931
+ }
1932
+ }
1933
+ exports.AdminTranslateRequest = AdminTranslateRequest;
1934
+ class AdminTranslatedItem extends protobuf_1.Message {
1935
+ key = "";
1936
+ values = {};
1937
+ constructor(data) {
1938
+ super();
1939
+ protobuf_1.proto3.util.initPartial(data, this);
1940
+ }
1941
+ static runtime = protobuf_1.proto3;
1942
+ static typeName = "micro.v1.mining.AdminTranslatedItem";
1943
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1944
+ { no: 1, name: "key", kind: "scalar", T: 9 },
1945
+ { no: 2, name: "values", kind: "map", K: 9, V: { kind: "scalar", T: 9 } },
1946
+ ]);
1947
+ static fromBinary(bytes, options) {
1948
+ return new AdminTranslatedItem().fromBinary(bytes, options);
1949
+ }
1950
+ static fromJson(jsonValue, options) {
1951
+ return new AdminTranslatedItem().fromJson(jsonValue, options);
1952
+ }
1953
+ static fromJsonString(jsonString, options) {
1954
+ return new AdminTranslatedItem().fromJsonString(jsonString, options);
1955
+ }
1956
+ static equals(a, b) {
1957
+ return protobuf_1.proto3.util.equals(AdminTranslatedItem, a, b);
1958
+ }
1959
+ }
1960
+ exports.AdminTranslatedItem = AdminTranslatedItem;
1961
+ class AdminTranslateResponse extends protobuf_1.Message {
1962
+ status;
1963
+ data = [];
1964
+ constructor(data) {
1965
+ super();
1966
+ protobuf_1.proto3.util.initPartial(data, this);
1967
+ }
1968
+ static runtime = protobuf_1.proto3;
1969
+ static typeName = "micro.v1.mining.AdminTranslateResponse";
1970
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1971
+ { no: 1, name: "status", kind: "message", T: general_pb_js_1.ResponseStatus },
1972
+ { no: 2, name: "data", kind: "message", T: AdminTranslatedItem, repeated: true },
1973
+ ]);
1974
+ static fromBinary(bytes, options) {
1975
+ return new AdminTranslateResponse().fromBinary(bytes, options);
1976
+ }
1977
+ static fromJson(jsonValue, options) {
1978
+ return new AdminTranslateResponse().fromJson(jsonValue, options);
1979
+ }
1980
+ static fromJsonString(jsonString, options) {
1981
+ return new AdminTranslateResponse().fromJsonString(jsonString, options);
1982
+ }
1983
+ static equals(a, b) {
1984
+ return protobuf_1.proto3.util.equals(AdminTranslateResponse, a, b);
1985
+ }
1986
+ }
1987
+ exports.AdminTranslateResponse = AdminTranslateResponse;
1988
+ class AdminUploadTaskIconRequest extends protobuf_1.Message {
1989
+ data = new Uint8Array(0);
1990
+ mimetype = "";
1991
+ constructor(data) {
1992
+ super();
1993
+ protobuf_1.proto3.util.initPartial(data, this);
1994
+ }
1995
+ static runtime = protobuf_1.proto3;
1996
+ static typeName = "micro.v1.mining.AdminUploadTaskIconRequest";
1997
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
1998
+ { no: 1, name: "data", kind: "scalar", T: 12 },
1999
+ { no: 2, name: "mimetype", kind: "scalar", T: 9 },
2000
+ ]);
2001
+ static fromBinary(bytes, options) {
2002
+ return new AdminUploadTaskIconRequest().fromBinary(bytes, options);
2003
+ }
2004
+ static fromJson(jsonValue, options) {
2005
+ return new AdminUploadTaskIconRequest().fromJson(jsonValue, options);
2006
+ }
2007
+ static fromJsonString(jsonString, options) {
2008
+ return new AdminUploadTaskIconRequest().fromJsonString(jsonString, options);
2009
+ }
2010
+ static equals(a, b) {
2011
+ return protobuf_1.proto3.util.equals(AdminUploadTaskIconRequest, a, b);
2012
+ }
2013
+ }
2014
+ exports.AdminUploadTaskIconRequest = AdminUploadTaskIconRequest;
2015
+ class AdminUploadTaskIconResponse extends protobuf_1.Message {
2016
+ status;
2017
+ id = "";
2018
+ constructor(data) {
2019
+ super();
2020
+ protobuf_1.proto3.util.initPartial(data, this);
2021
+ }
2022
+ static runtime = protobuf_1.proto3;
2023
+ static typeName = "micro.v1.mining.AdminUploadTaskIconResponse";
2024
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
2025
+ { no: 1, name: "status", kind: "message", T: general_pb_js_1.ResponseStatus },
2026
+ { no: 2, name: "id", kind: "scalar", T: 9 },
2027
+ ]);
2028
+ static fromBinary(bytes, options) {
2029
+ return new AdminUploadTaskIconResponse().fromBinary(bytes, options);
2030
+ }
2031
+ static fromJson(jsonValue, options) {
2032
+ return new AdminUploadTaskIconResponse().fromJson(jsonValue, options);
2033
+ }
2034
+ static fromJsonString(jsonString, options) {
2035
+ return new AdminUploadTaskIconResponse().fromJsonString(jsonString, options);
2036
+ }
2037
+ static equals(a, b) {
2038
+ return protobuf_1.proto3.util.equals(AdminUploadTaskIconResponse, a, b);
2039
+ }
2040
+ }
2041
+ exports.AdminUploadTaskIconResponse = AdminUploadTaskIconResponse;
2042
+ class TaskIconResponse extends protobuf_1.Message {
2043
+ status;
2044
+ data = new Uint8Array(0);
2045
+ mimetype = "";
2046
+ constructor(data) {
2047
+ super();
2048
+ protobuf_1.proto3.util.initPartial(data, this);
2049
+ }
2050
+ static runtime = protobuf_1.proto3;
2051
+ static typeName = "micro.v1.mining.TaskIconResponse";
2052
+ static fields = protobuf_1.proto3.util.newFieldList(() => [
2053
+ { no: 1, name: "status", kind: "message", T: general_pb_js_1.ResponseStatus },
2054
+ { no: 2, name: "data", kind: "scalar", T: 12 },
2055
+ { no: 3, name: "mimetype", kind: "scalar", T: 9 },
2056
+ ]);
2057
+ static fromBinary(bytes, options) {
2058
+ return new TaskIconResponse().fromBinary(bytes, options);
2059
+ }
2060
+ static fromJson(jsonValue, options) {
2061
+ return new TaskIconResponse().fromJson(jsonValue, options);
2062
+ }
2063
+ static fromJsonString(jsonString, options) {
2064
+ return new TaskIconResponse().fromJsonString(jsonString, options);
2065
+ }
2066
+ static equals(a, b) {
2067
+ return protobuf_1.proto3.util.equals(TaskIconResponse, a, b);
2068
+ }
2069
+ }
2070
+ exports.TaskIconResponse = TaskIconResponse;
1645
2071
  class AdminUsersRequest extends protobuf_1.Message {
1646
2072
  query = "";
1647
2073
  status = "";
@@ -1,5 +1,5 @@
1
1
  import { ByIdRequest, EmptyRequest, EmptyResponse } from "../general_pb.js";
2
- import { AdminDeviceClustersRequest, AdminDeviceClustersResponse, AdminGiftConfirmRequest, AdminGiftPreviewRequest, AdminGiftPreviewResponse, AdminGiftResponse, AdminGiftsRequest, AdminGiftsResponse, AdminInviteTreeResponse, AdminModerateRequest, AdminOverviewRequest, AdminOverviewResponse, AdminRiskQueueRequest, AdminRiskQueueResponse, AdminSendReportResponse, AdminSetTaskRequest, AdminTasksResponse, AdminTopEarnersResponse, AdminTopReferrersRequest, AdminTopReferrersResponse, AdminUserResponse, AdminUsersRequest, AdminUsersResponse, ClaimResponse, ConfigResponse, EnrollRequest, EnrollResponse, HistoryRequest, HistoryResponse, MiningMeResponse, ParametersResponse, ReferralListRequest, ReferralListResponse, ResolveCodeRequest, ResolveCodeResponse, SetParameterRequest, SetTeamRequest, TaskEventRequest, TaskEventResponse, TasksResponse, TeamResponse, UpdateSettingsRequest } from "./mining_messages_pb.js";
2
+ import { AdminDeviceClustersRequest, AdminDeviceClustersResponse, AdminGiftConfirmRequest, AdminGiftPreviewRequest, AdminGiftPreviewResponse, AdminGiftResponse, AdminGiftsRequest, AdminGiftsResponse, AdminInviteTreeResponse, AdminModerateRequest, AdminOverviewRequest, AdminOverviewResponse, AdminRiskQueueRequest, AdminRiskQueueResponse, AdminSaveTaskRequest, AdminSendReportResponse, AdminSetTaskRequest, AdminTaskActionRequest, AdminTasksResponse, AdminTopEarnersResponse, AdminTopReferrersRequest, AdminTopReferrersResponse, AdminTranslateRequest, AdminTranslateResponse, AdminUploadTaskIconRequest, AdminUploadTaskIconResponse, AdminUserResponse, AdminUsersRequest, AdminUsersResponse, ClaimResponse, ConfigResponse, EnrollRequest, EnrollResponse, HistoryRequest, HistoryResponse, MiningMeResponse, ParametersResponse, ReferralListRequest, ReferralListResponse, ResolveCodeRequest, ResolveCodeResponse, SetParameterRequest, SetTeamRequest, TaskEventRequest, TaskEventResponse, TaskIconResponse, TasksResponse, TeamResponse, UpdateSettingsRequest } from "./mining_messages_pb.js";
3
3
  import { MethodKind } from "@bufbuild/protobuf";
4
4
  export declare const PMiningService: {
5
5
  readonly typeName: "micro.v1.mining.PMiningService";
@@ -142,6 +142,36 @@ export declare const PMiningService: {
142
142
  readonly O: typeof AdminTasksResponse;
143
143
  readonly kind: MethodKind.ServerStreaming;
144
144
  };
145
+ readonly adminSaveTask: {
146
+ readonly name: "AdminSaveTask";
147
+ readonly I: typeof AdminSaveTaskRequest;
148
+ readonly O: typeof AdminTasksResponse;
149
+ readonly kind: MethodKind.ServerStreaming;
150
+ };
151
+ readonly adminTaskAction: {
152
+ readonly name: "AdminTaskAction";
153
+ readonly I: typeof AdminTaskActionRequest;
154
+ readonly O: typeof AdminTasksResponse;
155
+ readonly kind: MethodKind.ServerStreaming;
156
+ };
157
+ readonly adminTranslateTask: {
158
+ readonly name: "AdminTranslateTask";
159
+ readonly I: typeof AdminTranslateRequest;
160
+ readonly O: typeof AdminTranslateResponse;
161
+ readonly kind: MethodKind.ServerStreaming;
162
+ };
163
+ readonly adminUploadTaskIcon: {
164
+ readonly name: "AdminUploadTaskIcon";
165
+ readonly I: typeof AdminUploadTaskIconRequest;
166
+ readonly O: typeof AdminUploadTaskIconResponse;
167
+ readonly kind: MethodKind.ServerStreaming;
168
+ };
169
+ readonly taskIcon: {
170
+ readonly name: "TaskIcon";
171
+ readonly I: typeof ByIdRequest;
172
+ readonly O: typeof TaskIconResponse;
173
+ readonly kind: MethodKind.ServerStreaming;
174
+ };
145
175
  readonly adminUsers: {
146
176
  readonly name: "AdminUsers";
147
177
  readonly I: typeof AdminUsersRequest;
@@ -145,6 +145,36 @@ exports.PMiningService = {
145
145
  O: mining_messages_pb_js_1.AdminTasksResponse,
146
146
  kind: protobuf_1.MethodKind.ServerStreaming,
147
147
  },
148
+ adminSaveTask: {
149
+ name: "AdminSaveTask",
150
+ I: mining_messages_pb_js_1.AdminSaveTaskRequest,
151
+ O: mining_messages_pb_js_1.AdminTasksResponse,
152
+ kind: protobuf_1.MethodKind.ServerStreaming,
153
+ },
154
+ adminTaskAction: {
155
+ name: "AdminTaskAction",
156
+ I: mining_messages_pb_js_1.AdminTaskActionRequest,
157
+ O: mining_messages_pb_js_1.AdminTasksResponse,
158
+ kind: protobuf_1.MethodKind.ServerStreaming,
159
+ },
160
+ adminTranslateTask: {
161
+ name: "AdminTranslateTask",
162
+ I: mining_messages_pb_js_1.AdminTranslateRequest,
163
+ O: mining_messages_pb_js_1.AdminTranslateResponse,
164
+ kind: protobuf_1.MethodKind.ServerStreaming,
165
+ },
166
+ adminUploadTaskIcon: {
167
+ name: "AdminUploadTaskIcon",
168
+ I: mining_messages_pb_js_1.AdminUploadTaskIconRequest,
169
+ O: mining_messages_pb_js_1.AdminUploadTaskIconResponse,
170
+ kind: protobuf_1.MethodKind.ServerStreaming,
171
+ },
172
+ taskIcon: {
173
+ name: "TaskIcon",
174
+ I: general_pb_js_1.ByIdRequest,
175
+ O: mining_messages_pb_js_1.TaskIconResponse,
176
+ kind: protobuf_1.MethodKind.ServerStreaming,
177
+ },
148
178
  adminUsers: {
149
179
  name: "AdminUsers",
150
180
  I: mining_messages_pb_js_1.AdminUsersRequest,
@@ -1,7 +1,7 @@
1
1
  import type { Metadata } from "@grpc/grpc-js";
2
2
  import { Observable } from "rxjs";
3
3
  import { ByIdRequest, EmptyRequest, EmptyResponse } from "../general_nest";
4
- import { AdminDeviceClustersRequest, AdminDeviceClustersResponse, AdminGiftConfirmRequest, AdminGiftPreviewRequest, AdminGiftPreviewResponse, AdminGiftResponse, AdminGiftsRequest, AdminGiftsResponse, AdminInviteTreeResponse, AdminModerateRequest, AdminOverviewRequest, AdminOverviewResponse, AdminRiskQueueRequest, AdminRiskQueueResponse, AdminSendReportResponse, AdminSetTaskRequest, AdminTasksResponse, AdminTopEarnersResponse, AdminTopReferrersRequest, AdminTopReferrersResponse, AdminUserResponse, AdminUsersRequest, AdminUsersResponse, ClaimResponse, ConfigResponse, EnrollRequest, EnrollResponse, HistoryRequest, HistoryResponse, MiningMeResponse, ParametersResponse, ReferralListRequest, ReferralListResponse, ResolveCodeRequest, ResolveCodeResponse, SetParameterRequest, SetTeamRequest, TaskEventRequest, TaskEventResponse, TasksResponse, TeamResponse, UpdateSettingsRequest } from "./mining_messages_nest";
4
+ import { AdminDeviceClustersRequest, AdminDeviceClustersResponse, AdminGiftConfirmRequest, AdminGiftPreviewRequest, AdminGiftPreviewResponse, AdminGiftResponse, AdminGiftsRequest, AdminGiftsResponse, AdminInviteTreeResponse, AdminModerateRequest, AdminOverviewRequest, AdminOverviewResponse, AdminRiskQueueRequest, AdminRiskQueueResponse, AdminSaveTaskRequest, AdminSendReportResponse, AdminSetTaskRequest, AdminTaskActionRequest, AdminTasksResponse, AdminTopEarnersResponse, AdminTopReferrersRequest, AdminTopReferrersResponse, AdminTranslateRequest, AdminTranslateResponse, AdminUploadTaskIconRequest, AdminUploadTaskIconResponse, AdminUserResponse, AdminUsersRequest, AdminUsersResponse, ClaimResponse, ConfigResponse, EnrollRequest, EnrollResponse, HistoryRequest, HistoryResponse, MiningMeResponse, ParametersResponse, ReferralListRequest, ReferralListResponse, ResolveCodeRequest, ResolveCodeResponse, SetParameterRequest, SetTeamRequest, TaskEventRequest, TaskEventResponse, TaskIconResponse, TasksResponse, TeamResponse, UpdateSettingsRequest } from "./mining_messages_nest";
5
5
  export declare const protobufPackage = "micro.v1.mining";
6
6
  export declare const MICRO_V1_MINING_PACKAGE_NAME = "micro.v1.mining";
7
7
  export interface PMiningServiceClient {
@@ -28,6 +28,11 @@ export interface PMiningServiceClient {
28
28
  adminSetParameter(request: SetParameterRequest, metadata?: Metadata): Observable<ParametersResponse>;
29
29
  adminTasks(request: EmptyRequest, metadata?: Metadata): Observable<AdminTasksResponse>;
30
30
  adminSetTask(request: AdminSetTaskRequest, metadata?: Metadata): Observable<AdminTasksResponse>;
31
+ adminSaveTask(request: AdminSaveTaskRequest, metadata?: Metadata): Observable<AdminTasksResponse>;
32
+ adminTaskAction(request: AdminTaskActionRequest, metadata?: Metadata): Observable<AdminTasksResponse>;
33
+ adminTranslateTask(request: AdminTranslateRequest, metadata?: Metadata): Observable<AdminTranslateResponse>;
34
+ adminUploadTaskIcon(request: AdminUploadTaskIconRequest, metadata?: Metadata): Observable<AdminUploadTaskIconResponse>;
35
+ taskIcon(request: ByIdRequest, metadata?: Metadata): Observable<TaskIconResponse>;
31
36
  adminUsers(request: AdminUsersRequest, metadata?: Metadata): Observable<AdminUsersResponse>;
32
37
  adminUser(request: ByIdRequest, metadata?: Metadata): Observable<AdminUserResponse>;
33
38
  adminInviteTree(request: ByIdRequest, metadata?: Metadata): Observable<AdminInviteTreeResponse>;
@@ -63,6 +68,11 @@ export interface PMiningServiceController {
63
68
  adminSetParameter(request: SetParameterRequest, metadata?: Metadata): Observable<ParametersResponse>;
64
69
  adminTasks(request: EmptyRequest, metadata?: Metadata): Observable<AdminTasksResponse>;
65
70
  adminSetTask(request: AdminSetTaskRequest, metadata?: Metadata): Observable<AdminTasksResponse>;
71
+ adminSaveTask(request: AdminSaveTaskRequest, metadata?: Metadata): Observable<AdminTasksResponse>;
72
+ adminTaskAction(request: AdminTaskActionRequest, metadata?: Metadata): Observable<AdminTasksResponse>;
73
+ adminTranslateTask(request: AdminTranslateRequest, metadata?: Metadata): Observable<AdminTranslateResponse>;
74
+ adminUploadTaskIcon(request: AdminUploadTaskIconRequest, metadata?: Metadata): Observable<AdminUploadTaskIconResponse>;
75
+ taskIcon(request: ByIdRequest, metadata?: Metadata): Observable<TaskIconResponse>;
66
76
  adminUsers(request: AdminUsersRequest, metadata?: Metadata): Observable<AdminUsersResponse>;
67
77
  adminUser(request: ByIdRequest, metadata?: Metadata): Observable<AdminUserResponse>;
68
78
  adminInviteTree(request: ByIdRequest, metadata?: Metadata): Observable<AdminInviteTreeResponse>;
@@ -31,6 +31,11 @@ function PMiningServiceControllerMethods() {
31
31
  "adminSetParameter",
32
32
  "adminTasks",
33
33
  "adminSetTask",
34
+ "adminSaveTask",
35
+ "adminTaskAction",
36
+ "adminTranslateTask",
37
+ "adminUploadTaskIcon",
38
+ "taskIcon",
34
39
  "adminUsers",
35
40
  "adminUser",
36
41
  "adminInviteTree",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jr-common-micro",
3
- "version": "1.1.133",
3
+ "version": "1.1.134",
4
4
  "description": "",
5
5
  "author": "",
6
6
  "private": false,
@@ -162,6 +162,46 @@ message TaskInfo {
162
162
  // Admin view only: when the task was last done (start of its latest
163
163
  // window, RFC 3339), whether or not that window still runs; '' if never.
164
164
  string last_done_at = 15;
165
+
166
+ // ---- a custom task (made in the panel); all empty for a built-in one ----
167
+ // '' built-in | link (tapping the row opens the link and counts) | page
168
+ // (the row opens a page of blocks; its main button opens the link and
169
+ // counts). Only sent to an app that says it can show them.
170
+ string template = 16;
171
+ string description = 17;
172
+ // A key of the apps' own icon set (x, youtube, telegram, instagram, link,
173
+ // video, book, gift, megaphone, star); unknown keys draw the link icon.
174
+ string icon = 18;
175
+ // Public id of an uploaded icon, served by the gateway ('' = `icon`).
176
+ string icon_image = 19;
177
+ // Where the task takes the person, one of the two: an https address, or
178
+ // one of the app's own pages (news | education | premium | chat).
179
+ string url = 20;
180
+ string target = 21;
181
+ // The page's main button (page template).
182
+ string button_text = 22;
183
+ repeated TaskBlock blocks = 23;
184
+ // A one-off whose layer lasts this many days (0 = for good, or not a
185
+ // one-off).
186
+ int32 effect_days = 24;
187
+ // When the task leaves the list ('' = no end).
188
+ string ends_at = 25;
189
+ // Being tested: only admins get it.
190
+ bool test = 26;
191
+ }
192
+
193
+ // One block of a custom task's page, in the reader's language. Plain text
194
+ // only.
195
+ message TaskBlock {
196
+ // text (title, body, optional button) | steps (title, items) | note (body)
197
+ string type = 1;
198
+ string title = 2;
199
+ string body = 3;
200
+ string button_text = 4;
201
+ // The block button's link, like TaskInfo.url / target.
202
+ string button_url = 5;
203
+ string button_target = 6;
204
+ repeated string items = 7;
165
205
  }
166
206
 
167
207
  message TasksSummary {
@@ -523,11 +563,132 @@ message AdminTaskItem {
523
563
  // The title in the app's other languages (es, pt, de, ru, id, vi); one
524
564
  // missing reads title_en.
525
565
  map<string, string> titles = 12;
566
+ // People who completed it at least once, ever.
567
+ int32 completers = 14;
568
+
569
+ // ---- a custom task; all empty for a built-in one ------------------------
570
+ // '' built-in | link | page
571
+ string template = 15;
572
+ // draft (nobody sees it) | test (admins only) | published | archived
573
+ string state = 16;
574
+ // Short description and main button text per language (tr, en and the
575
+ // others); one missing reads English.
576
+ map<string, string> descriptions = 17;
577
+ map<string, string> button_texts = 18;
578
+ string icon = 19;
579
+ string icon_image = 20;
580
+ string url = 21;
581
+ string target = 22;
582
+ repeated AdminTaskBlock blocks = 23;
583
+ // A one-off's layer in days (0 = for good).
584
+ int32 effect_days = 24;
585
+ // The publication window, RFC 3339 ('' = open on that side).
586
+ string starts_at = 25;
587
+ string ends_at = 26;
588
+ // First publication ('' = never): from then on the repeat and the
589
+ // validity are fixed.
590
+ string published_at = 27;
591
+ }
592
+
593
+ // A language → text map (tr, en, es, ...).
594
+ message LocalizedText {
595
+ map<string, string> values = 1;
596
+ }
597
+
598
+ // A page block as the panel edits it: every text in every language.
599
+ message AdminTaskBlock {
600
+ // text | steps | note
601
+ string type = 1;
602
+ map<string, string> title = 2;
603
+ map<string, string> body = 3;
604
+ map<string, string> button_text = 4;
605
+ string button_url = 5;
606
+ string button_target = 6;
607
+ repeated LocalizedText items = 7;
526
608
  }
527
609
 
528
610
  message AdminTasksResponse {
529
611
  ResponseStatus status = 1;
530
612
  repeated AdminTaskItem data = 2;
613
+ // The task a save or a copy made or changed ('' otherwise).
614
+ string saved_id = 3;
615
+ }
616
+
617
+ // Create (id '') or edit a custom task. Everything is sent every time; a
618
+ // draft may be incomplete, the checks run when it goes to test or is
619
+ // published. Once published, kind and effect_days are ignored.
620
+ message AdminSaveTaskRequest {
621
+ string id = 1;
622
+ // link | page
623
+ string template = 2;
624
+ // daily | weekly | once
625
+ string kind = 3;
626
+ // 0.01 – 1.00
627
+ string multiplier = 4;
628
+ // All languages, tr and en included.
629
+ map<string, string> titles = 5;
630
+ map<string, string> descriptions = 6;
631
+ map<string, string> button_texts = 7;
632
+ string icon = 8;
633
+ string icon_image = 9;
634
+ string url = 10;
635
+ string target = 11;
636
+ repeated AdminTaskBlock blocks = 12;
637
+ int32 effect_days = 13;
638
+ string starts_at = 14;
639
+ string ends_at = 15;
640
+ }
641
+
642
+ message AdminTaskActionRequest {
643
+ string id = 1;
644
+ // draft | test | publish | archive | copy | up | down | delete
645
+ // (delete: only a task that was never published and nobody completed)
646
+ string action = 2;
647
+ }
648
+
649
+ // Texts to put into the app's other languages: each with its Turkish and
650
+ // English original.
651
+ message AdminTranslateItem {
652
+ string key = 1;
653
+ string tr = 2;
654
+ string en = 3;
655
+ // The longest the text may be (characters); 0 = the service's own limit.
656
+ int32 max = 4;
657
+ // More than one line (a card's body) rather than a one-line label.
658
+ bool paragraph = 5;
659
+ }
660
+
661
+ message AdminTranslateRequest {
662
+ repeated AdminTranslateItem items = 1;
663
+ }
664
+
665
+ message AdminTranslatedItem {
666
+ string key = 1;
667
+ // es, pt, de, ... → the translation.
668
+ map<string, string> values = 2;
669
+ }
670
+
671
+ message AdminTranslateResponse {
672
+ ResponseStatus status = 1;
673
+ repeated AdminTranslatedItem data = 2;
674
+ }
675
+
676
+ // A custom task's own icon: a square picture, re-encoded by the service.
677
+ message AdminUploadTaskIconRequest {
678
+ bytes data = 1;
679
+ string mimetype = 2;
680
+ }
681
+
682
+ message AdminUploadTaskIconResponse {
683
+ ResponseStatus status = 1;
684
+ // Public id of the stored icon.
685
+ string id = 2;
686
+ }
687
+
688
+ message TaskIconResponse {
689
+ ResponseStatus status = 1;
690
+ bytes data = 2;
691
+ string mimetype = 3;
531
692
  }
532
693
 
533
694
  // ---- admin review ---------------------------------------------------------
@@ -48,6 +48,15 @@ service PMiningService {
48
48
  rpc AdminSetParameter(SetParameterRequest) returns(stream ParametersResponse) {}
49
49
  rpc AdminTasks(EmptyRequest) returns(stream AdminTasksResponse) {}
50
50
  rpc AdminSetTask(AdminSetTaskRequest) returns(stream AdminTasksResponse) {}
51
+ // Custom tasks, made in the panel without a release: save a draft or an
52
+ // edit, move one between draft / test / published / archived, copy it or
53
+ // move it in the list; translate its texts; store its own icon.
54
+ rpc AdminSaveTask(AdminSaveTaskRequest) returns(stream AdminTasksResponse) {}
55
+ rpc AdminTaskAction(AdminTaskActionRequest) returns(stream AdminTasksResponse) {}
56
+ rpc AdminTranslateTask(AdminTranslateRequest) returns(stream AdminTranslateResponse) {}
57
+ rpc AdminUploadTaskIcon(AdminUploadTaskIconRequest) returns(stream AdminUploadTaskIconResponse) {}
58
+ // Public: an uploaded task icon by its public id.
59
+ rpc TaskIcon(ByIdRequest) returns(stream TaskIconResponse) {}
51
60
  // Admin review (the "overwatch"): find people, see one person's invitees,
52
61
  // device cluster, ledger and past decisions, and decide (clear, restrict,
53
62
  // ban, unban) with the JR that came from fraud taken back.