@randock/nameshift-api-client 0.0.316 → 0.0.317
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/.openapi-generator/FILES +6 -0
- package/README.md +3 -3
- package/dist/apis/NotificationsApi.d.ts +70 -0
- package/dist/apis/NotificationsApi.js +309 -0
- package/dist/apis/index.d.ts +1 -0
- package/dist/apis/index.js +1 -0
- package/dist/models/BulkMarkNotificationsAsReadInputDto.d.ts +38 -0
- package/dist/models/BulkMarkNotificationsAsReadInputDto.js +55 -0
- package/dist/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.d.ts +1 -0
- package/dist/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.js +2 -1
- package/dist/models/ListNotifications200Response.d.ts +47 -0
- package/dist/models/ListNotifications200Response.js +62 -0
- package/dist/models/UserNotificationAttachmentDto.d.ts +44 -0
- package/dist/models/UserNotificationAttachmentDto.js +59 -0
- package/dist/models/UserNotificationDto.d.ts +132 -0
- package/dist/models/UserNotificationDto.js +139 -0
- package/dist/models/UserNotificationListItemDto.d.ts +125 -0
- package/dist/models/UserNotificationListItemDto.js +134 -0
- package/dist/models/index.d.ts +5 -0
- package/dist/models/index.js +5 -0
- package/package.json +1 -1
- package/src/apis/NotificationsApi.ts +251 -0
- package/src/apis/index.ts +1 -0
- package/src/models/BulkMarkNotificationsAsReadInputDto.ts +75 -0
- package/src/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.ts +2 -1
- package/src/models/ListNotifications200Response.ts +106 -0
- package/src/models/UserNotificationAttachmentDto.ts +84 -0
- package/src/models/UserNotificationDto.ts +194 -0
- package/src/models/UserNotificationListItemDto.ts +177 -0
- package/src/models/index.ts +5 -0
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Nameshift
|
|
6
|
+
* Nameshift API
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.UserNotificationListItemDtoTypeEnum = void 0;
|
|
17
|
+
exports.instanceOfUserNotificationListItemDto = instanceOfUserNotificationListItemDto;
|
|
18
|
+
exports.UserNotificationListItemDtoFromJSON = UserNotificationListItemDtoFromJSON;
|
|
19
|
+
exports.UserNotificationListItemDtoFromJSONTyped = UserNotificationListItemDtoFromJSONTyped;
|
|
20
|
+
exports.UserNotificationListItemDtoToJSON = UserNotificationListItemDtoToJSON;
|
|
21
|
+
exports.UserNotificationListItemDtoToJSONTyped = UserNotificationListItemDtoToJSONTyped;
|
|
22
|
+
/**
|
|
23
|
+
* @export
|
|
24
|
+
*/
|
|
25
|
+
exports.UserNotificationListItemDtoTypeEnum = {
|
|
26
|
+
DOMAIN_OFFER_EMAIL_VERIFICATION: 'domain_offer_email_verification',
|
|
27
|
+
ACCOUNT_REGISTERED: 'account_registered',
|
|
28
|
+
ACCOUNT_ONBOARDING_FINISHED: 'account_onboarding_finished',
|
|
29
|
+
ACCOUNT_ONBOARDING_REJECTED: 'account_onboarding_rejected',
|
|
30
|
+
BUYER_ACCESS_TOKEN: 'buyer_access_token',
|
|
31
|
+
PURCHASES_ARE_CLOSED_DUE_DOMAINS_IS_SOLD_OR_DELETED: 'purchases_are_closed_due_domains_is_sold_or_deleted',
|
|
32
|
+
DOMAIN_OWNER_CHANGED: 'domain_owner_changed',
|
|
33
|
+
DOMAIN_SOLD_SELLER_NOTIFICATION: 'domain_sold_seller_notification',
|
|
34
|
+
DOMAIN_SOLD_BY_LEASE_TO_OWN_SELLER_NOTIFICATION: 'domain_sold_by_lease_to_own_seller_notification',
|
|
35
|
+
DOMAIN_SOLD_BY_RENT_SELLER_NOTIFICATION: 'domain_sold_by_rent_seller_notification',
|
|
36
|
+
DOMAIN_TRANSFER_VALIDATION_AUTO_CONFIRMED_EMAIL: 'domain_transfer_validation_auto_confirmed_email',
|
|
37
|
+
DOMAIN_TRANSFER_VALIDATION_REQUIRED_BY_BUYER_EMAIL: 'domain_transfer_validation_required_by_buyer_email',
|
|
38
|
+
DOMAIN_TRANSFER_COMPLETED_FOR_SELLER: 'domain_transfer.completed_for_seller',
|
|
39
|
+
DOMAIN_TRANSFER_REQUEST_AUTH_CODE_TO_SELLER: 'domain_transfer.request_auth_code_to_seller',
|
|
40
|
+
DOMAIN_TRANSFER_REQUEST_AUTH_CODE_TO_SELLER_REMINDER: 'domain_transfer.request_auth_code_to_seller.reminder',
|
|
41
|
+
DOMAIN_TRANSFER_REQUEST_AUTH_CODE_TO_SELLER_AUTH_CODE_INVALID: 'domain_transfer.request_auth_code_to_seller_auth_code_invalid',
|
|
42
|
+
DOMAIN_TRANSFER_DOMAIN_TRANSFER_REQUIRES_UNLOCK_DOMAIN: 'domain_transfer.domain_transfer_requires_unlock_domain',
|
|
43
|
+
DOMAIN_TRANSFER_NOTIFY_BUYER_TO_INITIALIZE_TRANSFER: 'domain_transfer.notify_buyer_to_initialize_transfer',
|
|
44
|
+
DOMAIN_TRANSFER_NOTIFY_SELLER_TO_INITIALIZE_TRANSFER: 'domain_transfer.notify_seller_to_initialize_transfer',
|
|
45
|
+
DOMAIN_TRANSFER_RECREATE_DOMAIN_IN_SELLER_ACCOUNT_ERROR: 'domain_transfer.recreate_domain_in_seller_account_error',
|
|
46
|
+
DOMAIN_TRANSFER_SEND_IPS_TAG_INSTRUCTIONS_TO_SELLER: 'domain_transfer.send_ips_tag_instructions_to_seller',
|
|
47
|
+
DOMAIN_TRANSFER_SEND_IPS_TAG_INSTRUCTIONS_TO_SELLER_REMINDER: 'domain_transfer.send_ips_tag_instructions_to_seller_reminder',
|
|
48
|
+
DOMAIN_TRANSFER_SEND_IPS_TAG_INSTRUCTIONS_TO_BUYER: 'domain_transfer.send_ips_tag_instructions_to_buyer',
|
|
49
|
+
DOMAIN_TRANSFER_SEND_IPS_TAG_INSTRUCTIONS_TO_START_TRANSFER_TO_SELLER: 'domain_transfer.send_ips_tag_instructions_to_start_transfer_to_seller',
|
|
50
|
+
DOMAIN_TRANSFER_RENT_SUBSCRIPTION_SEND_OWNED_DOMAIN_AUTH_CODE_TO_SELLER: 'domain_transfer.rent_subscription_send_owned_domain_auth_code_to_seller',
|
|
51
|
+
DOMAIN_TRANSFER_LEASE_TO_OWN_SUBSCRIPTION_SEND_OWNED_DOMAIN_AUTH_CODE_TO_SELLER: 'domain_transfer.lease_to_own_subscription_send_owned_domain_auth_code_to_seller',
|
|
52
|
+
REQUEST_IPS_TAG_TO_BUYER_IPS_TAG_INVALID: 'request_ips_tag_to_buyer_ips_tag_invalid',
|
|
53
|
+
REQUEST_IPS_TAG_TO_SELLER_IPS_TAG_INVALID: 'request_ips_tag_to_seller_ips_tag_invalid',
|
|
54
|
+
LEAD_CLOSED_SELLER: 'lead.closed.seller',
|
|
55
|
+
LEAD_CLOSED_BUYER: 'lead.closed.buyer',
|
|
56
|
+
ORDER_HAS_BEEN_PAID: 'order_has_been_paid',
|
|
57
|
+
EXPORT_COMPLETED: 'export_completed',
|
|
58
|
+
DOMAIN_IMPORT_FINISHED: 'domain_import_finished',
|
|
59
|
+
SELLER_PAYOUT_WAS_PAID: 'seller_payout_was_paid',
|
|
60
|
+
DOMAIN_OFFER_VERIFIED_BUYER_ACCESS_LINK_EMAIL: 'domain_offer_verified_buyer_access_link_email',
|
|
61
|
+
DOMAIN_OFFER_ACCEPTED_CONTINUE_ORDER_EMAIL: 'domain_offer_accepted_continue_order_email',
|
|
62
|
+
DOMAIN_OFFER_ACCEPTED_CONTINUE_LEASE_TO_OWN_EMAIL: 'domain_offer_accepted_continue_lease_to_own_email',
|
|
63
|
+
DOMAIN_OFFER_ACCEPTED_CONTINUE_LEASE_TO_OWN_EMAIL_INSTALLMENTS_RANGE: 'domain_offer_accepted_continue_lease_to_own_email_installments_range',
|
|
64
|
+
DOMAIN_OFFER_ACCEPTED_CONTINUE_RENT_EMAIL: 'domain_offer_accepted_continue_rent_email',
|
|
65
|
+
LEASE_TO_OWN_SUBSCRIPTION_RENEW_FAILED: 'lease_to_own_subscription_renew_failed',
|
|
66
|
+
LEASE_TO_OWN_SUBSCRIPTION_RENEW_FAILED_REQUIRE_CUSTOMER_ACTION: 'lease_to_own_subscription_renew_failed_require_customer_action',
|
|
67
|
+
RENT_SUBSCRIPTION_RENEW_FAILED: 'rent_subscription_renew_failed',
|
|
68
|
+
RENT_SUBSCRIPTION_RENEW_FAILED_REQUIRE_CUSTOMER_ACTION: 'rent_subscription_renew_failed_require_customer_action',
|
|
69
|
+
LEASE_TO_OWN_SUBSCRIPTION_CANCELLED: 'lease_to_own_subscription_cancelled',
|
|
70
|
+
RENT_SUBSCRIPTION_CANCELLED: 'rent_subscription_cancelled',
|
|
71
|
+
SELLER_LEASE_TO_OWN_SUBSCRIPTION_CANCELLED: 'seller_lease_to_own_subscription_cancelled',
|
|
72
|
+
SELLER_RENT_SUBSCRIPTION_CANCELLED: 'seller_rent_subscription_cancelled',
|
|
73
|
+
LEASE_TO_OWN_SUBSCRIPTION_HAS_BEEN_ACTIVATED_FOR_FIRST_TIME: 'lease_to_own_subscription_has_been_activated_for_first_time',
|
|
74
|
+
RENT_SUBSCRIPTION_HAS_BEEN_ACTIVATED_FOR_FIRST_TIME: 'rent_subscription_has_been_activated_for_first_time',
|
|
75
|
+
PASSWORD_RESET: 'password_reset',
|
|
76
|
+
BUYER_INVOICE: 'buyer_invoice',
|
|
77
|
+
BUYER_LEASE_TO_OWN_INSTALLMENT_INVOICE: 'buyer_lease_to_own_installment_invoice',
|
|
78
|
+
BUYER_RENT_INSTALLMENT_INVOICE: 'buyer_rent_installment_invoice',
|
|
79
|
+
SELLER_INVOICE: 'seller_invoice',
|
|
80
|
+
SELLER_LEASE_TO_OWN_INSTALLMENT_INVOICE: 'seller_lease_to_own_installment_invoice',
|
|
81
|
+
SELLER_RENT_INSTALLMENT_INVOICE: 'seller_rent_installment_invoice',
|
|
82
|
+
AFFILIATE_COMMISSIONS_INVOICE: 'affiliate_commissions_invoice'
|
|
83
|
+
};
|
|
84
|
+
/**
|
|
85
|
+
* Check if a given object implements the UserNotificationListItemDto interface.
|
|
86
|
+
*/
|
|
87
|
+
function instanceOfUserNotificationListItemDto(value) {
|
|
88
|
+
if (!('id' in value) || value['id'] === undefined)
|
|
89
|
+
return false;
|
|
90
|
+
if (!('type' in value) || value['type'] === undefined)
|
|
91
|
+
return false;
|
|
92
|
+
if (!('isRead' in value) || value['isRead'] === undefined)
|
|
93
|
+
return false;
|
|
94
|
+
if (!('sentAt' in value) || value['sentAt'] === undefined)
|
|
95
|
+
return false;
|
|
96
|
+
if (!('subject' in value) || value['subject'] === undefined)
|
|
97
|
+
return false;
|
|
98
|
+
if (!('hasAttachments' in value) || value['hasAttachments'] === undefined)
|
|
99
|
+
return false;
|
|
100
|
+
return true;
|
|
101
|
+
}
|
|
102
|
+
function UserNotificationListItemDtoFromJSON(json) {
|
|
103
|
+
return UserNotificationListItemDtoFromJSONTyped(json, false);
|
|
104
|
+
}
|
|
105
|
+
function UserNotificationListItemDtoFromJSONTyped(json, ignoreDiscriminator) {
|
|
106
|
+
if (json == null) {
|
|
107
|
+
return json;
|
|
108
|
+
}
|
|
109
|
+
return {
|
|
110
|
+
'id': json['id'],
|
|
111
|
+
'type': json['type'],
|
|
112
|
+
'isRead': json['isRead'],
|
|
113
|
+
'sentAt': (new Date(json['sentAt'])),
|
|
114
|
+
'subject': json['subject'],
|
|
115
|
+
'hasAttachments': json['hasAttachments'],
|
|
116
|
+
};
|
|
117
|
+
}
|
|
118
|
+
function UserNotificationListItemDtoToJSON(json) {
|
|
119
|
+
return UserNotificationListItemDtoToJSONTyped(json, false);
|
|
120
|
+
}
|
|
121
|
+
function UserNotificationListItemDtoToJSONTyped(value, ignoreDiscriminator) {
|
|
122
|
+
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
123
|
+
if (value == null) {
|
|
124
|
+
return value;
|
|
125
|
+
}
|
|
126
|
+
return {
|
|
127
|
+
'id': value['id'],
|
|
128
|
+
'type': value['type'],
|
|
129
|
+
'isRead': value['isRead'],
|
|
130
|
+
'sentAt': ((value['sentAt']).toISOString()),
|
|
131
|
+
'subject': value['subject'],
|
|
132
|
+
'hasAttachments': value['hasAttachments'],
|
|
133
|
+
};
|
|
134
|
+
}
|
package/dist/models/index.d.ts
CHANGED
|
@@ -45,6 +45,7 @@ export * from './BatchReadSellerLeadMessageInput';
|
|
|
45
45
|
export * from './BatchUpdateDomainsInput';
|
|
46
46
|
export * from './BatchVerifyBuyerLeadsInput';
|
|
47
47
|
export * from './BillingInformationDto';
|
|
48
|
+
export * from './BulkMarkNotificationsAsReadInputDto';
|
|
48
49
|
export * from './BuyerDomainTransferAuthCodeDto';
|
|
49
50
|
export * from './BuyerDomainTransferListItemDomainDto';
|
|
50
51
|
export * from './BuyerDomainTransferListItemDto';
|
|
@@ -168,6 +169,7 @@ export * from './ListAccounts200Response';
|
|
|
168
169
|
export * from './ListBankAccounts200Response';
|
|
169
170
|
export * from './ListDomains200Response';
|
|
170
171
|
export * from './ListLeadMessagesDto';
|
|
172
|
+
export * from './ListNotifications200Response';
|
|
171
173
|
export * from './LoginDto';
|
|
172
174
|
export * from './LoginInput';
|
|
173
175
|
export * from './MajesticMetrics';
|
|
@@ -279,6 +281,9 @@ export * from './UpdateOrderInput';
|
|
|
279
281
|
export * from './UpdateSubscriptionBillingPeriodicityInput';
|
|
280
282
|
export * from './UpdateSubscriptionInput';
|
|
281
283
|
export * from './UsBankAccountDetails';
|
|
284
|
+
export * from './UserNotificationAttachmentDto';
|
|
285
|
+
export * from './UserNotificationDto';
|
|
286
|
+
export * from './UserNotificationListItemDto';
|
|
282
287
|
export * from './UserPasswordResetDto';
|
|
283
288
|
export * from './ValidateTaxNumberDto';
|
|
284
289
|
export * from './ValidateTaxNumberInput';
|
package/dist/models/index.js
CHANGED
|
@@ -63,6 +63,7 @@ __exportStar(require("./BatchReadSellerLeadMessageInput"), exports);
|
|
|
63
63
|
__exportStar(require("./BatchUpdateDomainsInput"), exports);
|
|
64
64
|
__exportStar(require("./BatchVerifyBuyerLeadsInput"), exports);
|
|
65
65
|
__exportStar(require("./BillingInformationDto"), exports);
|
|
66
|
+
__exportStar(require("./BulkMarkNotificationsAsReadInputDto"), exports);
|
|
66
67
|
__exportStar(require("./BuyerDomainTransferAuthCodeDto"), exports);
|
|
67
68
|
__exportStar(require("./BuyerDomainTransferListItemDomainDto"), exports);
|
|
68
69
|
__exportStar(require("./BuyerDomainTransferListItemDto"), exports);
|
|
@@ -186,6 +187,7 @@ __exportStar(require("./ListAccounts200Response"), exports);
|
|
|
186
187
|
__exportStar(require("./ListBankAccounts200Response"), exports);
|
|
187
188
|
__exportStar(require("./ListDomains200Response"), exports);
|
|
188
189
|
__exportStar(require("./ListLeadMessagesDto"), exports);
|
|
190
|
+
__exportStar(require("./ListNotifications200Response"), exports);
|
|
189
191
|
__exportStar(require("./LoginDto"), exports);
|
|
190
192
|
__exportStar(require("./LoginInput"), exports);
|
|
191
193
|
__exportStar(require("./MajesticMetrics"), exports);
|
|
@@ -297,6 +299,9 @@ __exportStar(require("./UpdateOrderInput"), exports);
|
|
|
297
299
|
__exportStar(require("./UpdateSubscriptionBillingPeriodicityInput"), exports);
|
|
298
300
|
__exportStar(require("./UpdateSubscriptionInput"), exports);
|
|
299
301
|
__exportStar(require("./UsBankAccountDetails"), exports);
|
|
302
|
+
__exportStar(require("./UserNotificationAttachmentDto"), exports);
|
|
303
|
+
__exportStar(require("./UserNotificationDto"), exports);
|
|
304
|
+
__exportStar(require("./UserNotificationListItemDto"), exports);
|
|
300
305
|
__exportStar(require("./UserPasswordResetDto"), exports);
|
|
301
306
|
__exportStar(require("./ValidateTaxNumberDto"), exports);
|
|
302
307
|
__exportStar(require("./ValidateTaxNumberInput"), exports);
|
package/package.json
CHANGED
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift API
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
import * as runtime from '../runtime';
|
|
17
|
+
import type {
|
|
18
|
+
BulkMarkNotificationsAsReadInputDto,
|
|
19
|
+
ListNotifications200Response,
|
|
20
|
+
NotFoundException,
|
|
21
|
+
ThrottlerException,
|
|
22
|
+
UserNotificationDto,
|
|
23
|
+
ValidationException,
|
|
24
|
+
} from '../models/index';
|
|
25
|
+
import {
|
|
26
|
+
BulkMarkNotificationsAsReadInputDtoFromJSON,
|
|
27
|
+
BulkMarkNotificationsAsReadInputDtoToJSON,
|
|
28
|
+
ListNotifications200ResponseFromJSON,
|
|
29
|
+
ListNotifications200ResponseToJSON,
|
|
30
|
+
NotFoundExceptionFromJSON,
|
|
31
|
+
NotFoundExceptionToJSON,
|
|
32
|
+
ThrottlerExceptionFromJSON,
|
|
33
|
+
ThrottlerExceptionToJSON,
|
|
34
|
+
UserNotificationDtoFromJSON,
|
|
35
|
+
UserNotificationDtoToJSON,
|
|
36
|
+
ValidationExceptionFromJSON,
|
|
37
|
+
ValidationExceptionToJSON,
|
|
38
|
+
} from '../models/index';
|
|
39
|
+
|
|
40
|
+
export interface NotificationsApiBulkMarkNotificationsAsReadRequest {
|
|
41
|
+
bulkMarkNotificationsAsReadInputDto: BulkMarkNotificationsAsReadInputDto;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export interface NotificationsApiDownloadNotificationAttachmentRequest {
|
|
45
|
+
notificationId: string;
|
|
46
|
+
attachmentId: string;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface NotificationsApiGetNotificationByIdRequest {
|
|
50
|
+
notificationId: string;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export interface NotificationsApiListNotificationsRequest {
|
|
54
|
+
filter?: object;
|
|
55
|
+
page?: number;
|
|
56
|
+
limit?: number;
|
|
57
|
+
sortBy?: Array<string>;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
*
|
|
62
|
+
*/
|
|
63
|
+
export class NotificationsApi extends runtime.BaseAPI {
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Mark multiple notifications as read (true) or unread (false) based on the readStatus parameter
|
|
67
|
+
* Bulk mark notifications as read or unread
|
|
68
|
+
*/
|
|
69
|
+
async bulkMarkNotificationsAsReadRaw(requestParameters: NotificationsApiBulkMarkNotificationsAsReadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
70
|
+
if (requestParameters['bulkMarkNotificationsAsReadInputDto'] == null) {
|
|
71
|
+
throw new runtime.RequiredError(
|
|
72
|
+
'bulkMarkNotificationsAsReadInputDto',
|
|
73
|
+
'Required parameter "bulkMarkNotificationsAsReadInputDto" was null or undefined when calling bulkMarkNotificationsAsRead().'
|
|
74
|
+
);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
const queryParameters: any = {};
|
|
78
|
+
|
|
79
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
80
|
+
|
|
81
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
82
|
+
|
|
83
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
84
|
+
const token = this.configuration.accessToken;
|
|
85
|
+
const tokenString = await token("bearer", []);
|
|
86
|
+
|
|
87
|
+
if (tokenString) {
|
|
88
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
const response = await this.request({
|
|
92
|
+
path: `/private/notifications/bulk-mark-as-read`,
|
|
93
|
+
method: 'PATCH',
|
|
94
|
+
headers: headerParameters,
|
|
95
|
+
query: queryParameters,
|
|
96
|
+
body: BulkMarkNotificationsAsReadInputDtoToJSON(requestParameters['bulkMarkNotificationsAsReadInputDto']),
|
|
97
|
+
}, initOverrides);
|
|
98
|
+
|
|
99
|
+
return new runtime.VoidApiResponse(response);
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* Mark multiple notifications as read (true) or unread (false) based on the readStatus parameter
|
|
104
|
+
* Bulk mark notifications as read or unread
|
|
105
|
+
*/
|
|
106
|
+
async bulkMarkNotificationsAsRead(requestParameters: NotificationsApiBulkMarkNotificationsAsReadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
107
|
+
await this.bulkMarkNotificationsAsReadRaw(requestParameters, initOverrides);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* Download a specific notification attachment by attachment ID
|
|
112
|
+
* Download notification attachment
|
|
113
|
+
*/
|
|
114
|
+
async downloadNotificationAttachmentRaw(requestParameters: NotificationsApiDownloadNotificationAttachmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Blob>> {
|
|
115
|
+
if (requestParameters['notificationId'] == null) {
|
|
116
|
+
throw new runtime.RequiredError(
|
|
117
|
+
'notificationId',
|
|
118
|
+
'Required parameter "notificationId" was null or undefined when calling downloadNotificationAttachment().'
|
|
119
|
+
);
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
if (requestParameters['attachmentId'] == null) {
|
|
123
|
+
throw new runtime.RequiredError(
|
|
124
|
+
'attachmentId',
|
|
125
|
+
'Required parameter "attachmentId" was null or undefined when calling downloadNotificationAttachment().'
|
|
126
|
+
);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
const queryParameters: any = {};
|
|
130
|
+
|
|
131
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
132
|
+
|
|
133
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
134
|
+
const token = this.configuration.accessToken;
|
|
135
|
+
const tokenString = await token("bearer", []);
|
|
136
|
+
|
|
137
|
+
if (tokenString) {
|
|
138
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
const response = await this.request({
|
|
142
|
+
path: `/private/notifications/{notificationId}/attachments/{attachmentId}/download`.replace(`{${"notificationId"}}`, encodeURIComponent(String(requestParameters['notificationId']))).replace(`{${"attachmentId"}}`, encodeURIComponent(String(requestParameters['attachmentId']))),
|
|
143
|
+
method: 'GET',
|
|
144
|
+
headers: headerParameters,
|
|
145
|
+
query: queryParameters,
|
|
146
|
+
}, initOverrides);
|
|
147
|
+
|
|
148
|
+
return new runtime.BlobApiResponse(response);
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* Download a specific notification attachment by attachment ID
|
|
153
|
+
* Download notification attachment
|
|
154
|
+
*/
|
|
155
|
+
async downloadNotificationAttachment(requestParameters: NotificationsApiDownloadNotificationAttachmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Blob> {
|
|
156
|
+
const response = await this.downloadNotificationAttachmentRaw(requestParameters, initOverrides);
|
|
157
|
+
return await response.value();
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
/**
|
|
161
|
+
*
|
|
162
|
+
*/
|
|
163
|
+
async getNotificationByIdRaw(requestParameters: NotificationsApiGetNotificationByIdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<UserNotificationDto>> {
|
|
164
|
+
if (requestParameters['notificationId'] == null) {
|
|
165
|
+
throw new runtime.RequiredError(
|
|
166
|
+
'notificationId',
|
|
167
|
+
'Required parameter "notificationId" was null or undefined when calling getNotificationById().'
|
|
168
|
+
);
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
const queryParameters: any = {};
|
|
172
|
+
|
|
173
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
174
|
+
|
|
175
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
176
|
+
const token = this.configuration.accessToken;
|
|
177
|
+
const tokenString = await token("bearer", []);
|
|
178
|
+
|
|
179
|
+
if (tokenString) {
|
|
180
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
const response = await this.request({
|
|
184
|
+
path: `/private/notifications/{notificationId}`.replace(`{${"notificationId"}}`, encodeURIComponent(String(requestParameters['notificationId']))),
|
|
185
|
+
method: 'GET',
|
|
186
|
+
headers: headerParameters,
|
|
187
|
+
query: queryParameters,
|
|
188
|
+
}, initOverrides);
|
|
189
|
+
|
|
190
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => UserNotificationDtoFromJSON(jsonValue));
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
/**
|
|
194
|
+
*
|
|
195
|
+
*/
|
|
196
|
+
async getNotificationById(requestParameters: NotificationsApiGetNotificationByIdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<UserNotificationDto> {
|
|
197
|
+
const response = await this.getNotificationByIdRaw(requestParameters, initOverrides);
|
|
198
|
+
return await response.value();
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
/**
|
|
202
|
+
*
|
|
203
|
+
*/
|
|
204
|
+
async listNotificationsRaw(requestParameters: NotificationsApiListNotificationsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListNotifications200Response>> {
|
|
205
|
+
const queryParameters: any = {};
|
|
206
|
+
|
|
207
|
+
if (requestParameters['filter'] != null) {
|
|
208
|
+
queryParameters['filter'] = requestParameters['filter'];
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
if (requestParameters['page'] != null) {
|
|
212
|
+
queryParameters['page'] = requestParameters['page'];
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
if (requestParameters['limit'] != null) {
|
|
216
|
+
queryParameters['limit'] = requestParameters['limit'];
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
if (requestParameters['sortBy'] != null) {
|
|
220
|
+
queryParameters['sortBy'] = requestParameters['sortBy'];
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
224
|
+
|
|
225
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
226
|
+
const token = this.configuration.accessToken;
|
|
227
|
+
const tokenString = await token("bearer", []);
|
|
228
|
+
|
|
229
|
+
if (tokenString) {
|
|
230
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
const response = await this.request({
|
|
234
|
+
path: `/private/notifications`,
|
|
235
|
+
method: 'GET',
|
|
236
|
+
headers: headerParameters,
|
|
237
|
+
query: queryParameters,
|
|
238
|
+
}, initOverrides);
|
|
239
|
+
|
|
240
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ListNotifications200ResponseFromJSON(jsonValue));
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
/**
|
|
244
|
+
*
|
|
245
|
+
*/
|
|
246
|
+
async listNotifications(requestParameters: NotificationsApiListNotificationsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListNotifications200Response> {
|
|
247
|
+
const response = await this.listNotificationsRaw(requestParameters, initOverrides);
|
|
248
|
+
return await response.value();
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
}
|
package/src/apis/index.ts
CHANGED
|
@@ -13,6 +13,7 @@ export * from './EppApi';
|
|
|
13
13
|
export * from './InvoicesApi';
|
|
14
14
|
export * from './LeadsApi';
|
|
15
15
|
export * from './LeadsPublicApi';
|
|
16
|
+
export * from './NotificationsApi';
|
|
16
17
|
export * from './OrdersPublicApi';
|
|
17
18
|
export * from './SalesPublicApi';
|
|
18
19
|
export * from './StatsApi';
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift API
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface BulkMarkNotificationsAsReadInputDto
|
|
20
|
+
*/
|
|
21
|
+
export interface BulkMarkNotificationsAsReadInputDto {
|
|
22
|
+
/**
|
|
23
|
+
* Array of notification IDs to mark with the specified read status
|
|
24
|
+
* @type {Array<string>}
|
|
25
|
+
* @memberof BulkMarkNotificationsAsReadInputDto
|
|
26
|
+
*/
|
|
27
|
+
notificationIds: Array<string>;
|
|
28
|
+
/**
|
|
29
|
+
* Whether to mark notifications as read (true) or unread (false)
|
|
30
|
+
* @type {boolean}
|
|
31
|
+
* @memberof BulkMarkNotificationsAsReadInputDto
|
|
32
|
+
*/
|
|
33
|
+
readStatus: boolean;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Check if a given object implements the BulkMarkNotificationsAsReadInputDto interface.
|
|
38
|
+
*/
|
|
39
|
+
export function instanceOfBulkMarkNotificationsAsReadInputDto(value: object): value is BulkMarkNotificationsAsReadInputDto {
|
|
40
|
+
if (!('notificationIds' in value) || value['notificationIds'] === undefined) return false;
|
|
41
|
+
if (!('readStatus' in value) || value['readStatus'] === undefined) return false;
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function BulkMarkNotificationsAsReadInputDtoFromJSON(json: any): BulkMarkNotificationsAsReadInputDto {
|
|
46
|
+
return BulkMarkNotificationsAsReadInputDtoFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function BulkMarkNotificationsAsReadInputDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): BulkMarkNotificationsAsReadInputDto {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'notificationIds': json['notificationIds'],
|
|
56
|
+
'readStatus': json['readStatus'],
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function BulkMarkNotificationsAsReadInputDtoToJSON(json: any): BulkMarkNotificationsAsReadInputDto {
|
|
61
|
+
return BulkMarkNotificationsAsReadInputDtoToJSONTyped(json, false);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export function BulkMarkNotificationsAsReadInputDtoToJSONTyped(value?: BulkMarkNotificationsAsReadInputDto | null, ignoreDiscriminator: boolean = false): any {
|
|
65
|
+
if (value == null) {
|
|
66
|
+
return value;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
return {
|
|
70
|
+
|
|
71
|
+
'notificationIds': value['notificationIds'],
|
|
72
|
+
'readStatus': value['readStatus'],
|
|
73
|
+
};
|
|
74
|
+
}
|
|
75
|
+
|
package/src/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.ts
CHANGED
|
@@ -145,7 +145,8 @@ export const IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatur
|
|
|
145
145
|
AFFILIATE_PROGRAM: 'AFFILIATE_PROGRAM',
|
|
146
146
|
DOMAIN_AFFILIATE_PROGRAM: 'DOMAIN_AFFILIATE_PROGRAM',
|
|
147
147
|
SELLER_STATS_DASHBOARD: 'SELLER_STATS_DASHBOARD',
|
|
148
|
-
SELLER_TRANSFER_COSTS_PAYMENT: 'SELLER_TRANSFER_COSTS_PAYMENT'
|
|
148
|
+
SELLER_TRANSFER_COSTS_PAYMENT: 'SELLER_TRANSFER_COSTS_PAYMENT',
|
|
149
|
+
NOTIFICATIONS_MANAGER: 'NOTIFICATIONS_MANAGER'
|
|
149
150
|
} as const;
|
|
150
151
|
export type IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDtoEnabledFeaturesEnum = typeof IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDtoEnabledFeaturesEnum[keyof typeof IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDtoEnabledFeaturesEnum];
|
|
151
152
|
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift API
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { PaginateResponseLinks } from './PaginateResponseLinks';
|
|
17
|
+
import {
|
|
18
|
+
PaginateResponseLinksFromJSON,
|
|
19
|
+
PaginateResponseLinksFromJSONTyped,
|
|
20
|
+
PaginateResponseLinksToJSON,
|
|
21
|
+
PaginateResponseLinksToJSONTyped,
|
|
22
|
+
} from './PaginateResponseLinks';
|
|
23
|
+
import type { UserNotificationListItemDto } from './UserNotificationListItemDto';
|
|
24
|
+
import {
|
|
25
|
+
UserNotificationListItemDtoFromJSON,
|
|
26
|
+
UserNotificationListItemDtoFromJSONTyped,
|
|
27
|
+
UserNotificationListItemDtoToJSON,
|
|
28
|
+
UserNotificationListItemDtoToJSONTyped,
|
|
29
|
+
} from './UserNotificationListItemDto';
|
|
30
|
+
import type { PaginateResponseMeta } from './PaginateResponseMeta';
|
|
31
|
+
import {
|
|
32
|
+
PaginateResponseMetaFromJSON,
|
|
33
|
+
PaginateResponseMetaFromJSONTyped,
|
|
34
|
+
PaginateResponseMetaToJSON,
|
|
35
|
+
PaginateResponseMetaToJSONTyped,
|
|
36
|
+
} from './PaginateResponseMeta';
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @export
|
|
41
|
+
* @interface ListNotifications200Response
|
|
42
|
+
*/
|
|
43
|
+
export interface ListNotifications200Response {
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {Array<UserNotificationListItemDto>}
|
|
47
|
+
* @memberof ListNotifications200Response
|
|
48
|
+
*/
|
|
49
|
+
data: Array<UserNotificationListItemDto>;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @type {PaginateResponseMeta}
|
|
53
|
+
* @memberof ListNotifications200Response
|
|
54
|
+
*/
|
|
55
|
+
meta: PaginateResponseMeta;
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @type {PaginateResponseLinks}
|
|
59
|
+
* @memberof ListNotifications200Response
|
|
60
|
+
*/
|
|
61
|
+
links: PaginateResponseLinks;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Check if a given object implements the ListNotifications200Response interface.
|
|
66
|
+
*/
|
|
67
|
+
export function instanceOfListNotifications200Response(value: object): value is ListNotifications200Response {
|
|
68
|
+
if (!('data' in value) || value['data'] === undefined) return false;
|
|
69
|
+
if (!('meta' in value) || value['meta'] === undefined) return false;
|
|
70
|
+
if (!('links' in value) || value['links'] === undefined) return false;
|
|
71
|
+
return true;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export function ListNotifications200ResponseFromJSON(json: any): ListNotifications200Response {
|
|
75
|
+
return ListNotifications200ResponseFromJSONTyped(json, false);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
export function ListNotifications200ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ListNotifications200Response {
|
|
79
|
+
if (json == null) {
|
|
80
|
+
return json;
|
|
81
|
+
}
|
|
82
|
+
return {
|
|
83
|
+
|
|
84
|
+
'data': ((json['data'] as Array<any>).map(UserNotificationListItemDtoFromJSON)),
|
|
85
|
+
'meta': PaginateResponseMetaFromJSON(json['meta']),
|
|
86
|
+
'links': PaginateResponseLinksFromJSON(json['links']),
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
export function ListNotifications200ResponseToJSON(json: any): ListNotifications200Response {
|
|
91
|
+
return ListNotifications200ResponseToJSONTyped(json, false);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export function ListNotifications200ResponseToJSONTyped(value?: ListNotifications200Response | null, ignoreDiscriminator: boolean = false): any {
|
|
95
|
+
if (value == null) {
|
|
96
|
+
return value;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
return {
|
|
100
|
+
|
|
101
|
+
'data': ((value['data'] as Array<any>).map(UserNotificationListItemDtoToJSON)),
|
|
102
|
+
'meta': PaginateResponseMetaToJSON(value['meta']),
|
|
103
|
+
'links': PaginateResponseLinksToJSON(value['links']),
|
|
104
|
+
};
|
|
105
|
+
}
|
|
106
|
+
|