@arrowsphere/api-client 3.422.0 → 3.424.0

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 (43) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/build/cart/entities/index.d.ts +2 -0
  3. package/build/cart/entities/index.js +2 -0
  4. package/build/cart/entities/item.d.ts +4 -0
  5. package/build/cart/entities/item.js +15 -4
  6. package/build/cart/entities/itemPreferredCurrency.d.ts +18 -0
  7. package/build/cart/entities/itemPreferredCurrency.js +47 -0
  8. package/build/cart/entities/preferredCurrency/itemPreferredCurrencyValues.d.ts +22 -0
  9. package/build/cart/entities/preferredCurrency/itemPreferredCurrencyValues.js +61 -0
  10. package/build/customers/entities/invitations/contact/invitationContact.d.ts +1 -0
  11. package/build/quotes/entities/Quote.d.ts +50 -0
  12. package/build/quotes/entities/Quote.js +125 -0
  13. package/build/quotes/entities/QuoteLastVersion.d.ts +16 -0
  14. package/build/quotes/entities/QuoteLastVersion.js +45 -0
  15. package/build/quotes/entities/QuoteList.d.ts +9 -0
  16. package/build/quotes/entities/QuoteList.js +33 -0
  17. package/build/quotes/entities/QuoteProduct.d.ts +58 -0
  18. package/build/quotes/entities/QuoteProduct.js +135 -0
  19. package/build/quotes/entities/QuoteProductAssets.d.ts +16 -0
  20. package/build/quotes/entities/QuoteProductAssets.js +45 -0
  21. package/build/quotes/entities/QuoteProductPriceBand.d.ts +14 -0
  22. package/build/quotes/entities/QuoteProductPriceBand.js +39 -0
  23. package/build/quotes/entities/QuoteProductPriceBandArrowsphereIdentifier.d.ts +13 -0
  24. package/build/quotes/entities/QuoteProductPriceBandArrowsphereIdentifier.js +38 -0
  25. package/build/quotes/entities/QuoteProductPriceBandErpIdentifier.d.ts +13 -0
  26. package/build/quotes/entities/QuoteProductPriceBandErpIdentifier.js +38 -0
  27. package/build/quotes/entities/QuoteProductPriceBandIdentifiers.d.ts +22 -0
  28. package/build/quotes/entities/QuoteProductPriceBandIdentifiers.js +55 -0
  29. package/build/quotes/entities/QuoteProductPriceBandVendorIdentifier.d.ts +13 -0
  30. package/build/quotes/entities/QuoteProductPriceBandVendorIdentifier.js +38 -0
  31. package/build/quotes/entities/QuoteProductPrices.d.ts +31 -0
  32. package/build/quotes/entities/QuoteProductPrices.js +80 -0
  33. package/build/quotes/entities/QuoteProductProgram.d.ts +16 -0
  34. package/build/quotes/entities/QuoteProductProgram.js +45 -0
  35. package/build/quotes/entities/QuoteProductVendor.d.ts +13 -0
  36. package/build/quotes/entities/QuoteProductVendor.js +38 -0
  37. package/build/quotes/index.d.ts +13 -0
  38. package/build/quotes/index.js +13 -0
  39. package/build/quotes/quotesClient.d.ts +4 -0
  40. package/build/quotes/quotesClient.js +12 -0
  41. package/build/shared/contact/contact.d.ts +3 -1
  42. package/build/shared/contact/contact.js +1 -0
  43. package/package.json +1 -1
@@ -0,0 +1,80 @@
1
+ "use strict";
2
+ var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
3
+ if (kind === "m") throw new TypeError("Private method is not writable");
4
+ if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
5
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
6
+ return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
7
+ };
8
+ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
9
+ if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
10
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
11
+ return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
12
+ };
13
+ var _QuoteProductPrices_buy, _QuoteProductPrices_currency, _QuoteProductPrices_periodicity, _QuoteProductPrices_periodicityCode, _QuoteProductPrices_sell, _QuoteProductPrices_term, _QuoteProductPrices_termCode;
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.QuoteProductPrices = exports.QuoteProductPricesFields = void 0;
16
+ const abstractEntity_1 = require("../../abstractEntity");
17
+ var QuoteProductPricesFields;
18
+ (function (QuoteProductPricesFields) {
19
+ QuoteProductPricesFields["BUY"] = "buy";
20
+ QuoteProductPricesFields["CURRENCY"] = "currency";
21
+ QuoteProductPricesFields["PERIODICITY"] = "periodicity";
22
+ QuoteProductPricesFields["PERIODICITY_CODE"] = "periodicityCode";
23
+ QuoteProductPricesFields["SELL"] = "sell";
24
+ QuoteProductPricesFields["TERM"] = "term";
25
+ QuoteProductPricesFields["TERM_CODE"] = "termCode";
26
+ })(QuoteProductPricesFields = exports.QuoteProductPricesFields || (exports.QuoteProductPricesFields = {}));
27
+ class QuoteProductPrices extends abstractEntity_1.AbstractEntity {
28
+ constructor(data) {
29
+ super(data);
30
+ _QuoteProductPrices_buy.set(this, void 0);
31
+ _QuoteProductPrices_currency.set(this, void 0);
32
+ _QuoteProductPrices_periodicity.set(this, void 0);
33
+ _QuoteProductPrices_periodicityCode.set(this, void 0);
34
+ _QuoteProductPrices_sell.set(this, void 0);
35
+ _QuoteProductPrices_term.set(this, void 0);
36
+ _QuoteProductPrices_termCode.set(this, void 0);
37
+ __classPrivateFieldSet(this, _QuoteProductPrices_buy, data[QuoteProductPricesFields.BUY], "f");
38
+ __classPrivateFieldSet(this, _QuoteProductPrices_currency, data[QuoteProductPricesFields.CURRENCY], "f");
39
+ __classPrivateFieldSet(this, _QuoteProductPrices_periodicity, data[QuoteProductPricesFields.PERIODICITY], "f");
40
+ __classPrivateFieldSet(this, _QuoteProductPrices_periodicityCode, data[QuoteProductPricesFields.PERIODICITY_CODE], "f");
41
+ __classPrivateFieldSet(this, _QuoteProductPrices_sell, data[QuoteProductPricesFields.SELL], "f");
42
+ __classPrivateFieldSet(this, _QuoteProductPrices_term, data[QuoteProductPricesFields.TERM], "f");
43
+ __classPrivateFieldSet(this, _QuoteProductPrices_termCode, data[QuoteProductPricesFields.TERM_CODE], "f");
44
+ }
45
+ get buy() {
46
+ return __classPrivateFieldGet(this, _QuoteProductPrices_buy, "f");
47
+ }
48
+ get currency() {
49
+ return __classPrivateFieldGet(this, _QuoteProductPrices_currency, "f");
50
+ }
51
+ get periodicity() {
52
+ return __classPrivateFieldGet(this, _QuoteProductPrices_periodicity, "f");
53
+ }
54
+ get periodicityCode() {
55
+ return __classPrivateFieldGet(this, _QuoteProductPrices_periodicityCode, "f");
56
+ }
57
+ get sell() {
58
+ return __classPrivateFieldGet(this, _QuoteProductPrices_sell, "f");
59
+ }
60
+ get term() {
61
+ return __classPrivateFieldGet(this, _QuoteProductPrices_term, "f");
62
+ }
63
+ get termCode() {
64
+ return __classPrivateFieldGet(this, _QuoteProductPrices_termCode, "f");
65
+ }
66
+ toJSON() {
67
+ return {
68
+ [QuoteProductPricesFields.BUY]: this.buy,
69
+ [QuoteProductPricesFields.CURRENCY]: this.currency,
70
+ [QuoteProductPricesFields.PERIODICITY]: this.periodicity,
71
+ [QuoteProductPricesFields.PERIODICITY_CODE]: this.periodicityCode,
72
+ [QuoteProductPricesFields.SELL]: this.sell,
73
+ [QuoteProductPricesFields.TERM]: this.term,
74
+ [QuoteProductPricesFields.TERM_CODE]: this.termCode,
75
+ };
76
+ }
77
+ }
78
+ exports.QuoteProductPrices = QuoteProductPrices;
79
+ _QuoteProductPrices_buy = new WeakMap(), _QuoteProductPrices_currency = new WeakMap(), _QuoteProductPrices_periodicity = new WeakMap(), _QuoteProductPrices_periodicityCode = new WeakMap(), _QuoteProductPrices_sell = new WeakMap(), _QuoteProductPrices_term = new WeakMap(), _QuoteProductPrices_termCode = new WeakMap();
80
+ //# sourceMappingURL=QuoteProductPrices.js.map
@@ -0,0 +1,16 @@
1
+ import { AbstractEntity } from '../../abstractEntity';
2
+ export declare enum QuoteProductProgramFields {
3
+ INTERNAL_NAME = "internalName",
4
+ LEGACY_CODE = "legacyCode"
5
+ }
6
+ export declare type QuoteProductProgramData = {
7
+ [QuoteProductProgramFields.INTERNAL_NAME]?: string;
8
+ [QuoteProductProgramFields.LEGACY_CODE]: string;
9
+ };
10
+ export declare class QuoteProductProgram extends AbstractEntity<QuoteProductProgramData> {
11
+ #private;
12
+ constructor(data: QuoteProductProgramData);
13
+ get internalName(): string | undefined;
14
+ get legacyCode(): string;
15
+ toJSON(): QuoteProductProgramData;
16
+ }
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+ var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
3
+ if (kind === "m") throw new TypeError("Private method is not writable");
4
+ if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
5
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
6
+ return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
7
+ };
8
+ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
9
+ if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
10
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
11
+ return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
12
+ };
13
+ var _QuoteProductProgram_internalName, _QuoteProductProgram_legacyCode;
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.QuoteProductProgram = exports.QuoteProductProgramFields = void 0;
16
+ const abstractEntity_1 = require("../../abstractEntity");
17
+ var QuoteProductProgramFields;
18
+ (function (QuoteProductProgramFields) {
19
+ QuoteProductProgramFields["INTERNAL_NAME"] = "internalName";
20
+ QuoteProductProgramFields["LEGACY_CODE"] = "legacyCode";
21
+ })(QuoteProductProgramFields = exports.QuoteProductProgramFields || (exports.QuoteProductProgramFields = {}));
22
+ class QuoteProductProgram extends abstractEntity_1.AbstractEntity {
23
+ constructor(data) {
24
+ super(data);
25
+ _QuoteProductProgram_internalName.set(this, void 0);
26
+ _QuoteProductProgram_legacyCode.set(this, void 0);
27
+ __classPrivateFieldSet(this, _QuoteProductProgram_internalName, data[QuoteProductProgramFields.INTERNAL_NAME], "f");
28
+ __classPrivateFieldSet(this, _QuoteProductProgram_legacyCode, data[QuoteProductProgramFields.LEGACY_CODE], "f");
29
+ }
30
+ get internalName() {
31
+ return __classPrivateFieldGet(this, _QuoteProductProgram_internalName, "f");
32
+ }
33
+ get legacyCode() {
34
+ return __classPrivateFieldGet(this, _QuoteProductProgram_legacyCode, "f");
35
+ }
36
+ toJSON() {
37
+ return {
38
+ [QuoteProductProgramFields.INTERNAL_NAME]: this.internalName,
39
+ [QuoteProductProgramFields.LEGACY_CODE]: this.legacyCode,
40
+ };
41
+ }
42
+ }
43
+ exports.QuoteProductProgram = QuoteProductProgram;
44
+ _QuoteProductProgram_internalName = new WeakMap(), _QuoteProductProgram_legacyCode = new WeakMap();
45
+ //# sourceMappingURL=QuoteProductProgram.js.map
@@ -0,0 +1,13 @@
1
+ import { AbstractEntity } from '../../abstractEntity';
2
+ export declare enum QuoteProductVendorFields {
3
+ NAME = "name"
4
+ }
5
+ export declare type QuoteProductVendorData = {
6
+ [QuoteProductVendorFields.NAME]: string;
7
+ };
8
+ export declare class QuoteProductVendor extends AbstractEntity<QuoteProductVendorData> {
9
+ #private;
10
+ constructor(data: QuoteProductVendorData);
11
+ get name(): string;
12
+ toJSON(): QuoteProductVendorData;
13
+ }
@@ -0,0 +1,38 @@
1
+ "use strict";
2
+ var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
3
+ if (kind === "m") throw new TypeError("Private method is not writable");
4
+ if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
5
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
6
+ return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
7
+ };
8
+ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
9
+ if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
10
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
11
+ return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
12
+ };
13
+ var _QuoteProductVendor_name;
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.QuoteProductVendor = exports.QuoteProductVendorFields = void 0;
16
+ const abstractEntity_1 = require("../../abstractEntity");
17
+ var QuoteProductVendorFields;
18
+ (function (QuoteProductVendorFields) {
19
+ QuoteProductVendorFields["NAME"] = "name";
20
+ })(QuoteProductVendorFields = exports.QuoteProductVendorFields || (exports.QuoteProductVendorFields = {}));
21
+ class QuoteProductVendor extends abstractEntity_1.AbstractEntity {
22
+ constructor(data) {
23
+ super(data);
24
+ _QuoteProductVendor_name.set(this, void 0);
25
+ __classPrivateFieldSet(this, _QuoteProductVendor_name, data[QuoteProductVendorFields.NAME], "f");
26
+ }
27
+ get name() {
28
+ return __classPrivateFieldGet(this, _QuoteProductVendor_name, "f");
29
+ }
30
+ toJSON() {
31
+ return {
32
+ [QuoteProductVendorFields.NAME]: this.name,
33
+ };
34
+ }
35
+ }
36
+ exports.QuoteProductVendor = QuoteProductVendor;
37
+ _QuoteProductVendor_name = new WeakMap();
38
+ //# sourceMappingURL=QuoteProductVendor.js.map
@@ -1 +1,14 @@
1
1
  export * from './quotesClient';
2
+ export * from './entities/Quote';
3
+ export * from './entities/QuoteLastVersion';
4
+ export * from './entities/QuoteProduct';
5
+ export * from './entities/QuoteProductAssets';
6
+ export * from './entities/QuoteProductPriceBand';
7
+ export * from './entities/QuoteProductPriceBandArrowsphereIdentifier';
8
+ export * from './entities/QuoteProductPriceBandErpIdentifier';
9
+ export * from './entities/QuoteProductPriceBandIdentifiers';
10
+ export * from './entities/QuoteProductPriceBandVendorIdentifier';
11
+ export * from './entities/QuoteProductProgram';
12
+ export * from './entities/QuoteProductPrices';
13
+ export * from './entities/QuoteProductVendor';
14
+ export * from './entities/QuoteList';
@@ -15,4 +15,17 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./quotesClient"), exports);
18
+ __exportStar(require("./entities/Quote"), exports);
19
+ __exportStar(require("./entities/QuoteLastVersion"), exports);
20
+ __exportStar(require("./entities/QuoteProduct"), exports);
21
+ __exportStar(require("./entities/QuoteProductAssets"), exports);
22
+ __exportStar(require("./entities/QuoteProductPriceBand"), exports);
23
+ __exportStar(require("./entities/QuoteProductPriceBandArrowsphereIdentifier"), exports);
24
+ __exportStar(require("./entities/QuoteProductPriceBandErpIdentifier"), exports);
25
+ __exportStar(require("./entities/QuoteProductPriceBandIdentifiers"), exports);
26
+ __exportStar(require("./entities/QuoteProductPriceBandVendorIdentifier"), exports);
27
+ __exportStar(require("./entities/QuoteProductProgram"), exports);
28
+ __exportStar(require("./entities/QuoteProductPrices"), exports);
29
+ __exportStar(require("./entities/QuoteProductVendor"), exports);
30
+ __exportStar(require("./entities/QuoteList"), exports);
18
31
  //# sourceMappingURL=index.js.map
@@ -3,6 +3,8 @@ import { GetResult } from '../getResult';
3
3
  import { QuoteRequest } from './entities/QuoteRequest';
4
4
  import { PutQuoteResult } from './entities/PutQuoteResult';
5
5
  import { QuoteComments } from './entities/QuoteComments';
6
+ import { Quote } from './entities/Quote';
7
+ import { QuoteList } from './entities/QuoteList';
6
8
  export declare type RequestQuoteRequestType = {
7
9
  agreeToReceiveCommunications: boolean;
8
10
  agreeSharingInformation: boolean;
@@ -65,6 +67,8 @@ export declare type CreateCommentType = {
65
67
  };
66
68
  export declare class QuotesClient extends AbstractRestfulClient {
67
69
  protected basePath: string;
70
+ listQuotes(perPage?: number, page?: number, parameters?: Parameters): Promise<GetResult<QuoteList>>;
71
+ getQuote(reference: string): Promise<GetResult<Quote>>;
68
72
  requestQuote(postData: RequestQuoteRequestType, parameters?: Parameters): Promise<GetResult<QuoteRequest>>;
69
73
  requestQuoteForVendor(vendor: string, postData: RequestQuoteIbmRequestType, parameters?: Parameters): Promise<void>;
70
74
  deleteQuote(quoteReference: string, parameters?: Parameters): Promise<void>;
@@ -6,11 +6,23 @@ const getResult_1 = require("../getResult");
6
6
  const QuoteRequest_1 = require("./entities/QuoteRequest");
7
7
  const PutQuoteResult_1 = require("./entities/PutQuoteResult");
8
8
  const QuoteComments_1 = require("./entities/QuoteComments");
9
+ const Quote_1 = require("./entities/Quote");
10
+ const QuoteList_1 = require("./entities/QuoteList");
9
11
  class QuotesClient extends abstractRestfulClient_1.AbstractRestfulClient {
10
12
  constructor() {
11
13
  super(...arguments);
12
14
  this.basePath = '/quotes';
13
15
  }
16
+ async listQuotes(perPage = 25, page = 1, parameters = {}) {
17
+ this.path = '';
18
+ this.setPerPage(perPage);
19
+ this.setPage(page);
20
+ return new getResult_1.GetResult(QuoteList_1.QuoteList, await this.get(parameters));
21
+ }
22
+ async getQuote(reference) {
23
+ this.path = `/${reference}`;
24
+ return new getResult_1.GetResult(Quote_1.Quote, await this.get());
25
+ }
14
26
  async requestQuote(postData, parameters = {}) {
15
27
  this.path = '/request';
16
28
  return new getResult_1.GetResult(QuoteRequest_1.QuoteRequest, await this.post(postData, parameters));
@@ -1,10 +1,12 @@
1
1
  export declare enum SharedContactFields {
2
2
  COLUMN_FIRSTNAME = "firstName",
3
3
  COLUMN_LASTNAME = "lastName",
4
- COLUMN_EMAIL = "email"
4
+ COLUMN_EMAIL = "email",
5
+ COLUMN_PHONE = "phone"
5
6
  }
6
7
  export interface SharedContactInterface {
7
8
  [SharedContactFields.COLUMN_FIRSTNAME]: string;
8
9
  [SharedContactFields.COLUMN_LASTNAME]: string;
9
10
  [SharedContactFields.COLUMN_EMAIL]: string;
11
+ [SharedContactFields.COLUMN_PHONE]?: string;
10
12
  }
@@ -6,5 +6,6 @@ var SharedContactFields;
6
6
  SharedContactFields["COLUMN_FIRSTNAME"] = "firstName";
7
7
  SharedContactFields["COLUMN_LASTNAME"] = "lastName";
8
8
  SharedContactFields["COLUMN_EMAIL"] = "email";
9
+ SharedContactFields["COLUMN_PHONE"] = "phone";
9
10
  })(SharedContactFields = exports.SharedContactFields || (exports.SharedContactFields = {}));
10
11
  //# sourceMappingURL=contact.js.map
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "type": "git",
5
5
  "url": "https://github.com/ArrowSphere/nodejs-api-client.git"
6
6
  },
7
- "version": "3.422.0",
7
+ "version": "3.424.0",
8
8
  "description": "Node.js client for ArrowSphere's public API",
9
9
  "main": "build/index.js",
10
10
  "types": "build/index.d.ts",