@arrowsphere/api-client 3.159.0 → 3.160.0-rc-jpb-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.
@@ -3,10 +3,85 @@ import { SubscriptionType } from './subscription';
3
3
  import { VendorsType } from './vendor';
4
4
  export declare type GraphqlApiProgramType = {
5
5
  id?: number;
6
+ clickToAccept?: number;
7
+ description?: string;
8
+ expire?: number;
6
9
  internalName?: string;
10
+ introduction?: string;
11
+ levels?: ProgramLevelType[];
7
12
  name?: string;
13
+ subscriptionDetailKeys?: SubscriptionDetailKeyType[];
14
+ url?: string;
8
15
  vendor?: VendorsType;
9
16
  };
17
+ export declare type SubscriptionDetailKeyType = {
18
+ id?: number;
19
+ name?: string;
20
+ key?: string;
21
+ specificProgramId?: number;
22
+ isMandatory?: boolean;
23
+ isSendXac?: boolean;
24
+ type?: string;
25
+ rule?: string;
26
+ description?: string;
27
+ };
28
+ export declare type ProgramSkuPackAvailabilityType = {
29
+ id?: number;
30
+ programId?: number;
31
+ levelId?: number;
32
+ skuPackId?: number;
33
+ countryGroupId?: number;
34
+ startDate?: Date;
35
+ endDate?: Date;
36
+ programSkuPack?: ProgramSkuPackType;
37
+ };
38
+ export declare type ProgramSkuPackType = {
39
+ id?: number;
40
+ name?: string;
41
+ description?: string;
42
+ note?: string;
43
+ packSku?: string;
44
+ notAvailableToUser?: boolean;
45
+ isCustom?: boolean;
46
+ companyId?: number;
47
+ programSkus?: ProgramSkuType[];
48
+ };
49
+ export declare type ProgramSkuType = {
50
+ id?: number;
51
+ description?: string;
52
+ typeId?: number;
53
+ };
54
+ export declare type ProgramLevelType = {
55
+ id?: number;
56
+ uuid?: string;
57
+ programId?: number;
58
+ internalName?: string;
59
+ name?: string;
60
+ description?: string;
61
+ imageLogo?: string;
62
+ monthLength?: string;
63
+ agreementId?: number;
64
+ level?: number;
65
+ enabled?: boolean;
66
+ benefits?: ProgramBenefitType[];
67
+ requirements?: ProgramRequirementType[];
68
+ programSkuPackAvailabilities?: ProgramSkuPackAvailabilityType[];
69
+ };
70
+ export declare type ProgramBenefitType = {
71
+ id?: number;
72
+ uuid?: string;
73
+ programId?: number;
74
+ title?: string;
75
+ description?: string;
76
+ };
77
+ export declare type ProgramRequirementType = {
78
+ id?: number;
79
+ uuid?: string;
80
+ programId?: number;
81
+ levelId?: number;
82
+ title?: string;
83
+ description?: string;
84
+ };
10
85
  export declare type SubscribedProgramType = {
11
86
  id?: number;
12
87
  availabilityEndedAt?: string;
@@ -1,10 +1,26 @@
1
+ import { CountryType } from './country';
1
2
  export declare type VendorsType = {
2
3
  id?: number;
3
4
  identifier?: string;
4
5
  licenseUrl?: string;
6
+ location?: VendorLocationType;
5
7
  logoLarge?: string;
6
8
  logoSmall?: string;
7
9
  logoStandard?: string;
8
10
  name?: string;
9
11
  url?: string;
10
12
  };
13
+ export declare type VendorLocationType = {
14
+ id?: number;
15
+ vendorId?: number;
16
+ name?: string;
17
+ address1?: string;
18
+ address2?: string;
19
+ city?: string;
20
+ state?: string;
21
+ zipCode?: string;
22
+ countryId?: number;
23
+ country?: CountryType;
24
+ phoneNumber?: string;
25
+ footprint?: string;
26
+ };
@@ -2,7 +2,7 @@ import { ArrowCompanyType, EndCustomerType, PartnerType } from './entities/compa
2
2
  import { ContinentType, CountryType } from './entities/country';
3
3
  import { LicenseBudgetType } from './entities/licenseBudget';
4
4
  import { PartnertagType } from './entities/partnertag';
5
- import { SubscribedProgramType } from './entities/program';
5
+ import { GraphqlApiProgramType, ProgramSkuPackAvailabilityType, SubscribedProgramType } from './entities/program';
6
6
  import { QuoteType } from './entities/quote';
7
7
  import { SubscriptionType } from './entities/subscription';
8
8
  import { UserHistoryType, UserType } from './entities/user';
@@ -119,6 +119,8 @@ export declare enum SelectDataField {
119
119
  LICENSE_BUDGET = "licenseBudget",
120
120
  PARTNER = "partner",
121
121
  PARTNERTAG = "partnertag",
122
+ PROGRAM = "program",
123
+ PROGRAM_SKU_PACK_AVAILABILITY = "programSkuPackAvailability",
122
124
  QUOTE = "quote",
123
125
  SUBSCRIBED_PROGRAM = "subscribedProgram",
124
126
  SUBSCRIPTION = "subscription",
@@ -141,6 +143,8 @@ export declare type SelectAllResponseDataType = {
141
143
  [SelectDataField.LICENSE_BUDGET]?: LicenseBudgetType[];
142
144
  [SelectDataField.PARTNER]?: PartnerType[];
143
145
  [SelectDataField.PARTNERTAG]?: PartnertagType[];
146
+ [SelectDataField.PROGRAM]?: GraphqlApiProgramType[];
147
+ [SelectDataField.PROGRAM_SKU_PACK_AVAILABILITY]?: ProgramSkuPackAvailabilityType[];
144
148
  [SelectDataField.QUOTE]?: QuoteType[];
145
149
  [SelectDataField.SUBSCRIBED_PROGRAM]?: SubscribedProgramType[];
146
150
  [SelectDataField.SUBSCRIPTION]?: SubscriptionType[];
@@ -189,6 +193,8 @@ export declare type SelectOneResponseDataType = {
189
193
  [SelectDataField.LICENSE_BUDGET]?: LicenseBudgetType;
190
194
  [SelectDataField.PARTNER]?: PartnerType;
191
195
  [SelectDataField.PARTNERTAG]?: PartnertagType;
196
+ [SelectDataField.PROGRAM]?: GraphqlApiProgramType;
197
+ [SelectDataField.PROGRAM_SKU_PACK_AVAILABILITY]?: ProgramSkuPackAvailabilityType;
192
198
  [SelectDataField.QUOTE]?: QuoteType;
193
199
  [SelectDataField.SUBSCRIBED_PROGRAM]?: SubscribedProgramType;
194
200
  [SelectDataField.SUBSCRIPTION]?: SubscriptionType;
@@ -97,6 +97,8 @@ var SelectDataField;
97
97
  SelectDataField["LICENSE_BUDGET"] = "licenseBudget";
98
98
  SelectDataField["PARTNER"] = "partner";
99
99
  SelectDataField["PARTNERTAG"] = "partnertag";
100
+ SelectDataField["PROGRAM"] = "program";
101
+ SelectDataField["PROGRAM_SKU_PACK_AVAILABILITY"] = "programSkuPackAvailability";
100
102
  SelectDataField["QUOTE"] = "quote";
101
103
  SelectDataField["SUBSCRIBED_PROGRAM"] = "subscribedProgram";
102
104
  SelectDataField["SUBSCRIPTION"] = "subscription";
@@ -9,7 +9,7 @@ import { SubscriptionType } from './entities/subscription';
9
9
  import { SpecialPriceRateType } from './entities/specialPriceRate';
10
10
  import { OrderItemsType, OrdersType } from './entities/order';
11
11
  import { VendorsType } from './entities/vendor';
12
- import { GraphqlApiProgramType, SubscribedProgramType } from './entities/program';
12
+ import { GraphqlApiProgramType, ProgramBenefitType, ProgramLevelType, ProgramRequirementType, ProgramSkuPackAvailabilityType, ProgramSkuPackType, ProgramSkuType, SubscribedProgramType, SubscriptionDetailKeyType } from './entities/program';
13
13
  import { LicenseBudgetNotificationType, LicenseBudgetType } from './entities/licenseBudget';
14
14
  import { UserHistoryType, UserType } from './entities/user';
15
15
  import { OrganizationUnitsType } from './entities/organizationUnit';
@@ -97,7 +97,30 @@ export declare type ErrorsSchema = Schema<ErrorsType, boolean>;
97
97
  export declare type LicenseBudgetNotificationSchema = Schema<LicenseBudgetNotificationType, boolean>;
98
98
  export declare type OrganizationUnitSchema = Schema<OrganizationUnitsType, boolean>;
99
99
  export declare type PageSchema = Schema<PageType, boolean>;
100
- export declare type GraphqlApiProgramSchema = Schema<GraphqlApiProgramType, boolean>;
100
+ export declare type ProgramBenefitSchema = Schema<ProgramBenefitType, boolean>;
101
+ export declare type ProgramSkuSchema = Schema<ProgramSkuType, boolean>;
102
+ export declare type ProgramRequirementSchema = Schema<ProgramRequirementType, boolean>;
103
+ export declare type ProgramLevelSchema = Schema<ProgramLevelType, boolean>;
104
+ declare type MissingFieldsOfProgramSkuPackSchema = {
105
+ programSkus?: ProgramSkuSchema;
106
+ };
107
+ declare type ProgramSkuPackSchema = Merge<Schema<ProgramSkuPackType, boolean>, MissingFieldsOfProgramSkuPackSchema>;
108
+ declare type MissingFieldsOfProgramSkuPackAvailabilitySchema = {
109
+ programSkuPack?: ProgramSkuPackSchema;
110
+ };
111
+ export declare type ProgramSkuPackAvailabilitySchema = Merge<Schema<ProgramSkuPackAvailabilityType, // append programSkuPack <----------------------------------------------------
112
+ boolean>, MissingFieldsOfProgramSkuPackAvailabilitySchema>;
113
+ export declare type SubscriptionDetailKeySchema = Schema<SubscriptionDetailKeyType, boolean>;
114
+ export declare type MissingFieldsOfLevelSchema = {
115
+ benefits?: ProgramBenefitSchema;
116
+ programSkuPackAvailabilities?: ProgramSkuPackAvailabilitySchema;
117
+ requirements?: ProgramRequirementSchema;
118
+ };
119
+ export declare type MissingFieldsOfProgramSchema = {
120
+ levels?: Merge<Schema<ProgramLevelSchema, boolean>, MissingFieldsOfLevelSchema>;
121
+ subscriptionDetailKeys?: SubscriptionDetailKeySchema;
122
+ };
123
+ export declare type GraphqlApiProgramSchema = Merge<Schema<GraphqlApiProgramType, boolean>, MissingFieldsOfProgramSchema>;
101
124
  export declare type SpecialPriceRateSchema = Schema<SpecialPriceRateType, boolean>;
102
125
  export declare type SubscribedProgramSchema = Schema<SubscribedProgramType, boolean>;
103
126
  export declare type SubscriptionSchema = Schema<SubscriptionType, boolean>;
@@ -117,6 +140,8 @@ export declare type SelectAllResponseDataSchema = {
117
140
  [SelectDataField.LICENSE_BUDGET]?: LicenseBudgetSchema;
118
141
  [SelectDataField.PARTNER]?: PartnerSchema;
119
142
  [SelectDataField.PARTNERTAG]?: PartnertagSchema;
143
+ [SelectDataField.PROGRAM]?: GraphqlApiProgramSchema;
144
+ [SelectDataField.PROGRAM_SKU_PACK_AVAILABILITY]?: ProgramSkuPackAvailabilitySchema;
120
145
  [SelectDataField.QUOTE]?: QuoteSchema;
121
146
  [SelectDataField.SUBSCRIBED_PROGRAM]?: SubscribedProgramSchema;
122
147
  [SelectDataField.SUBSCRIPTION]?: SubscriptionSchema;
@@ -136,6 +161,7 @@ export declare type SelectOneResponseDataSchema = {
136
161
  [SelectDataField.LICENSE_BUDGET]?: LicenseBudgetSchema;
137
162
  [SelectDataField.PARTNER]?: PartnerSchema;
138
163
  [SelectDataField.PARTNERTAG]?: PartnertagSchema;
164
+ [SelectDataField.PROGRAM]?: GraphqlApiProgramSchema;
139
165
  [SelectDataField.QUOTE]?: QuoteSchema;
140
166
  [SelectDataField.SUBSCRIBED_PROGRAM]?: SubscribedProgramSchema;
141
167
  [SelectDataField.SUBSCRIPTION]?: SubscriptionSchema;
@@ -29,6 +29,16 @@ export declare type SubscriptionsListData = {
29
29
  previous: string;
30
30
  };
31
31
  };
32
+ export declare type SubscriptionCreationData = {
33
+ name: string;
34
+ level: string;
35
+ sku: string;
36
+ extraInformation?: {
37
+ programs: {
38
+ [programName: string]: Record<string, string>;
39
+ };
40
+ };
41
+ };
32
42
  export declare class SubscriptionsClient extends AbstractRestfulClient {
33
43
  /**
34
44
  * The base path of the API
@@ -62,4 +72,5 @@ export declare class SubscriptionsClient extends AbstractRestfulClient {
62
72
  *
63
73
  */
64
74
  list(postData?: SubscriptionsListPayload, perPage?: number, page?: number): Promise<SubscriptionsListResult>;
75
+ addSubscription(postData: SubscriptionCreationData): Promise<void>;
65
76
  }
@@ -50,6 +50,9 @@ class SubscriptionsClient extends abstractRestfulClient_1.AbstractRestfulClient
50
50
  const response = await this.listRaw(postData);
51
51
  return new subscriptionsListResult_1.SubscriptionsListResult(response, this, postData);
52
52
  }
53
+ async addSubscription(postData) {
54
+ return this.post(postData);
55
+ }
53
56
  }
54
57
  exports.SubscriptionsClient = SubscriptionsClient;
55
58
  //# sourceMappingURL=subscriptionsClient.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.159.0",
7
+ "version": "3.160.0-rc-jpb-1",
8
8
  "description": "Node.js client for ArrowSphere's public API",
9
9
  "main": "build/index.js",
10
10
  "types": "build/index.d.ts",