@equisoft/equisoft-connect-sdk-typescript 13.49.0 → 13.49.1-snapshot.20260429151415
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 +2 -0
- package/.tool-versions +1 -1
- package/README.md +2 -0
- package/dist/apis/ContactsApi.d.ts +17 -1
- package/dist/apis/ContactsApi.js +56 -0
- package/dist/esm/apis/ContactsApi.d.ts +17 -1
- package/dist/esm/apis/ContactsApi.js +57 -1
- package/dist/esm/models/ContactsHouseholdCreateHouseholdPayload.d.ts +32 -0
- package/dist/esm/models/ContactsHouseholdCreateHouseholdPayload.js +43 -0
- package/dist/esm/models/index.d.ts +1 -0
- package/dist/esm/models/index.js +1 -0
- package/dist/models/ContactsHouseholdCreateHouseholdPayload.d.ts +32 -0
- package/dist/models/ContactsHouseholdCreateHouseholdPayload.js +50 -0
- package/dist/models/index.d.ts +1 -0
- package/dist/models/index.js +1 -0
- package/docs/ContactsApi.md +75 -0
- package/docs/ContactsHouseholdCreateHouseholdPayload.md +34 -0
- package/package.json +1 -1
- package/src/apis/ContactsApi.ts +72 -0
- package/src/models/ContactsHouseholdCreateHouseholdPayload.ts +66 -0
- package/src/models/index.ts +1 -0
package/.openapi-generator/FILES
CHANGED
|
@@ -35,6 +35,7 @@ docs/ContactsCreateRevenuePayload.md
|
|
|
35
35
|
docs/ContactsCreateSegmentationPayload.md
|
|
36
36
|
docs/ContactsCreateWebsitePayload.md
|
|
37
37
|
docs/ContactsEmail.md
|
|
38
|
+
docs/ContactsHouseholdCreateHouseholdPayload.md
|
|
38
39
|
docs/ContactsIdentification.md
|
|
39
40
|
docs/ContactsIndividualIdentification.md
|
|
40
41
|
docs/ContactsInvestmentObjective.md
|
|
@@ -366,6 +367,7 @@ src/models/ContactsCreateRevenuePayload.ts
|
|
|
366
367
|
src/models/ContactsCreateSegmentationPayload.ts
|
|
367
368
|
src/models/ContactsCreateWebsitePayload.ts
|
|
368
369
|
src/models/ContactsEmail.ts
|
|
370
|
+
src/models/ContactsHouseholdCreateHouseholdPayload.ts
|
|
369
371
|
src/models/ContactsIdentification.ts
|
|
370
372
|
src/models/ContactsIndividualIdentification.ts
|
|
371
373
|
src/models/ContactsInvestmentObjective.ts
|
package/.tool-versions
CHANGED
package/README.md
CHANGED
|
@@ -55,6 +55,7 @@ All URIs are relative to *http://localhost*
|
|
|
55
55
|
| Class | Method | HTTP request | Description
|
|
56
56
|
| ----- | ------ | ------------ | -------------
|
|
57
57
|
*ContactsApi* | [**createContact**](docs/ContactsApi.md#createcontact) | **POST** /crm/api/v1/contacts | Create a contact
|
|
58
|
+
*ContactsApi* | [**createHousehold**](docs/ContactsApi.md#createhousehold) | **POST** /crm/api/v1/contacts/household | Create a household (EXPERIMENTAL)
|
|
58
59
|
*ContactsApi* | [**getByUuid**](docs/ContactsApi.md#getbyuuid) | **GET** /crm/api/v1/contacts/{contactUuid} | Get contact by Uuid
|
|
59
60
|
*ContactsApi* | [**listContact**](docs/ContactsApi.md#listcontact) | **GET** /crm/api/v1/contacts | List contact
|
|
60
61
|
*ContactsApi* | [**listContactDocument**](docs/ContactsApi.md#listcontactdocument) | **GET** /crm/api/v1/contacts/{contactUuid}/documents | List contact documents
|
|
@@ -229,6 +230,7 @@ All URIs are relative to *http://localhost*
|
|
|
229
230
|
- [ContactsCreateSegmentationPayload](docs/ContactsCreateSegmentationPayload.md)
|
|
230
231
|
- [ContactsCreateWebsitePayload](docs/ContactsCreateWebsitePayload.md)
|
|
231
232
|
- [ContactsEmail](docs/ContactsEmail.md)
|
|
233
|
+
- [ContactsHouseholdCreateHouseholdPayload](docs/ContactsHouseholdCreateHouseholdPayload.md)
|
|
232
234
|
- [ContactsIdentification](docs/ContactsIdentification.md)
|
|
233
235
|
- [ContactsIndividualIdentification](docs/ContactsIndividualIdentification.md)
|
|
234
236
|
- [ContactsInvestmentObjective](docs/ContactsInvestmentObjective.md)
|
|
@@ -10,10 +10,14 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { ContactPatchContactPayload, ContactsContact, ContactsCreateContactPayload, ContactsListContactResponse, DocumentsListDocumentResponse, InvestmentsListAccountResponse } from '../models/index';
|
|
13
|
+
import type { ContactPatchContactPayload, ContactsContact, ContactsCreateContactPayload, ContactsHouseholdCreateHouseholdPayload, ContactsListContactResponse, DocumentsListDocumentResponse, InvestmentsListAccountResponse } from '../models/index';
|
|
14
14
|
export interface CreateContactRequest {
|
|
15
15
|
contactsCreateContactPayload: ContactsCreateContactPayload;
|
|
16
16
|
}
|
|
17
|
+
export interface CreateHouseholdRequest {
|
|
18
|
+
contactsHouseholdCreateHouseholdPayload: ContactsHouseholdCreateHouseholdPayload;
|
|
19
|
+
name?: string;
|
|
20
|
+
}
|
|
17
21
|
export interface GetByUuidRequest {
|
|
18
22
|
contactUuid: string;
|
|
19
23
|
acceptLanguage?: string;
|
|
@@ -74,6 +78,18 @@ export declare class ContactsApi extends runtime.BaseAPI {
|
|
|
74
78
|
* Create a contact
|
|
75
79
|
*/
|
|
76
80
|
createContact(requestParameters: CreateContactRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ContactsContact>;
|
|
81
|
+
/**
|
|
82
|
+
* Creates request options for createHousehold without sending the request
|
|
83
|
+
*/
|
|
84
|
+
createHouseholdRequestOpts(requestParameters: CreateHouseholdRequest): Promise<runtime.RequestOpts>;
|
|
85
|
+
/**
|
|
86
|
+
* Create a household (EXPERIMENTAL)
|
|
87
|
+
*/
|
|
88
|
+
createHouseholdRaw(requestParameters: CreateHouseholdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>>;
|
|
89
|
+
/**
|
|
90
|
+
* Create a household (EXPERIMENTAL)
|
|
91
|
+
*/
|
|
92
|
+
createHousehold(requestParameters: CreateHouseholdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any>;
|
|
77
93
|
/**
|
|
78
94
|
* Creates request options for getByUuid without sending the request
|
|
79
95
|
*/
|
package/dist/apis/ContactsApi.js
CHANGED
|
@@ -77,6 +77,62 @@ class ContactsApi extends runtime.BaseAPI {
|
|
|
77
77
|
return yield response.value();
|
|
78
78
|
});
|
|
79
79
|
}
|
|
80
|
+
/**
|
|
81
|
+
* Creates request options for createHousehold without sending the request
|
|
82
|
+
*/
|
|
83
|
+
createHouseholdRequestOpts(requestParameters) {
|
|
84
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
85
|
+
if (requestParameters['contactsHouseholdCreateHouseholdPayload'] == null) {
|
|
86
|
+
throw new runtime.RequiredError('contactsHouseholdCreateHouseholdPayload', 'Required parameter "contactsHouseholdCreateHouseholdPayload" was null or undefined when calling createHousehold().');
|
|
87
|
+
}
|
|
88
|
+
const queryParameters = {};
|
|
89
|
+
if (requestParameters['name'] != null) {
|
|
90
|
+
queryParameters['name'] = requestParameters['name'];
|
|
91
|
+
}
|
|
92
|
+
const headerParameters = {};
|
|
93
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
94
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
95
|
+
// oauth required
|
|
96
|
+
const token = this.configuration.accessToken;
|
|
97
|
+
const tokenString = yield token("OAuth2", ["crm:contact"]);
|
|
98
|
+
if (tokenString) {
|
|
99
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
let urlPath = `/crm/api/v1/contacts/household`;
|
|
103
|
+
return {
|
|
104
|
+
path: urlPath,
|
|
105
|
+
method: 'POST',
|
|
106
|
+
headers: headerParameters,
|
|
107
|
+
query: queryParameters,
|
|
108
|
+
body: (0, index_1.ContactsHouseholdCreateHouseholdPayloadToJSON)(requestParameters['contactsHouseholdCreateHouseholdPayload']),
|
|
109
|
+
};
|
|
110
|
+
});
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Create a household (EXPERIMENTAL)
|
|
114
|
+
*/
|
|
115
|
+
createHouseholdRaw(requestParameters, initOverrides) {
|
|
116
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
117
|
+
const requestOptions = yield this.createHouseholdRequestOpts(requestParameters);
|
|
118
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
119
|
+
if (this.isJsonMime(response.headers.get('content-type'))) {
|
|
120
|
+
return new runtime.JSONApiResponse(response);
|
|
121
|
+
}
|
|
122
|
+
else {
|
|
123
|
+
return new runtime.TextApiResponse(response);
|
|
124
|
+
}
|
|
125
|
+
});
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* Create a household (EXPERIMENTAL)
|
|
129
|
+
*/
|
|
130
|
+
createHousehold(requestParameters, initOverrides) {
|
|
131
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
132
|
+
const response = yield this.createHouseholdRaw(requestParameters, initOverrides);
|
|
133
|
+
return yield response.value();
|
|
134
|
+
});
|
|
135
|
+
}
|
|
80
136
|
/**
|
|
81
137
|
* Creates request options for getByUuid without sending the request
|
|
82
138
|
*/
|
|
@@ -10,10 +10,14 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { ContactPatchContactPayload, ContactsContact, ContactsCreateContactPayload, ContactsListContactResponse, DocumentsListDocumentResponse, InvestmentsListAccountResponse } from '../models/index';
|
|
13
|
+
import type { ContactPatchContactPayload, ContactsContact, ContactsCreateContactPayload, ContactsHouseholdCreateHouseholdPayload, ContactsListContactResponse, DocumentsListDocumentResponse, InvestmentsListAccountResponse } from '../models/index';
|
|
14
14
|
export interface CreateContactRequest {
|
|
15
15
|
contactsCreateContactPayload: ContactsCreateContactPayload;
|
|
16
16
|
}
|
|
17
|
+
export interface CreateHouseholdRequest {
|
|
18
|
+
contactsHouseholdCreateHouseholdPayload: ContactsHouseholdCreateHouseholdPayload;
|
|
19
|
+
name?: string;
|
|
20
|
+
}
|
|
17
21
|
export interface GetByUuidRequest {
|
|
18
22
|
contactUuid: string;
|
|
19
23
|
acceptLanguage?: string;
|
|
@@ -74,6 +78,18 @@ export declare class ContactsApi extends runtime.BaseAPI {
|
|
|
74
78
|
* Create a contact
|
|
75
79
|
*/
|
|
76
80
|
createContact(requestParameters: CreateContactRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ContactsContact>;
|
|
81
|
+
/**
|
|
82
|
+
* Creates request options for createHousehold without sending the request
|
|
83
|
+
*/
|
|
84
|
+
createHouseholdRequestOpts(requestParameters: CreateHouseholdRequest): Promise<runtime.RequestOpts>;
|
|
85
|
+
/**
|
|
86
|
+
* Create a household (EXPERIMENTAL)
|
|
87
|
+
*/
|
|
88
|
+
createHouseholdRaw(requestParameters: CreateHouseholdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>>;
|
|
89
|
+
/**
|
|
90
|
+
* Create a household (EXPERIMENTAL)
|
|
91
|
+
*/
|
|
92
|
+
createHousehold(requestParameters: CreateHouseholdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any>;
|
|
77
93
|
/**
|
|
78
94
|
* Creates request options for getByUuid without sending the request
|
|
79
95
|
*/
|
|
@@ -21,7 +21,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
21
21
|
});
|
|
22
22
|
};
|
|
23
23
|
import * as runtime from '../runtime';
|
|
24
|
-
import { ContactPatchContactPayloadToJSON, ContactsContactFromJSON, ContactsCreateContactPayloadToJSON, ContactsListContactResponseFromJSON, DocumentsListDocumentResponseFromJSON, InvestmentsListAccountResponseFromJSON, } from '../models/index';
|
|
24
|
+
import { ContactPatchContactPayloadToJSON, ContactsContactFromJSON, ContactsCreateContactPayloadToJSON, ContactsHouseholdCreateHouseholdPayloadToJSON, ContactsListContactResponseFromJSON, DocumentsListDocumentResponseFromJSON, InvestmentsListAccountResponseFromJSON, } from '../models/index';
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
@@ -74,6 +74,62 @@ export class ContactsApi extends runtime.BaseAPI {
|
|
|
74
74
|
return yield response.value();
|
|
75
75
|
});
|
|
76
76
|
}
|
|
77
|
+
/**
|
|
78
|
+
* Creates request options for createHousehold without sending the request
|
|
79
|
+
*/
|
|
80
|
+
createHouseholdRequestOpts(requestParameters) {
|
|
81
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
82
|
+
if (requestParameters['contactsHouseholdCreateHouseholdPayload'] == null) {
|
|
83
|
+
throw new runtime.RequiredError('contactsHouseholdCreateHouseholdPayload', 'Required parameter "contactsHouseholdCreateHouseholdPayload" was null or undefined when calling createHousehold().');
|
|
84
|
+
}
|
|
85
|
+
const queryParameters = {};
|
|
86
|
+
if (requestParameters['name'] != null) {
|
|
87
|
+
queryParameters['name'] = requestParameters['name'];
|
|
88
|
+
}
|
|
89
|
+
const headerParameters = {};
|
|
90
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
91
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
92
|
+
// oauth required
|
|
93
|
+
const token = this.configuration.accessToken;
|
|
94
|
+
const tokenString = yield token("OAuth2", ["crm:contact"]);
|
|
95
|
+
if (tokenString) {
|
|
96
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
let urlPath = `/crm/api/v1/contacts/household`;
|
|
100
|
+
return {
|
|
101
|
+
path: urlPath,
|
|
102
|
+
method: 'POST',
|
|
103
|
+
headers: headerParameters,
|
|
104
|
+
query: queryParameters,
|
|
105
|
+
body: ContactsHouseholdCreateHouseholdPayloadToJSON(requestParameters['contactsHouseholdCreateHouseholdPayload']),
|
|
106
|
+
};
|
|
107
|
+
});
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* Create a household (EXPERIMENTAL)
|
|
111
|
+
*/
|
|
112
|
+
createHouseholdRaw(requestParameters, initOverrides) {
|
|
113
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
114
|
+
const requestOptions = yield this.createHouseholdRequestOpts(requestParameters);
|
|
115
|
+
const response = yield this.request(requestOptions, initOverrides);
|
|
116
|
+
if (this.isJsonMime(response.headers.get('content-type'))) {
|
|
117
|
+
return new runtime.JSONApiResponse(response);
|
|
118
|
+
}
|
|
119
|
+
else {
|
|
120
|
+
return new runtime.TextApiResponse(response);
|
|
121
|
+
}
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Create a household (EXPERIMENTAL)
|
|
126
|
+
*/
|
|
127
|
+
createHousehold(requestParameters, initOverrides) {
|
|
128
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
129
|
+
const response = yield this.createHouseholdRaw(requestParameters, initOverrides);
|
|
130
|
+
return yield response.value();
|
|
131
|
+
});
|
|
132
|
+
}
|
|
77
133
|
/**
|
|
78
134
|
* Creates request options for getByUuid without sending the request
|
|
79
135
|
*/
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Equisoft /connect API
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: latest
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface ContactsHouseholdCreateHouseholdPayload
|
|
16
|
+
*/
|
|
17
|
+
export interface ContactsHouseholdCreateHouseholdPayload {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof ContactsHouseholdCreateHouseholdPayload
|
|
22
|
+
*/
|
|
23
|
+
name: string;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Check if a given object implements the ContactsHouseholdCreateHouseholdPayload interface.
|
|
27
|
+
*/
|
|
28
|
+
export declare function instanceOfContactsHouseholdCreateHouseholdPayload(value: object): value is ContactsHouseholdCreateHouseholdPayload;
|
|
29
|
+
export declare function ContactsHouseholdCreateHouseholdPayloadFromJSON(json: any): ContactsHouseholdCreateHouseholdPayload;
|
|
30
|
+
export declare function ContactsHouseholdCreateHouseholdPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): ContactsHouseholdCreateHouseholdPayload;
|
|
31
|
+
export declare function ContactsHouseholdCreateHouseholdPayloadToJSON(json: any): ContactsHouseholdCreateHouseholdPayload;
|
|
32
|
+
export declare function ContactsHouseholdCreateHouseholdPayloadToJSONTyped(value?: ContactsHouseholdCreateHouseholdPayload | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Equisoft /connect API
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: latest
|
|
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
|
+
* Check if a given object implements the ContactsHouseholdCreateHouseholdPayload interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfContactsHouseholdCreateHouseholdPayload(value) {
|
|
18
|
+
if (!('name' in value) || value['name'] === undefined)
|
|
19
|
+
return false;
|
|
20
|
+
return true;
|
|
21
|
+
}
|
|
22
|
+
export function ContactsHouseholdCreateHouseholdPayloadFromJSON(json) {
|
|
23
|
+
return ContactsHouseholdCreateHouseholdPayloadFromJSONTyped(json, false);
|
|
24
|
+
}
|
|
25
|
+
export function ContactsHouseholdCreateHouseholdPayloadFromJSONTyped(json, ignoreDiscriminator) {
|
|
26
|
+
if (json == null) {
|
|
27
|
+
return json;
|
|
28
|
+
}
|
|
29
|
+
return {
|
|
30
|
+
'name': json['name'],
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
export function ContactsHouseholdCreateHouseholdPayloadToJSON(json) {
|
|
34
|
+
return ContactsHouseholdCreateHouseholdPayloadToJSONTyped(json, false);
|
|
35
|
+
}
|
|
36
|
+
export function ContactsHouseholdCreateHouseholdPayloadToJSONTyped(value, ignoreDiscriminator = false) {
|
|
37
|
+
if (value == null) {
|
|
38
|
+
return value;
|
|
39
|
+
}
|
|
40
|
+
return {
|
|
41
|
+
'name': value['name'],
|
|
42
|
+
};
|
|
43
|
+
}
|
|
@@ -32,6 +32,7 @@ export * from './ContactsCreateRevenuePayload';
|
|
|
32
32
|
export * from './ContactsCreateSegmentationPayload';
|
|
33
33
|
export * from './ContactsCreateWebsitePayload';
|
|
34
34
|
export * from './ContactsEmail';
|
|
35
|
+
export * from './ContactsHouseholdCreateHouseholdPayload';
|
|
35
36
|
export * from './ContactsIdentification';
|
|
36
37
|
export * from './ContactsIndividualIdentification';
|
|
37
38
|
export * from './ContactsInvestmentObjective';
|
package/dist/esm/models/index.js
CHANGED
|
@@ -34,6 +34,7 @@ export * from './ContactsCreateRevenuePayload';
|
|
|
34
34
|
export * from './ContactsCreateSegmentationPayload';
|
|
35
35
|
export * from './ContactsCreateWebsitePayload';
|
|
36
36
|
export * from './ContactsEmail';
|
|
37
|
+
export * from './ContactsHouseholdCreateHouseholdPayload';
|
|
37
38
|
export * from './ContactsIdentification';
|
|
38
39
|
export * from './ContactsIndividualIdentification';
|
|
39
40
|
export * from './ContactsInvestmentObjective';
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Equisoft /connect API
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: latest
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface ContactsHouseholdCreateHouseholdPayload
|
|
16
|
+
*/
|
|
17
|
+
export interface ContactsHouseholdCreateHouseholdPayload {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof ContactsHouseholdCreateHouseholdPayload
|
|
22
|
+
*/
|
|
23
|
+
name: string;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Check if a given object implements the ContactsHouseholdCreateHouseholdPayload interface.
|
|
27
|
+
*/
|
|
28
|
+
export declare function instanceOfContactsHouseholdCreateHouseholdPayload(value: object): value is ContactsHouseholdCreateHouseholdPayload;
|
|
29
|
+
export declare function ContactsHouseholdCreateHouseholdPayloadFromJSON(json: any): ContactsHouseholdCreateHouseholdPayload;
|
|
30
|
+
export declare function ContactsHouseholdCreateHouseholdPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): ContactsHouseholdCreateHouseholdPayload;
|
|
31
|
+
export declare function ContactsHouseholdCreateHouseholdPayloadToJSON(json: any): ContactsHouseholdCreateHouseholdPayload;
|
|
32
|
+
export declare function ContactsHouseholdCreateHouseholdPayloadToJSONTyped(value?: ContactsHouseholdCreateHouseholdPayload | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Equisoft /connect API
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: latest
|
|
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.instanceOfContactsHouseholdCreateHouseholdPayload = instanceOfContactsHouseholdCreateHouseholdPayload;
|
|
17
|
+
exports.ContactsHouseholdCreateHouseholdPayloadFromJSON = ContactsHouseholdCreateHouseholdPayloadFromJSON;
|
|
18
|
+
exports.ContactsHouseholdCreateHouseholdPayloadFromJSONTyped = ContactsHouseholdCreateHouseholdPayloadFromJSONTyped;
|
|
19
|
+
exports.ContactsHouseholdCreateHouseholdPayloadToJSON = ContactsHouseholdCreateHouseholdPayloadToJSON;
|
|
20
|
+
exports.ContactsHouseholdCreateHouseholdPayloadToJSONTyped = ContactsHouseholdCreateHouseholdPayloadToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the ContactsHouseholdCreateHouseholdPayload interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfContactsHouseholdCreateHouseholdPayload(value) {
|
|
25
|
+
if (!('name' in value) || value['name'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
return true;
|
|
28
|
+
}
|
|
29
|
+
function ContactsHouseholdCreateHouseholdPayloadFromJSON(json) {
|
|
30
|
+
return ContactsHouseholdCreateHouseholdPayloadFromJSONTyped(json, false);
|
|
31
|
+
}
|
|
32
|
+
function ContactsHouseholdCreateHouseholdPayloadFromJSONTyped(json, ignoreDiscriminator) {
|
|
33
|
+
if (json == null) {
|
|
34
|
+
return json;
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
'name': json['name'],
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
function ContactsHouseholdCreateHouseholdPayloadToJSON(json) {
|
|
41
|
+
return ContactsHouseholdCreateHouseholdPayloadToJSONTyped(json, false);
|
|
42
|
+
}
|
|
43
|
+
function ContactsHouseholdCreateHouseholdPayloadToJSONTyped(value, ignoreDiscriminator = false) {
|
|
44
|
+
if (value == null) {
|
|
45
|
+
return value;
|
|
46
|
+
}
|
|
47
|
+
return {
|
|
48
|
+
'name': value['name'],
|
|
49
|
+
};
|
|
50
|
+
}
|
package/dist/models/index.d.ts
CHANGED
|
@@ -32,6 +32,7 @@ export * from './ContactsCreateRevenuePayload';
|
|
|
32
32
|
export * from './ContactsCreateSegmentationPayload';
|
|
33
33
|
export * from './ContactsCreateWebsitePayload';
|
|
34
34
|
export * from './ContactsEmail';
|
|
35
|
+
export * from './ContactsHouseholdCreateHouseholdPayload';
|
|
35
36
|
export * from './ContactsIdentification';
|
|
36
37
|
export * from './ContactsIndividualIdentification';
|
|
37
38
|
export * from './ContactsInvestmentObjective';
|
package/dist/models/index.js
CHANGED
|
@@ -50,6 +50,7 @@ __exportStar(require("./ContactsCreateRevenuePayload"), exports);
|
|
|
50
50
|
__exportStar(require("./ContactsCreateSegmentationPayload"), exports);
|
|
51
51
|
__exportStar(require("./ContactsCreateWebsitePayload"), exports);
|
|
52
52
|
__exportStar(require("./ContactsEmail"), exports);
|
|
53
|
+
__exportStar(require("./ContactsHouseholdCreateHouseholdPayload"), exports);
|
|
53
54
|
__exportStar(require("./ContactsIdentification"), exports);
|
|
54
55
|
__exportStar(require("./ContactsIndividualIdentification"), exports);
|
|
55
56
|
__exportStar(require("./ContactsInvestmentObjective"), exports);
|
package/docs/ContactsApi.md
CHANGED
|
@@ -5,6 +5,7 @@ All URIs are relative to *http://localhost*
|
|
|
5
5
|
| Method | HTTP request | Description |
|
|
6
6
|
|------------- | ------------- | -------------|
|
|
7
7
|
| [**createContact**](ContactsApi.md#createcontact) | **POST** /crm/api/v1/contacts | Create a contact |
|
|
8
|
+
| [**createHousehold**](ContactsApi.md#createhousehold) | **POST** /crm/api/v1/contacts/household | Create a household (EXPERIMENTAL) |
|
|
8
9
|
| [**getByUuid**](ContactsApi.md#getbyuuid) | **GET** /crm/api/v1/contacts/{contactUuid} | Get contact by Uuid |
|
|
9
10
|
| [**listContact**](ContactsApi.md#listcontact) | **GET** /crm/api/v1/contacts | List contact |
|
|
10
11
|
| [**listContactDocument**](ContactsApi.md#listcontactdocument) | **GET** /crm/api/v1/contacts/{contactUuid}/documents | List contact documents |
|
|
@@ -84,6 +85,80 @@ example().catch(console.error);
|
|
|
84
85
|
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
85
86
|
|
|
86
87
|
|
|
88
|
+
## createHousehold
|
|
89
|
+
|
|
90
|
+
> any createHousehold(contactsHouseholdCreateHouseholdPayload, name)
|
|
91
|
+
|
|
92
|
+
Create a household (EXPERIMENTAL)
|
|
93
|
+
|
|
94
|
+
### Example
|
|
95
|
+
|
|
96
|
+
```ts
|
|
97
|
+
import {
|
|
98
|
+
Configuration,
|
|
99
|
+
ContactsApi,
|
|
100
|
+
} from '@equisoft/equisoft-connect-sdk-typescript';
|
|
101
|
+
import type { CreateHouseholdRequest } from '@equisoft/equisoft-connect-sdk-typescript';
|
|
102
|
+
|
|
103
|
+
async function example() {
|
|
104
|
+
console.log("🚀 Testing @equisoft/equisoft-connect-sdk-typescript SDK...");
|
|
105
|
+
const config = new Configuration({
|
|
106
|
+
// To configure OAuth2 access token for authorization: OAuth2 accessCode
|
|
107
|
+
accessToken: "YOUR ACCESS TOKEN",
|
|
108
|
+
});
|
|
109
|
+
const api = new ContactsApi(config);
|
|
110
|
+
|
|
111
|
+
const body = {
|
|
112
|
+
// ContactsHouseholdCreateHouseholdPayload
|
|
113
|
+
contactsHouseholdCreateHouseholdPayload: ...,
|
|
114
|
+
// string | The name of the Household to create (optional)
|
|
115
|
+
name: name_example,
|
|
116
|
+
} satisfies CreateHouseholdRequest;
|
|
117
|
+
|
|
118
|
+
try {
|
|
119
|
+
const data = await api.createHousehold(body);
|
|
120
|
+
console.log(data);
|
|
121
|
+
} catch (error) {
|
|
122
|
+
console.error(error);
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
// Run the test
|
|
127
|
+
example().catch(console.error);
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
### Parameters
|
|
131
|
+
|
|
132
|
+
|
|
133
|
+
| Name | Type | Description | Notes |
|
|
134
|
+
|------------- | ------------- | ------------- | -------------|
|
|
135
|
+
| **contactsHouseholdCreateHouseholdPayload** | [ContactsHouseholdCreateHouseholdPayload](ContactsHouseholdCreateHouseholdPayload.md) | | |
|
|
136
|
+
| **name** | `string` | The name of the Household to create | [Optional] [Defaults to `undefined`] |
|
|
137
|
+
|
|
138
|
+
### Return type
|
|
139
|
+
|
|
140
|
+
**any**
|
|
141
|
+
|
|
142
|
+
### Authorization
|
|
143
|
+
|
|
144
|
+
[OAuth2 accessCode](../README.md#OAuth2-accessCode)
|
|
145
|
+
|
|
146
|
+
### HTTP request headers
|
|
147
|
+
|
|
148
|
+
- **Content-Type**: `application/json`
|
|
149
|
+
- **Accept**: `application/json`
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
### HTTP response details
|
|
153
|
+
| Status code | Description | Response headers |
|
|
154
|
+
|-------------|-------------|------------------|
|
|
155
|
+
| **201** | Created | * Location - The URI of the created resource <br> |
|
|
156
|
+
| **500** | Internal Server Error | - |
|
|
157
|
+
| **400** | Bad Request | - |
|
|
158
|
+
|
|
159
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
160
|
+
|
|
161
|
+
|
|
87
162
|
## getByUuid
|
|
88
163
|
|
|
89
164
|
> ContactsContact getByUuid(contactUuid, acceptLanguage)
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
|
|
2
|
+
# ContactsHouseholdCreateHouseholdPayload
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type
|
|
8
|
+
------------ | -------------
|
|
9
|
+
`name` | string
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```typescript
|
|
14
|
+
import type { ContactsHouseholdCreateHouseholdPayload } from '@equisoft/equisoft-connect-sdk-typescript'
|
|
15
|
+
|
|
16
|
+
// TODO: Update the object below with actual values
|
|
17
|
+
const example = {
|
|
18
|
+
"name": null,
|
|
19
|
+
} satisfies ContactsHouseholdCreateHouseholdPayload
|
|
20
|
+
|
|
21
|
+
console.log(example)
|
|
22
|
+
|
|
23
|
+
// Convert the instance to a JSON string
|
|
24
|
+
const exampleJSON: string = JSON.stringify(example)
|
|
25
|
+
console.log(exampleJSON)
|
|
26
|
+
|
|
27
|
+
// Parse the JSON string back to an object
|
|
28
|
+
const exampleParsed = JSON.parse(exampleJSON) as ContactsHouseholdCreateHouseholdPayload
|
|
29
|
+
console.log(exampleParsed)
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
33
|
+
|
|
34
|
+
|
package/package.json
CHANGED
package/src/apis/ContactsApi.ts
CHANGED
|
@@ -18,6 +18,7 @@ import type {
|
|
|
18
18
|
ContactPatchContactPayload,
|
|
19
19
|
ContactsContact,
|
|
20
20
|
ContactsCreateContactPayload,
|
|
21
|
+
ContactsHouseholdCreateHouseholdPayload,
|
|
21
22
|
ContactsListContactResponse,
|
|
22
23
|
DocumentsListDocumentResponse,
|
|
23
24
|
ErrorResponse,
|
|
@@ -30,6 +31,8 @@ import {
|
|
|
30
31
|
ContactsContactToJSON,
|
|
31
32
|
ContactsCreateContactPayloadFromJSON,
|
|
32
33
|
ContactsCreateContactPayloadToJSON,
|
|
34
|
+
ContactsHouseholdCreateHouseholdPayloadFromJSON,
|
|
35
|
+
ContactsHouseholdCreateHouseholdPayloadToJSON,
|
|
33
36
|
ContactsListContactResponseFromJSON,
|
|
34
37
|
ContactsListContactResponseToJSON,
|
|
35
38
|
DocumentsListDocumentResponseFromJSON,
|
|
@@ -44,6 +47,11 @@ export interface CreateContactRequest {
|
|
|
44
47
|
contactsCreateContactPayload: ContactsCreateContactPayload;
|
|
45
48
|
}
|
|
46
49
|
|
|
50
|
+
export interface CreateHouseholdRequest {
|
|
51
|
+
contactsHouseholdCreateHouseholdPayload: ContactsHouseholdCreateHouseholdPayload;
|
|
52
|
+
name?: string;
|
|
53
|
+
}
|
|
54
|
+
|
|
47
55
|
export interface GetByUuidRequest {
|
|
48
56
|
contactUuid: string;
|
|
49
57
|
acceptLanguage?: string;
|
|
@@ -154,6 +162,70 @@ export class ContactsApi extends runtime.BaseAPI {
|
|
|
154
162
|
return await response.value();
|
|
155
163
|
}
|
|
156
164
|
|
|
165
|
+
/**
|
|
166
|
+
* Creates request options for createHousehold without sending the request
|
|
167
|
+
*/
|
|
168
|
+
async createHouseholdRequestOpts(requestParameters: CreateHouseholdRequest): Promise<runtime.RequestOpts> {
|
|
169
|
+
if (requestParameters['contactsHouseholdCreateHouseholdPayload'] == null) {
|
|
170
|
+
throw new runtime.RequiredError(
|
|
171
|
+
'contactsHouseholdCreateHouseholdPayload',
|
|
172
|
+
'Required parameter "contactsHouseholdCreateHouseholdPayload" was null or undefined when calling createHousehold().'
|
|
173
|
+
);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
const queryParameters: any = {};
|
|
177
|
+
|
|
178
|
+
if (requestParameters['name'] != null) {
|
|
179
|
+
queryParameters['name'] = requestParameters['name'];
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
183
|
+
|
|
184
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
185
|
+
|
|
186
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
187
|
+
// oauth required
|
|
188
|
+
const token = this.configuration.accessToken;
|
|
189
|
+
const tokenString = await token("OAuth2", ["crm:contact"]);
|
|
190
|
+
if (tokenString) {
|
|
191
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
let urlPath = `/crm/api/v1/contacts/household`;
|
|
197
|
+
|
|
198
|
+
return {
|
|
199
|
+
path: urlPath,
|
|
200
|
+
method: 'POST',
|
|
201
|
+
headers: headerParameters,
|
|
202
|
+
query: queryParameters,
|
|
203
|
+
body: ContactsHouseholdCreateHouseholdPayloadToJSON(requestParameters['contactsHouseholdCreateHouseholdPayload']),
|
|
204
|
+
};
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
/**
|
|
208
|
+
* Create a household (EXPERIMENTAL)
|
|
209
|
+
*/
|
|
210
|
+
async createHouseholdRaw(requestParameters: CreateHouseholdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>> {
|
|
211
|
+
const requestOptions = await this.createHouseholdRequestOpts(requestParameters);
|
|
212
|
+
const response = await this.request(requestOptions, initOverrides);
|
|
213
|
+
|
|
214
|
+
if (this.isJsonMime(response.headers.get('content-type'))) {
|
|
215
|
+
return new runtime.JSONApiResponse<any>(response);
|
|
216
|
+
} else {
|
|
217
|
+
return new runtime.TextApiResponse(response) as any;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
/**
|
|
222
|
+
* Create a household (EXPERIMENTAL)
|
|
223
|
+
*/
|
|
224
|
+
async createHousehold(requestParameters: CreateHouseholdRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any> {
|
|
225
|
+
const response = await this.createHouseholdRaw(requestParameters, initOverrides);
|
|
226
|
+
return await response.value();
|
|
227
|
+
}
|
|
228
|
+
|
|
157
229
|
/**
|
|
158
230
|
* Creates request options for getByUuid without sending the request
|
|
159
231
|
*/
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Equisoft /connect API
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: latest
|
|
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 ContactsHouseholdCreateHouseholdPayload
|
|
20
|
+
*/
|
|
21
|
+
export interface ContactsHouseholdCreateHouseholdPayload {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof ContactsHouseholdCreateHouseholdPayload
|
|
26
|
+
*/
|
|
27
|
+
name: string;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the ContactsHouseholdCreateHouseholdPayload interface.
|
|
32
|
+
*/
|
|
33
|
+
export function instanceOfContactsHouseholdCreateHouseholdPayload(value: object): value is ContactsHouseholdCreateHouseholdPayload {
|
|
34
|
+
if (!('name' in value) || value['name'] === undefined) return false;
|
|
35
|
+
return true;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function ContactsHouseholdCreateHouseholdPayloadFromJSON(json: any): ContactsHouseholdCreateHouseholdPayload {
|
|
39
|
+
return ContactsHouseholdCreateHouseholdPayloadFromJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function ContactsHouseholdCreateHouseholdPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): ContactsHouseholdCreateHouseholdPayload {
|
|
43
|
+
if (json == null) {
|
|
44
|
+
return json;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
|
|
48
|
+
'name': json['name'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export function ContactsHouseholdCreateHouseholdPayloadToJSON(json: any): ContactsHouseholdCreateHouseholdPayload {
|
|
53
|
+
return ContactsHouseholdCreateHouseholdPayloadToJSONTyped(json, false);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export function ContactsHouseholdCreateHouseholdPayloadToJSONTyped(value?: ContactsHouseholdCreateHouseholdPayload | null, ignoreDiscriminator: boolean = false): any {
|
|
57
|
+
if (value == null) {
|
|
58
|
+
return value;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
return {
|
|
62
|
+
|
|
63
|
+
'name': value['name'],
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
|
package/src/models/index.ts
CHANGED
|
@@ -34,6 +34,7 @@ export * from './ContactsCreateRevenuePayload';
|
|
|
34
34
|
export * from './ContactsCreateSegmentationPayload';
|
|
35
35
|
export * from './ContactsCreateWebsitePayload';
|
|
36
36
|
export * from './ContactsEmail';
|
|
37
|
+
export * from './ContactsHouseholdCreateHouseholdPayload';
|
|
37
38
|
export * from './ContactsIdentification';
|
|
38
39
|
export * from './ContactsIndividualIdentification';
|
|
39
40
|
export * from './ContactsInvestmentObjective';
|