@use-stall/types 0.1.6 → 0.1.7
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/index.d.ts +0 -1
- package/package.json +1 -1
- package/src/connectors.d.ts +1 -0
- package/src/cloud-connectors.d.ts +0 -68
package/index.d.ts
CHANGED
package/package.json
CHANGED
package/src/connectors.d.ts
CHANGED
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
// These are the types for the cloud connectors that will power the users app per location.
|
|
2
|
-
// Each Location will have logs
|
|
3
|
-
//When creating a custom connector user must provider for all actions
|
|
4
|
-
|
|
5
|
-
type ModuleKey =
|
|
6
|
-
| "products"
|
|
7
|
-
| "variants"
|
|
8
|
-
| "collections"
|
|
9
|
-
| "categories"
|
|
10
|
-
| "tags"
|
|
11
|
-
| "inventory_levels" // For products with stock tracking
|
|
12
|
-
| "inventory_history" // History of inventory levels at a specific point in time
|
|
13
|
-
| "coupons"
|
|
14
|
-
| "gift_cards"
|
|
15
|
-
| "orders"
|
|
16
|
-
| "order_notes" // Activities related to order
|
|
17
|
-
| "refunds" // Activities related to refunds
|
|
18
|
-
| "payment_providers"
|
|
19
|
-
| "payments" // Create, Read, Update, Delete, Webhooks
|
|
20
|
-
| "receipts" // These are not tax invoices but rather and indication of a successful payment
|
|
21
|
-
| "tax_regions" // can be tax class or groups in other data sources
|
|
22
|
-
| "tax_rates"
|
|
23
|
-
| "customers"
|
|
24
|
-
| "locations" // Can be stock locations, warehouses, or any other location-related data
|
|
25
|
-
| "sessions_tracking" // This will be used for cash tracking and tracking the POS/Flex user
|
|
26
|
-
| "fulfillment_types" // Like delivery, pickup, etc.
|
|
27
|
-
| "fulfillment_providers" // Providers third party or custom like DHL, FedEx, UPS, etc.
|
|
28
|
-
| "fulfillments"; // Individual fulfillment instances for an order
|
|
29
|
-
|
|
30
|
-
export interface ConnectorModulesType {
|
|
31
|
-
[key in ModuleKey]: {
|
|
32
|
-
supported: boolean;
|
|
33
|
-
actions: {
|
|
34
|
-
create: boolean;
|
|
35
|
-
read: boolean;
|
|
36
|
-
update: boolean;
|
|
37
|
-
delete: boolean;
|
|
38
|
-
};
|
|
39
|
-
};
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
export interface ConnectorType {
|
|
43
|
-
id: string;
|
|
44
|
-
version: string;
|
|
45
|
-
name: string;
|
|
46
|
-
description: string;
|
|
47
|
-
logo: string;
|
|
48
|
-
modules: ConnectorModulesType;
|
|
49
|
-
authentication: {
|
|
50
|
-
type: "basic" | "bearer" | "api_key" | "none";
|
|
51
|
-
ttl_type: "permanent" | "session";
|
|
52
|
-
ttl_value: number; // TTL value in minutes
|
|
53
|
-
};
|
|
54
|
-
integration_url: string; // Where to redirect the users to connect their account
|
|
55
|
-
integration_docs: string; // Where to redirect the users to learn how to connect their account
|
|
56
|
-
active: boolean;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
export interface ConnectorConfigurationType {
|
|
60
|
-
connector_id: string;
|
|
61
|
-
configuration: {
|
|
62
|
-
username: string; // For basic authentication
|
|
63
|
-
password: string; // For basic authentication
|
|
64
|
-
token: string; // For bearer authentication
|
|
65
|
-
api_key_header: string; // For API key authentication or Custom header
|
|
66
|
-
api_key_value: string; // For API key authentication or Custom header
|
|
67
|
-
};
|
|
68
|
-
}
|