@wisemen/wise-crm 0.0.1
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/README.md +0 -0
- package/dist/clients/index.d.ts +2 -0
- package/dist/clients/index.js +3 -0
- package/dist/clients/index.js.map +1 -0
- package/dist/clients/wise-crm-api-client/business.client.d.ts +9 -0
- package/dist/clients/wise-crm-api-client/business.client.js +18 -0
- package/dist/clients/wise-crm-api-client/business.client.js.map +1 -0
- package/dist/clients/wise-crm-api-client/index.d.ts +2 -0
- package/dist/clients/wise-crm-api-client/index.js +3 -0
- package/dist/clients/wise-crm-api-client/index.js.map +1 -0
- package/dist/clients/wise-crm-api-client/wise-crm-api.client.d.ts +9 -0
- package/dist/clients/wise-crm-api-client/wise-crm-api.client.js +8 -0
- package/dist/clients/wise-crm-api-client/wise-crm-api.client.js.map +1 -0
- package/dist/clients/wise-crm-service-user-client/index.d.ts +1 -0
- package/dist/clients/wise-crm-service-user-client/index.js +2 -0
- package/dist/clients/wise-crm-service-user-client/index.js.map +1 -0
- package/dist/clients/wise-crm-service-user-client/wise-crm-service-user.client.d.ts +19 -0
- package/dist/clients/wise-crm-service-user-client/wise-crm-service-user.client.js +93 -0
- package/dist/clients/wise-crm-service-user-client/wise-crm-service-user.client.js.map +1 -0
- package/dist/constants/index.d.ts +1 -0
- package/dist/constants/index.js +2 -0
- package/dist/constants/index.js.map +1 -0
- package/dist/constants/nats-subjects/index.d.ts +1 -0
- package/dist/constants/nats-subjects/index.js +2 -0
- package/dist/constants/nats-subjects/index.js.map +1 -0
- package/dist/constants/nats-subjects/subjects.d.ts +2 -0
- package/dist/constants/nats-subjects/subjects.js +3 -0
- package/dist/constants/nats-subjects/subjects.js.map +1 -0
- package/dist/functions/index.d.ts +1 -0
- package/dist/functions/index.js +2 -0
- package/dist/functions/index.js.map +1 -0
- package/dist/functions/map-address-string-to-command.function.d.ts +2 -0
- package/dist/functions/map-address-string-to-command.function.js +18 -0
- package/dist/functions/map-address-string-to-command.function.js.map +1 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -0
- package/dist/types/address/address-command.builder.d.ts +16 -0
- package/dist/types/address/address-command.builder.js +57 -0
- package/dist/types/address/address-command.builder.js.map +1 -0
- package/dist/types/address/address-command.d.ts +14 -0
- package/dist/types/address/address-command.js +26 -0
- package/dist/types/address/address-command.js.map +1 -0
- package/dist/types/address/address.builder.d.ts +16 -0
- package/dist/types/address/address.builder.js +57 -0
- package/dist/types/address/address.builder.js.map +1 -0
- package/dist/types/address/address.d.ts +12 -0
- package/dist/types/address/address.js +12 -0
- package/dist/types/address/address.js.map +1 -0
- package/dist/types/address/address.response.d.ts +12 -0
- package/dist/types/address/address.response.js +12 -0
- package/dist/types/address/address.response.js.map +1 -0
- package/dist/types/address/index.d.ts +1 -0
- package/dist/types/address/index.js +2 -0
- package/dist/types/address/index.js.map +1 -0
- package/dist/types/business/business-billing-information.response.d.ts +11 -0
- package/dist/types/business/business-billing-information.response.js +11 -0
- package/dist/types/business/business-billing-information.response.js.map +1 -0
- package/dist/types/business/business-contact-person.response.d.ts +11 -0
- package/dist/types/business/business-contact-person.response.js +11 -0
- package/dist/types/business/business-contact-person.response.js.map +1 -0
- package/dist/types/business/business-detail.response.d.ts +22 -0
- package/dist/types/business/business-detail.response.js +18 -0
- package/dist/types/business/business-detail.response.js.map +1 -0
- package/dist/types/business/business-index.query.d.ts +6 -0
- package/dist/types/business/business-index.query.js +7 -0
- package/dist/types/business/business-index.query.js.map +1 -0
- package/dist/types/business/business-index.response.d.ts +14 -0
- package/dist/types/business/business-index.response.js +13 -0
- package/dist/types/business/business-index.response.js.map +1 -0
- package/dist/types/business/business.uuid.d.ts +2 -0
- package/dist/types/business/business.uuid.js +2 -0
- package/dist/types/business/business.uuid.js.map +1 -0
- package/dist/types/business/child-parent-business.response.d.ts +14 -0
- package/dist/types/business/child-parent-business.response.js +13 -0
- package/dist/types/business/child-parent-business.response.js.map +1 -0
- package/dist/types/business/index.d.ts +7 -0
- package/dist/types/business/index.js +8 -0
- package/dist/types/business/index.js.map +1 -0
- package/dist/types/index.d.ts +5 -0
- package/dist/types/index.js +6 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/individual/index.d.ts +5 -0
- package/dist/types/individual/index.js +6 -0
- package/dist/types/individual/index.js.map +1 -0
- package/dist/types/individual/individual-billing-information.response.d.ts +7 -0
- package/dist/types/individual/individual-billing-information.response.js +7 -0
- package/dist/types/individual/individual-billing-information.response.js.map +1 -0
- package/dist/types/individual/individual-contact-person.response.d.ts +11 -0
- package/dist/types/individual/individual-contact-person.response.js +11 -0
- package/dist/types/individual/individual-contact-person.response.js.map +1 -0
- package/dist/types/individual/individual-detail.response.d.ts +22 -0
- package/dist/types/individual/individual-detail.response.js +18 -0
- package/dist/types/individual/individual-detail.response.js.map +1 -0
- package/dist/types/individual/individual-linked-business.response.d.ts +9 -0
- package/dist/types/individual/individual-linked-business.response.js +9 -0
- package/dist/types/individual/individual-linked-business.response.js.map +1 -0
- package/dist/types/individual/individual.uuid.d.ts +2 -0
- package/dist/types/individual/individual.uuid.js +2 -0
- package/dist/types/individual/individual.uuid.js.map +1 -0
- package/dist/types/integration-events/business-billing-information-upserted-content.type.d.ts +10 -0
- package/dist/types/integration-events/business-billing-information-upserted-content.type.js +2 -0
- package/dist/types/integration-events/business-billing-information-upserted-content.type.js.map +1 -0
- package/dist/types/integration-events/business-created-content.type.d.ts +9 -0
- package/dist/types/integration-events/business-created-content.type.js +2 -0
- package/dist/types/integration-events/business-created-content.type.js.map +1 -0
- package/dist/types/integration-events/business-updated-content.type.d.ts +9 -0
- package/dist/types/integration-events/business-updated-content.type.js +2 -0
- package/dist/types/integration-events/business-updated-content.type.js.map +1 -0
- package/dist/types/integration-events/index.d.ts +7 -0
- package/dist/types/integration-events/index.js +8 -0
- package/dist/types/integration-events/index.js.map +1 -0
- package/dist/types/integration-events/individual-billing-information-upserted-content.type.d.ts +6 -0
- package/dist/types/integration-events/individual-billing-information-upserted-content.type.js +2 -0
- package/dist/types/integration-events/individual-billing-information-upserted-content.type.js.map +1 -0
- package/dist/types/integration-events/individual-created-content.type.d.ts +10 -0
- package/dist/types/integration-events/individual-created-content.type.js +2 -0
- package/dist/types/integration-events/individual-created-content.type.js.map +1 -0
- package/dist/types/integration-events/individual-updated-content.type.d.ts +10 -0
- package/dist/types/integration-events/individual-updated-content.type.js +2 -0
- package/dist/types/integration-events/individual-updated-content.type.js.map +1 -0
- package/dist/types/integration-events/integration-event.type.d.ts +9 -0
- package/dist/types/integration-events/integration-event.type.js +11 -0
- package/dist/types/integration-events/integration-event.type.js.map +1 -0
- package/dist/types/location/index.d.ts +2 -0
- package/dist/types/location/index.js +3 -0
- package/dist/types/location/index.js.map +1 -0
- package/dist/types/location/location-detail.response.d.ts +8 -0
- package/dist/types/location/location-detail.response.js +7 -0
- package/dist/types/location/location-detail.response.js.map +1 -0
- package/dist/types/location/location.uuid.d.ts +2 -0
- package/dist/types/location/location.uuid.js +2 -0
- package/dist/types/location/location.uuid.js.map +1 -0
- package/dist/types/uuid.d.ts +6 -0
- package/dist/types/uuid.js +4 -0
- package/dist/types/uuid.js.map +1 -0
- package/package.json +38 -0
package/README.md
ADDED
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../lib/clients/index.ts"],"names":[],"mappings":"AAAA,cAAc,gCAAgC,CAAA;AAC9C,cAAc,yCAAyC,CAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { BusinessDetailResponse, ViewBusinessIndexQuery, BusinessIndexResponse } from "../../types/index.js";
|
|
2
|
+
import { WiseCrmApiClientOptions } from "./wise-crm-api.client.js";
|
|
3
|
+
export declare class BusinessClient {
|
|
4
|
+
private baseUrl;
|
|
5
|
+
private getAccessToken;
|
|
6
|
+
constructor(options: WiseCrmApiClientOptions);
|
|
7
|
+
detail(businessUuid: string): Promise<BusinessDetailResponse>;
|
|
8
|
+
index(queryParams: ViewBusinessIndexQuery): Promise<BusinessIndexResponse>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import axios from "axios";
|
|
2
|
+
export class BusinessClient {
|
|
3
|
+
baseUrl;
|
|
4
|
+
getAccessToken;
|
|
5
|
+
constructor(options) {
|
|
6
|
+
this.baseUrl = `${options.host}/api/v1`;
|
|
7
|
+
this.getAccessToken = options.getAccessToken;
|
|
8
|
+
}
|
|
9
|
+
async detail(businessUuid) {
|
|
10
|
+
return axios
|
|
11
|
+
.get(`${this.baseUrl}/businesses/${businessUuid}`, { headers: { Authorization: `Bearer ${this.getAccessToken}` } }).then((res) => res.data);
|
|
12
|
+
}
|
|
13
|
+
async index(queryParams) {
|
|
14
|
+
return axios
|
|
15
|
+
.get(`${this.baseUrl}/businesses`, { headers: { Authorization: `Bearer ${this.getAccessToken}` }, params: queryParams }).then((res) => res.data);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=business.client.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"business.client.js","sourceRoot":"","sources":["../../../lib/clients/wise-crm-api-client/business.client.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,MAAM,OAAO,cAAc;IACjB,OAAO,CAAQ;IACf,cAAc,CAAuB;IAE7C,YAAY,OAAgC;QAC1C,IAAI,CAAC,OAAO,GAAG,GAAG,OAAO,CAAC,IAAI,SAAS,CAAA;QACvC,IAAI,CAAC,cAAc,GAAG,OAAO,CAAC,cAAc,CAAA;IAC9C,CAAC;IAEM,KAAK,CAAC,MAAM,CACjB,YAAoB;QAEpB,OAAO,KAAK;aACT,GAAG,CACF,GAAG,IAAI,CAAC,OAAO,eAAe,YAAY,EAAE,EAC5C,EAAE,OAAO,EAAE,EAAE,aAAa,EAAE,UAAU,IAAI,CAAC,cAAc,EAAE,EAAE,EAAE,CAChE,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IAC9B,CAAC;IAEM,KAAK,CAAC,KAAK,CAChB,WAAmC;QAEnC,OAAO,KAAK;aACT,GAAG,CACF,GAAG,IAAI,CAAC,OAAO,aAAa,EAC5B,EAAE,OAAO,EAAE,EAAE,aAAa,EAAE,UAAU,IAAI,CAAC,cAAc,EAAE,EAAE,EAAE,MAAM,EAAE,WAAW,EAAE,CACrF,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IAC9B,CAAC;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/clients/wise-crm-api-client/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAA;AACpC,cAAc,0BAA0B,CAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { BusinessClient } from "./business.client.js";
|
|
2
|
+
export interface WiseCrmApiClientOptions {
|
|
3
|
+
host: string;
|
|
4
|
+
getAccessToken: () => Promise<string>;
|
|
5
|
+
}
|
|
6
|
+
export declare class WiseCrmApiClient {
|
|
7
|
+
business: BusinessClient;
|
|
8
|
+
constructor(options: WiseCrmApiClientOptions);
|
|
9
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wise-crm-api.client.js","sourceRoot":"","sources":["../../../lib/clients/wise-crm-api-client/wise-crm-api.client.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAQtD,MAAM,OAAO,gBAAgB;IACpB,QAAQ,CAAiB;IAEhC,YAAY,OAAgC;QAC1C,IAAI,CAAC,QAAQ,GAAG,IAAI,cAAc,CAAC,OAAO,CAAC,CAAC;IAC9C,CAAC;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './wise-crm-service-user.client.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/clients/wise-crm-service-user-client/index.ts"],"names":[],"mappings":"AAAA,cAAc,mCAAmC,CAAA"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { BusinessDetailResponse } from "../../types/index.js";
|
|
2
|
+
import { ViewIndividualDetailResponse } from "../../types/individual/individual-detail.response.js";
|
|
3
|
+
export interface WiseCrmServiceUserClientOptions {
|
|
4
|
+
host: string;
|
|
5
|
+
issuer: string;
|
|
6
|
+
serviceUserKey: string;
|
|
7
|
+
projectId: string;
|
|
8
|
+
}
|
|
9
|
+
export declare class WiseCrmServiceUserClient {
|
|
10
|
+
private readonly issuer;
|
|
11
|
+
private readonly baseUrl;
|
|
12
|
+
private readonly serviceUserKey;
|
|
13
|
+
private readonly projectId;
|
|
14
|
+
constructor(options: WiseCrmServiceUserClientOptions);
|
|
15
|
+
getBusinessOrFail(businessUuid: string): Promise<BusinessDetailResponse>;
|
|
16
|
+
getIndividualOrFail(individualUuid: string): Promise<ViewIndividualDetailResponse>;
|
|
17
|
+
private getToken;
|
|
18
|
+
private getJwt;
|
|
19
|
+
}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import axios from "axios";
|
|
11
|
+
import dayjs from "dayjs";
|
|
12
|
+
import jwt from "jsonwebtoken";
|
|
13
|
+
import { Injectable } from "@nestjs/common";
|
|
14
|
+
let WiseCrmServiceUserClient = class WiseCrmServiceUserClient {
|
|
15
|
+
issuer;
|
|
16
|
+
baseUrl;
|
|
17
|
+
serviceUserKey;
|
|
18
|
+
projectId;
|
|
19
|
+
constructor(options) {
|
|
20
|
+
this.issuer = options.issuer;
|
|
21
|
+
this.baseUrl = `${options.host}/api/v1`;
|
|
22
|
+
this.serviceUserKey = options.serviceUserKey;
|
|
23
|
+
this.projectId = options.projectId;
|
|
24
|
+
}
|
|
25
|
+
async getBusinessOrFail(businessUuid) {
|
|
26
|
+
const token = await this.getToken();
|
|
27
|
+
try {
|
|
28
|
+
return await axios.get(`${this.baseUrl}/businesses/${businessUuid}`, { headers: {
|
|
29
|
+
'Authorization': `Bearer ${token}`,
|
|
30
|
+
'User-Type': 'serviceaccount'
|
|
31
|
+
} }).then(res => res.data);
|
|
32
|
+
}
|
|
33
|
+
catch (error) {
|
|
34
|
+
throw new Error('Failed to fetch business from CRM');
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
async getIndividualOrFail(individualUuid) {
|
|
38
|
+
const token = await this.getToken();
|
|
39
|
+
try {
|
|
40
|
+
return await axios.get(`${this.baseUrl}/individuals/${individualUuid}`, { headers: {
|
|
41
|
+
'Authorization': `Bearer ${token}`,
|
|
42
|
+
'User-Type': 'serviceaccount'
|
|
43
|
+
} }).then(res => res.data);
|
|
44
|
+
}
|
|
45
|
+
catch (error) {
|
|
46
|
+
throw new Error('Failed to fetch individual from CRM');
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
async getToken() {
|
|
50
|
+
const authCrmTokenUrl = `${this.issuer}/oauth/v2/token`;
|
|
51
|
+
const authCrmProjectId = this.projectId;
|
|
52
|
+
const scopes = [
|
|
53
|
+
`urn:zitadel:iam:org:project:id:${authCrmProjectId}:aud`,
|
|
54
|
+
'urn:zitadel:iam:user:resourceowner'
|
|
55
|
+
];
|
|
56
|
+
const jwt = this.getJwt();
|
|
57
|
+
try {
|
|
58
|
+
const response = await axios.post(authCrmTokenUrl, new URLSearchParams({
|
|
59
|
+
grant_type: 'urn:ietf:params:oauth:grant-type:jwt-bearer',
|
|
60
|
+
assertion: jwt,
|
|
61
|
+
scope: scopes.join(' ')
|
|
62
|
+
}), {
|
|
63
|
+
headers: {
|
|
64
|
+
'Content-Type': 'application/x-www-form-urlencoded'
|
|
65
|
+
}
|
|
66
|
+
});
|
|
67
|
+
return response.data.access_token;
|
|
68
|
+
}
|
|
69
|
+
catch (error) {
|
|
70
|
+
throw new Error('Token exchange failed');
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
getJwt() {
|
|
74
|
+
const encodedServiceUserKey = this.serviceUserKey;
|
|
75
|
+
const serviceUserKey = JSON.parse(Buffer.from(encodedServiceUserKey, 'base64').toString('utf-8'));
|
|
76
|
+
return jwt.sign({
|
|
77
|
+
iss: serviceUserKey.userId,
|
|
78
|
+
sub: serviceUserKey.userId,
|
|
79
|
+
aud: this.issuer,
|
|
80
|
+
exp: dayjs().add(1, 'hour').unix(),
|
|
81
|
+
iat: dayjs().unix()
|
|
82
|
+
}, serviceUserKey.key, {
|
|
83
|
+
algorithm: 'RS256',
|
|
84
|
+
keyid: serviceUserKey.keyId
|
|
85
|
+
});
|
|
86
|
+
}
|
|
87
|
+
};
|
|
88
|
+
WiseCrmServiceUserClient = __decorate([
|
|
89
|
+
Injectable(),
|
|
90
|
+
__metadata("design:paramtypes", [Object])
|
|
91
|
+
], WiseCrmServiceUserClient);
|
|
92
|
+
export { WiseCrmServiceUserClient };
|
|
93
|
+
//# sourceMappingURL=wise-crm-service-user.client.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wise-crm-service-user.client.js","sourceRoot":"","sources":["../../../lib/clients/wise-crm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,EAAE,QAAQ,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAmB,CAAA;QAE9F,OAAO,GAAG,CAAC,IAAI,CACb;YACE,GAAG,EAAE,cAAc,CAAC,MAAM;YAC1B,GAAG,EAAE,cAAc,CAAC,MAAM;YAC1B,GAAG,EAAE,IAAI,CAAC,MAAM;YAChB,GAAG,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,IAAI,EAAE;YAClC,GAAG,EAAE,KAAK,EAAE,CAAC,IAAI,EAAE;SACpB,EACD,cAAc,CAAC,GAAG,EAClB;YACE,SAAS,EAAE,OAAO;YAClB,KAAK,EAAE,cAAc,CAAC,KAAK;SAC5B,CACF,CAAA;IACH,CAAC;CACF,CAAA;AAjGY,wBAAwB;IADpC,UAAU,EAAE;;GACA,wBAAwB,CAiGpC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './nats-subjects/index.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../lib/constants/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './subjects.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/constants/nats-subjects/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"subjects.js","sourceRoot":"","sources":["../../../lib/constants/nats-subjects/subjects.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,wBAAwB,GAAI,+CAA+C,CAAA;AACxF,MAAM,CAAC,MAAM,0BAA0B,GAAG,iDAAiD,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './map-address-string-to-command.function.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../lib/functions/index.ts"],"names":[],"mappings":"AAAA,cAAc,6CAA6C,CAAA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { CoordinatesCommandBuilder } from "@wisemen/coordinates";
|
|
2
|
+
import { AddressCommandBuilder } from "../types/address/address-command.builder.js";
|
|
3
|
+
export function mapAddressStringToCommand(addressString) {
|
|
4
|
+
const address = JSON.parse(addressString);
|
|
5
|
+
return new AddressCommandBuilder()
|
|
6
|
+
.withStreetName(address.streetName ?? null)
|
|
7
|
+
.withStreetNumber(address.streetNumber ?? null)
|
|
8
|
+
.withUnit(address.unit ?? null)
|
|
9
|
+
.withCity(address.city ?? null)
|
|
10
|
+
.withPostalCode(address.postalCode ?? null)
|
|
11
|
+
.withCountry(address.country ?? null)
|
|
12
|
+
.withCoordinates(new CoordinatesCommandBuilder()
|
|
13
|
+
.withLatitude(address.coordinates?.latitude ?? 0)
|
|
14
|
+
.withLongitude(address.coordinates?.longitude ?? 0)
|
|
15
|
+
.build())
|
|
16
|
+
.build();
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=map-address-string-to-command.function.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"map-address-string-to-command.function.js","sourceRoot":"","sources":["../../lib/functions/map-address-string-to-command.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,sBAAsB,CAAA;AAGhE,OAAO,EAAE,qBAAqB,EAAE,MAAM,6CAA6C,CAAA;AAEnF,MAAM,UAAU,yBAAyB,CAAE,aAAqB;IAC5D,MAAM,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,aAAa,CAAY,CAAA;IACpD,OAAO,IAAI,qBAAqB,EAAE;SAC/B,cAAc,CAAC,OAAO,CAAC,UAAU,IAAI,IAAI,CAAC;SAC1C,gBAAgB,CAAC,OAAO,CAAC,YAAY,IAAI,IAAI,CAAC;SAC9C,QAAQ,CAAC,OAAO,CAAC,IAAI,IAAI,IAAI,CAAC;SAC9B,QAAQ,CAAC,OAAO,CAAC,IAAI,IAAI,IAAI,CAAC;SAC9B,cAAc,CAAC,OAAO,CAAC,UAAU,IAAI,IAAI,CAAC;SAC1C,WAAW,CAAC,OAAO,CAAC,OAAO,IAAI,IAAI,CAAC;SACpC,eAAe,CAAC,IAAI,yBAAyB,EAAE;SAC7C,YAAY,CAAC,OAAO,CAAC,WAAW,EAAE,QAAQ,IAAI,CAAC,CAAC;SAChD,aAAa,CAAC,OAAO,CAAC,WAAW,EAAE,SAAS,IAAI,CAAC,CAAC;SAClD,KAAK,EAAE,CAAC;SACV,KAAK,EAAE,CAAA;AACZ,CAAC"}
|
package/dist/index.d.ts
ADDED
package/dist/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../lib/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAA;AAChC,cAAc,oBAAoB,CAAA;AAClC,cAAc,sBAAsB,CAAA;AACpC,cAAc,sBAAsB,CAAA"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { CoordinatesCommand } from '@wisemen/coordinates';
|
|
2
|
+
import { AddressCommand } from './address-command.js';
|
|
3
|
+
export declare class AddressCommandBuilder {
|
|
4
|
+
private command;
|
|
5
|
+
constructor();
|
|
6
|
+
withPlaceName(placeName: string | null): this;
|
|
7
|
+
withPlaceId(placeId: string | null): this;
|
|
8
|
+
withCountry(country: string | null): this;
|
|
9
|
+
withCity(city: string | null): this;
|
|
10
|
+
withPostalCode(postalCode: string | null): this;
|
|
11
|
+
withStreetName(streetName: string | null): this;
|
|
12
|
+
withStreetNumber(streetNumber: string | null): this;
|
|
13
|
+
withUnit(unit: string | null): this;
|
|
14
|
+
withCoordinates(coordinates: CoordinatesCommand): this;
|
|
15
|
+
build(): AddressCommand;
|
|
16
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { CoordinatesCommandBuilder } from '@wisemen/coordinates';
|
|
2
|
+
import { AddressCommand } from './address-command.js';
|
|
3
|
+
export class AddressCommandBuilder {
|
|
4
|
+
command;
|
|
5
|
+
constructor() {
|
|
6
|
+
this.command = new AddressCommand();
|
|
7
|
+
this.command.placeName = null;
|
|
8
|
+
this.command.placeId = null;
|
|
9
|
+
this.command.country = null;
|
|
10
|
+
this.command.city = null;
|
|
11
|
+
this.command.postalCode = null;
|
|
12
|
+
this.command.streetName = null;
|
|
13
|
+
this.command.streetNumber = null;
|
|
14
|
+
this.command.unit = null;
|
|
15
|
+
this.command.coordinates = new CoordinatesCommandBuilder().build();
|
|
16
|
+
}
|
|
17
|
+
withPlaceName(placeName) {
|
|
18
|
+
this.command.placeName = placeName;
|
|
19
|
+
return this;
|
|
20
|
+
}
|
|
21
|
+
withPlaceId(placeId) {
|
|
22
|
+
this.command.placeId = placeId;
|
|
23
|
+
return this;
|
|
24
|
+
}
|
|
25
|
+
withCountry(country) {
|
|
26
|
+
this.command.country = country;
|
|
27
|
+
return this;
|
|
28
|
+
}
|
|
29
|
+
withCity(city) {
|
|
30
|
+
this.command.city = city;
|
|
31
|
+
return this;
|
|
32
|
+
}
|
|
33
|
+
withPostalCode(postalCode) {
|
|
34
|
+
this.command.postalCode = postalCode;
|
|
35
|
+
return this;
|
|
36
|
+
}
|
|
37
|
+
withStreetName(streetName) {
|
|
38
|
+
this.command.streetName = streetName;
|
|
39
|
+
return this;
|
|
40
|
+
}
|
|
41
|
+
withStreetNumber(streetNumber) {
|
|
42
|
+
this.command.streetNumber = streetNumber;
|
|
43
|
+
return this;
|
|
44
|
+
}
|
|
45
|
+
withUnit(unit) {
|
|
46
|
+
this.command.unit = unit;
|
|
47
|
+
return this;
|
|
48
|
+
}
|
|
49
|
+
withCoordinates(coordinates) {
|
|
50
|
+
this.command.coordinates = coordinates;
|
|
51
|
+
return this;
|
|
52
|
+
}
|
|
53
|
+
build() {
|
|
54
|
+
return this.command;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=address-command.builder.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"address-command.builder.js","sourceRoot":"","sources":["../../../lib/types/address/address-command.builder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsB,yBAAyB,EAAE,MAAM,sBAAsB,CAAA;AACpF,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAErD,MAAM,OAAO,qBAAqB;IACxB,OAAO,CAAgB;IAE/B;QACE,IAAI,CAAC,OAAO,GAAG,IAAI,cAAc,EAAE,CAAA;QACnC,IAAI,CAAC,OAAO,CAAC,SAAS,GAAG,IAAI,CAAA;QAC7B,IAAI,CAAC,OAAO,CAAC,OAAO,GAAG,IAAI,CAAA;QAC3B,IAAI,CAAC,OAAO,CAAC,OAAO,GAAG,IAAI,CAAA;QAC3B,IAAI,CAAC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAA;QACxB,IAAI,CAAC,OAAO,CAAC,UAAU,GAAG,IAAI,CAAA;QAC9B,IAAI,CAAC,OAAO,CAAC,UAAU,GAAG,IAAI,CAAA;QAC9B,IAAI,CAAC,OAAO,CAAC,YAAY,GAAG,IAAI,CAAA;QAChC,IAAI,CAAC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAA;QACxB,IAAI,CAAC,OAAO,CAAC,WAAW,GAAG,IAAI,yBAAyB,EAAE,CAAC,KAAK,EAAE,CAAA;IACpE,CAAC;IAED,aAAa,CAAE,SAAwB;QACrC,IAAI,CAAC,OAAO,CAAC,SAAS,GAAG,SAAS,CAAA;QAClC,OAAO,IAAI,CAAA;IACb,CAAC;IAED,WAAW,CAAE,OAAsB;QACjC,IAAI,CAAC,OAAO,CAAC,OAAO,GAAG,OAAO,CAAA;QAC9B,OAAO,IAAI,CAAA;IACb,CAAC;IAED,WAAW,CAAE,OAAsB;QACjC,IAAI,CAAC,OAAO,CAAC,OAAO,GAAG,OAAO,CAAA;QAC9B,OAAO,IAAI,CAAA;IACb,CAAC;IAED,QAAQ,CAAE,IAAmB;QAC3B,IAAI,CAAC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAA;QACxB,OAAO,IAAI,CAAA;IACb,CAAC;IAED,cAAc,CAAE,UAAyB;QACvC,IAAI,CAAC,OAAO,CAAC,UAAU,GAAG,UAAU,CAAA;QACpC,OAAO,IAAI,CAAA;IACb,CAAC;IAED,cAAc,CAAE,UAAyB;QACvC,IAAI,CAAC,OAAO,CAAC,UAAU,GAAG,UAAU,CAAA;QACpC,OAAO,IAAI,CAAA;IACb,CAAC;IAED,gBAAgB,CAAE,YAA2B;QAC3C,IAAI,CAAC,OAAO,CAAC,YAAY,GAAG,YAAY,CAAA;QACxC,OAAO,IAAI,CAAA;IACb,CAAC;IAED,QAAQ,CAAE,IAAmB;QAC3B,IAAI,CAAC,OAAO,CAAC,IAAI,GAAG,IAAI,CAAA;QACxB,OAAO,IAAI,CAAA;IACb,CAAC;IAED,eAAe,CAAE,WAA+B;QAC9C,IAAI,CAAC,OAAO,CAAC,WAAW,GAAG,WAAW,CAAA;QACtC,OAAO,IAAI,CAAA;IACb,CAAC;IAED,KAAK;QACH,OAAO,IAAI,CAAC,OAAO,CAAA;IACrB,CAAC;CACF"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CoordinatesCommand } from '@wisemen/coordinates';
|
|
2
|
+
import { Address } from './address.js';
|
|
3
|
+
export declare class AddressCommand {
|
|
4
|
+
placeName: string | null;
|
|
5
|
+
placeId: string | null;
|
|
6
|
+
country: string | null;
|
|
7
|
+
city: string | null;
|
|
8
|
+
postalCode: string | null;
|
|
9
|
+
streetName: string | null;
|
|
10
|
+
streetNumber: string | null;
|
|
11
|
+
unit: string | null;
|
|
12
|
+
coordinates: CoordinatesCommand | null;
|
|
13
|
+
parse(): Address;
|
|
14
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { AddressBuilder } from './address.builder.js';
|
|
2
|
+
export class AddressCommand {
|
|
3
|
+
placeName;
|
|
4
|
+
placeId;
|
|
5
|
+
country;
|
|
6
|
+
city;
|
|
7
|
+
postalCode;
|
|
8
|
+
streetName;
|
|
9
|
+
streetNumber;
|
|
10
|
+
unit;
|
|
11
|
+
coordinates;
|
|
12
|
+
parse() {
|
|
13
|
+
return new AddressBuilder()
|
|
14
|
+
.withPlaceName(this.placeName)
|
|
15
|
+
.withPlaceId(this.placeId)
|
|
16
|
+
.withCountry(this.country)
|
|
17
|
+
.withCity(this.city)
|
|
18
|
+
.withPostalCode(this.postalCode)
|
|
19
|
+
.withStreetName(this.streetName)
|
|
20
|
+
.withStreetNumber(this.streetNumber)
|
|
21
|
+
.withUnit(this.unit)
|
|
22
|
+
.withCoordinates(this.coordinates ? this.coordinates.toCoordinates() : null)
|
|
23
|
+
.build();
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=address-command.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"address-command.js","sourceRoot":"","sources":["../../../lib/types/address/address-command.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAGrD,MAAM,OAAO,cAAc;IACzB,SAAS,CAAe;IACxB,OAAO,CAAe;IACtB,OAAO,CAAe;IACtB,IAAI,CAAe;IACnB,UAAU,CAAe;IACzB,UAAU,CAAe;IACzB,YAAY,CAAe;IAC3B,IAAI,CAAe;IACnB,WAAW,CAA2B;IAEtC,KAAK;QACH,OAAO,IAAI,cAAc,EAAE;aACxB,aAAa,CAAC,IAAI,CAAC,SAAS,CAAC;aAC7B,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC;aACzB,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC;aACzB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC;aACnB,cAAc,CAAC,IAAI,CAAC,UAAU,CAAC;aAC/B,cAAc,CAAC,IAAI,CAAC,UAAU,CAAC;aAC/B,gBAAgB,CAAC,IAAI,CAAC,YAAY,CAAC;aACnC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC;aACnB,eAAe,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,aAAa,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC;aAC3E,KAAK,EAAE,CAAA;IACZ,CAAC;CACF"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Coordinates } from '@wisemen/coordinates';
|
|
2
|
+
import { Address } from './address.js';
|
|
3
|
+
export declare class AddressBuilder {
|
|
4
|
+
private readonly address;
|
|
5
|
+
constructor();
|
|
6
|
+
withPlaceName(placeName?: string | null): this;
|
|
7
|
+
withPlaceId(placeId?: string | null): this;
|
|
8
|
+
withCountry(country?: string | null): this;
|
|
9
|
+
withCity(city?: string | null): this;
|
|
10
|
+
withPostalCode(postalCode?: string | null): this;
|
|
11
|
+
withStreetName(streetName?: string | null): this;
|
|
12
|
+
withStreetNumber(streetNumber?: string | null): this;
|
|
13
|
+
withUnit(unit?: string | null): this;
|
|
14
|
+
withCoordinates(coordinates?: Coordinates | null): this;
|
|
15
|
+
build(): Address;
|
|
16
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { Coordinates } from '@wisemen/coordinates';
|
|
2
|
+
import { Address } from './address.js';
|
|
3
|
+
export class AddressBuilder {
|
|
4
|
+
address;
|
|
5
|
+
constructor() {
|
|
6
|
+
this.address = new Address();
|
|
7
|
+
this.address.placeName = null;
|
|
8
|
+
this.address.placeId = null;
|
|
9
|
+
this.address.coordinates = new Coordinates(0, 0);
|
|
10
|
+
this.address.country = null;
|
|
11
|
+
this.address.city = null;
|
|
12
|
+
this.address.postalCode = null;
|
|
13
|
+
this.address.streetName = null;
|
|
14
|
+
this.address.streetNumber = null;
|
|
15
|
+
this.address.unit = null;
|
|
16
|
+
}
|
|
17
|
+
withPlaceName(placeName) {
|
|
18
|
+
this.address.placeName = placeName ?? undefined;
|
|
19
|
+
return this;
|
|
20
|
+
}
|
|
21
|
+
withPlaceId(placeId) {
|
|
22
|
+
this.address.placeId = placeId ?? undefined;
|
|
23
|
+
return this;
|
|
24
|
+
}
|
|
25
|
+
withCountry(country) {
|
|
26
|
+
this.address.country = country ?? undefined;
|
|
27
|
+
return this;
|
|
28
|
+
}
|
|
29
|
+
withCity(city) {
|
|
30
|
+
this.address.city = city ?? undefined;
|
|
31
|
+
return this;
|
|
32
|
+
}
|
|
33
|
+
withPostalCode(postalCode) {
|
|
34
|
+
this.address.postalCode = postalCode ?? undefined;
|
|
35
|
+
return this;
|
|
36
|
+
}
|
|
37
|
+
withStreetName(streetName) {
|
|
38
|
+
this.address.streetName = streetName ?? undefined;
|
|
39
|
+
return this;
|
|
40
|
+
}
|
|
41
|
+
withStreetNumber(streetNumber) {
|
|
42
|
+
this.address.streetNumber = streetNumber ?? undefined;
|
|
43
|
+
return this;
|
|
44
|
+
}
|
|
45
|
+
withUnit(unit) {
|
|
46
|
+
this.address.unit = unit ?? undefined;
|
|
47
|
+
return this;
|
|
48
|
+
}
|
|
49
|
+
withCoordinates(coordinates) {
|
|
50
|
+
this.address.coordinates = coordinates ?? undefined;
|
|
51
|
+
return this;
|
|
52
|
+
}
|
|
53
|
+
build() {
|
|
54
|
+
return this.address;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=address.builder.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"address.builder.js","sourceRoot":"","sources":["../../../lib/types/address/address.builder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAA;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAEtC,MAAM,OAAO,cAAc;IACR,OAAO,CAAS;IAEjC;QACE,IAAI,CAAC,OAAO,GAAG,IAAI,OAAO,EAAE,CAAA;QAC5B,IAAI,CAAC,OAAO,CAAC,SAAS,GAAG,IAAI,CAAA;QAC7B,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CAAC;IAED,gBAAgB,CAAE,YAA4B;QAC5C,IAAI,CAAC,OAAO,CAAC,YAAY,GAAG,YAAY,IAAI,SAAS,CAAA;QACrD,OAAO,IAAI,CAAA;IACb,CAAC;IAED,QAAQ,CAAE,IAAoB;QAC5B,IAAI,CAAC,OAAO,CAAC,IAAI,GAAG,IAAI,IAAI,SAAS,CAAA;QACrC,OAAO,IAAI,CAAA;IACb,CAAC;IAED,eAAe,CAAE,WAAgC;QAC/C,IAAI,CAAC,OAAO,CAAC,WAAW,GAAG,WAAW,IAAI,SAAS,CAAA;QACnD,OAAO,IAAI,CAAA;IACb,CAAC;IAED,KAAK;QACH,OAAO,IAAI,CAAC,OAAO,CAAA;IACrB,CAAC;CACF"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Coordinates } from '@wisemen/coordinates';
|
|
2
|
+
export declare class Address {
|
|
3
|
+
placeName?: string | null;
|
|
4
|
+
placeId?: string | null;
|
|
5
|
+
country?: string | null;
|
|
6
|
+
city?: string | null;
|
|
7
|
+
postalCode?: string | null;
|
|
8
|
+
streetName?: string | null;
|
|
9
|
+
streetNumber?: string | null;
|
|
10
|
+
unit?: string | null;
|
|
11
|
+
coordinates?: Coordinates | null;
|
|
12
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"address.js","sourceRoot":"","sources":["../../../lib/types/address/address.ts"],"names":[],"mappings":"AAEA,MAAM,OAAO,OAAO;IAClB,SAAS,CAAgB;IACzB,OAAO,CAAgB;IACvB,OAAO,CAAgB;IACvB,IAAI,CAAgB;IACpB,UAAU,CAAgB;IAC1B,UAAU,CAAgB;IAC1B,YAAY,CAAgB;IAC5B,IAAI,CAAgB;IACpB,WAAW,CAAqB;CACjC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { CoordinatesResponse } from "@wisemen/coordinates";
|
|
2
|
+
export declare class AddressResponse {
|
|
3
|
+
placeName: string | null;
|
|
4
|
+
placeId: string | null;
|
|
5
|
+
country: string | null;
|
|
6
|
+
city: string | null;
|
|
7
|
+
postalCode: string | null;
|
|
8
|
+
streetName: string | null;
|
|
9
|
+
streetNumber: string | null;
|
|
10
|
+
unit: string | null;
|
|
11
|
+
coordinates: CoordinatesResponse | null;
|
|
12
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"address.response.js","sourceRoot":"","sources":["../../../lib/types/address/address.response.ts"],"names":[],"mappings":"AAEA,MAAM,OAAO,eAAe;IAC1B,SAAS,CAAe;IACxB,OAAO,CAAe;IACtB,OAAO,CAAe;IACtB,IAAI,CAAe;IACnB,UAAU,CAAe;IACzB,UAAU,CAAe;IACzB,YAAY,CAAe;IAC3B,IAAI,CAAe;IACnB,WAAW,CAA4B;CACxC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './address.response.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/types/address/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAA"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { LocationDetailResponse } from "../location/location-detail.response.js";
|
|
2
|
+
export declare class BusinessBillingInformationResponse {
|
|
3
|
+
uuid: string;
|
|
4
|
+
invoiceEmail: string;
|
|
5
|
+
invoiceCcEmails: string[];
|
|
6
|
+
reminderEmail: string;
|
|
7
|
+
reminderCcEmails: string[];
|
|
8
|
+
purchaseNoteEmail: string;
|
|
9
|
+
purchaseNoteCcEmails: string[];
|
|
10
|
+
location: LocationDetailResponse;
|
|
11
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export class BusinessBillingInformationResponse {
|
|
2
|
+
uuid;
|
|
3
|
+
invoiceEmail;
|
|
4
|
+
invoiceCcEmails;
|
|
5
|
+
reminderEmail;
|
|
6
|
+
reminderCcEmails;
|
|
7
|
+
purchaseNoteEmail;
|
|
8
|
+
purchaseNoteCcEmails;
|
|
9
|
+
location;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=business-billing-information.response.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"business-billing-information.response.js","sourceRoot":"","sources":["../../../lib/types/business/business-billing-information.response.ts"],"names":[],"mappings":"AAEA,MAAM,OAAO,kCAAkC;IAC7C,IAAI,CAAQ;IACZ,YAAY,CAAQ;IACpB,eAAe,CAAU;IACzB,aAAa,CAAQ;IACrB,gBAAgB,CAAU;IAC1B,iBAAiB,CAAQ;IACzB,oBAAoB,CAAU;IAC9B,QAAQ,CAAwB;CACjC"}
|