arky-sdk 0.7.68 → 0.7.71
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/index.cjs +1 -22
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -40
- package/dist/index.d.ts +4 -40
- package/dist/index.js +1 -22
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -21,8 +21,6 @@ interface HttpClientConfig {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
interface AnalyticsSummary {
|
|
24
|
-
revenue: number;
|
|
25
|
-
revenueChange: number;
|
|
26
24
|
orders: number;
|
|
27
25
|
ordersChange: number;
|
|
28
26
|
bookings: number;
|
|
@@ -31,27 +29,8 @@ interface AnalyticsSummary {
|
|
|
31
29
|
newCustomersChange: number;
|
|
32
30
|
formSubmissions: number;
|
|
33
31
|
formSubmissionsChange: number;
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
activeProviders: number;
|
|
37
|
-
}
|
|
38
|
-
interface TimeSeriesPoint {
|
|
39
|
-
date: string;
|
|
40
|
-
value: number;
|
|
41
|
-
}
|
|
42
|
-
interface TimeSeriesResponse {
|
|
43
|
-
period: {
|
|
44
|
-
start: string;
|
|
45
|
-
end: string;
|
|
46
|
-
};
|
|
47
|
-
interval: string;
|
|
48
|
-
series: Record<string, TimeSeriesPoint[]>;
|
|
49
|
-
}
|
|
50
|
-
interface TopEntity {
|
|
51
|
-
entityId: string;
|
|
52
|
-
label: string;
|
|
53
|
-
count: number;
|
|
54
|
-
revenue: number;
|
|
32
|
+
reactions: number;
|
|
33
|
+
reactionsChange: number;
|
|
55
34
|
}
|
|
56
35
|
interface StatusBreakdown {
|
|
57
36
|
status: string;
|
|
@@ -186,7 +165,7 @@ declare global {
|
|
|
186
165
|
}
|
|
187
166
|
declare function track(eventName: string, params?: Record<string, any>): void;
|
|
188
167
|
|
|
189
|
-
declare const SDK_VERSION = "0.7.
|
|
168
|
+
declare const SDK_VERSION = "0.7.71";
|
|
190
169
|
declare const SUPPORTED_FRAMEWORKS: readonly ["astro", "react", "vue", "svelte", "vanilla"];
|
|
191
170
|
interface ApiConfig {
|
|
192
171
|
httpClient: any;
|
|
@@ -465,25 +444,10 @@ declare function createAdmin(config: HttpClientConfig & {
|
|
|
465
444
|
analytics: {
|
|
466
445
|
track: typeof track;
|
|
467
446
|
getSummary: (params?: {
|
|
468
|
-
market?: string;
|
|
469
447
|
period?: string;
|
|
470
448
|
}, options?: RequestOptions) => Promise<AnalyticsSummary>;
|
|
471
|
-
getSeries: (params: {
|
|
472
|
-
metrics: string[];
|
|
473
|
-
market?: string;
|
|
474
|
-
period?: string;
|
|
475
|
-
interval?: string;
|
|
476
|
-
}, options?: RequestOptions) => Promise<TimeSeriesResponse>;
|
|
477
|
-
getTopEntities: (params: {
|
|
478
|
-
entity: string;
|
|
479
|
-
market?: string;
|
|
480
|
-
period?: string;
|
|
481
|
-
limit?: number;
|
|
482
|
-
}, options?: RequestOptions) => Promise<TopEntity[]>;
|
|
483
449
|
getStatusBreakdown: (params: {
|
|
484
450
|
entity: string;
|
|
485
|
-
market?: string;
|
|
486
|
-
period?: string;
|
|
487
451
|
}, options?: RequestOptions) => Promise<StatusBreakdown[]>;
|
|
488
452
|
};
|
|
489
453
|
setBusinessId: (businessId: string) => void;
|
|
@@ -751,4 +715,4 @@ declare function createStorefront(config: HttpClientConfig & {
|
|
|
751
715
|
};
|
|
752
716
|
}>;
|
|
753
717
|
|
|
754
|
-
export { type AnalyticsSummary, type ApiConfig, AvailabilityResponse, Block, CreateAgentParams, CreateLocationParams, type CreateReactionParams, DEFAULT_REACTION_KINDS, DeleteLocationParams, type EngagementSummary, type EngagementSummaryParams, type FindReactionsParams, GetAgentParams, GetAgentsParams, GetAvailabilityParams, type GetCountriesResponse, type GetReactionParams, GetShippingRatesParams, type HttpClientConfig, Location, type LocationCountry, type LocationState, Market, type ModerateReactionParams, REACTION_KIND_REGEX, type Reaction, type ReactionStatus, type ReactionTarget, type ReactionTargetType, SDK_VERSION, SUPPORTED_FRAMEWORKS, ShipParams, ShipResult, ShippingRate, Slot, type StatusBreakdown,
|
|
718
|
+
export { type AnalyticsSummary, type ApiConfig, AvailabilityResponse, Block, CreateAgentParams, CreateLocationParams, type CreateReactionParams, DEFAULT_REACTION_KINDS, DeleteLocationParams, type EngagementSummary, type EngagementSummaryParams, type FindReactionsParams, GetAgentParams, GetAgentsParams, GetAvailabilityParams, type GetCountriesResponse, type GetReactionParams, GetShippingRatesParams, type HttpClientConfig, Location, type LocationCountry, type LocationState, Market, type ModerateReactionParams, REACTION_KIND_REGEX, type Reaction, type ReactionStatus, type ReactionTarget, type ReactionTargetType, SDK_VERSION, SUPPORTED_FRAMEWORKS, ShipParams, ShipResult, ShippingRate, Slot, type StatusBreakdown, UpdateAgentParams, UpdateLocationParams, type UpdateReactionParams, computeAverageStars, createAdmin, createStorefront, isValidReactionKind };
|
package/dist/index.d.ts
CHANGED
|
@@ -21,8 +21,6 @@ interface HttpClientConfig {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
interface AnalyticsSummary {
|
|
24
|
-
revenue: number;
|
|
25
|
-
revenueChange: number;
|
|
26
24
|
orders: number;
|
|
27
25
|
ordersChange: number;
|
|
28
26
|
bookings: number;
|
|
@@ -31,27 +29,8 @@ interface AnalyticsSummary {
|
|
|
31
29
|
newCustomersChange: number;
|
|
32
30
|
formSubmissions: number;
|
|
33
31
|
formSubmissionsChange: number;
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
activeProviders: number;
|
|
37
|
-
}
|
|
38
|
-
interface TimeSeriesPoint {
|
|
39
|
-
date: string;
|
|
40
|
-
value: number;
|
|
41
|
-
}
|
|
42
|
-
interface TimeSeriesResponse {
|
|
43
|
-
period: {
|
|
44
|
-
start: string;
|
|
45
|
-
end: string;
|
|
46
|
-
};
|
|
47
|
-
interval: string;
|
|
48
|
-
series: Record<string, TimeSeriesPoint[]>;
|
|
49
|
-
}
|
|
50
|
-
interface TopEntity {
|
|
51
|
-
entityId: string;
|
|
52
|
-
label: string;
|
|
53
|
-
count: number;
|
|
54
|
-
revenue: number;
|
|
32
|
+
reactions: number;
|
|
33
|
+
reactionsChange: number;
|
|
55
34
|
}
|
|
56
35
|
interface StatusBreakdown {
|
|
57
36
|
status: string;
|
|
@@ -186,7 +165,7 @@ declare global {
|
|
|
186
165
|
}
|
|
187
166
|
declare function track(eventName: string, params?: Record<string, any>): void;
|
|
188
167
|
|
|
189
|
-
declare const SDK_VERSION = "0.7.
|
|
168
|
+
declare const SDK_VERSION = "0.7.71";
|
|
190
169
|
declare const SUPPORTED_FRAMEWORKS: readonly ["astro", "react", "vue", "svelte", "vanilla"];
|
|
191
170
|
interface ApiConfig {
|
|
192
171
|
httpClient: any;
|
|
@@ -465,25 +444,10 @@ declare function createAdmin(config: HttpClientConfig & {
|
|
|
465
444
|
analytics: {
|
|
466
445
|
track: typeof track;
|
|
467
446
|
getSummary: (params?: {
|
|
468
|
-
market?: string;
|
|
469
447
|
period?: string;
|
|
470
448
|
}, options?: RequestOptions) => Promise<AnalyticsSummary>;
|
|
471
|
-
getSeries: (params: {
|
|
472
|
-
metrics: string[];
|
|
473
|
-
market?: string;
|
|
474
|
-
period?: string;
|
|
475
|
-
interval?: string;
|
|
476
|
-
}, options?: RequestOptions) => Promise<TimeSeriesResponse>;
|
|
477
|
-
getTopEntities: (params: {
|
|
478
|
-
entity: string;
|
|
479
|
-
market?: string;
|
|
480
|
-
period?: string;
|
|
481
|
-
limit?: number;
|
|
482
|
-
}, options?: RequestOptions) => Promise<TopEntity[]>;
|
|
483
449
|
getStatusBreakdown: (params: {
|
|
484
450
|
entity: string;
|
|
485
|
-
market?: string;
|
|
486
|
-
period?: string;
|
|
487
451
|
}, options?: RequestOptions) => Promise<StatusBreakdown[]>;
|
|
488
452
|
};
|
|
489
453
|
setBusinessId: (businessId: string) => void;
|
|
@@ -751,4 +715,4 @@ declare function createStorefront(config: HttpClientConfig & {
|
|
|
751
715
|
};
|
|
752
716
|
}>;
|
|
753
717
|
|
|
754
|
-
export { type AnalyticsSummary, type ApiConfig, AvailabilityResponse, Block, CreateAgentParams, CreateLocationParams, type CreateReactionParams, DEFAULT_REACTION_KINDS, DeleteLocationParams, type EngagementSummary, type EngagementSummaryParams, type FindReactionsParams, GetAgentParams, GetAgentsParams, GetAvailabilityParams, type GetCountriesResponse, type GetReactionParams, GetShippingRatesParams, type HttpClientConfig, Location, type LocationCountry, type LocationState, Market, type ModerateReactionParams, REACTION_KIND_REGEX, type Reaction, type ReactionStatus, type ReactionTarget, type ReactionTargetType, SDK_VERSION, SUPPORTED_FRAMEWORKS, ShipParams, ShipResult, ShippingRate, Slot, type StatusBreakdown,
|
|
718
|
+
export { type AnalyticsSummary, type ApiConfig, AvailabilityResponse, Block, CreateAgentParams, CreateLocationParams, type CreateReactionParams, DEFAULT_REACTION_KINDS, DeleteLocationParams, type EngagementSummary, type EngagementSummaryParams, type FindReactionsParams, GetAgentParams, GetAgentsParams, GetAvailabilityParams, type GetCountriesResponse, type GetReactionParams, GetShippingRatesParams, type HttpClientConfig, Location, type LocationCountry, type LocationState, Market, type ModerateReactionParams, REACTION_KIND_REGEX, type Reaction, type ReactionStatus, type ReactionTarget, type ReactionTargetType, SDK_VERSION, SUPPORTED_FRAMEWORKS, ShipParams, ShipResult, ShippingRate, Slot, type StatusBreakdown, UpdateAgentParams, UpdateLocationParams, type UpdateReactionParams, computeAverageStars, createAdmin, createStorefront, isValidReactionKind };
|
package/dist/index.js
CHANGED
|
@@ -1913,25 +1913,6 @@ var createAnalyticsApi = (apiConfig) => {
|
|
|
1913
1913
|
}
|
|
1914
1914
|
);
|
|
1915
1915
|
},
|
|
1916
|
-
async getSeries(params, options) {
|
|
1917
|
-
const { metrics, ...rest } = params;
|
|
1918
|
-
return apiConfig.httpClient.get(
|
|
1919
|
-
`/v1/businesses/${apiConfig.businessId}/analytics/series`,
|
|
1920
|
-
{
|
|
1921
|
-
...options,
|
|
1922
|
-
params: { ...rest, metrics: metrics.join(",") }
|
|
1923
|
-
}
|
|
1924
|
-
);
|
|
1925
|
-
},
|
|
1926
|
-
async getTopEntities(params, options) {
|
|
1927
|
-
return apiConfig.httpClient.get(
|
|
1928
|
-
`/v1/businesses/${apiConfig.businessId}/analytics/top`,
|
|
1929
|
-
{
|
|
1930
|
-
...options,
|
|
1931
|
-
params
|
|
1932
|
-
}
|
|
1933
|
-
);
|
|
1934
|
-
},
|
|
1935
1916
|
async getStatusBreakdown(params, options) {
|
|
1936
1917
|
return apiConfig.httpClient.get(
|
|
1937
1918
|
`/v1/businesses/${apiConfig.businessId}/analytics/status`,
|
|
@@ -2790,7 +2771,7 @@ function getFirstAvailableFCId(variant, quantity = 1) {
|
|
|
2790
2771
|
}
|
|
2791
2772
|
|
|
2792
2773
|
// src/index.ts
|
|
2793
|
-
var SDK_VERSION = "0.7.
|
|
2774
|
+
var SDK_VERSION = "0.7.71";
|
|
2794
2775
|
var SUPPORTED_FRAMEWORKS = [
|
|
2795
2776
|
"astro",
|
|
2796
2777
|
"react",
|
|
@@ -3030,8 +3011,6 @@ async function createAdmin(config) {
|
|
|
3030
3011
|
analytics: {
|
|
3031
3012
|
track,
|
|
3032
3013
|
getSummary: analyticsApi.getSummary,
|
|
3033
|
-
getSeries: analyticsApi.getSeries,
|
|
3034
|
-
getTopEntities: analyticsApi.getTopEntities,
|
|
3035
3014
|
getStatusBreakdown: analyticsApi.getStatusBreakdown
|
|
3036
3015
|
},
|
|
3037
3016
|
setBusinessId: (businessId) => {
|