@maxim_mazurok/gapi.client.gmailpostmastertools-v2 0.1.20260621 → 0.1.20260623

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.
Files changed (3) hide show
  1. package/index.d.ts +460 -2
  2. package/package.json +1 -1
  3. package/readme.md +25 -0
package/index.d.ts CHANGED
@@ -9,7 +9,7 @@
9
9
  // This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
10
10
  // In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
11
11
  // Generated from: https://gmailpostmastertools.googleapis.com/$discovery/rest?version=v2
12
- // Revision: 20260621
12
+ // Revision: 20260623
13
13
 
14
14
  /// <reference types="gapi.client" />
15
15
 
@@ -77,6 +77,21 @@ declare namespace gapi.client {
77
77
  /** Output only. The compliance status. */
78
78
  status?: 'STATE_UNSPECIFIED' | 'COMPLIANT' | 'NEEDS_WORK';
79
79
  }
80
+ interface CreateDomainRequest {
81
+ /** Required. The domain to add. e.g., "example.com" */
82
+ domainId?: string;
83
+ }
84
+ interface CreateUserRequest {
85
+ /** Optional. Specifies the permission level to give the user for the specified domain. If not specified, the default value for this field is READER. */
86
+ permission?:
87
+ | 'PERMISSION_UNSPECIFIED'
88
+ | 'READER'
89
+ | 'ADMIN'
90
+ | 'OWNER'
91
+ | 'NONE';
92
+ /** Required. The user to create. */
93
+ userId?: string;
94
+ }
80
95
  interface Date {
81
96
  /** Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant. */
82
97
  day?: number;
@@ -99,6 +114,20 @@ declare namespace gapi.client {
99
114
  /** Required. The list of date ranges for which to retrieve data. */
100
115
  dateRanges?: DateRange[];
101
116
  }
117
+ interface DeliverabilityStatusVerdict {
118
+ /** Output only. The specific reason for the compliance verdict. */
119
+ reason?:
120
+ | 'REASON_UNSPECIFIED'
121
+ | 'MESSAGE_VOLUME_LOW'
122
+ | 'SMTP_ERRORS_HIGH'
123
+ | 'SENDER_NOT_COMPLIANT'
124
+ | 'SPAM_RATE_HIGH'
125
+ | 'USER_FEEDBACK_NEGATIVE'
126
+ | 'USER_FEEDBACK_LOW'
127
+ | 'USER_FEEDBACK_POSITIVE';
128
+ /** Output only. The compliance state. */
129
+ state?: ComplianceStatus;
130
+ }
102
131
  interface Domain {
103
132
  /** Output only. Immutable. The timestamp at which the domain was added to the user's account. */
104
133
  createTime?: string;
@@ -107,7 +136,12 @@ declare namespace gapi.client {
107
136
  /** Identifier. The resource name of the domain. Format: `domains/{domain_name}`, where domain_name is the fully qualified domain name (i.e., mymail.mydomain.com). */
108
137
  name?: string;
109
138
  /** Output only. User's permission of this domain. */
110
- permission?: 'PERMISSION_UNSPECIFIED' | 'READER' | 'OWNER' | 'NONE';
139
+ permission?:
140
+ | 'PERMISSION_UNSPECIFIED'
141
+ | 'READER'
142
+ | 'ADMIN'
143
+ | 'OWNER'
144
+ | 'NONE';
111
145
  /** Output only. Information about a user's verification history and properties for the domain. */
112
146
  verificationState?:
113
147
  | 'VERIFICATION_STATE_UNSPECIFIED'
@@ -115,6 +149,8 @@ declare namespace gapi.client {
115
149
  | 'VERIFIED';
116
150
  }
117
151
  interface DomainComplianceData {
152
+ /** Output only. Deliverability status verdict. */
153
+ deliverabilityStatusVerdict?: DeliverabilityStatusVerdict;
118
154
  /** Domain that this data is for. */
119
155
  domainId?: string;
120
156
  /** Unsubscribe honoring compliance verdict. */
@@ -142,6 +178,18 @@ declare namespace gapi.client {
142
178
  /** The value of the corresponding metric. */
143
179
  value?: StatisticValue;
144
180
  }
181
+ interface DomainVerificationToken {
182
+ /** Identifier. The resource name of the domain verification token. Format: domains/{domain}/verificationToken */
183
+ name?: string;
184
+ /** The verification token. */
185
+ token?: string;
186
+ /** The verification method used. */
187
+ verificationMethod?:
188
+ | 'DOMAIN_VERIFICATION_METHOD_UNSPECIFIED'
189
+ | 'TXT'
190
+ | 'CNAME';
191
+ }
192
+ interface Empty {}
145
193
  interface HonorUnsubscribeVerdict {
146
194
  /** The specific reason for the compliance verdict. Must be empty if the status is compliant. */
147
195
  reason?:
@@ -158,6 +206,12 @@ declare namespace gapi.client {
158
206
  /** Token to retrieve the next page of results, or empty if there are no more results in the list. */
159
207
  nextPageToken?: string;
160
208
  }
209
+ interface ListUsersResponse {
210
+ /** Token to retrieve the next page of results, or empty if there are no more results in the list. */
211
+ nextPageToken?: string;
212
+ /** The users that have access to the domain. */
213
+ users?: User[];
214
+ }
161
215
  interface MetricDefinition {
162
216
  /** Required. The underlying metric to query. */
163
217
  baseMetric?: BaseMetric;
@@ -229,6 +283,31 @@ declare namespace gapi.client {
229
283
  /** A list of date ranges. */
230
284
  dateRanges?: DateRanges;
231
285
  }
286
+ interface User {
287
+ /** Output only. The user that added the current user. */
288
+ accessGranter?: string;
289
+ /** Output only. The time the user was granted access. */
290
+ createTime?: string;
291
+ /** Identifier. The resource name of the user. Format: users/{user} Note: {user} is the user's email address. */
292
+ name?: string;
293
+ /** The permission level that the user has for the specified domain. */
294
+ permission?:
295
+ | 'PERMISSION_UNSPECIFIED'
296
+ | 'READER'
297
+ | 'ADMIN'
298
+ | 'OWNER'
299
+ | 'NONE';
300
+ /** The user's email address. */
301
+ user?: string;
302
+ }
303
+ interface VerifyDomainRequest {
304
+ /** Required. The verification method used. Must be specified, i.e. TXT or CNAME. */
305
+ verificationMethod?:
306
+ | 'DOMAIN_VERIFICATION_METHOD_UNSPECIFIED'
307
+ | 'TXT'
308
+ | 'CNAME';
309
+ }
310
+ interface VerifyDomainResponse {}
232
311
  interface DomainStatsResource {
233
312
  /** Retrieves a list of domain statistics for a given domain and time period. Returns statistics only for dates where data is available. Returns PERMISSION_DENIED if you don't have permission to access DomainStats for the domain. */
234
313
  query(request: {
@@ -289,7 +368,295 @@ declare namespace gapi.client {
289
368
  body: QueryDomainStatsRequest,
290
369
  ): Request<QueryDomainStatsResponse>;
291
370
  }
371
+ interface UsersResource {
372
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Creates a user, who has access to a domain. Returns INVALID_ARGUMENT if a user is not provided. */
373
+ create(request: {
374
+ /** V1 error format. */
375
+ '$.xgafv'?: '1' | '2';
376
+ /** OAuth access token. */
377
+ access_token?: string;
378
+ /** Data format for response. */
379
+ alt?: 'json' | 'media' | 'proto';
380
+ /** JSONP */
381
+ callback?: string;
382
+ /** Selector specifying which fields to include in a partial response. */
383
+ fields?: string;
384
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
385
+ key?: string;
386
+ /** OAuth 2.0 token for the current user. */
387
+ oauth_token?: string;
388
+ /** Required. The parent resource where this user will be created. Format: domains/{domain} */
389
+ parent: string;
390
+ /** Returns response with indentations and line breaks. */
391
+ prettyPrint?: boolean;
392
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
393
+ quotaUser?: string;
394
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
395
+ upload_protocol?: string;
396
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
397
+ uploadType?: string;
398
+ /** Request body */
399
+ resource: CreateUserRequest;
400
+ }): Request<User>;
401
+ create(
402
+ request: {
403
+ /** V1 error format. */
404
+ '$.xgafv'?: '1' | '2';
405
+ /** OAuth access token. */
406
+ access_token?: string;
407
+ /** Data format for response. */
408
+ alt?: 'json' | 'media' | 'proto';
409
+ /** JSONP */
410
+ callback?: string;
411
+ /** Selector specifying which fields to include in a partial response. */
412
+ fields?: string;
413
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
414
+ key?: string;
415
+ /** OAuth 2.0 token for the current user. */
416
+ oauth_token?: string;
417
+ /** Required. The parent resource where this user will be created. Format: domains/{domain} */
418
+ parent: string;
419
+ /** Returns response with indentations and line breaks. */
420
+ prettyPrint?: boolean;
421
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
422
+ quotaUser?: string;
423
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
424
+ upload_protocol?: string;
425
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
426
+ uploadType?: string;
427
+ },
428
+ body: CreateUserRequest,
429
+ ): Request<User>;
430
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Deletes a user from a domain. Returns NOT_FOUND if the user does not exist. */
431
+ delete(request?: {
432
+ /** V1 error format. */
433
+ '$.xgafv'?: '1' | '2';
434
+ /** OAuth access token. */
435
+ access_token?: string;
436
+ /** Data format for response. */
437
+ alt?: 'json' | 'media' | 'proto';
438
+ /** JSONP */
439
+ callback?: string;
440
+ /** Selector specifying which fields to include in a partial response. */
441
+ fields?: string;
442
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
443
+ key?: string;
444
+ /** Required. The resource name of the user to delete. Format: domains/{domain}/users/{user} */
445
+ name: string;
446
+ /** OAuth 2.0 token for the current user. */
447
+ oauth_token?: string;
448
+ /** Returns response with indentations and line breaks. */
449
+ prettyPrint?: boolean;
450
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
451
+ quotaUser?: string;
452
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
453
+ upload_protocol?: string;
454
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
455
+ uploadType?: string;
456
+ }): Request<{}>;
457
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Retrieves detailed information about a user that has access to a domain. Returns NOT_FOUND if the user does not exist. */
458
+ get(request?: {
459
+ /** V1 error format. */
460
+ '$.xgafv'?: '1' | '2';
461
+ /** OAuth access token. */
462
+ access_token?: string;
463
+ /** Data format for response. */
464
+ alt?: 'json' | 'media' | 'proto';
465
+ /** JSONP */
466
+ callback?: string;
467
+ /** Selector specifying which fields to include in a partial response. */
468
+ fields?: string;
469
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
470
+ key?: string;
471
+ /** Required. The resource name of the user to retrieve. Format: `domains/{domain}/users/{user}` */
472
+ name: string;
473
+ /** OAuth 2.0 token for the current user. */
474
+ oauth_token?: string;
475
+ /** Returns response with indentations and line breaks. */
476
+ prettyPrint?: boolean;
477
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
478
+ quotaUser?: string;
479
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
480
+ upload_protocol?: string;
481
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
482
+ uploadType?: string;
483
+ }): Request<User>;
484
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Lists the users that have access to a domain. */
485
+ list(request?: {
486
+ /** V1 error format. */
487
+ '$.xgafv'?: '1' | '2';
488
+ /** OAuth access token. */
489
+ access_token?: string;
490
+ /** Data format for response. */
491
+ alt?: 'json' | 'media' | 'proto';
492
+ /** JSONP */
493
+ callback?: string;
494
+ /** Selector specifying which fields to include in a partial response. */
495
+ fields?: string;
496
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
497
+ key?: string;
498
+ /** OAuth 2.0 token for the current user. */
499
+ oauth_token?: string;
500
+ /** Optional. Requested page size. Server may return fewer users than requested. If unspecified, the default value for this field is 10. The maximum value for this field is 200. */
501
+ pageSize?: number;
502
+ /** Optional. The next_page_token value returned from a previous List request, if any. */
503
+ pageToken?: string;
504
+ /** Required. The parent resource name for which to list users. Format: `domains/{domain}` */
505
+ parent: string;
506
+ /** Returns response with indentations and line breaks. */
507
+ prettyPrint?: boolean;
508
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
509
+ quotaUser?: string;
510
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
511
+ upload_protocol?: string;
512
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
513
+ uploadType?: string;
514
+ }): Request<ListUsersResponse>;
515
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Updates a user for a domain. Only Owners and Admins can execute this RPC, only a user's domain permission will be allowed to be updated. Returns NOT_FOUND if the user does not exist. Returns INVALID_ARGUMENT if a permission is not provided or is PERMISSION_UNSPECIFIED, NONE, or OWNER. */
516
+ patch(request: {
517
+ /** V1 error format. */
518
+ '$.xgafv'?: '1' | '2';
519
+ /** OAuth access token. */
520
+ access_token?: string;
521
+ /** Data format for response. */
522
+ alt?: 'json' | 'media' | 'proto';
523
+ /** JSONP */
524
+ callback?: string;
525
+ /** Selector specifying which fields to include in a partial response. */
526
+ fields?: string;
527
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
528
+ key?: string;
529
+ /** Identifier. The resource name of the user. Format: users/{user} Note: {user} is the user's email address. */
530
+ name: string;
531
+ /** OAuth 2.0 token for the current user. */
532
+ oauth_token?: string;
533
+ /** Returns response with indentations and line breaks. */
534
+ prettyPrint?: boolean;
535
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
536
+ quotaUser?: string;
537
+ /** The list of fields to update. */
538
+ updateMask?: string;
539
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
540
+ upload_protocol?: string;
541
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
542
+ uploadType?: string;
543
+ /** Request body */
544
+ resource: User;
545
+ }): Request<User>;
546
+ patch(
547
+ request: {
548
+ /** V1 error format. */
549
+ '$.xgafv'?: '1' | '2';
550
+ /** OAuth access token. */
551
+ access_token?: string;
552
+ /** Data format for response. */
553
+ alt?: 'json' | 'media' | 'proto';
554
+ /** JSONP */
555
+ callback?: string;
556
+ /** Selector specifying which fields to include in a partial response. */
557
+ fields?: string;
558
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
559
+ key?: string;
560
+ /** Identifier. The resource name of the user. Format: users/{user} Note: {user} is the user's email address. */
561
+ name: string;
562
+ /** OAuth 2.0 token for the current user. */
563
+ oauth_token?: string;
564
+ /** Returns response with indentations and line breaks. */
565
+ prettyPrint?: boolean;
566
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
567
+ quotaUser?: string;
568
+ /** The list of fields to update. */
569
+ updateMask?: string;
570
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
571
+ upload_protocol?: string;
572
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
573
+ uploadType?: string;
574
+ },
575
+ body: User,
576
+ ): Request<User>;
577
+ }
292
578
  interface DomainsResource {
579
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Adds a domain to the user's account. Returns INVALID_ARGUMENT if a domain is not provided. Returns ALREADY_EXISTS if the domain is already registered by the user. */
580
+ create(request: {
581
+ /** V1 error format. */
582
+ '$.xgafv'?: '1' | '2';
583
+ /** OAuth access token. */
584
+ access_token?: string;
585
+ /** Data format for response. */
586
+ alt?: 'json' | 'media' | 'proto';
587
+ /** JSONP */
588
+ callback?: string;
589
+ /** Selector specifying which fields to include in a partial response. */
590
+ fields?: string;
591
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
592
+ key?: string;
593
+ /** OAuth 2.0 token for the current user. */
594
+ oauth_token?: string;
595
+ /** Returns response with indentations and line breaks. */
596
+ prettyPrint?: boolean;
597
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
598
+ quotaUser?: string;
599
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
600
+ upload_protocol?: string;
601
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
602
+ uploadType?: string;
603
+ /** Request body */
604
+ resource: CreateDomainRequest;
605
+ }): Request<Domain>;
606
+ create(
607
+ request: {
608
+ /** V1 error format. */
609
+ '$.xgafv'?: '1' | '2';
610
+ /** OAuth access token. */
611
+ access_token?: string;
612
+ /** Data format for response. */
613
+ alt?: 'json' | 'media' | 'proto';
614
+ /** JSONP */
615
+ callback?: string;
616
+ /** Selector specifying which fields to include in a partial response. */
617
+ fields?: string;
618
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
619
+ key?: string;
620
+ /** OAuth 2.0 token for the current user. */
621
+ oauth_token?: string;
622
+ /** Returns response with indentations and line breaks. */
623
+ prettyPrint?: boolean;
624
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
625
+ quotaUser?: string;
626
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
627
+ upload_protocol?: string;
628
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
629
+ uploadType?: string;
630
+ },
631
+ body: CreateDomainRequest,
632
+ ): Request<Domain>;
633
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Deletes a domain from the user's account. Returns NOT_FOUND if the domain is not registered by the user. */
634
+ delete(request?: {
635
+ /** V1 error format. */
636
+ '$.xgafv'?: '1' | '2';
637
+ /** OAuth access token. */
638
+ access_token?: string;
639
+ /** Data format for response. */
640
+ alt?: 'json' | 'media' | 'proto';
641
+ /** JSONP */
642
+ callback?: string;
643
+ /** Selector specifying which fields to include in a partial response. */
644
+ fields?: string;
645
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
646
+ key?: string;
647
+ /** Required. The domain to delete. */
648
+ name: string;
649
+ /** OAuth 2.0 token for the current user. */
650
+ oauth_token?: string;
651
+ /** Returns response with indentations and line breaks. */
652
+ prettyPrint?: boolean;
653
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
654
+ quotaUser?: string;
655
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
656
+ upload_protocol?: string;
657
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
658
+ uploadType?: string;
659
+ }): Request<{}>;
293
660
  /** Retrieves detailed information about a domain registered by you. Returns NOT_FOUND if the domain is not registered by you. Domain represents the metadata of a domain that has been registered within the system and linked to a user. */
294
661
  get(request?: {
295
662
  /** V1 error format. */
@@ -344,6 +711,38 @@ declare namespace gapi.client {
344
711
  /** Legacy upload protocol for media (e.g. "media", "multipart"). */
345
712
  uploadType?: string;
346
713
  }): Request<DomainComplianceStatus>;
714
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Gets a verification token used for verifying a user's ownership over a domain. */
715
+ getVerificationToken(request?: {
716
+ /** V1 error format. */
717
+ '$.xgafv'?: '1' | '2';
718
+ /** OAuth access token. */
719
+ access_token?: string;
720
+ /** Data format for response. */
721
+ alt?: 'json' | 'media' | 'proto';
722
+ /** JSONP */
723
+ callback?: string;
724
+ /** Selector specifying which fields to include in a partial response. */
725
+ fields?: string;
726
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
727
+ key?: string;
728
+ /** Required. The resource name of the verification token to retrieve. Format: `domains/{domain}/verificationToken` */
729
+ name: string;
730
+ /** OAuth 2.0 token for the current user. */
731
+ oauth_token?: string;
732
+ /** Returns response with indentations and line breaks. */
733
+ prettyPrint?: boolean;
734
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
735
+ quotaUser?: string;
736
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
737
+ upload_protocol?: string;
738
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
739
+ uploadType?: string;
740
+ /** Required. The verification method used. Must be specified, i.e. TXT or CNAME. */
741
+ verificationMethod?:
742
+ | 'DOMAIN_VERIFICATION_METHOD_UNSPECIFIED'
743
+ | 'TXT'
744
+ | 'CNAME';
745
+ }): Request<DomainVerificationToken>;
347
746
  /** Retrieves a list of all domains registered by you, along with their corresponding metadata. The order of domains in the response is unspecified and non-deterministic. Newly registered domains will not necessarily be added to the end of this list. */
348
747
  list(request?: {
349
748
  /** V1 error format. */
@@ -373,7 +772,66 @@ declare namespace gapi.client {
373
772
  /** Legacy upload protocol for media (e.g. "media", "multipart"). */
374
773
  uploadType?: string;
375
774
  }): Request<ListDomainsResponse>;
775
+ /** [Developer Preview](https://developers.google.com/workspace/preview): Verifies a user's ownership of a domain at the DNS level. Note that this is distinct from checking if the user has OWNER status within IRDB. */
776
+ verify(request: {
777
+ /** V1 error format. */
778
+ '$.xgafv'?: '1' | '2';
779
+ /** OAuth access token. */
780
+ access_token?: string;
781
+ /** Data format for response. */
782
+ alt?: 'json' | 'media' | 'proto';
783
+ /** JSONP */
784
+ callback?: string;
785
+ /** Selector specifying which fields to include in a partial response. */
786
+ fields?: string;
787
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
788
+ key?: string;
789
+ /** Required. The domain to verify. */
790
+ name: string;
791
+ /** OAuth 2.0 token for the current user. */
792
+ oauth_token?: string;
793
+ /** Returns response with indentations and line breaks. */
794
+ prettyPrint?: boolean;
795
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
796
+ quotaUser?: string;
797
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
798
+ upload_protocol?: string;
799
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
800
+ uploadType?: string;
801
+ /** Request body */
802
+ resource: VerifyDomainRequest;
803
+ }): Request<{}>;
804
+ verify(
805
+ request: {
806
+ /** V1 error format. */
807
+ '$.xgafv'?: '1' | '2';
808
+ /** OAuth access token. */
809
+ access_token?: string;
810
+ /** Data format for response. */
811
+ alt?: 'json' | 'media' | 'proto';
812
+ /** JSONP */
813
+ callback?: string;
814
+ /** Selector specifying which fields to include in a partial response. */
815
+ fields?: string;
816
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
817
+ key?: string;
818
+ /** Required. The domain to verify. */
819
+ name: string;
820
+ /** OAuth 2.0 token for the current user. */
821
+ oauth_token?: string;
822
+ /** Returns response with indentations and line breaks. */
823
+ prettyPrint?: boolean;
824
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
825
+ quotaUser?: string;
826
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
827
+ upload_protocol?: string;
828
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
829
+ uploadType?: string;
830
+ },
831
+ body: VerifyDomainRequest,
832
+ ): Request<{}>;
376
833
  domainStats: DomainStatsResource;
834
+ users: UsersResource;
377
835
  }
378
836
  interface DomainStatsResource {
379
837
  /** Executes a batch of QueryDomainStats requests for multiple domains. Returns PERMISSION_DENIED if you don't have permission to access DomainStats for any of the requested domains. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maxim_mazurok/gapi.client.gmailpostmastertools-v2",
3
- "version": "0.1.20260621",
3
+ "version": "0.1.20260623",
4
4
  "description": "TypeScript typings for Gmail Postmaster Tools API v2",
5
5
  "repository": {
6
6
  "type": "git",
package/readme.md CHANGED
@@ -73,6 +73,9 @@ var client_id = '',
73
73
 
74
74
  // Get email traffic metrics for the domains you have registered with Postmaster Tools
75
75
  'https://www.googleapis.com/auth/postmaster.traffic.readonly',
76
+
77
+ // View and manage users for the domains you have registered with Postmaster Tools
78
+ 'https://www.googleapis.com/auth/postmaster.user',
76
79
  ],
77
80
  immediate = true;
78
81
  // ...
@@ -92,6 +95,16 @@ gapi.auth.authorize(
92
95
  After that you can use Gmail Postmaster Tools API resources: <!-- TODO: make this work for multiple namespaces -->
93
96
 
94
97
  ```typescript
98
+ /*
99
+ [Developer Preview](https://developers.google.com/workspace/preview): Adds a domain to the user's account. Returns INVALID_ARGUMENT if a domain is not provided. Returns ALREADY_EXISTS if the domain is already registered by the user.
100
+ */
101
+ await gapi.client.gmailpostmastertools.domains.create({});
102
+
103
+ /*
104
+ [Developer Preview](https://developers.google.com/workspace/preview): Deletes a domain from the user's account. Returns NOT_FOUND if the domain is not registered by the user.
105
+ */
106
+ await gapi.client.gmailpostmastertools.domains.delete({name: 'name'});
107
+
95
108
  /*
96
109
  Retrieves detailed information about a domain registered by you. Returns NOT_FOUND if the domain is not registered by you. Domain represents the metadata of a domain that has been registered within the system and linked to a user.
97
110
  */
@@ -104,11 +117,23 @@ await gapi.client.gmailpostmastertools.domains.getComplianceStatus({
104
117
  name: 'name',
105
118
  });
106
119
 
120
+ /*
121
+ [Developer Preview](https://developers.google.com/workspace/preview): Gets a verification token used for verifying a user's ownership over a domain.
122
+ */
123
+ await gapi.client.gmailpostmastertools.domains.getVerificationToken({
124
+ name: 'name',
125
+ });
126
+
107
127
  /*
108
128
  Retrieves a list of all domains registered by you, along with their corresponding metadata. The order of domains in the response is unspecified and non-deterministic. Newly registered domains will not necessarily be added to the end of this list.
109
129
  */
110
130
  await gapi.client.gmailpostmastertools.domains.list({});
111
131
 
132
+ /*
133
+ [Developer Preview](https://developers.google.com/workspace/preview): Verifies a user's ownership of a domain at the DNS level. Note that this is distinct from checking if the user has OWNER status within IRDB.
134
+ */
135
+ await gapi.client.gmailpostmastertools.domains.verify({name: 'name'});
136
+
112
137
  /*
113
138
  Executes a batch of QueryDomainStats requests for multiple domains. Returns PERMISSION_DENIED if you don't have permission to access DomainStats for any of the requested domains.
114
139
  */