@randock/nameshift-api-client 0.0.538 → 0.0.540
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 +20 -0
- package/README.md +3 -3
- package/dist/apis/AdminApi.d.ts +36 -1
- package/dist/apis/AdminApi.js +136 -0
- package/dist/apis/BrokeredLeadsApi.d.ts +195 -0
- package/dist/apis/BrokeredLeadsApi.js +912 -0
- package/dist/apis/BrokeredLeadsPublicApi.d.ts +31 -0
- package/dist/apis/BrokeredLeadsPublicApi.js +126 -0
- package/dist/apis/index.d.ts +2 -0
- package/dist/apis/index.js +2 -0
- package/dist/models/AccountBrokerSettingsInput.d.ts +38 -0
- package/dist/models/AccountBrokerSettingsInput.js +51 -0
- package/dist/models/AccountDto.d.ts +12 -0
- package/dist/models/AccountDto.js +8 -0
- package/dist/models/AccountNameshiftCommissionBySubtypeDto.d.ts +1 -0
- package/dist/models/AccountNameshiftCommissionBySubtypeDto.js +2 -1
- package/dist/models/AccountNameshiftCommissionItemDto.d.ts +1 -0
- package/dist/models/AccountNameshiftCommissionItemDto.js +2 -1
- package/dist/models/AccountNameshiftCommissionReasonDto.d.ts +1 -0
- package/dist/models/AccountNameshiftCommissionReasonDto.js +2 -1
- package/dist/models/AccountNotificationDto.d.ts +1 -0
- package/dist/models/AccountNotificationDto.js +2 -1
- package/dist/models/AccountSettingsBrokerDto.d.ts +38 -0
- package/dist/models/AccountSettingsBrokerDto.js +55 -0
- package/dist/models/AccountSettingsDto.d.ts +7 -0
- package/dist/models/AccountSettingsDto.js +5 -0
- package/dist/models/AccountSettingsInput.d.ts +7 -0
- package/dist/models/AccountSettingsInput.js +3 -0
- package/dist/models/AdminBrokeredLeadDto.d.ts +248 -0
- package/dist/models/AdminBrokeredLeadDto.js +204 -0
- package/dist/models/AdminListBrokeredLeads200Response.d.ts +47 -0
- package/dist/models/AdminListBrokeredLeads200Response.js +62 -0
- package/dist/models/ApiKeyDto.d.ts +2 -0
- package/dist/models/ApiKeyDto.js +2 -0
- package/dist/models/ApiKeyScopeDto.d.ts +2 -0
- package/dist/models/ApiKeyScopeDto.js +2 -0
- package/dist/models/BrokerBrokeredLeadDto.d.ts +189 -0
- package/dist/models/BrokerBrokeredLeadDto.js +162 -0
- package/dist/models/BrokerCommissionInput.d.ts +52 -0
- package/dist/models/BrokerCommissionInput.js +63 -0
- package/dist/models/BrokeredLeadBreakdownDto.d.ts +58 -0
- package/dist/models/BrokeredLeadBreakdownDto.js +69 -0
- package/dist/models/BrokeredLeadBuyerContactDto.d.ts +50 -0
- package/dist/models/BrokeredLeadBuyerContactDto.js +63 -0
- package/dist/models/BrokeredLeadBuyerInput.d.ts +50 -0
- package/dist/models/BrokeredLeadBuyerInput.js +63 -0
- package/dist/models/BrokeredLeadCommissionDto.d.ts +71 -0
- package/dist/models/BrokeredLeadCommissionDto.js +80 -0
- package/dist/models/BrokeredLeadInvitationDto.d.ts +57 -0
- package/dist/models/BrokeredLeadInvitationDto.js +68 -0
- package/dist/models/BuyerInvoiceDto.d.ts +6 -0
- package/dist/models/BuyerInvoiceDto.js +4 -0
- package/dist/models/BuyerNotificationDto.d.ts +6 -0
- package/dist/models/BuyerNotificationDto.js +7 -1
- package/dist/models/BuyerNotificationListItemDto.d.ts +6 -0
- package/dist/models/BuyerNotificationListItemDto.js +7 -1
- package/dist/models/CommissionDto.d.ts +1 -0
- package/dist/models/CommissionDto.js +2 -1
- package/dist/models/CommissionPayloadInput.d.ts +1 -0
- package/dist/models/CommissionPayloadInput.js +2 -1
- package/dist/models/CommissionReasonDto.d.ts +1 -0
- package/dist/models/CommissionReasonDto.js +2 -1
- package/dist/models/CommissionSimulationItemInput.d.ts +1 -0
- package/dist/models/CommissionSimulationItemInput.js +2 -1
- package/dist/models/CreateApiKeyInput.d.ts +2 -0
- package/dist/models/CreateApiKeyInput.js +2 -0
- package/dist/models/CreateBrokeredLeadInput.d.ts +59 -0
- package/dist/models/CreateBrokeredLeadInput.js +68 -0
- package/dist/models/CreatedApiKeyDto.d.ts +2 -0
- package/dist/models/CreatedApiKeyDto.js +2 -0
- package/dist/models/CustomerSuccessListAccountDto.d.ts +6 -0
- package/dist/models/CustomerSuccessListAccountDto.js +4 -0
- package/dist/models/CustomerSuccessListAccountMetricsDto.d.ts +6 -0
- package/dist/models/CustomerSuccessListAccountMetricsDto.js +4 -0
- package/dist/models/DeclineBrokeredLeadInput.d.ts +32 -0
- package/dist/models/DeclineBrokeredLeadInput.js +49 -0
- package/dist/models/FeatureFlagListItemDto.d.ts +1 -0
- package/dist/models/FeatureFlagListItemDto.js +1 -0
- package/dist/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.d.ts +13 -0
- package/dist/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.js +9 -0
- package/dist/models/IntersectionDomainDtoWithHijackerDtoWithAccountDto.d.ts +1 -1
- package/dist/models/InvoiceDto.d.ts +6 -0
- package/dist/models/InvoiceDto.js +4 -0
- package/dist/models/LeadBrokeredDealDto.d.ts +39 -0
- package/dist/models/LeadBrokeredDealDto.js +56 -0
- package/dist/models/ListAccountMetricsDto.d.ts +6 -0
- package/dist/models/ListAccountMetricsDto.js +4 -0
- package/dist/models/ListBrokerLeads200Response.d.ts +47 -0
- package/dist/models/ListBrokerLeads200Response.js +62 -0
- package/dist/models/ListLeadsResultItem.d.ts +7 -0
- package/dist/models/ListLeadsResultItem.js +5 -0
- package/dist/models/ManualLeadDetails.d.ts +7 -0
- package/dist/models/ManualLeadDetails.js +5 -0
- package/dist/models/OverrideBrokeredLeadNameshiftCommissionInput.d.ts +38 -0
- package/dist/models/OverrideBrokeredLeadNameshiftCommissionInput.js +55 -0
- package/dist/models/PrivateAccountGetMeResponse.d.ts +19 -0
- package/dist/models/PrivateAccountGetMeResponse.js +13 -0
- package/dist/models/RegisterAccountInput.d.ts +6 -0
- package/dist/models/RegisterAccountInput.js +2 -0
- package/dist/models/SellerBrokeredLeadDto.d.ts +114 -0
- package/dist/models/SellerBrokeredLeadDto.js +111 -0
- package/dist/models/SellerBrokeredLeadVerificationDto.d.ts +44 -0
- package/dist/models/SellerBrokeredLeadVerificationDto.js +59 -0
- package/dist/models/SellerInvoiceDto.d.ts +6 -0
- package/dist/models/SellerInvoiceDto.js +4 -0
- package/dist/models/SimulateCommissionInput.d.ts +1 -0
- package/dist/models/SimulateCommissionInput.js +2 -1
- package/dist/models/UpdateApiKeyInput.d.ts +2 -0
- package/dist/models/UpdateApiKeyInput.js +2 -0
- package/dist/models/UserNotificationDto.d.ts +6 -0
- package/dist/models/UserNotificationDto.js +7 -1
- package/dist/models/UserNotificationListItemDto.d.ts +6 -0
- package/dist/models/UserNotificationListItemDto.js +7 -1
- package/dist/models/WithSettingsInner.d.ts +11 -4
- package/dist/models/WithSettingsInner.js +9 -4
- package/dist/models/index.d.ts +18 -0
- package/dist/models/index.js +18 -0
- package/package.json +1 -1
- package/src/apis/AdminApi.ts +145 -0
- package/src/apis/BrokeredLeadsApi.ts +740 -0
- package/src/apis/BrokeredLeadsPublicApi.ts +69 -0
- package/src/apis/index.ts +2 -0
- package/src/models/AccountBrokerSettingsInput.ts +73 -0
- package/src/models/AccountDto.ts +18 -0
- package/src/models/AccountNameshiftCommissionBySubtypeDto.ts +2 -1
- package/src/models/AccountNameshiftCommissionItemDto.ts +2 -1
- package/src/models/AccountNameshiftCommissionReasonDto.ts +2 -1
- package/src/models/AccountNotificationDto.ts +2 -1
- package/src/models/AccountSettingsBrokerDto.ts +75 -0
- package/src/models/AccountSettingsDto.ts +16 -0
- package/src/models/AccountSettingsInput.ts +15 -0
- package/src/models/AdminBrokeredLeadDto.ts +404 -0
- package/src/models/AdminListBrokeredLeads200Response.ts +106 -0
- package/src/models/ApiKeyDto.ts +2 -0
- package/src/models/ApiKeyScopeDto.ts +2 -0
- package/src/models/BrokerBrokeredLeadDto.ts +320 -0
- package/src/models/BrokerCommissionInput.ts +93 -0
- package/src/models/BrokeredLeadBreakdownDto.ts +117 -0
- package/src/models/BrokeredLeadBuyerContactDto.ts +93 -0
- package/src/models/BrokeredLeadBuyerInput.ts +93 -0
- package/src/models/BrokeredLeadCommissionDto.ts +130 -0
- package/src/models/BrokeredLeadInvitationDto.ts +110 -0
- package/src/models/BuyerInvoiceDto.ts +9 -0
- package/src/models/BuyerNotificationDto.ts +7 -1
- package/src/models/BuyerNotificationListItemDto.ts +7 -1
- package/src/models/CommissionDto.ts +2 -1
- package/src/models/CommissionPayloadInput.ts +2 -1
- package/src/models/CommissionReasonDto.ts +2 -1
- package/src/models/CommissionSimulationItemInput.ts +2 -1
- package/src/models/CreateApiKeyInput.ts +2 -0
- package/src/models/CreateBrokeredLeadInput.ts +123 -0
- package/src/models/CreatedApiKeyDto.ts +2 -0
- package/src/models/CustomerSuccessListAccountDto.ts +9 -0
- package/src/models/CustomerSuccessListAccountMetricsDto.ts +9 -0
- package/src/models/DeclineBrokeredLeadInput.ts +65 -0
- package/src/models/FeatureFlagListItemDto.ts +1 -0
- package/src/models/IntersectionAccountDtoWithSettingsDtoWithNotificationsDtoWithFeatureFlagsDto.ts +19 -0
- package/src/models/IntersectionDomainDtoWithHijackerDtoWithAccountDto.ts +1 -1
- package/src/models/InvoiceDto.ts +9 -0
- package/src/models/LeadBrokeredDealDto.ts +83 -0
- package/src/models/ListAccountMetricsDto.ts +9 -0
- package/src/models/ListBrokerLeads200Response.ts +106 -0
- package/src/models/ListLeadsResultItem.ts +16 -0
- package/src/models/ManualLeadDetails.ts +16 -0
- package/src/models/OverrideBrokeredLeadNameshiftCommissionInput.ts +75 -0
- package/src/models/PrivateAccountGetMeResponse.ts +28 -0
- package/src/models/RegisterAccountInput.ts +8 -0
- package/src/models/SellerBrokeredLeadDto.ts +215 -0
- package/src/models/SellerBrokeredLeadVerificationDto.ts +84 -0
- package/src/models/SellerInvoiceDto.ts +9 -0
- package/src/models/SimulateCommissionInput.ts +2 -1
- package/src/models/UpdateApiKeyInput.ts +2 -0
- package/src/models/UserNotificationDto.ts +7 -1
- package/src/models/UserNotificationListItemDto.ts +7 -1
- package/src/models/WithSettingsInner.ts +44 -28
- package/src/models/index.ts +18 -0
|
@@ -0,0 +1,740 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
|
|
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
|
+
BrokerBrokeredLeadDto,
|
|
19
|
+
CreateBrokeredLeadInput,
|
|
20
|
+
DeclineBrokeredLeadInput,
|
|
21
|
+
ListBrokerLeads200Response,
|
|
22
|
+
ObjectId,
|
|
23
|
+
SellerBrokeredLeadDto,
|
|
24
|
+
} from '../models/index';
|
|
25
|
+
import {
|
|
26
|
+
BrokerBrokeredLeadDtoFromJSON,
|
|
27
|
+
BrokerBrokeredLeadDtoToJSON,
|
|
28
|
+
CreateBrokeredLeadInputFromJSON,
|
|
29
|
+
CreateBrokeredLeadInputToJSON,
|
|
30
|
+
DeclineBrokeredLeadInputFromJSON,
|
|
31
|
+
DeclineBrokeredLeadInputToJSON,
|
|
32
|
+
ListBrokerLeads200ResponseFromJSON,
|
|
33
|
+
ListBrokerLeads200ResponseToJSON,
|
|
34
|
+
ObjectIdFromJSON,
|
|
35
|
+
ObjectIdToJSON,
|
|
36
|
+
SellerBrokeredLeadDtoFromJSON,
|
|
37
|
+
SellerBrokeredLeadDtoToJSON,
|
|
38
|
+
} from '../models/index';
|
|
39
|
+
|
|
40
|
+
export interface BrokeredLeadsApiApproveSellerBrokeredLeadRequest {
|
|
41
|
+
brokeredLeadId: string;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export interface BrokeredLeadsApiCancelBrokerLeadRequest {
|
|
45
|
+
brokeredLeadId: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export interface BrokeredLeadsApiClaimSellerBrokeredLeadInvitationRequest {
|
|
49
|
+
token: string;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export interface BrokeredLeadsApiCreateBrokerLeadRequest {
|
|
53
|
+
createBrokeredLeadInput: CreateBrokeredLeadInput;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export interface BrokeredLeadsApiDeclineSellerBrokeredLeadRequest {
|
|
57
|
+
brokeredLeadId: string;
|
|
58
|
+
declineBrokeredLeadInput: DeclineBrokeredLeadInput;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export interface BrokeredLeadsApiGetBrokerLeadRequest {
|
|
62
|
+
brokeredLeadId: string;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export interface BrokeredLeadsApiGetSellerBrokeredLeadRequest {
|
|
66
|
+
brokeredLeadId: string;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export interface BrokeredLeadsApiListBrokerLeadsRequest {
|
|
70
|
+
filter?: { [key: string]: string; };
|
|
71
|
+
page?: number;
|
|
72
|
+
limit?: number;
|
|
73
|
+
sortBy?: Array<string>;
|
|
74
|
+
filterStatus?: string;
|
|
75
|
+
filterBrokerStatus?: string;
|
|
76
|
+
filterSearchTerm?: string;
|
|
77
|
+
filterCreatedAtFrom?: string;
|
|
78
|
+
filterCreatedAtTo?: string;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
export interface BrokeredLeadsApiNotifyBrokerLeadBuyerRequest {
|
|
82
|
+
brokeredLeadId: string;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export interface BrokeredLeadsApiNotifyBrokerLeadSellerRequest {
|
|
86
|
+
brokeredLeadId: string;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export interface BrokeredLeadsApiRecheckSellerBrokeredLeadVerificationRequest {
|
|
90
|
+
brokeredLeadId: string;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
export interface BrokeredLeadsApiRenewBrokerLeadSellerLinkRequest {
|
|
94
|
+
brokeredLeadId: string;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
*
|
|
99
|
+
*/
|
|
100
|
+
export class BrokeredLeadsApi extends runtime.BaseAPI {
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* The seller agrees to the deal. It becomes a lead the buyer can pay as soon as the domain is verified as the seller’s and the seller account is verified; the domain is checked right away. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
104
|
+
* Approve a brokered deal
|
|
105
|
+
*/
|
|
106
|
+
async approveSellerBrokeredLeadRaw(requestParameters: BrokeredLeadsApiApproveSellerBrokeredLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
107
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
108
|
+
throw new runtime.RequiredError(
|
|
109
|
+
'brokeredLeadId',
|
|
110
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling approveSellerBrokeredLead().'
|
|
111
|
+
);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
const queryParameters: any = {};
|
|
115
|
+
|
|
116
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
117
|
+
|
|
118
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
119
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
123
|
+
const token = this.configuration.accessToken;
|
|
124
|
+
const tokenString = await token("bearer", []);
|
|
125
|
+
|
|
126
|
+
if (tokenString) {
|
|
127
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
const response = await this.request({
|
|
131
|
+
path: `/private/brokered-leads/{brokeredLeadId}/approve`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
132
|
+
method: 'POST',
|
|
133
|
+
headers: headerParameters,
|
|
134
|
+
query: queryParameters,
|
|
135
|
+
}, initOverrides);
|
|
136
|
+
|
|
137
|
+
return new runtime.VoidApiResponse(response);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* The seller agrees to the deal. It becomes a lead the buyer can pay as soon as the domain is verified as the seller’s and the seller account is verified; the domain is checked right away. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
142
|
+
* Approve a brokered deal
|
|
143
|
+
*/
|
|
144
|
+
async approveSellerBrokeredLead(requestParameters: BrokeredLeadsApiApproveSellerBrokeredLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
145
|
+
await this.approveSellerBrokeredLeadRaw(requestParameters, initOverrides);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
/**
|
|
149
|
+
* Withdraws a deal the seller has not completed yet. The seller signup link stops working. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
150
|
+
* Cancel a deal
|
|
151
|
+
*/
|
|
152
|
+
async cancelBrokerLeadRaw(requestParameters: BrokeredLeadsApiCancelBrokerLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
153
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
154
|
+
throw new runtime.RequiredError(
|
|
155
|
+
'brokeredLeadId',
|
|
156
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling cancelBrokerLead().'
|
|
157
|
+
);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
const queryParameters: any = {};
|
|
161
|
+
|
|
162
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
163
|
+
|
|
164
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
165
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
169
|
+
const token = this.configuration.accessToken;
|
|
170
|
+
const tokenString = await token("bearer", []);
|
|
171
|
+
|
|
172
|
+
if (tokenString) {
|
|
173
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
const response = await this.request({
|
|
177
|
+
path: `/private/broker/leads/{brokeredLeadId}/cancel`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
178
|
+
method: 'POST',
|
|
179
|
+
headers: headerParameters,
|
|
180
|
+
query: queryParameters,
|
|
181
|
+
}, initOverrides);
|
|
182
|
+
|
|
183
|
+
return new runtime.VoidApiResponse(response);
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* Withdraws a deal the seller has not completed yet. The seller signup link stops working. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
188
|
+
* Cancel a deal
|
|
189
|
+
*/
|
|
190
|
+
async cancelBrokerLead(requestParameters: BrokeredLeadsApiCancelBrokerLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
191
|
+
await this.cancelBrokerLeadRaw(requestParameters, initOverrides);
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
/**
|
|
195
|
+
* For a seller who already has an account: the deal behind the link joins this account’s brokered deals and waits for the seller’s review. The domain is added to the account when no account has it. When another account holds it, this account claims it, and the domain moves over once its DNS names this account. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
196
|
+
* Take up a broker’s signup link with this account
|
|
197
|
+
*/
|
|
198
|
+
async claimSellerBrokeredLeadInvitationRaw(requestParameters: BrokeredLeadsApiClaimSellerBrokeredLeadInvitationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
199
|
+
if (requestParameters['token'] == null) {
|
|
200
|
+
throw new runtime.RequiredError(
|
|
201
|
+
'token',
|
|
202
|
+
'Required parameter "token" was null or undefined when calling claimSellerBrokeredLeadInvitation().'
|
|
203
|
+
);
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
const queryParameters: any = {};
|
|
207
|
+
|
|
208
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
209
|
+
|
|
210
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
211
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
215
|
+
const token = this.configuration.accessToken;
|
|
216
|
+
const tokenString = await token("bearer", []);
|
|
217
|
+
|
|
218
|
+
if (tokenString) {
|
|
219
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
const response = await this.request({
|
|
223
|
+
path: `/private/brokered-leads/invitations/{token}/claim`.replace(`{${"token"}}`, encodeURIComponent(String(requestParameters['token']))),
|
|
224
|
+
method: 'POST',
|
|
225
|
+
headers: headerParameters,
|
|
226
|
+
query: queryParameters,
|
|
227
|
+
}, initOverrides);
|
|
228
|
+
|
|
229
|
+
return new runtime.VoidApiResponse(response);
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
/**
|
|
233
|
+
* For a seller who already has an account: the deal behind the link joins this account’s brokered deals and waits for the seller’s review. The domain is added to the account when no account has it. When another account holds it, this account claims it, and the domain moves over once its DNS names this account. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
234
|
+
* Take up a broker’s signup link with this account
|
|
235
|
+
*/
|
|
236
|
+
async claimSellerBrokeredLeadInvitation(requestParameters: BrokeredLeadsApiClaimSellerBrokeredLeadInvitationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
237
|
+
await this.claimSellerBrokeredLeadInvitationRaw(requestParameters, initOverrides);
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
/**
|
|
241
|
+
* Records a sale the broker arranged. When the account that holds the domain has verified it through DNS, that seller finds the deal waiting for review. For any other domain the deal carries a link for the seller: whoever takes it up has to show through DNS that the domain is theirs. Nobody is emailed until the broker asks for it. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
242
|
+
* Bring in a deal as a broker
|
|
243
|
+
*/
|
|
244
|
+
async createBrokerLeadRaw(requestParameters: BrokeredLeadsApiCreateBrokerLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ObjectId>> {
|
|
245
|
+
if (requestParameters['createBrokeredLeadInput'] == null) {
|
|
246
|
+
throw new runtime.RequiredError(
|
|
247
|
+
'createBrokeredLeadInput',
|
|
248
|
+
'Required parameter "createBrokeredLeadInput" was null or undefined when calling createBrokerLead().'
|
|
249
|
+
);
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
const queryParameters: any = {};
|
|
253
|
+
|
|
254
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
255
|
+
|
|
256
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
257
|
+
|
|
258
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
259
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
263
|
+
const token = this.configuration.accessToken;
|
|
264
|
+
const tokenString = await token("bearer", []);
|
|
265
|
+
|
|
266
|
+
if (tokenString) {
|
|
267
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
const response = await this.request({
|
|
271
|
+
path: `/private/broker/leads`,
|
|
272
|
+
method: 'POST',
|
|
273
|
+
headers: headerParameters,
|
|
274
|
+
query: queryParameters,
|
|
275
|
+
body: CreateBrokeredLeadInputToJSON(requestParameters['createBrokeredLeadInput']),
|
|
276
|
+
}, initOverrides);
|
|
277
|
+
|
|
278
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ObjectIdFromJSON(jsonValue));
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
/**
|
|
282
|
+
* Records a sale the broker arranged. When the account that holds the domain has verified it through DNS, that seller finds the deal waiting for review. For any other domain the deal carries a link for the seller: whoever takes it up has to show through DNS that the domain is theirs. Nobody is emailed until the broker asks for it. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
283
|
+
* Bring in a deal as a broker
|
|
284
|
+
*/
|
|
285
|
+
async createBrokerLead(requestParameters: BrokeredLeadsApiCreateBrokerLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ObjectId> {
|
|
286
|
+
const response = await this.createBrokerLeadRaw(requestParameters, initOverrides);
|
|
287
|
+
return await response.value();
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
/**
|
|
291
|
+
* Declines a deal under review, or backs out of an approved deal that still waits for verification. The broker is told, along with the reason if given. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
292
|
+
* Decline a brokered deal
|
|
293
|
+
*/
|
|
294
|
+
async declineSellerBrokeredLeadRaw(requestParameters: BrokeredLeadsApiDeclineSellerBrokeredLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
295
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
296
|
+
throw new runtime.RequiredError(
|
|
297
|
+
'brokeredLeadId',
|
|
298
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling declineSellerBrokeredLead().'
|
|
299
|
+
);
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
if (requestParameters['declineBrokeredLeadInput'] == null) {
|
|
303
|
+
throw new runtime.RequiredError(
|
|
304
|
+
'declineBrokeredLeadInput',
|
|
305
|
+
'Required parameter "declineBrokeredLeadInput" was null or undefined when calling declineSellerBrokeredLead().'
|
|
306
|
+
);
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
const queryParameters: any = {};
|
|
310
|
+
|
|
311
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
312
|
+
|
|
313
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
314
|
+
|
|
315
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
316
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
320
|
+
const token = this.configuration.accessToken;
|
|
321
|
+
const tokenString = await token("bearer", []);
|
|
322
|
+
|
|
323
|
+
if (tokenString) {
|
|
324
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
const response = await this.request({
|
|
328
|
+
path: `/private/brokered-leads/{brokeredLeadId}/decline`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
329
|
+
method: 'POST',
|
|
330
|
+
headers: headerParameters,
|
|
331
|
+
query: queryParameters,
|
|
332
|
+
body: DeclineBrokeredLeadInputToJSON(requestParameters['declineBrokeredLeadInput']),
|
|
333
|
+
}, initOverrides);
|
|
334
|
+
|
|
335
|
+
return new runtime.VoidApiResponse(response);
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
/**
|
|
339
|
+
* Declines a deal under review, or backs out of an approved deal that still waits for verification. The broker is told, along with the reason if given. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
340
|
+
* Decline a brokered deal
|
|
341
|
+
*/
|
|
342
|
+
async declineSellerBrokeredLead(requestParameters: BrokeredLeadsApiDeclineSellerBrokeredLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
343
|
+
await this.declineSellerBrokeredLeadRaw(requestParameters, initOverrides);
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
/**
|
|
347
|
+
* **API key scope required:** `BROKERED_LEADS_READ`. Requests authenticated with a seller session do not need any scope.
|
|
348
|
+
* Get a deal brought in as a broker
|
|
349
|
+
*/
|
|
350
|
+
async getBrokerLeadRaw(requestParameters: BrokeredLeadsApiGetBrokerLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<BrokerBrokeredLeadDto>> {
|
|
351
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
352
|
+
throw new runtime.RequiredError(
|
|
353
|
+
'brokeredLeadId',
|
|
354
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling getBrokerLead().'
|
|
355
|
+
);
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
const queryParameters: any = {};
|
|
359
|
+
|
|
360
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
361
|
+
|
|
362
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
363
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
367
|
+
const token = this.configuration.accessToken;
|
|
368
|
+
const tokenString = await token("bearer", []);
|
|
369
|
+
|
|
370
|
+
if (tokenString) {
|
|
371
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
372
|
+
}
|
|
373
|
+
}
|
|
374
|
+
const response = await this.request({
|
|
375
|
+
path: `/private/broker/leads/{brokeredLeadId}`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
376
|
+
method: 'GET',
|
|
377
|
+
headers: headerParameters,
|
|
378
|
+
query: queryParameters,
|
|
379
|
+
}, initOverrides);
|
|
380
|
+
|
|
381
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => BrokerBrokeredLeadDtoFromJSON(jsonValue));
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
/**
|
|
385
|
+
* **API key scope required:** `BROKERED_LEADS_READ`. Requests authenticated with a seller session do not need any scope.
|
|
386
|
+
* Get a deal brought in as a broker
|
|
387
|
+
*/
|
|
388
|
+
async getBrokerLead(requestParameters: BrokeredLeadsApiGetBrokerLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<BrokerBrokeredLeadDto> {
|
|
389
|
+
const response = await this.getBrokerLeadRaw(requestParameters, initOverrides);
|
|
390
|
+
return await response.value();
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
/**
|
|
394
|
+
* **API key scope required:** `BROKERED_LEADS_READ`. Requests authenticated with a seller session do not need any scope.
|
|
395
|
+
* Get a brokered deal on one of the seller’s domains
|
|
396
|
+
*/
|
|
397
|
+
async getSellerBrokeredLeadRaw(requestParameters: BrokeredLeadsApiGetSellerBrokeredLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SellerBrokeredLeadDto>> {
|
|
398
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
399
|
+
throw new runtime.RequiredError(
|
|
400
|
+
'brokeredLeadId',
|
|
401
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling getSellerBrokeredLead().'
|
|
402
|
+
);
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
const queryParameters: any = {};
|
|
406
|
+
|
|
407
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
408
|
+
|
|
409
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
410
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
414
|
+
const token = this.configuration.accessToken;
|
|
415
|
+
const tokenString = await token("bearer", []);
|
|
416
|
+
|
|
417
|
+
if (tokenString) {
|
|
418
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
const response = await this.request({
|
|
422
|
+
path: `/private/brokered-leads/{brokeredLeadId}`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
423
|
+
method: 'GET',
|
|
424
|
+
headers: headerParameters,
|
|
425
|
+
query: queryParameters,
|
|
426
|
+
}, initOverrides);
|
|
427
|
+
|
|
428
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => SellerBrokeredLeadDtoFromJSON(jsonValue));
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
/**
|
|
432
|
+
* **API key scope required:** `BROKERED_LEADS_READ`. Requests authenticated with a seller session do not need any scope.
|
|
433
|
+
* Get a brokered deal on one of the seller’s domains
|
|
434
|
+
*/
|
|
435
|
+
async getSellerBrokeredLead(requestParameters: BrokeredLeadsApiGetSellerBrokeredLeadRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SellerBrokeredLeadDto> {
|
|
436
|
+
const response = await this.getSellerBrokeredLeadRaw(requestParameters, initOverrides);
|
|
437
|
+
return await response.value();
|
|
438
|
+
}
|
|
439
|
+
|
|
440
|
+
/**
|
|
441
|
+
* Lists the deals this account brought in as a broker, newest first, with their status, commission and the links to share. **API key scope required:** `BROKERED_LEADS_READ`. Requests authenticated with a seller session do not need any scope.
|
|
442
|
+
* List the deals brought in as a broker
|
|
443
|
+
*/
|
|
444
|
+
async listBrokerLeadsRaw(requestParameters: BrokeredLeadsApiListBrokerLeadsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListBrokerLeads200Response>> {
|
|
445
|
+
const queryParameters: any = {};
|
|
446
|
+
|
|
447
|
+
if (requestParameters['filter'] != null) {
|
|
448
|
+
queryParameters['filter'] = requestParameters['filter'];
|
|
449
|
+
}
|
|
450
|
+
|
|
451
|
+
if (requestParameters['page'] != null) {
|
|
452
|
+
queryParameters['page'] = requestParameters['page'];
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
if (requestParameters['limit'] != null) {
|
|
456
|
+
queryParameters['limit'] = requestParameters['limit'];
|
|
457
|
+
}
|
|
458
|
+
|
|
459
|
+
if (requestParameters['sortBy'] != null) {
|
|
460
|
+
queryParameters['sortBy'] = requestParameters['sortBy'];
|
|
461
|
+
}
|
|
462
|
+
|
|
463
|
+
if (requestParameters['filterStatus'] != null) {
|
|
464
|
+
queryParameters['filter[status]'] = requestParameters['filterStatus'];
|
|
465
|
+
}
|
|
466
|
+
|
|
467
|
+
if (requestParameters['filterBrokerStatus'] != null) {
|
|
468
|
+
queryParameters['filter[broker_status]'] = requestParameters['filterBrokerStatus'];
|
|
469
|
+
}
|
|
470
|
+
|
|
471
|
+
if (requestParameters['filterSearchTerm'] != null) {
|
|
472
|
+
queryParameters['filter[search_term]'] = requestParameters['filterSearchTerm'];
|
|
473
|
+
}
|
|
474
|
+
|
|
475
|
+
if (requestParameters['filterCreatedAtFrom'] != null) {
|
|
476
|
+
queryParameters['filter[createdAtFrom]'] = requestParameters['filterCreatedAtFrom'];
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
if (requestParameters['filterCreatedAtTo'] != null) {
|
|
480
|
+
queryParameters['filter[createdAtTo]'] = requestParameters['filterCreatedAtTo'];
|
|
481
|
+
}
|
|
482
|
+
|
|
483
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
484
|
+
|
|
485
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
486
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
490
|
+
const token = this.configuration.accessToken;
|
|
491
|
+
const tokenString = await token("bearer", []);
|
|
492
|
+
|
|
493
|
+
if (tokenString) {
|
|
494
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
495
|
+
}
|
|
496
|
+
}
|
|
497
|
+
const response = await this.request({
|
|
498
|
+
path: `/private/broker/leads`,
|
|
499
|
+
method: 'GET',
|
|
500
|
+
headers: headerParameters,
|
|
501
|
+
query: queryParameters,
|
|
502
|
+
}, initOverrides);
|
|
503
|
+
|
|
504
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ListBrokerLeads200ResponseFromJSON(jsonValue));
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
/**
|
|
508
|
+
* Lists the deals this account brought in as a broker, newest first, with their status, commission and the links to share. **API key scope required:** `BROKERED_LEADS_READ`. Requests authenticated with a seller session do not need any scope.
|
|
509
|
+
* List the deals brought in as a broker
|
|
510
|
+
*/
|
|
511
|
+
async listBrokerLeads(requestParameters: BrokeredLeadsApiListBrokerLeadsRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListBrokerLeads200Response> {
|
|
512
|
+
const response = await this.listBrokerLeadsRaw(requestParameters, initOverrides);
|
|
513
|
+
return await response.value();
|
|
514
|
+
}
|
|
515
|
+
|
|
516
|
+
/**
|
|
517
|
+
* Deals brokers brought in for this account’s domains that wait for approval or for the domain and account to be verified. **API key scope required:** `BROKERED_LEADS_READ`. Requests authenticated with a seller session do not need any scope.
|
|
518
|
+
* List the brokered deals waiting on the seller
|
|
519
|
+
*/
|
|
520
|
+
async listSellerBrokeredLeadsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<SellerBrokeredLeadDto>>> {
|
|
521
|
+
const queryParameters: any = {};
|
|
522
|
+
|
|
523
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
524
|
+
|
|
525
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
526
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
527
|
+
}
|
|
528
|
+
|
|
529
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
530
|
+
const token = this.configuration.accessToken;
|
|
531
|
+
const tokenString = await token("bearer", []);
|
|
532
|
+
|
|
533
|
+
if (tokenString) {
|
|
534
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
535
|
+
}
|
|
536
|
+
}
|
|
537
|
+
const response = await this.request({
|
|
538
|
+
path: `/private/brokered-leads`,
|
|
539
|
+
method: 'GET',
|
|
540
|
+
headers: headerParameters,
|
|
541
|
+
query: queryParameters,
|
|
542
|
+
}, initOverrides);
|
|
543
|
+
|
|
544
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(SellerBrokeredLeadDtoFromJSON));
|
|
545
|
+
}
|
|
546
|
+
|
|
547
|
+
/**
|
|
548
|
+
* Deals brokers brought in for this account’s domains that wait for approval or for the domain and account to be verified. **API key scope required:** `BROKERED_LEADS_READ`. Requests authenticated with a seller session do not need any scope.
|
|
549
|
+
* List the brokered deals waiting on the seller
|
|
550
|
+
*/
|
|
551
|
+
async listSellerBrokeredLeads(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<SellerBrokeredLeadDto>> {
|
|
552
|
+
const response = await this.listSellerBrokeredLeadsRaw(initOverrides);
|
|
553
|
+
return await response.value();
|
|
554
|
+
}
|
|
555
|
+
|
|
556
|
+
/**
|
|
557
|
+
* Emails the buyer a reminder with the payment link, while the deal waits for payment. Once a week at most. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
558
|
+
* Email the buyer the payment link
|
|
559
|
+
*/
|
|
560
|
+
async notifyBrokerLeadBuyerRaw(requestParameters: BrokeredLeadsApiNotifyBrokerLeadBuyerRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
561
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
562
|
+
throw new runtime.RequiredError(
|
|
563
|
+
'brokeredLeadId',
|
|
564
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling notifyBrokerLeadBuyer().'
|
|
565
|
+
);
|
|
566
|
+
}
|
|
567
|
+
|
|
568
|
+
const queryParameters: any = {};
|
|
569
|
+
|
|
570
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
571
|
+
|
|
572
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
573
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
574
|
+
}
|
|
575
|
+
|
|
576
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
577
|
+
const token = this.configuration.accessToken;
|
|
578
|
+
const tokenString = await token("bearer", []);
|
|
579
|
+
|
|
580
|
+
if (tokenString) {
|
|
581
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
const response = await this.request({
|
|
585
|
+
path: `/private/broker/leads/{brokeredLeadId}/notify-buyer`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
586
|
+
method: 'POST',
|
|
587
|
+
headers: headerParameters,
|
|
588
|
+
query: queryParameters,
|
|
589
|
+
}, initOverrides);
|
|
590
|
+
|
|
591
|
+
return new runtime.VoidApiResponse(response);
|
|
592
|
+
}
|
|
593
|
+
|
|
594
|
+
/**
|
|
595
|
+
* Emails the buyer a reminder with the payment link, while the deal waits for payment. Once a week at most. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
596
|
+
* Email the buyer the payment link
|
|
597
|
+
*/
|
|
598
|
+
async notifyBrokerLeadBuyer(requestParameters: BrokeredLeadsApiNotifyBrokerLeadBuyerRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
599
|
+
await this.notifyBrokerLeadBuyerRaw(requestParameters, initOverrides);
|
|
600
|
+
}
|
|
601
|
+
|
|
602
|
+
/**
|
|
603
|
+
* Emails a seller with an account to review the deal, or invites a seller without one to sign up. Once a week at most. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
604
|
+
* Email the seller about the deal
|
|
605
|
+
*/
|
|
606
|
+
async notifyBrokerLeadSellerRaw(requestParameters: BrokeredLeadsApiNotifyBrokerLeadSellerRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
607
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
608
|
+
throw new runtime.RequiredError(
|
|
609
|
+
'brokeredLeadId',
|
|
610
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling notifyBrokerLeadSeller().'
|
|
611
|
+
);
|
|
612
|
+
}
|
|
613
|
+
|
|
614
|
+
const queryParameters: any = {};
|
|
615
|
+
|
|
616
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
617
|
+
|
|
618
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
619
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
620
|
+
}
|
|
621
|
+
|
|
622
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
623
|
+
const token = this.configuration.accessToken;
|
|
624
|
+
const tokenString = await token("bearer", []);
|
|
625
|
+
|
|
626
|
+
if (tokenString) {
|
|
627
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
628
|
+
}
|
|
629
|
+
}
|
|
630
|
+
const response = await this.request({
|
|
631
|
+
path: `/private/broker/leads/{brokeredLeadId}/notify-seller`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
632
|
+
method: 'POST',
|
|
633
|
+
headers: headerParameters,
|
|
634
|
+
query: queryParameters,
|
|
635
|
+
}, initOverrides);
|
|
636
|
+
|
|
637
|
+
return new runtime.VoidApiResponse(response);
|
|
638
|
+
}
|
|
639
|
+
|
|
640
|
+
/**
|
|
641
|
+
* Emails a seller with an account to review the deal, or invites a seller without one to sign up. Once a week at most. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
642
|
+
* Email the seller about the deal
|
|
643
|
+
*/
|
|
644
|
+
async notifyBrokerLeadSeller(requestParameters: BrokeredLeadsApiNotifyBrokerLeadSellerRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
645
|
+
await this.notifyBrokerLeadSellerRaw(requestParameters, initOverrides);
|
|
646
|
+
}
|
|
647
|
+
|
|
648
|
+
/**
|
|
649
|
+
* Checks the domain DNS again and completes the deal if the domain and the account are verified by now. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
650
|
+
* Check the verification of an approved brokered deal again
|
|
651
|
+
*/
|
|
652
|
+
async recheckSellerBrokeredLeadVerificationRaw(requestParameters: BrokeredLeadsApiRecheckSellerBrokeredLeadVerificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
653
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
654
|
+
throw new runtime.RequiredError(
|
|
655
|
+
'brokeredLeadId',
|
|
656
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling recheckSellerBrokeredLeadVerification().'
|
|
657
|
+
);
|
|
658
|
+
}
|
|
659
|
+
|
|
660
|
+
const queryParameters: any = {};
|
|
661
|
+
|
|
662
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
663
|
+
|
|
664
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
665
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
666
|
+
}
|
|
667
|
+
|
|
668
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
669
|
+
const token = this.configuration.accessToken;
|
|
670
|
+
const tokenString = await token("bearer", []);
|
|
671
|
+
|
|
672
|
+
if (tokenString) {
|
|
673
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
674
|
+
}
|
|
675
|
+
}
|
|
676
|
+
const response = await this.request({
|
|
677
|
+
path: `/private/brokered-leads/{brokeredLeadId}/verification`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
678
|
+
method: 'POST',
|
|
679
|
+
headers: headerParameters,
|
|
680
|
+
query: queryParameters,
|
|
681
|
+
}, initOverrides);
|
|
682
|
+
|
|
683
|
+
return new runtime.VoidApiResponse(response);
|
|
684
|
+
}
|
|
685
|
+
|
|
686
|
+
/**
|
|
687
|
+
* Checks the domain DNS again and completes the deal if the domain and the account are verified by now. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
688
|
+
* Check the verification of an approved brokered deal again
|
|
689
|
+
*/
|
|
690
|
+
async recheckSellerBrokeredLeadVerification(requestParameters: BrokeredLeadsApiRecheckSellerBrokeredLeadVerificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
691
|
+
await this.recheckSellerBrokeredLeadVerificationRaw(requestParameters, initOverrides);
|
|
692
|
+
}
|
|
693
|
+
|
|
694
|
+
/**
|
|
695
|
+
* Issues a new link for a seller who has not taken up the deal yet, e.g. once the previous one expired. The previous link stops working. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
696
|
+
* Renew the seller signup link
|
|
697
|
+
*/
|
|
698
|
+
async renewBrokerLeadSellerLinkRaw(requestParameters: BrokeredLeadsApiRenewBrokerLeadSellerLinkRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
699
|
+
if (requestParameters['brokeredLeadId'] == null) {
|
|
700
|
+
throw new runtime.RequiredError(
|
|
701
|
+
'brokeredLeadId',
|
|
702
|
+
'Required parameter "brokeredLeadId" was null or undefined when calling renewBrokerLeadSellerLink().'
|
|
703
|
+
);
|
|
704
|
+
}
|
|
705
|
+
|
|
706
|
+
const queryParameters: any = {};
|
|
707
|
+
|
|
708
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
709
|
+
|
|
710
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
711
|
+
headerParameters["apikey"] = await this.configuration.apiKey("apikey"); // api_key authentication
|
|
712
|
+
}
|
|
713
|
+
|
|
714
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
715
|
+
const token = this.configuration.accessToken;
|
|
716
|
+
const tokenString = await token("bearer", []);
|
|
717
|
+
|
|
718
|
+
if (tokenString) {
|
|
719
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
720
|
+
}
|
|
721
|
+
}
|
|
722
|
+
const response = await this.request({
|
|
723
|
+
path: `/private/broker/leads/{brokeredLeadId}/seller-link`.replace(`{${"brokeredLeadId"}}`, encodeURIComponent(String(requestParameters['brokeredLeadId']))),
|
|
724
|
+
method: 'POST',
|
|
725
|
+
headers: headerParameters,
|
|
726
|
+
query: queryParameters,
|
|
727
|
+
}, initOverrides);
|
|
728
|
+
|
|
729
|
+
return new runtime.VoidApiResponse(response);
|
|
730
|
+
}
|
|
731
|
+
|
|
732
|
+
/**
|
|
733
|
+
* Issues a new link for a seller who has not taken up the deal yet, e.g. once the previous one expired. The previous link stops working. **API key scope required:** `BROKERED_LEADS_WRITE`. Requests authenticated with a seller session do not need any scope.
|
|
734
|
+
* Renew the seller signup link
|
|
735
|
+
*/
|
|
736
|
+
async renewBrokerLeadSellerLink(requestParameters: BrokeredLeadsApiRenewBrokerLeadSellerLinkRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
737
|
+
await this.renewBrokerLeadSellerLinkRaw(requestParameters, initOverrides);
|
|
738
|
+
}
|
|
739
|
+
|
|
740
|
+
}
|