node-cnb 1.12.0 → 1.13.0

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/paths.json CHANGED
@@ -387,7 +387,7 @@
387
387
  "description": "OK",
388
388
  "schema": {
389
389
  "items": {
390
- "$ref": "#/definitions/dto.Repos4UserBase"
390
+ "$ref": "#/definitions/dto.Repos4User"
391
391
  },
392
392
  "type": "array"
393
393
  }
@@ -424,6 +424,41 @@
424
424
  "path": "/users/{username}",
425
425
  "method": "get"
426
426
  },
427
+ "users.activities.get": {
428
+ "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \naccount-engage:r",
429
+ "operationId": "GetUserActivitiesByDate",
430
+ "tags": [
431
+ "Activities"
432
+ ],
433
+ "summary": "获取个人动态活跃详情汇总",
434
+ "parameters": [
435
+ {
436
+ "default": "someone",
437
+ "description": "UserName",
438
+ "in": "path",
439
+ "name": "username",
440
+ "required": true,
441
+ "type": "string"
442
+ },
443
+ {
444
+ "default": "",
445
+ "description": "查询日期,格式 yyyyMM,或者 yyyyMMdd",
446
+ "in": "query",
447
+ "name": "date",
448
+ "type": "string"
449
+ }
450
+ ],
451
+ "responses": {
452
+ "200": {
453
+ "description": "OK",
454
+ "schema": {
455
+ "$ref": "#/definitions/dto.ActivityDate"
456
+ }
457
+ }
458
+ },
459
+ "path": "/users/{username}/activities",
460
+ "method": "get"
461
+ },
427
462
  "users.avatar.get": {
428
463
  "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \naccount-profile:r",
429
464
  "operationId": "GetUserAvatar",
@@ -639,6 +674,63 @@
639
674
  "path": "/users/{username}/pinned-repos",
640
675
  "method": "get"
641
676
  },
677
+ "users.repoActivities.list": {
678
+ "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \naccount-engage:r",
679
+ "operationId": "GetUserRepoActivityDetails",
680
+ "tags": [
681
+ "Activities"
682
+ ],
683
+ "summary": "个人仓库动态详情列表",
684
+ "parameters": [
685
+ {
686
+ "default": "someone",
687
+ "description": "UserName",
688
+ "in": "path",
689
+ "name": "username",
690
+ "required": true,
691
+ "type": "string"
692
+ },
693
+ {
694
+ "description": "activity type",
695
+ "enum": [
696
+ "issue",
697
+ "pull_request",
698
+ "code_review"
699
+ ],
700
+ "in": "path",
701
+ "name": "activityType",
702
+ "required": true,
703
+ "type": "string"
704
+ },
705
+ {
706
+ "default": "",
707
+ "description": "仓库路径",
708
+ "in": "query",
709
+ "name": "slug",
710
+ "required": true,
711
+ "type": "string"
712
+ },
713
+ {
714
+ "default": "",
715
+ "description": "查询日期,格式 yyyyMM,或者 yyyyMMdd",
716
+ "in": "query",
717
+ "name": "date",
718
+ "required": true,
719
+ "type": "string"
720
+ }
721
+ ],
722
+ "responses": {
723
+ "200": {
724
+ "description": "返回 []dto.ActivityPullRequestDetail|[]dto.ActivityIssueDetail",
725
+ "schema": {
726
+ "items": {},
727
+ "type": "array"
728
+ }
729
+ }
730
+ },
731
+ "path": "/users/{username}/repo-activities/{activityType}",
732
+ "method": "get"
733
+ },
642
734
  "users.repos.list": {
643
735
  "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \naccount-engage:r",
644
736
  "operationId": "GetReposByUserName",
@@ -1536,7 +1628,7 @@
1536
1628
  "description": "OK",
1537
1629
  "schema": {
1538
1630
  "items": {
1539
- "$ref": "#/definitions/dto.Repos4UserBase"
1631
+ "$ref": "#/definitions/dto.Repos4User"
1540
1632
  },
1541
1633
  "type": "array"
1542
1634
  }
@@ -2352,7 +2444,7 @@
2352
2444
  "path": "/{repo}/-/files/{userIdKey}/{randomUUID}/{fileName}",
2353
2445
  "method": "put"
2354
2446
  },
2355
- "repo.forks.list": {
2447
+ "repo.forks.get": {
2356
2448
  "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \nrepo-base-info:r",
2357
2449
  "operationId": "ListForksRepos",
2358
2450
  "tags": [
@@ -2367,6 +2459,13 @@
2367
2459
  "required": true,
2368
2460
  "type": "string"
2369
2461
  },
2462
+ {
2463
+ "default": false,
2464
+ "description": "从fork根节点开始展示",
2465
+ "in": "query",
2466
+ "name": "start_from_root",
2467
+ "type": "boolean"
2468
+ },
2370
2469
  {
2371
2470
  "default": 1,
2372
2471
  "description": "Pagination page number",
@@ -2388,10 +2487,7 @@
2388
2487
  "200": {
2389
2488
  "description": "OK",
2390
2489
  "schema": {
2391
- "items": {
2392
- "$ref": "#/definitions/dto.Forks"
2393
- },
2394
- "type": "array"
2490
+ "$ref": "#/definitions/dto.ListForks"
2395
2491
  }
2396
2492
  }
2397
2493
  },
@@ -3018,7 +3114,7 @@
3018
3114
  "in": "path",
3019
3115
  "name": "sha1",
3020
3116
  "required": true,
3021
- "type": "integer"
3117
+ "type": "string"
3022
3118
  },
3023
3119
  {
3024
3120
  "description": "upload token",
@@ -3075,7 +3171,7 @@
3075
3171
  "in": "path",
3076
3172
  "name": "sha1",
3077
3173
  "required": true,
3078
- "type": "integer"
3174
+ "type": "string"
3079
3175
  },
3080
3176
  {
3081
3177
  "description": "Post Commit Asset Upload URL Form",
@@ -3137,7 +3233,7 @@
3137
3233
  "in": "path",
3138
3234
  "name": "asset_id",
3139
3235
  "required": true,
3140
- "type": "integer"
3236
+ "type": "string"
3141
3237
  }
3142
3238
  ],
3143
3239
  "responses": {
@@ -4090,6 +4186,18 @@
4090
4186
  "name": "updated_time_end",
4091
4187
  "type": "string"
4092
4188
  },
4189
+ {
4190
+ "description": "issue filter close time begin example: 2022-01-31",
4191
+ "in": "query",
4192
+ "name": "close_time_begin",
4193
+ "type": "string"
4194
+ },
4195
+ {
4196
+ "description": "issue filter close time end, example: 2022-01-31",
4197
+ "in": "query",
4198
+ "name": "close_time_end",
4199
+ "type": "string"
4200
+ },
4093
4201
  {
4094
4202
  "description": "issue order, example: created_at, -updated_at, reference_count。‘-’ prefix means descending order",
4095
4203
  "in": "query",
@@ -4272,6 +4380,113 @@
4272
4380
  "path": "/{repo}/-/issues/{number}",
4273
4381
  "method": "patch"
4274
4382
  },
4383
+ "repo.issues.assignees.list": {
4384
+ "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \nrepo-notes:r",
4385
+ "operationId": "ListIssueAssignees",
4386
+ "tags": [
4387
+ "Issues"
4388
+ ],
4389
+ "summary": "查询指定 Issue 的 Assignees。 List repository issue assignees.",
4390
+ "parameters": [
4391
+ {
4392
+ "description": "repo",
4393
+ "in": "path",
4394
+ "name": "repo",
4395
+ "required": true,
4396
+ "type": "string"
4397
+ },
4398
+ {
4399
+ "description": "issue number",
4400
+ "in": "path",
4401
+ "name": "number",
4402
+ "required": true,
4403
+ "type": "string"
4404
+ }
4405
+ ],
4406
+ "responses": {
4407
+ "200": {
4408
+ "description": "OK",
4409
+ "schema": {
4410
+ "items": {
4411
+ "$ref": "#/definitions/git_woa_com_cnb_monorepo_git_internal_app_vcs_service_bff_api.UserInfo"
4412
+ },
4413
+ "type": "array"
4414
+ }
4415
+ },
4416
+ "404": {
4417
+ "description": "Not Found",
4418
+ "schema": {
4419
+ "$ref": "#/definitions/die.WebError"
4420
+ }
4421
+ },
4422
+ "500": {
4423
+ "description": "Internal Server Error",
4424
+ "schema": {
4425
+ "$ref": "#/definitions/die.WebError"
4426
+ }
4427
+ }
4428
+ },
4429
+ "path": "/{repo}/-/issues/{number}/assignees",
4430
+ "method": "get"
4431
+ },
4432
+ "repo.issues.assignees.post": {
4433
+ "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \nrepo-notes:rw",
4434
+ "operationId": "PostIssueAssignees",
4435
+ "tags": [
4436
+ "Issues"
4437
+ ],
4438
+ "summary": "添加 Assignees 到指定的 Issue。 Adds up to 10 assignees to an issue. Users already assigned to an issue are not replaced.",
4439
+ "parameters": [
4440
+ {
4441
+ "description": "repo",
4442
+ "in": "path",
4443
+ "name": "repo",
4444
+ "required": true,
4445
+ "type": "string"
4446
+ },
4447
+ {
4448
+ "description": "issue number",
4449
+ "in": "path",
4450
+ "name": "number",
4451
+ "required": true,
4452
+ "type": "string"
4453
+ },
4454
+ {
4455
+ "description": "Post Issue Assignees Form",
4456
+ "in": "body",
4457
+ "name": "post_issue_assignees_form",
4458
+ "required": true,
4459
+ "schema": {
4460
+ "$ref": "#/definitions/api.PostIssueAssigneesForm"
4461
+ }
4462
+ }
4463
+ ],
4464
+ "responses": {
4465
+ "201": {
4466
+ "description": "Created",
4467
+ "schema": {
4468
+ "items": {
4469
+ "$ref": "#/definitions/api.IssueDetail"
4470
+ },
4471
+ "type": "array"
4472
+ }
4473
+ },
4474
+ "404": {
4475
+ "description": "Not Found",
4476
+ "schema": {
4477
+ "$ref": "#/definitions/die.WebError"
4478
+ }
4479
+ },
4480
+ "500": {
4481
+ "description": "Internal Server Error",
4482
+ "schema": {
4483
+ "$ref": "#/definitions/die.WebError"
4484
+ }
4485
+ }
4486
+ },
4487
+ "path": "/{repo}/-/issues/{number}/assignees",
4488
+ "method": "post"
4489
+ },
4275
4490
  "repo.issues.comments.list": {
4276
4491
  "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \nrepo-notes:r",
4277
4492
  "operationId": "ListIssueComments",
@@ -4410,14 +4625,14 @@
4410
4625
  "in": "path",
4411
4626
  "name": "number",
4412
4627
  "required": true,
4413
- "type": "integer"
4628
+ "type": "string"
4414
4629
  },
4415
4630
  {
4416
4631
  "description": "comment_id",
4417
4632
  "in": "path",
4418
4633
  "name": "comment_id",
4419
4634
  "required": true,
4420
- "type": "integer"
4635
+ "type": "string"
4421
4636
  }
4422
4637
  ],
4423
4638
  "responses": {
@@ -5658,7 +5873,7 @@
5658
5873
  "in": "path",
5659
5874
  "name": "number",
5660
5875
  "required": true,
5661
- "type": "integer"
5876
+ "type": "string"
5662
5877
  }
5663
5878
  ],
5664
5879
  "responses": {
@@ -5704,7 +5919,7 @@
5704
5919
  "in": "path",
5705
5920
  "name": "number",
5706
5921
  "required": true,
5707
- "type": "integer"
5922
+ "type": "string"
5708
5923
  },
5709
5924
  {
5710
5925
  "description": "Update Pull Request Form",
@@ -5739,6 +5954,110 @@
5739
5954
  "path": "/{repo}/-/pulls/{number}",
5740
5955
  "method": "patch"
5741
5956
  },
5957
+ "repo.pulls.assignees.list": {
5958
+ "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \nrepo-notes:r",
5959
+ "operationId": "ListPullAssignees",
5960
+ "tags": [
5961
+ "Pulls"
5962
+ ],
5963
+ "summary": "查询指定 PullRequest 的 Assignees。List repository pull request assignees.",
5964
+ "parameters": [
5965
+ {
5966
+ "description": "repo",
5967
+ "in": "path",
5968
+ "name": "repo",
5969
+ "required": true,
5970
+ "type": "string"
5971
+ },
5972
+ {
5973
+ "description": "pull request number",
5974
+ "in": "path",
5975
+ "name": "number",
5976
+ "required": true,
5977
+ "type": "string"
5978
+ }
5979
+ ],
5980
+ "responses": {
5981
+ "200": {
5982
+ "description": "OK",
5983
+ "schema": {
5984
+ "items": {
5985
+ "$ref": "#/definitions/git_woa_com_cnb_monorepo_git_internal_app_git_service_bff_api.UserInfo"
5986
+ },
5987
+ "type": "array"
5988
+ }
5989
+ },
5990
+ "404": {
5991
+ "description": "Not Found",
5992
+ "schema": {
5993
+ "$ref": "#/definitions/die.WebError"
5994
+ }
5995
+ },
5996
+ "500": {
5997
+ "description": "Internal Server Error",
5998
+ "schema": {
5999
+ "$ref": "#/definitions/die.WebError"
6000
+ }
6001
+ }
6002
+ },
6003
+ "path": "/{repo}/-/pulls/{number}/assignees",
6004
+ "method": "get"
6005
+ },
6006
+ "repo.pulls.assignees.post": {
6007
+ "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \nrepo-notes:rw",
6008
+ "operationId": "PostPullAssignees",
6009
+ "tags": [
6010
+ "Pulls"
6011
+ ],
6012
+ "summary": "添加 Assignees 到指定的 PullRequest。 Adds up to 10 assignees to a pull request. Users already assigned to an issue are not replaced.",
6013
+ "parameters": [
6014
+ {
6015
+ "description": "repo",
6016
+ "in": "path",
6017
+ "name": "repo",
6018
+ "required": true,
6019
+ "type": "string"
6020
+ },
6021
+ {
6022
+ "description": "number",
6023
+ "in": "path",
6024
+ "name": "number",
6025
+ "required": true,
6026
+ "type": "string"
6027
+ },
6028
+ {
6029
+ "description": "Post Pull Assignees Form",
6030
+ "in": "body",
6031
+ "name": "post_pull_assignees_form",
6032
+ "required": true,
6033
+ "schema": {
6034
+ "$ref": "#/definitions/api.PostPullAssigneesForm"
6035
+ }
6036
+ }
6037
+ ],
6038
+ "responses": {
6039
+ "201": {
6040
+ "description": "Created",
6041
+ "schema": {
6042
+ "$ref": "#/definitions/api.Pull"
6043
+ }
6044
+ },
6045
+ "404": {
6046
+ "description": "Not Found",
6047
+ "schema": {
6048
+ "$ref": "#/definitions/die.WebError"
6049
+ }
6050
+ },
6051
+ "500": {
6052
+ "description": "Internal Server Error",
6053
+ "schema": {
6054
+ "$ref": "#/definitions/die.WebError"
6055
+ }
6056
+ }
6057
+ },
6058
+ "path": "/{repo}/-/pulls/{number}/assignees",
6059
+ "method": "post"
6060
+ },
5742
6061
  "repo.pulls.comments.list": {
5743
6062
  "description": "访问令牌调用此接口需包含以下权限。Required permissions for access token. \nrepo-notes:r",
5744
6063
  "operationId": "ListPullComments",
@@ -5822,7 +6141,7 @@
5822
6141
  "in": "path",
5823
6142
  "name": "number",
5824
6143
  "required": true,
5825
- "type": "integer"
6144
+ "type": "string"
5826
6145
  },
5827
6146
  {
5828
6147
  "description": "Post Pull Request Comment Form",
@@ -5874,7 +6193,7 @@
5874
6193
  "in": "path",
5875
6194
  "name": "number",
5876
6195
  "required": true,
5877
- "type": "integer"
6196
+ "type": "string"
5878
6197
  }
5879
6198
  ],
5880
6199
  "responses": {
@@ -5917,7 +6236,7 @@
5917
6236
  "in": "path",
5918
6237
  "name": "number",
5919
6238
  "required": true,
5920
- "type": "integer"
6239
+ "type": "string"
5921
6240
  },
5922
6241
  {
5923
6242
  "default": 1,
@@ -5980,7 +6299,7 @@
5980
6299
  "in": "path",
5981
6300
  "name": "number",
5982
6301
  "required": true,
5983
- "type": "integer"
6302
+ "type": "string"
5984
6303
  },
5985
6304
  {
5986
6305
  "description": "Post Pull Labels Form",
@@ -6035,7 +6354,7 @@
6035
6354
  "in": "path",
6036
6355
  "name": "number",
6037
6356
  "required": true,
6038
- "type": "integer"
6357
+ "type": "string"
6039
6358
  },
6040
6359
  {
6041
6360
  "description": "Put Pull Labels Form",
@@ -6090,7 +6409,7 @@
6090
6409
  "in": "path",
6091
6410
  "name": "number",
6092
6411
  "required": true,
6093
- "type": "integer"
6412
+ "type": "string"
6094
6413
  },
6095
6414
  {
6096
6415
  "description": "label name",
@@ -6143,7 +6462,7 @@
6143
6462
  "in": "path",
6144
6463
  "name": "number",
6145
6464
  "required": true,
6146
- "type": "integer"
6465
+ "type": "string"
6147
6466
  },
6148
6467
  {
6149
6468
  "description": "Merge Pull Request Form",
@@ -6198,7 +6517,7 @@
6198
6517
  "in": "path",
6199
6518
  "name": "number",
6200
6519
  "required": true,
6201
- "type": "integer"
6520
+ "type": "string"
6202
6521
  },
6203
6522
  {
6204
6523
  "description": "Post Pull Review Form",
@@ -6509,7 +6828,7 @@
6509
6828
  "in": "path",
6510
6829
  "name": "release_id",
6511
6830
  "required": true,
6512
- "type": "integer"
6831
+ "type": "string"
6513
6832
  }
6514
6833
  ],
6515
6834
  "responses": {
@@ -6552,7 +6871,7 @@
6552
6871
  "in": "path",
6553
6872
  "name": "release_id",
6554
6873
  "required": true,
6555
- "type": "integer"
6874
+ "type": "string"
6556
6875
  }
6557
6876
  ],
6558
6877
  "responses": {
@@ -6598,7 +6917,7 @@
6598
6917
  "in": "path",
6599
6918
  "name": "release_id",
6600
6919
  "required": true,
6601
- "type": "integer"
6920
+ "type": "string"
6602
6921
  },
6603
6922
  {
6604
6923
  "description": "patch release form",
@@ -6650,7 +6969,7 @@
6650
6969
  "in": "path",
6651
6970
  "name": "release_id",
6652
6971
  "required": true,
6653
- "type": "integer"
6972
+ "type": "string"
6654
6973
  },
6655
6974
  {
6656
6975
  "description": "upload token",
@@ -6707,7 +7026,7 @@
6707
7026
  "in": "path",
6708
7027
  "name": "release_id",
6709
7028
  "required": true,
6710
- "type": "integer"
7029
+ "type": "string"
6711
7030
  },
6712
7031
  {
6713
7032
  "description": "Post Release Asset Upload URL Form",
@@ -6762,14 +7081,14 @@
6762
7081
  "in": "path",
6763
7082
  "name": "release_id",
6764
7083
  "required": true,
6765
- "type": "integer"
7084
+ "type": "string"
6766
7085
  },
6767
7086
  {
6768
7087
  "description": "asset id",
6769
7088
  "in": "path",
6770
7089
  "name": "asset_id",
6771
7090
  "required": true,
6772
- "type": "integer"
7091
+ "type": "string"
6773
7092
  }
6774
7093
  ],
6775
7094
  "responses": {
@@ -6812,14 +7131,14 @@
6812
7131
  "in": "path",
6813
7132
  "name": "release_id",
6814
7133
  "required": true,
6815
- "type": "integer"
7134
+ "type": "string"
6816
7135
  },
6817
7136
  {
6818
7137
  "description": "asset id",
6819
7138
  "in": "path",
6820
7139
  "name": "asset_id",
6821
7140
  "required": true,
6822
- "type": "integer"
7141
+ "type": "string"
6823
7142
  }
6824
7143
  ],
6825
7144
  "responses": {
@@ -7496,7 +7815,7 @@
7496
7815
  "tags": [
7497
7816
  "Assets"
7498
7817
  ],
7499
- "summary": "发起一个上传 release 附件的请求,返回上传 cos 的 url 和 form 内容。Initiate a request to upload release attachments, returns COS upload URL and form data.",
7818
+ "summary": "发起一个上传 release 附件的请求,返回上传 cos 的 url Initiate a request to upload release attachments,",
7500
7819
  "parameters": [
7501
7820
  {
7502
7821
  "default": "test-group/test-repo",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-cnb",
3
- "version": "1.12.0",
3
+ "version": "1.13.0",
4
4
  "description": "node sdk for cnb open api",
5
5
  "main": "dist/index.js",
6
6
  "typings": "./src/index.d.ts",