@spytecgps/nova-orm 0.0.156 → 0.0.158
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/dist/entities/aempToken.d.ts +9 -0
- package/dist/entities/billingKlarnaCustomer.d.ts +14 -0
- package/dist/entities/billingKlarnaOrder.d.ts +17 -0
- package/dist/entities/index.d.ts +4 -1
- package/dist/index.js +1 -1
- package/dist/repositories/aempToken/createAempToken.d.ts +5 -0
- package/dist/repositories/aempToken/deleteAempTokens.d.ts +4 -0
- package/dist/repositories/aempToken/getAempTokens.d.ts +5 -0
- package/dist/repositories/aempToken/index.d.ts +33 -0
- package/dist/repositories/billing/index.d.ts +14 -2
- package/dist/repositories/billing/upsertBillingKlarnaCustomer.d.ts +5 -0
- package/dist/repositories/billing/upsertBillingKlarnaOrder.d.ts +5 -0
- package/dist/repositories/index.d.ts +2 -1
- package/dist/types/aempToken.d.ts +19 -0
- package/dist/types/billing.d.ts +31 -0
- package/package.json +1 -1
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { AempToken } from '../../entities';
|
|
2
|
+
import { NovaDataSource } from '../../novaDataSource';
|
|
3
|
+
import { CreateAempTokenParams } from '../../types/aempToken';
|
|
4
|
+
import { Logger } from '../../types/logger';
|
|
5
|
+
export declare const createAempToken: (novaDataSource: NovaDataSource, params: CreateAempTokenParams, logger: Logger) => Promise<AempToken>;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { NovaDataSource } from '../../novaDataSource';
|
|
2
|
+
import { DeleteAempTokensParams } from '../../types/aempToken';
|
|
3
|
+
import { Logger } from '../../types/logger';
|
|
4
|
+
export declare const deleteAempTokens: (novaDataSource: NovaDataSource, params: DeleteAempTokensParams, logger: Logger) => Promise<boolean>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { AempToken } from '../../entities';
|
|
2
|
+
import { NovaDataSource } from '../../novaDataSource';
|
|
3
|
+
import { GetAempTokensParams } from '../../types/aempToken';
|
|
4
|
+
import { Logger } from '../../types/logger';
|
|
5
|
+
export declare const getAempTokens: (novaDataSource: NovaDataSource, params: GetAempTokensParams, logger: Logger) => Promise<AempToken[]>;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { AempToken } from '../../entities';
|
|
2
|
+
import { CreateAempTokenParams, DeleteAempTokensParams, GetAempTokensParams } from '../../types/aempToken';
|
|
3
|
+
import { BaseRepository } from '../baseRepository';
|
|
4
|
+
export declare class AempTokenRepository extends BaseRepository {
|
|
5
|
+
/**
|
|
6
|
+
* Get AMP tokens by client ID
|
|
7
|
+
* @param params - GetAempTokensParams
|
|
8
|
+
* One of the following is required:
|
|
9
|
+
* - filters.clientId: The client id
|
|
10
|
+
* - filters.token: The token
|
|
11
|
+
* @returns AempToken[]
|
|
12
|
+
*/
|
|
13
|
+
getAempTokens(params: GetAempTokensParams): Promise<AempToken[]>;
|
|
14
|
+
/**
|
|
15
|
+
* Create an AMP token
|
|
16
|
+
* @param params - CreateAempTokenParams
|
|
17
|
+
* - clientId: The client id, required
|
|
18
|
+
* - token: The token, required
|
|
19
|
+
* - expiresAt: The expiration date, optional
|
|
20
|
+
* @returns AempToken
|
|
21
|
+
*/
|
|
22
|
+
createAempToken(params: CreateAempTokenParams): Promise<AempToken>;
|
|
23
|
+
/**
|
|
24
|
+
* Delete AMP tokens
|
|
25
|
+
* @param params - DeleteAempTokensParams
|
|
26
|
+
* One of the following is required:
|
|
27
|
+
* - filters.id: The id
|
|
28
|
+
* - filters.clientId: The client id
|
|
29
|
+
* - filters.token: The token
|
|
30
|
+
* @returns True if the token was deleted, false otherwise
|
|
31
|
+
*/
|
|
32
|
+
deleteAempTokens(params: DeleteAempTokensParams): Promise<boolean>;
|
|
33
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Billing, BillingCustomerBraintree, BillingDeviceHistory, BillingHubspotPaymentLog, BillingStatusHistoryBraintree, BillingSubscriptionBraintree, Magento2Plan, User } from '../../entities';
|
|
2
|
-
import { BillingSubscriptionChurnStatus, CanceledImeiResult, CreateBillingDeviceHistoryParams, CreateBillingHubspotPaymentLogParams, CreateBillingParams, CreateBillingStatusHistoryBraintreeParams, GetBillingCustomerBraintreeByIdParams, GetBillingsParams, GetBillingSubscriptionsBraintreeParams, GetCanceledImeisParams, GetChurnStatusByClientIdParams, GetClientIdFromBraintreeCustomerParams, GetMagentoPlanParams, GetUserByBraintreeCustomerIdParams, UpdateBillingCustomerBraintreeParams, UpdateBillingParams, UpsertBillingCustomerBraintreeParams, UpsertBillingSubscriptionBraintreeParams } from '../../types/billing';
|
|
1
|
+
import { Billing, BillingCustomerBraintree, BillingDeviceHistory, BillingHubspotPaymentLog, BillingKlarnaCustomer, BillingKlarnaOrder, BillingStatusHistoryBraintree, BillingSubscriptionBraintree, Magento2Plan, User } from '../../entities';
|
|
2
|
+
import { BillingSubscriptionChurnStatus, CanceledImeiResult, CreateBillingDeviceHistoryParams, CreateBillingHubspotPaymentLogParams, CreateBillingParams, CreateBillingStatusHistoryBraintreeParams, GetBillingCustomerBraintreeByIdParams, GetBillingsParams, GetBillingSubscriptionsBraintreeParams, GetCanceledImeisParams, GetChurnStatusByClientIdParams, GetClientIdFromBraintreeCustomerParams, GetMagentoPlanParams, GetUserByBraintreeCustomerIdParams, UpdateBillingCustomerBraintreeParams, UpdateBillingParams, UpsertBillingCustomerBraintreeParams, UpsertBillingKlarnaCustomerParams, UpsertBillingKlarnaOrderParams, UpsertBillingSubscriptionBraintreeParams } from '../../types/billing';
|
|
3
3
|
import { BaseRepository } from '../baseRepository';
|
|
4
4
|
export declare class BillingRepository extends BaseRepository {
|
|
5
5
|
/**
|
|
@@ -178,4 +178,16 @@ export declare class BillingRepository extends BaseRepository {
|
|
|
178
178
|
* @returns The created billing hubspot payment log information
|
|
179
179
|
*/
|
|
180
180
|
createBillingHubspotPaymentLog(params: CreateBillingHubspotPaymentLogParams): Promise<BillingHubspotPaymentLog>;
|
|
181
|
+
/**
|
|
182
|
+
* Upsert billing klarna customer
|
|
183
|
+
* @param {UpsertBillingKlarnaCustomerParams} params containing information to upsert billing klarna customer
|
|
184
|
+
* @returns The upserted billing klarna customer information
|
|
185
|
+
*/
|
|
186
|
+
upsertBillingKlarnaCustomer(params: UpsertBillingKlarnaCustomerParams): Promise<BillingKlarnaCustomer>;
|
|
187
|
+
/**
|
|
188
|
+
* Upsert billing klarna order
|
|
189
|
+
* @param {UpsertBillingKlarnaOrderParams} params containing information to upsert billing klarna order
|
|
190
|
+
* @returns The upserted billing klarna order information
|
|
191
|
+
*/
|
|
192
|
+
upsertBillingKlarnaOrder(params: UpsertBillingKlarnaOrderParams): Promise<BillingKlarnaOrder>;
|
|
181
193
|
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { BillingKlarnaCustomer } from '../../entities';
|
|
2
|
+
import { NovaDataSource } from '../../novaDataSource';
|
|
3
|
+
import { UpsertBillingKlarnaCustomerParams } from '../../types/billing';
|
|
4
|
+
import { Logger } from '../../types/logger';
|
|
5
|
+
export declare const upsertBillingKlarnaCustomer: (novaDataSource: NovaDataSource, params: UpsertBillingKlarnaCustomerParams, logger: Logger) => Promise<BillingKlarnaCustomer>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { BillingKlarnaOrder } from '../../entities';
|
|
2
|
+
import { NovaDataSource } from '../../novaDataSource';
|
|
3
|
+
import { UpsertBillingKlarnaOrderParams } from '../../types/billing';
|
|
4
|
+
import { Logger } from '../../types/logger';
|
|
5
|
+
export declare const upsertBillingKlarnaOrder: (novaDataSource: NovaDataSource, params: UpsertBillingKlarnaOrderParams, logger: Logger) => Promise<BillingKlarnaOrder>;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { AcumaticaRepository } from './acumatica';
|
|
2
|
+
import { AempTokenRepository } from './aempToken';
|
|
2
3
|
import { AlertRepository } from './alerts';
|
|
3
4
|
import { AlertTypesRepository } from './alertTypes';
|
|
4
5
|
import { AssetCategoriesRepository } from './assetCategories';
|
|
@@ -24,4 +25,4 @@ import { UserInvitationsRepository } from './userInvitations';
|
|
|
24
25
|
import { UserRatingRequestsRepository } from './userRatingRequests';
|
|
25
26
|
import { UserRegistrationAttemptsRepository } from './userRegistrationAttempts';
|
|
26
27
|
import { UsersRepository } from './users';
|
|
27
|
-
export { AcumaticaRepository, AlertRepository, AlertTypesRepository, AssetCategoriesRepository, BillingRepository, BlacklistRepository, BoundariesRepository, ClientsRepository, CountriesRepository, DeactivationsRepository, DeviceBehaviorsRepository, DevicesRepository, FirmwaresRepository, NotificationRecipientsRepository, PositionRepository, SecurityRepository, TripRepository, UserActivationsRepository, UserAppFeedbackRepository, UserAppIncidentsRepository, UserConfigurationsRepository, UserDataDeletionRequestsRepository, UserInvitationsRepository, UserRatingRequestsRepository, UserRegistrationAttemptsRepository, UsersRepository, };
|
|
28
|
+
export { AcumaticaRepository, AempTokenRepository, AlertRepository, AlertTypesRepository, AssetCategoriesRepository, BillingRepository, BlacklistRepository, BoundariesRepository, ClientsRepository, CountriesRepository, DeactivationsRepository, DeviceBehaviorsRepository, DevicesRepository, FirmwaresRepository, NotificationRecipientsRepository, PositionRepository, SecurityRepository, TripRepository, UserActivationsRepository, UserAppFeedbackRepository, UserAppIncidentsRepository, UserConfigurationsRepository, UserDataDeletionRequestsRepository, UserInvitationsRepository, UserRatingRequestsRepository, UserRegistrationAttemptsRepository, UsersRepository, };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export interface GetAempTokensParams {
|
|
2
|
+
filters: {
|
|
3
|
+
clientId?: number;
|
|
4
|
+
token?: string;
|
|
5
|
+
};
|
|
6
|
+
}
|
|
7
|
+
export interface CreateAempTokenParams {
|
|
8
|
+
id?: number;
|
|
9
|
+
clientId: number;
|
|
10
|
+
token: string;
|
|
11
|
+
expiresAt?: Date;
|
|
12
|
+
}
|
|
13
|
+
export interface DeleteAempTokensParams {
|
|
14
|
+
filters: {
|
|
15
|
+
id?: number;
|
|
16
|
+
clientId?: number;
|
|
17
|
+
token?: string;
|
|
18
|
+
};
|
|
19
|
+
}
|
package/dist/types/billing.d.ts
CHANGED
|
@@ -227,3 +227,34 @@ export interface CreateBillingHubspotPaymentLogParams {
|
|
|
227
227
|
totalTaxes?: number | null;
|
|
228
228
|
updatedByUserId?: string | null;
|
|
229
229
|
}
|
|
230
|
+
export interface UpsertBillingKlarnaCustomerParams {
|
|
231
|
+
id: string;
|
|
232
|
+
firstName?: string | null;
|
|
233
|
+
lastName?: string | null;
|
|
234
|
+
billingEmail?: string | null;
|
|
235
|
+
shippingEmail?: string | null;
|
|
236
|
+
streetAddress?: string | null;
|
|
237
|
+
city?: string | null;
|
|
238
|
+
region?: string | null;
|
|
239
|
+
country?: string | null;
|
|
240
|
+
postalCode?: string | null;
|
|
241
|
+
phone?: string | null;
|
|
242
|
+
createdAt?: Date | null;
|
|
243
|
+
}
|
|
244
|
+
export interface UpsertBillingKlarnaOrderParams {
|
|
245
|
+
id: string;
|
|
246
|
+
klarnaCustomerId: string;
|
|
247
|
+
planId?: string | null;
|
|
248
|
+
createdAt?: Date | null;
|
|
249
|
+
subscriptionStart?: Date | null;
|
|
250
|
+
subscriptionEnd?: Date | null;
|
|
251
|
+
nextBillingDate?: Date | null;
|
|
252
|
+
subscriptionValue?: number | null;
|
|
253
|
+
status?: string | null;
|
|
254
|
+
paymentType?: string | null;
|
|
255
|
+
discounts?: object | null;
|
|
256
|
+
addons?: object | null;
|
|
257
|
+
nextBillingPeriodAmount?: number | null;
|
|
258
|
+
paymentMethodToken?: string | null;
|
|
259
|
+
deviceId?: string | null;
|
|
260
|
+
}
|