@randock/nameshift-api-client 0.0.562 → 0.0.564

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 (81) hide show
  1. package/.openapi-generator/FILES +16 -0
  2. package/README.md +3 -3
  3. package/dist/apis/AdminApi.d.ts +28 -1
  4. package/dist/apis/AdminApi.js +113 -0
  5. package/dist/apis/BuyersApi.d.ts +14 -1
  6. package/dist/apis/BuyersApi.js +57 -0
  7. package/dist/apis/BuyersPublicApi.d.ts +100 -1
  8. package/dist/apis/BuyersPublicApi.js +426 -0
  9. package/dist/apis/LeadsApi.d.ts +28 -1
  10. package/dist/apis/LeadsApi.js +129 -0
  11. package/dist/apis/LeadsPublicApi.d.ts +5 -5
  12. package/dist/apis/LeadsPublicApi.js +6 -4
  13. package/dist/models/AcceptHighestBuyerLeadOfferInput.d.ts +32 -0
  14. package/dist/models/AcceptHighestBuyerLeadOfferInput.js +51 -0
  15. package/dist/models/BuyerCheckoutProfileDto.d.ts +116 -0
  16. package/dist/models/BuyerCheckoutProfileDto.js +107 -0
  17. package/dist/models/BuyerCheckoutProfileSummaryDto.d.ts +74 -0
  18. package/dist/models/BuyerCheckoutProfileSummaryDto.js +79 -0
  19. package/dist/models/BuyerLandingSessionOutput.d.ts +68 -0
  20. package/dist/models/BuyerLandingSessionOutput.js +75 -0
  21. package/dist/models/BuyerNotificationDto.d.ts +1 -0
  22. package/dist/models/BuyerNotificationDto.js +1 -0
  23. package/dist/models/BuyerNotificationListItemDto.d.ts +1 -0
  24. package/dist/models/BuyerNotificationListItemDto.js +1 -0
  25. package/dist/models/BuyerSessionEstablishTicketOutput.d.ts +32 -0
  26. package/dist/models/BuyerSessionEstablishTicketOutput.js +51 -0
  27. package/dist/models/BuyerSessionPurchaseTypeEnum.d.ts +26 -0
  28. package/dist/models/BuyerSessionPurchaseTypeEnum.js +52 -0
  29. package/dist/models/CreateBuyerSessionEstablishTicketInput.d.ts +38 -0
  30. package/dist/models/CreateBuyerSessionEstablishTicketInput.js +55 -0
  31. package/dist/models/CreateBuyerSessionFromPurchaseInput.d.ts +39 -0
  32. package/dist/models/CreateBuyerSessionFromPurchaseInput.js +56 -0
  33. package/dist/models/CreateDashboardBuyerSessionInput.d.ts +32 -0
  34. package/dist/models/CreateDashboardBuyerSessionInput.js +51 -0
  35. package/dist/models/ExchangeBuyerSessionCodeInput.d.ts +38 -0
  36. package/dist/models/ExchangeBuyerSessionCodeInput.js +55 -0
  37. package/dist/models/LeadEmailVerificationResultOutput.d.ts +33 -0
  38. package/dist/models/LeadEmailVerificationResultOutput.js +52 -0
  39. package/dist/models/LeadOfferSummaryCannotAcceptReason.d.ts +29 -0
  40. package/dist/models/LeadOfferSummaryCannotAcceptReason.js +55 -0
  41. package/dist/models/LeadOfferSummaryDto.d.ts +52 -0
  42. package/dist/models/LeadOfferSummaryDto.js +65 -0
  43. package/dist/models/LeadOfferSummaryItemDto.d.ts +61 -0
  44. package/dist/models/LeadOfferSummaryItemDto.js +74 -0
  45. package/dist/models/LeadPhoneVerificationResultOutput.d.ts +47 -0
  46. package/dist/models/LeadPhoneVerificationResultOutput.js +62 -0
  47. package/dist/models/UserNotificationDto.d.ts +1 -0
  48. package/dist/models/UserNotificationDto.js +1 -0
  49. package/dist/models/UserNotificationListItemDto.d.ts +1 -0
  50. package/dist/models/UserNotificationListItemDto.js +1 -0
  51. package/dist/models/VerifyBuyerSessionEmailOtpInput.d.ts +32 -0
  52. package/dist/models/VerifyBuyerSessionEmailOtpInput.js +51 -0
  53. package/dist/models/index.d.ts +16 -0
  54. package/dist/models/index.js +16 -0
  55. package/package.json +1 -1
  56. package/src/apis/AdminApi.ts +110 -0
  57. package/src/apis/BuyersApi.ts +56 -0
  58. package/src/apis/BuyersPublicApi.ts +378 -0
  59. package/src/apis/LeadsApi.ts +118 -0
  60. package/src/apis/LeadsPublicApi.ts +14 -7
  61. package/src/models/AcceptHighestBuyerLeadOfferInput.ts +66 -0
  62. package/src/models/BuyerCheckoutProfileDto.ts +192 -0
  63. package/src/models/BuyerCheckoutProfileSummaryDto.ts +129 -0
  64. package/src/models/BuyerLandingSessionOutput.ts +120 -0
  65. package/src/models/BuyerNotificationDto.ts +1 -0
  66. package/src/models/BuyerNotificationListItemDto.ts +1 -0
  67. package/src/models/BuyerSessionEstablishTicketOutput.ts +66 -0
  68. package/src/models/BuyerSessionPurchaseTypeEnum.ts +54 -0
  69. package/src/models/CreateBuyerSessionEstablishTicketInput.ts +75 -0
  70. package/src/models/CreateBuyerSessionFromPurchaseInput.ts +85 -0
  71. package/src/models/CreateDashboardBuyerSessionInput.ts +66 -0
  72. package/src/models/ExchangeBuyerSessionCodeInput.ts +75 -0
  73. package/src/models/LeadEmailVerificationResultOutput.ts +74 -0
  74. package/src/models/LeadOfferSummaryCannotAcceptReason.ts +57 -0
  75. package/src/models/LeadOfferSummaryDto.ts +110 -0
  76. package/src/models/LeadOfferSummaryItemDto.ts +114 -0
  77. package/src/models/LeadPhoneVerificationResultOutput.ts +106 -0
  78. package/src/models/UserNotificationDto.ts +1 -0
  79. package/src/models/UserNotificationListItemDto.ts +1 -0
  80. package/src/models/VerifyBuyerSessionEmailOtpInput.ts +66 -0
  81. package/src/models/index.ts +16 -0
@@ -0,0 +1,75 @@
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
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface CreateBuyerSessionEstablishTicketInput
20
+ */
21
+ export interface CreateBuyerSessionEstablishTicketInput {
22
+ /**
23
+ * Domain whose landing the browser returns to.
24
+ * @type {string}
25
+ * @memberof CreateBuyerSessionEstablishTicketInput
26
+ */
27
+ domainName: string;
28
+ /**
29
+ * Locale of the landing page.
30
+ * @type {string}
31
+ * @memberof CreateBuyerSessionEstablishTicketInput
32
+ */
33
+ locale: string;
34
+ }
35
+
36
+ /**
37
+ * Check if a given object implements the CreateBuyerSessionEstablishTicketInput interface.
38
+ */
39
+ export function instanceOfCreateBuyerSessionEstablishTicketInput(value: object): value is CreateBuyerSessionEstablishTicketInput {
40
+ if (!('domainName' in value) || value['domainName'] === undefined) return false;
41
+ if (!('locale' in value) || value['locale'] === undefined) return false;
42
+ return true;
43
+ }
44
+
45
+ export function CreateBuyerSessionEstablishTicketInputFromJSON(json: any): CreateBuyerSessionEstablishTicketInput {
46
+ return CreateBuyerSessionEstablishTicketInputFromJSONTyped(json, false);
47
+ }
48
+
49
+ export function CreateBuyerSessionEstablishTicketInputFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateBuyerSessionEstablishTicketInput {
50
+ if (json == null) {
51
+ return json;
52
+ }
53
+ return {
54
+
55
+ 'domainName': json['domainName'],
56
+ 'locale': json['locale'],
57
+ };
58
+ }
59
+
60
+ export function CreateBuyerSessionEstablishTicketInputToJSON(json: any): CreateBuyerSessionEstablishTicketInput {
61
+ return CreateBuyerSessionEstablishTicketInputToJSONTyped(json, false);
62
+ }
63
+
64
+ export function CreateBuyerSessionEstablishTicketInputToJSONTyped(value?: CreateBuyerSessionEstablishTicketInput | null, ignoreDiscriminator: boolean = false): any {
65
+ if (value == null) {
66
+ return value;
67
+ }
68
+
69
+ return {
70
+
71
+ 'domainName': value['domainName'],
72
+ 'locale': value['locale'],
73
+ };
74
+ }
75
+
@@ -0,0 +1,85 @@
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
+ import { mapValues } from '../runtime';
16
+ import type { BuyerSessionPurchaseTypeEnum } from './BuyerSessionPurchaseTypeEnum';
17
+ import {
18
+ BuyerSessionPurchaseTypeEnumFromJSON,
19
+ BuyerSessionPurchaseTypeEnumFromJSONTyped,
20
+ BuyerSessionPurchaseTypeEnumToJSON,
21
+ BuyerSessionPurchaseTypeEnumToJSONTyped,
22
+ } from './BuyerSessionPurchaseTypeEnum';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface CreateBuyerSessionFromPurchaseInput
28
+ */
29
+ export interface CreateBuyerSessionFromPurchaseInput {
30
+ /**
31
+ * Kind of purchase the buyer just paid.
32
+ * @type {BuyerSessionPurchaseTypeEnum}
33
+ * @memberof CreateBuyerSessionFromPurchaseInput
34
+ */
35
+ type: BuyerSessionPurchaseTypeEnum;
36
+ /**
37
+ * Identifier of the purchase.
38
+ * @type {string}
39
+ * @memberof CreateBuyerSessionFromPurchaseInput
40
+ */
41
+ id: string;
42
+ }
43
+
44
+
45
+
46
+ /**
47
+ * Check if a given object implements the CreateBuyerSessionFromPurchaseInput interface.
48
+ */
49
+ export function instanceOfCreateBuyerSessionFromPurchaseInput(value: object): value is CreateBuyerSessionFromPurchaseInput {
50
+ if (!('type' in value) || value['type'] === undefined) return false;
51
+ if (!('id' in value) || value['id'] === undefined) return false;
52
+ return true;
53
+ }
54
+
55
+ export function CreateBuyerSessionFromPurchaseInputFromJSON(json: any): CreateBuyerSessionFromPurchaseInput {
56
+ return CreateBuyerSessionFromPurchaseInputFromJSONTyped(json, false);
57
+ }
58
+
59
+ export function CreateBuyerSessionFromPurchaseInputFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateBuyerSessionFromPurchaseInput {
60
+ if (json == null) {
61
+ return json;
62
+ }
63
+ return {
64
+
65
+ 'type': BuyerSessionPurchaseTypeEnumFromJSON(json['type']),
66
+ 'id': json['id'],
67
+ };
68
+ }
69
+
70
+ export function CreateBuyerSessionFromPurchaseInputToJSON(json: any): CreateBuyerSessionFromPurchaseInput {
71
+ return CreateBuyerSessionFromPurchaseInputToJSONTyped(json, false);
72
+ }
73
+
74
+ export function CreateBuyerSessionFromPurchaseInputToJSONTyped(value?: CreateBuyerSessionFromPurchaseInput | null, ignoreDiscriminator: boolean = false): any {
75
+ if (value == null) {
76
+ return value;
77
+ }
78
+
79
+ return {
80
+
81
+ 'type': BuyerSessionPurchaseTypeEnumToJSON(value['type']),
82
+ 'id': value['id'],
83
+ };
84
+ }
85
+
@@ -0,0 +1,66 @@
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
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface CreateDashboardBuyerSessionInput
20
+ */
21
+ export interface CreateDashboardBuyerSessionInput {
22
+ /**
23
+ * Locale of the dashboard page.
24
+ * @type {string}
25
+ * @memberof CreateDashboardBuyerSessionInput
26
+ */
27
+ locale: string;
28
+ }
29
+
30
+ /**
31
+ * Check if a given object implements the CreateDashboardBuyerSessionInput interface.
32
+ */
33
+ export function instanceOfCreateDashboardBuyerSessionInput(value: object): value is CreateDashboardBuyerSessionInput {
34
+ if (!('locale' in value) || value['locale'] === undefined) return false;
35
+ return true;
36
+ }
37
+
38
+ export function CreateDashboardBuyerSessionInputFromJSON(json: any): CreateDashboardBuyerSessionInput {
39
+ return CreateDashboardBuyerSessionInputFromJSONTyped(json, false);
40
+ }
41
+
42
+ export function CreateDashboardBuyerSessionInputFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateDashboardBuyerSessionInput {
43
+ if (json == null) {
44
+ return json;
45
+ }
46
+ return {
47
+
48
+ 'locale': json['locale'],
49
+ };
50
+ }
51
+
52
+ export function CreateDashboardBuyerSessionInputToJSON(json: any): CreateDashboardBuyerSessionInput {
53
+ return CreateDashboardBuyerSessionInputToJSONTyped(json, false);
54
+ }
55
+
56
+ export function CreateDashboardBuyerSessionInputToJSONTyped(value?: CreateDashboardBuyerSessionInput | null, ignoreDiscriminator: boolean = false): any {
57
+ if (value == null) {
58
+ return value;
59
+ }
60
+
61
+ return {
62
+
63
+ 'locale': value['locale'],
64
+ };
65
+ }
66
+
@@ -0,0 +1,75 @@
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
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface ExchangeBuyerSessionCodeInput
20
+ */
21
+ export interface ExchangeBuyerSessionCodeInput {
22
+ /**
23
+ * Code the API sent back to the landing after the redirect.
24
+ * @type {string}
25
+ * @memberof ExchangeBuyerSessionCodeInput
26
+ */
27
+ code: string;
28
+ /**
29
+ * PKCE verifier whose SHA-256, in base64url, was sent as codeChallenge.
30
+ * @type {string}
31
+ * @memberof ExchangeBuyerSessionCodeInput
32
+ */
33
+ codeVerifier: string;
34
+ }
35
+
36
+ /**
37
+ * Check if a given object implements the ExchangeBuyerSessionCodeInput interface.
38
+ */
39
+ export function instanceOfExchangeBuyerSessionCodeInput(value: object): value is ExchangeBuyerSessionCodeInput {
40
+ if (!('code' in value) || value['code'] === undefined) return false;
41
+ if (!('codeVerifier' in value) || value['codeVerifier'] === undefined) return false;
42
+ return true;
43
+ }
44
+
45
+ export function ExchangeBuyerSessionCodeInputFromJSON(json: any): ExchangeBuyerSessionCodeInput {
46
+ return ExchangeBuyerSessionCodeInputFromJSONTyped(json, false);
47
+ }
48
+
49
+ export function ExchangeBuyerSessionCodeInputFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExchangeBuyerSessionCodeInput {
50
+ if (json == null) {
51
+ return json;
52
+ }
53
+ return {
54
+
55
+ 'code': json['code'],
56
+ 'codeVerifier': json['codeVerifier'],
57
+ };
58
+ }
59
+
60
+ export function ExchangeBuyerSessionCodeInputToJSON(json: any): ExchangeBuyerSessionCodeInput {
61
+ return ExchangeBuyerSessionCodeInputToJSONTyped(json, false);
62
+ }
63
+
64
+ export function ExchangeBuyerSessionCodeInputToJSONTyped(value?: ExchangeBuyerSessionCodeInput | null, ignoreDiscriminator: boolean = false): any {
65
+ if (value == null) {
66
+ return value;
67
+ }
68
+
69
+ return {
70
+
71
+ 'code': value['code'],
72
+ 'codeVerifier': value['codeVerifier'],
73
+ };
74
+ }
75
+
@@ -0,0 +1,74 @@
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
+ import { mapValues } from '../runtime';
16
+ import type { BuyerLandingSessionOutput } from './BuyerLandingSessionOutput';
17
+ import {
18
+ BuyerLandingSessionOutputFromJSON,
19
+ BuyerLandingSessionOutputFromJSONTyped,
20
+ BuyerLandingSessionOutputToJSON,
21
+ BuyerLandingSessionOutputToJSONTyped,
22
+ } from './BuyerLandingSessionOutput';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface LeadEmailVerificationResultOutput
28
+ */
29
+ export interface LeadEmailVerificationResultOutput {
30
+ /**
31
+ * Buyer session for the landing that sent the request.
32
+ * @type {BuyerLandingSessionOutput}
33
+ * @memberof LeadEmailVerificationResultOutput
34
+ */
35
+ session: BuyerLandingSessionOutput | null;
36
+ }
37
+
38
+ /**
39
+ * Check if a given object implements the LeadEmailVerificationResultOutput interface.
40
+ */
41
+ export function instanceOfLeadEmailVerificationResultOutput(value: object): value is LeadEmailVerificationResultOutput {
42
+ if (!('session' in value) || value['session'] === undefined) return false;
43
+ return true;
44
+ }
45
+
46
+ export function LeadEmailVerificationResultOutputFromJSON(json: any): LeadEmailVerificationResultOutput {
47
+ return LeadEmailVerificationResultOutputFromJSONTyped(json, false);
48
+ }
49
+
50
+ export function LeadEmailVerificationResultOutputFromJSONTyped(json: any, ignoreDiscriminator: boolean): LeadEmailVerificationResultOutput {
51
+ if (json == null) {
52
+ return json;
53
+ }
54
+ return {
55
+
56
+ 'session': BuyerLandingSessionOutputFromJSON(json['session']),
57
+ };
58
+ }
59
+
60
+ export function LeadEmailVerificationResultOutputToJSON(json: any): LeadEmailVerificationResultOutput {
61
+ return LeadEmailVerificationResultOutputToJSONTyped(json, false);
62
+ }
63
+
64
+ export function LeadEmailVerificationResultOutputToJSONTyped(value?: LeadEmailVerificationResultOutput | null, ignoreDiscriminator: boolean = false): any {
65
+ if (value == null) {
66
+ return value;
67
+ }
68
+
69
+ return {
70
+
71
+ 'session': BuyerLandingSessionOutputToJSON(value['session']),
72
+ };
73
+ }
74
+
@@ -0,0 +1,57 @@
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
+ /**
17
+ * Why the highest buyer offer cannot be accepted, if so.
18
+ * @export
19
+ */
20
+ export const LeadOfferSummaryCannotAcceptReason = {
21
+ NO_BUYER_OFFER: 'no_buyer_offer',
22
+ LEAD_NOT_NEGOTIABLE: 'lead_not_negotiable',
23
+ MANUAL_LEAD: 'manual_lead',
24
+ DOMAIN_IS_LOCKED: 'domain_is_locked',
25
+ DOMAIN_HAS_AN_AUCTION: 'domain_has_an_auction',
26
+ DOMAIN_NOT_PURCHASABLE: 'domain_not_purchasable'
27
+ } as const;
28
+ export type LeadOfferSummaryCannotAcceptReason = typeof LeadOfferSummaryCannotAcceptReason[keyof typeof LeadOfferSummaryCannotAcceptReason];
29
+
30
+
31
+ export function instanceOfLeadOfferSummaryCannotAcceptReason(value: any): boolean {
32
+ for (const key in LeadOfferSummaryCannotAcceptReason) {
33
+ if (Object.prototype.hasOwnProperty.call(LeadOfferSummaryCannotAcceptReason, key)) {
34
+ if (LeadOfferSummaryCannotAcceptReason[key as keyof typeof LeadOfferSummaryCannotAcceptReason] === value) {
35
+ return true;
36
+ }
37
+ }
38
+ }
39
+ return false;
40
+ }
41
+
42
+ export function LeadOfferSummaryCannotAcceptReasonFromJSON(json: any): LeadOfferSummaryCannotAcceptReason {
43
+ return LeadOfferSummaryCannotAcceptReasonFromJSONTyped(json, false);
44
+ }
45
+
46
+ export function LeadOfferSummaryCannotAcceptReasonFromJSONTyped(json: any, ignoreDiscriminator: boolean): LeadOfferSummaryCannotAcceptReason {
47
+ return json as LeadOfferSummaryCannotAcceptReason;
48
+ }
49
+
50
+ export function LeadOfferSummaryCannotAcceptReasonToJSON(value?: LeadOfferSummaryCannotAcceptReason | null): any {
51
+ return value as any;
52
+ }
53
+
54
+ export function LeadOfferSummaryCannotAcceptReasonToJSONTyped(value: any, ignoreDiscriminator: boolean): LeadOfferSummaryCannotAcceptReason {
55
+ return value as LeadOfferSummaryCannotAcceptReason;
56
+ }
57
+
@@ -0,0 +1,110 @@
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
+ import { mapValues } from '../runtime';
16
+ import type { LeadOfferSummaryCannotAcceptReason } from './LeadOfferSummaryCannotAcceptReason';
17
+ import {
18
+ LeadOfferSummaryCannotAcceptReasonFromJSON,
19
+ LeadOfferSummaryCannotAcceptReasonFromJSONTyped,
20
+ LeadOfferSummaryCannotAcceptReasonToJSON,
21
+ LeadOfferSummaryCannotAcceptReasonToJSONTyped,
22
+ } from './LeadOfferSummaryCannotAcceptReason';
23
+ import type { LeadOfferSummaryItemDto } from './LeadOfferSummaryItemDto';
24
+ import {
25
+ LeadOfferSummaryItemDtoFromJSON,
26
+ LeadOfferSummaryItemDtoFromJSONTyped,
27
+ LeadOfferSummaryItemDtoToJSON,
28
+ LeadOfferSummaryItemDtoToJSONTyped,
29
+ } from './LeadOfferSummaryItemDto';
30
+
31
+ /**
32
+ *
33
+ * @export
34
+ * @interface LeadOfferSummaryDto
35
+ */
36
+ export interface LeadOfferSummaryDto {
37
+ /**
38
+ * The highest plain purchase offer the buyer made and did not withdraw, in the domain currency. Null when there is none.
39
+ * @type {LeadOfferSummaryItemDto}
40
+ * @memberof LeadOfferSummaryDto
41
+ */
42
+ highestBuyerOffer: LeadOfferSummaryItemDto | null;
43
+ /**
44
+ * The lowest plain purchase offer the seller side (seller or price negotiator) made and did not withdraw, in the domain currency. Null when there is none.
45
+ * @type {LeadOfferSummaryItemDto}
46
+ * @memberof LeadOfferSummaryDto
47
+ */
48
+ lowestSellerOffer: LeadOfferSummaryItemDto | null;
49
+ /**
50
+ * Whether the highest buyer offer can be accepted right now with the accept-highest-buyer-offer endpoint.
51
+ * @type {boolean}
52
+ * @memberof LeadOfferSummaryDto
53
+ */
54
+ canAcceptHighestBuyerOffer: boolean;
55
+ /**
56
+ * Why the highest buyer offer cannot be accepted, if so.
57
+ * @type {LeadOfferSummaryCannotAcceptReason}
58
+ * @memberof LeadOfferSummaryDto
59
+ */
60
+ cannotAcceptReason: LeadOfferSummaryCannotAcceptReason | null;
61
+ }
62
+
63
+
64
+
65
+ /**
66
+ * Check if a given object implements the LeadOfferSummaryDto interface.
67
+ */
68
+ export function instanceOfLeadOfferSummaryDto(value: object): value is LeadOfferSummaryDto {
69
+ if (!('highestBuyerOffer' in value) || value['highestBuyerOffer'] === undefined) return false;
70
+ if (!('lowestSellerOffer' in value) || value['lowestSellerOffer'] === undefined) return false;
71
+ if (!('canAcceptHighestBuyerOffer' in value) || value['canAcceptHighestBuyerOffer'] === undefined) return false;
72
+ if (!('cannotAcceptReason' in value) || value['cannotAcceptReason'] === undefined) return false;
73
+ return true;
74
+ }
75
+
76
+ export function LeadOfferSummaryDtoFromJSON(json: any): LeadOfferSummaryDto {
77
+ return LeadOfferSummaryDtoFromJSONTyped(json, false);
78
+ }
79
+
80
+ export function LeadOfferSummaryDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): LeadOfferSummaryDto {
81
+ if (json == null) {
82
+ return json;
83
+ }
84
+ return {
85
+
86
+ 'highestBuyerOffer': LeadOfferSummaryItemDtoFromJSON(json['highestBuyerOffer']),
87
+ 'lowestSellerOffer': LeadOfferSummaryItemDtoFromJSON(json['lowestSellerOffer']),
88
+ 'canAcceptHighestBuyerOffer': json['canAcceptHighestBuyerOffer'],
89
+ 'cannotAcceptReason': LeadOfferSummaryCannotAcceptReasonFromJSON(json['cannotAcceptReason']),
90
+ };
91
+ }
92
+
93
+ export function LeadOfferSummaryDtoToJSON(json: any): LeadOfferSummaryDto {
94
+ return LeadOfferSummaryDtoToJSONTyped(json, false);
95
+ }
96
+
97
+ export function LeadOfferSummaryDtoToJSONTyped(value?: LeadOfferSummaryDto | null, ignoreDiscriminator: boolean = false): any {
98
+ if (value == null) {
99
+ return value;
100
+ }
101
+
102
+ return {
103
+
104
+ 'highestBuyerOffer': LeadOfferSummaryItemDtoToJSON(value['highestBuyerOffer']),
105
+ 'lowestSellerOffer': LeadOfferSummaryItemDtoToJSON(value['lowestSellerOffer']),
106
+ 'canAcceptHighestBuyerOffer': value['canAcceptHighestBuyerOffer'],
107
+ 'cannotAcceptReason': LeadOfferSummaryCannotAcceptReasonToJSON(value['cannotAcceptReason']),
108
+ };
109
+ }
110
+
@@ -0,0 +1,114 @@
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
+ import { mapValues } from '../runtime';
16
+ import type { MoneyDto } from './MoneyDto';
17
+ import {
18
+ MoneyDtoFromJSON,
19
+ MoneyDtoFromJSONTyped,
20
+ MoneyDtoToJSON,
21
+ MoneyDtoToJSONTyped,
22
+ } from './MoneyDto';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface LeadOfferSummaryItemDto
28
+ */
29
+ export interface LeadOfferSummaryItemDto {
30
+ /**
31
+ * The id of the offer message in the lead conversation.
32
+ * @type {string}
33
+ * @memberof LeadOfferSummaryItemDto
34
+ */
35
+ leadMessageId: string;
36
+ /**
37
+ * The amount offered.
38
+ * @type {MoneyDto}
39
+ * @memberof LeadOfferSummaryItemDto
40
+ */
41
+ price: MoneyDto;
42
+ /**
43
+ * Who made the offer.
44
+ * @type {string}
45
+ * @memberof LeadOfferSummaryItemDto
46
+ */
47
+ origin: LeadOfferSummaryItemDtoOriginEnum;
48
+ /**
49
+ * When the offer was made.
50
+ * @type {Date}
51
+ * @memberof LeadOfferSummaryItemDto
52
+ */
53
+ createdAt: Date;
54
+ }
55
+
56
+
57
+ /**
58
+ * @export
59
+ */
60
+ export const LeadOfferSummaryItemDtoOriginEnum = {
61
+ BUYER: 'buyer',
62
+ SELLER: 'seller',
63
+ AI: 'ai',
64
+ ADMIN: 'admin'
65
+ } as const;
66
+ export type LeadOfferSummaryItemDtoOriginEnum = typeof LeadOfferSummaryItemDtoOriginEnum[keyof typeof LeadOfferSummaryItemDtoOriginEnum];
67
+
68
+
69
+ /**
70
+ * Check if a given object implements the LeadOfferSummaryItemDto interface.
71
+ */
72
+ export function instanceOfLeadOfferSummaryItemDto(value: object): value is LeadOfferSummaryItemDto {
73
+ if (!('leadMessageId' in value) || value['leadMessageId'] === undefined) return false;
74
+ if (!('price' in value) || value['price'] === undefined) return false;
75
+ if (!('origin' in value) || value['origin'] === undefined) return false;
76
+ if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
77
+ return true;
78
+ }
79
+
80
+ export function LeadOfferSummaryItemDtoFromJSON(json: any): LeadOfferSummaryItemDto {
81
+ return LeadOfferSummaryItemDtoFromJSONTyped(json, false);
82
+ }
83
+
84
+ export function LeadOfferSummaryItemDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): LeadOfferSummaryItemDto {
85
+ if (json == null) {
86
+ return json;
87
+ }
88
+ return {
89
+
90
+ 'leadMessageId': json['leadMessageId'],
91
+ 'price': MoneyDtoFromJSON(json['price']),
92
+ 'origin': json['origin'],
93
+ 'createdAt': (new Date(json['createdAt'])),
94
+ };
95
+ }
96
+
97
+ export function LeadOfferSummaryItemDtoToJSON(json: any): LeadOfferSummaryItemDto {
98
+ return LeadOfferSummaryItemDtoToJSONTyped(json, false);
99
+ }
100
+
101
+ export function LeadOfferSummaryItemDtoToJSONTyped(value?: LeadOfferSummaryItemDto | null, ignoreDiscriminator: boolean = false): any {
102
+ if (value == null) {
103
+ return value;
104
+ }
105
+
106
+ return {
107
+
108
+ 'leadMessageId': value['leadMessageId'],
109
+ 'price': MoneyDtoToJSON(value['price']),
110
+ 'origin': value['origin'],
111
+ 'createdAt': ((value['createdAt']).toISOString()),
112
+ };
113
+ }
114
+