@pikku/addon-woocommerce 0.0.2
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/README.md +12 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.d.ts +67 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.d.ts.map +1 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.js +78 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.js.map +1 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.ts +106 -0
- package/dist/.pikku/addon/pikku-package.gen.d.ts +2 -0
- package/dist/.pikku/addon/pikku-package.gen.d.ts.map +1 -0
- package/dist/.pikku/addon/pikku-package.gen.js +10 -0
- package/dist/.pikku/addon/pikku-package.gen.js.map +1 -0
- package/dist/.pikku/addon/pikku-package.gen.ts +11 -0
- package/dist/.pikku/agent/pikku-agent-map.gen.d.ts +4 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.d.ts +47 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.d.ts.map +1 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.js +18 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.js.map +1 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.ts +82 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.d.ts +112 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.d.ts.map +1 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.js +60 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.js.map +1 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.ts +177 -0
- package/dist/.pikku/console/pikku-node-types.gen.d.ts +7 -0
- package/dist/.pikku/console/pikku-node-types.gen.d.ts.map +1 -0
- package/dist/.pikku/console/pikku-node-types.gen.js +2 -0
- package/dist/.pikku/console/pikku-node-types.gen.js.map +1 -0
- package/dist/.pikku/console/pikku-node-types.gen.ts +8 -0
- package/dist/.pikku/credentials/pikku-credentials-meta.gen.json +10 -0
- package/dist/.pikku/credentials/pikku-credentials.gen.d.ts +15 -0
- package/dist/.pikku/credentials/pikku-credentials.gen.d.ts.map +1 -0
- package/dist/.pikku/credentials/pikku-credentials.gen.js +13 -0
- package/dist/.pikku/credentials/pikku-credentials.gen.js.map +1 -0
- package/dist/.pikku/credentials/pikku-credentials.gen.ts +23 -0
- package/dist/.pikku/function/pikku-function-types.gen.d.ts +490 -0
- package/dist/.pikku/function/pikku-function-types.gen.d.ts.map +1 -0
- package/dist/.pikku/function/pikku-function-types.gen.js +334 -0
- package/dist/.pikku/function/pikku-function-types.gen.js.map +1 -0
- package/dist/.pikku/function/pikku-function-types.gen.ts +754 -0
- package/dist/.pikku/function/pikku-functions-meta-verbose.gen.json +437 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.d.ts +2 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.d.ts.map +1 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.js +7 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.js.map +1 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.json +287 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.ts +7 -0
- package/dist/.pikku/function/pikku-functions.gen.d.ts +2 -0
- package/dist/.pikku/function/pikku-functions.gen.d.ts.map +1 -0
- package/dist/.pikku/function/pikku-functions.gen.js +36 -0
- package/dist/.pikku/function/pikku-functions.gen.js.map +1 -0
- package/dist/.pikku/function/pikku-functions.gen.ts +36 -0
- package/dist/.pikku/http/pikku-http-types.gen.d.ts +120 -0
- package/dist/.pikku/http/pikku-http-types.gen.d.ts.map +1 -0
- package/dist/.pikku/http/pikku-http-types.gen.js +72 -0
- package/dist/.pikku/http/pikku-http-types.gen.js.map +1 -0
- package/dist/.pikku/http/pikku-http-types.gen.ts +147 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts +131 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts.map +1 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.js +38 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.js.map +1 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.ts +183 -0
- package/dist/.pikku/pikku-bootstrap.gen.d.ts +9 -0
- package/dist/.pikku/pikku-bootstrap.gen.d.ts.map +1 -0
- package/dist/.pikku/pikku-bootstrap.gen.js +9 -0
- package/dist/.pikku/pikku-bootstrap.gen.js.map +1 -0
- package/dist/.pikku/pikku-bootstrap.gen.ts +8 -0
- package/dist/.pikku/pikku-meta-service.gen.d.ts +8 -0
- package/dist/.pikku/pikku-meta-service.gen.d.ts.map +1 -0
- package/dist/.pikku/pikku-meta-service.gen.js +10 -0
- package/dist/.pikku/pikku-meta-service.gen.js.map +1 -0
- package/dist/.pikku/pikku-meta-service.gen.ts +10 -0
- package/dist/.pikku/pikku-services.gen.d.ts +35 -0
- package/dist/.pikku/pikku-services.gen.d.ts.map +1 -0
- package/dist/.pikku/pikku-services.gen.js +30 -0
- package/dist/.pikku/pikku-services.gen.js.map +1 -0
- package/dist/.pikku/pikku-services.gen.ts +42 -0
- package/dist/.pikku/pikku-types.gen.d.ts +12 -0
- package/dist/.pikku/pikku-types.gen.d.ts.map +1 -0
- package/dist/.pikku/pikku-types.gen.js +17 -0
- package/dist/.pikku/pikku-types.gen.js.map +1 -0
- package/dist/.pikku/pikku-types.gen.ts +21 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.d.ts +24 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.d.ts.map +1 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.js +17 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.js.map +1 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.ts +27 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +209 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +224 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.d.ts +2 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.d.ts.map +1 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js +7 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js.map +1 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.json +17 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts +6 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts +22 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts.map +1 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js +17 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js.map +1 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.ts +25 -0
- package/dist/.pikku/schemas/register.gen.d.ts +2 -0
- package/dist/.pikku/schemas/register.gen.d.ts.map +1 -0
- package/dist/.pikku/schemas/register.gen.js +69 -0
- package/dist/.pikku/schemas/register.gen.js.map +1 -0
- package/dist/.pikku/schemas/register.gen.ts +131 -0
- package/dist/.pikku/schemas/schemas/CredentialSchema_woocommerce.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerCreateInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerCreateOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerDeleteInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerDeleteOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerGetAllInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerGetAllOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerGetInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerGetOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerUpdateInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/CustomerUpdateOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderCreateInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderCreateOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderDeleteInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderDeleteOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderGetAllInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderGetAllOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderGetInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderGetOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderUpdateInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OrderUpdateOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductCreateInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductCreateOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductDeleteInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductDeleteOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductGetAllInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductGetAllOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductGetInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductGetOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductUpdateInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/ProductUpdateOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/VariableSchema_WOOCOMMERCE_BASE_URL.schema.json +1 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts +6 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts.map +1 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.js +5 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.js.map +1 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.ts +5 -0
- package/dist/.pikku/secrets/pikku-secrets-meta.gen.json +1 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.d.ts +12 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.d.ts.map +1 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.js +11 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.js.map +1 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.ts +21 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.d.ts +114 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.d.ts.map +1 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.js +34 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.js.map +1 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.ts +160 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.d.ts +6 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.d.ts.map +1 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.js +5 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.js.map +1 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.ts +5 -0
- package/dist/.pikku/variables/pikku-variables-meta.gen.json +10 -0
- package/dist/.pikku/variables/pikku-variables.gen.d.ts +15 -0
- package/dist/.pikku/variables/pikku-variables.gen.d.ts.map +1 -0
- package/dist/.pikku/variables/pikku-variables.gen.js +13 -0
- package/dist/.pikku/variables/pikku-variables.gen.js.map +1 -0
- package/dist/.pikku/variables/pikku-variables.gen.ts +23 -0
- package/dist/.pikku/workflow/pikku-workflow-map.gen.d.ts +38 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts +90 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.js +18 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.js.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.ts +167 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.d.ts +2 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.d.ts.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js +7 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.ts +9 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.d.ts +5 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.d.ts.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js +5 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.ts +3 -0
- package/dist/src/functions/customerCreate.function.d.ts +37 -0
- package/dist/src/functions/customerCreate.function.d.ts.map +1 -0
- package/dist/src/functions/customerCreate.function.js +21 -0
- package/dist/src/functions/customerCreate.function.js.map +1 -0
- package/dist/src/functions/customerDelete.function.d.ts +21 -0
- package/dist/src/functions/customerDelete.function.d.ts.map +1 -0
- package/dist/src/functions/customerDelete.function.js +17 -0
- package/dist/src/functions/customerDelete.function.js.map +1 -0
- package/dist/src/functions/customerGet.function.d.ts +25 -0
- package/dist/src/functions/customerGet.function.d.ts.map +1 -0
- package/dist/src/functions/customerGet.function.js +18 -0
- package/dist/src/functions/customerGet.function.js.map +1 -0
- package/dist/src/functions/customerGetAll.function.d.ts +17 -0
- package/dist/src/functions/customerGetAll.function.d.ts.map +1 -0
- package/dist/src/functions/customerGetAll.function.js +16 -0
- package/dist/src/functions/customerGetAll.function.js.map +1 -0
- package/dist/src/functions/customerUpdate.function.d.ts +29 -0
- package/dist/src/functions/customerUpdate.function.d.ts.map +1 -0
- package/dist/src/functions/customerUpdate.function.js +19 -0
- package/dist/src/functions/customerUpdate.function.js.map +1 -0
- package/dist/src/functions/orderCreate.function.d.ts +29 -0
- package/dist/src/functions/orderCreate.function.d.ts.map +1 -0
- package/dist/src/functions/orderCreate.function.js +19 -0
- package/dist/src/functions/orderCreate.function.js.map +1 -0
- package/dist/src/functions/orderDelete.function.d.ts +21 -0
- package/dist/src/functions/orderDelete.function.d.ts.map +1 -0
- package/dist/src/functions/orderDelete.function.js +17 -0
- package/dist/src/functions/orderDelete.function.js.map +1 -0
- package/dist/src/functions/orderGet.function.d.ts +21 -0
- package/dist/src/functions/orderGet.function.d.ts.map +1 -0
- package/dist/src/functions/orderGet.function.js +17 -0
- package/dist/src/functions/orderGet.function.js.map +1 -0
- package/dist/src/functions/orderGetAll.function.d.ts +17 -0
- package/dist/src/functions/orderGetAll.function.d.ts.map +1 -0
- package/dist/src/functions/orderGetAll.function.js +16 -0
- package/dist/src/functions/orderGetAll.function.js.map +1 -0
- package/dist/src/functions/orderUpdate.function.d.ts +25 -0
- package/dist/src/functions/orderUpdate.function.d.ts.map +1 -0
- package/dist/src/functions/orderUpdate.function.js +18 -0
- package/dist/src/functions/orderUpdate.function.js.map +1 -0
- package/dist/src/functions/productCreate.function.d.ts +37 -0
- package/dist/src/functions/productCreate.function.d.ts.map +1 -0
- package/dist/src/functions/productCreate.function.js +21 -0
- package/dist/src/functions/productCreate.function.js.map +1 -0
- package/dist/src/functions/productDelete.function.d.ts +21 -0
- package/dist/src/functions/productDelete.function.d.ts.map +1 -0
- package/dist/src/functions/productDelete.function.js +17 -0
- package/dist/src/functions/productDelete.function.js.map +1 -0
- package/dist/src/functions/productGet.function.d.ts +25 -0
- package/dist/src/functions/productGet.function.d.ts.map +1 -0
- package/dist/src/functions/productGet.function.js +18 -0
- package/dist/src/functions/productGet.function.js.map +1 -0
- package/dist/src/functions/productGetAll.function.d.ts +17 -0
- package/dist/src/functions/productGetAll.function.d.ts.map +1 -0
- package/dist/src/functions/productGetAll.function.js +16 -0
- package/dist/src/functions/productGetAll.function.js.map +1 -0
- package/dist/src/functions/productUpdate.function.d.ts +29 -0
- package/dist/src/functions/productUpdate.function.d.ts.map +1 -0
- package/dist/src/functions/productUpdate.function.js +19 -0
- package/dist/src/functions/productUpdate.function.js.map +1 -0
- package/dist/src/index.d.ts +16 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/index.js +16 -0
- package/dist/src/index.js.map +1 -0
- package/dist/src/services.d.ts +2 -0
- package/dist/src/services.d.ts.map +1 -0
- package/dist/src/services.js +14 -0
- package/dist/src/services.js.map +1 -0
- package/dist/src/woocommerce-api.service.d.ts +10 -0
- package/dist/src/woocommerce-api.service.d.ts.map +1 -0
- package/dist/src/woocommerce-api.service.js +177 -0
- package/dist/src/woocommerce-api.service.js.map +1 -0
- package/dist/src/woocommerce.credential.d.ts +5 -0
- package/dist/src/woocommerce.credential.d.ts.map +1 -0
- package/dist/src/woocommerce.credential.js +13 -0
- package/dist/src/woocommerce.credential.js.map +1 -0
- package/dist/src/woocommerce.types.d.ts +7 -0
- package/dist/src/woocommerce.types.d.ts.map +1 -0
- package/dist/src/woocommerce.types.js +8 -0
- package/dist/src/woocommerce.types.js.map +1 -0
- package/dist/src/woocommerce.variable.d.ts +5 -0
- package/dist/src/woocommerce.variable.d.ts.map +1 -0
- package/dist/src/woocommerce.variable.js +11 -0
- package/dist/src/woocommerce.variable.js.map +1 -0
- package/package.json +39 -0
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.54
|
|
3
|
+
*/
|
|
4
|
+
import { WorkflowCancelledException } from '@pikku/core/workflow'
|
|
5
|
+
import { template } from '@pikku/core/workflow'
|
|
6
|
+
import {
|
|
7
|
+
pikkuWorkflowGraph as corePikkuWorkflowGraph,
|
|
8
|
+
type PikkuWorkflowGraphConfig,
|
|
9
|
+
type PikkuWorkflowGraphResult,
|
|
10
|
+
} from '@pikku/core/workflow'
|
|
11
|
+
import type { PikkuWorkflowWire, WorkflowStepOptions } from '@pikku/core/workflow'
|
|
12
|
+
|
|
13
|
+
export { WorkflowCancelledException }
|
|
14
|
+
import type { PikkuFunctionSessionless, PikkuFunctionConfig } from '../function/pikku-function-types.gen.js'
|
|
15
|
+
import type { FlattenedRPCMap } from '../rpc/pikku-rpc-wirings-map.internal.gen.d.js'
|
|
16
|
+
import type { FlattenedWorkflowMap } from './pikku-workflow-map.gen.d.js'
|
|
17
|
+
|
|
18
|
+
export { template }
|
|
19
|
+
|
|
20
|
+
export interface TypedWorkflow extends PikkuWorkflowWire {
|
|
21
|
+
do<K extends keyof FlattenedRPCMap>(
|
|
22
|
+
stepName: string,
|
|
23
|
+
rpcName: K,
|
|
24
|
+
data: FlattenedRPCMap[K]['input'],
|
|
25
|
+
options?: WorkflowStepOptions
|
|
26
|
+
): Promise<FlattenedRPCMap[K]['output']>
|
|
27
|
+
|
|
28
|
+
do<K extends keyof FlattenedWorkflowMap>(
|
|
29
|
+
stepName: string,
|
|
30
|
+
workflowName: K,
|
|
31
|
+
data: FlattenedWorkflowMap[K]['input'],
|
|
32
|
+
options?: WorkflowStepOptions
|
|
33
|
+
): Promise<FlattenedWorkflowMap[K]['output']>
|
|
34
|
+
|
|
35
|
+
do<T>(
|
|
36
|
+
stepName: string,
|
|
37
|
+
fn: () => T | Promise<T>,
|
|
38
|
+
options?: WorkflowStepOptions
|
|
39
|
+
): Promise<T>
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
import type { StandardSchemaV1 } from '@standard-schema/spec'
|
|
43
|
+
import type { InferSchemaOutput, PikkuPermission, PikkuMiddleware, NodeConfig, PikkuApprovalDescription } from '../function/pikku-function-types.gen.js'
|
|
44
|
+
import { PikkuError } from '@pikku/core/errors'
|
|
45
|
+
import type { CorePermissionGroup } from '@pikku/core'
|
|
46
|
+
|
|
47
|
+
export type PikkuFunctionWorkflow<
|
|
48
|
+
In = unknown,
|
|
49
|
+
Out = never
|
|
50
|
+
> = PikkuFunctionSessionless<In, Out, 'workflow'>
|
|
51
|
+
|
|
52
|
+
export type PikkuWorkflowConfigWithSchema<
|
|
53
|
+
InputSchema extends StandardSchemaV1 | undefined = undefined,
|
|
54
|
+
OutputSchema extends StandardSchemaV1 | undefined = undefined
|
|
55
|
+
> = {
|
|
56
|
+
title?: string
|
|
57
|
+
description?: string
|
|
58
|
+
tags?: string[]
|
|
59
|
+
expose?: boolean
|
|
60
|
+
internal?: boolean
|
|
61
|
+
override?: string
|
|
62
|
+
version?: number
|
|
63
|
+
remote?: boolean
|
|
64
|
+
mcp?: boolean
|
|
65
|
+
readonly?: boolean
|
|
66
|
+
approvalRequired?: boolean
|
|
67
|
+
approvalDescription?: InputSchema extends StandardSchemaV1 ? PikkuApprovalDescription<InferSchemaOutput<InputSchema>> : never
|
|
68
|
+
func: PikkuFunctionWorkflow<
|
|
69
|
+
InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown,
|
|
70
|
+
OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown
|
|
71
|
+
>
|
|
72
|
+
auth?: boolean
|
|
73
|
+
permissions?: InputSchema extends StandardSchemaV1 ? CorePermissionGroup<PikkuPermission<InferSchemaOutput<InputSchema>>> : undefined
|
|
74
|
+
middleware?: PikkuMiddleware[]
|
|
75
|
+
input?: InputSchema
|
|
76
|
+
output?: OutputSchema
|
|
77
|
+
node?: NodeConfig
|
|
78
|
+
errors?: Array<typeof PikkuError>
|
|
79
|
+
inline?: boolean
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export function pikkuWorkflowFunc<
|
|
83
|
+
InputSchema extends StandardSchemaV1 | undefined = undefined,
|
|
84
|
+
OutputSchema extends StandardSchemaV1 | undefined = undefined
|
|
85
|
+
>(
|
|
86
|
+
config: PikkuWorkflowConfigWithSchema<InputSchema, OutputSchema>
|
|
87
|
+
): PikkuFunctionConfig<InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown, OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown, 'workflow', PikkuFunctionWorkflow<InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown, OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown>, InputSchema, OutputSchema>
|
|
88
|
+
export function pikkuWorkflowFunc<In, Out = unknown>(
|
|
89
|
+
func:
|
|
90
|
+
| PikkuFunctionWorkflow<In, Out>
|
|
91
|
+
| PikkuFunctionConfig<In, Out, 'workflow', PikkuFunctionWorkflow<In, Out>>
|
|
92
|
+
): PikkuFunctionConfig<In, Out, 'workflow'>
|
|
93
|
+
export function pikkuWorkflowFunc(func: any) {
|
|
94
|
+
return typeof func === 'function' ? { func } : func
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
export function pikkuWorkflowComplexFunc<
|
|
98
|
+
InputSchema extends StandardSchemaV1 | undefined = undefined,
|
|
99
|
+
OutputSchema extends StandardSchemaV1 | undefined = undefined
|
|
100
|
+
>(
|
|
101
|
+
config: PikkuWorkflowConfigWithSchema<InputSchema, OutputSchema>
|
|
102
|
+
): PikkuFunctionConfig<InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown, OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown, 'workflow', PikkuFunctionWorkflow<InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown, OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown>, InputSchema, OutputSchema>
|
|
103
|
+
export function pikkuWorkflowComplexFunc<In, Out = unknown>(
|
|
104
|
+
func:
|
|
105
|
+
| PikkuFunctionWorkflow<In, Out>
|
|
106
|
+
| PikkuFunctionConfig<In, Out, 'workflow', PikkuFunctionWorkflow<In, Out>>
|
|
107
|
+
): PikkuFunctionConfig<In, Out, 'workflow'>
|
|
108
|
+
export function pikkuWorkflowComplexFunc(func: any) {
|
|
109
|
+
return typeof func === 'function' ? { func } : func
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
type TypedRef<T> = { $ref: string; path?: string } & { __phantomType?: T }
|
|
113
|
+
|
|
114
|
+
type TemplateString = {
|
|
115
|
+
$template: {
|
|
116
|
+
parts: string[]
|
|
117
|
+
expressions: Array<{ $ref: string; path?: string }>
|
|
118
|
+
}
|
|
119
|
+
} & { __brand: 'TemplateString' }
|
|
120
|
+
|
|
121
|
+
type InputWithRefs<T> = {
|
|
122
|
+
[K in keyof T]?: T[K] | TypedRef<T[K]> | TypedRef<unknown> | TemplateString
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
type NodeInputType<FuncMap extends Record<string, string>, K extends keyof FuncMap> =
|
|
126
|
+
FuncMap[K] extends keyof FlattenedRPCMap
|
|
127
|
+
? InputWithRefs<FlattenedRPCMap[FuncMap[K]]['input']>
|
|
128
|
+
: Record<string, unknown>
|
|
129
|
+
|
|
130
|
+
type NodeOutputKeys<FuncMap extends Record<string, string>, N extends string> =
|
|
131
|
+
N extends keyof FuncMap
|
|
132
|
+
? FuncMap[N] extends keyof FlattenedRPCMap
|
|
133
|
+
? keyof FlattenedRPCMap[FuncMap[N]]['output'] & string
|
|
134
|
+
: string
|
|
135
|
+
: string
|
|
136
|
+
|
|
137
|
+
type RefFunction<FuncMap extends Record<string, string>> = {
|
|
138
|
+
<N extends Extract<keyof FuncMap, string>>(
|
|
139
|
+
nodeId: N,
|
|
140
|
+
path: NodeOutputKeys<FuncMap, N>
|
|
141
|
+
): TypedRef<unknown>
|
|
142
|
+
(nodeId: 'trigger' | '$item', path?: string): TypedRef<unknown>
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
type TemplateFunction = (templateStr: string, refs: TypedRef<unknown>[]) => TemplateString
|
|
146
|
+
|
|
147
|
+
type GraphNodeConfigMap<FuncMap extends Record<string, string>> = {
|
|
148
|
+
[K in Extract<keyof FuncMap, string>]?: {
|
|
149
|
+
next?: NextConfig<Extract<keyof FuncMap, string>>
|
|
150
|
+
input?:
|
|
151
|
+
| NodeInputType<FuncMap, K>
|
|
152
|
+
| (() => NodeInputType<FuncMap, K>)
|
|
153
|
+
| ((ref: RefFunction<FuncMap>, template: TemplateFunction) => NodeInputType<FuncMap, K>)
|
|
154
|
+
onError?: Extract<keyof FuncMap, string> | Extract<keyof FuncMap, string>[]
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
type NextConfig<NodeIds extends string> = NodeIds | NodeIds[] | { if: string; then: NodeIds; else?: NodeIds }
|
|
159
|
+
|
|
160
|
+
export function pikkuWorkflowGraph<
|
|
161
|
+
const FuncMap extends Record<string, keyof FlattenedRPCMap & string>
|
|
162
|
+
>(
|
|
163
|
+
config: PikkuWorkflowGraphConfig<FuncMap, GraphNodeConfigMap<FuncMap>>
|
|
164
|
+
): PikkuWorkflowGraphResult {
|
|
165
|
+
return corePikkuWorkflowGraph(config as any)
|
|
166
|
+
}
|
|
167
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-workflow-wirings-meta.gen.d.ts","sourceRoot":"","sources":["../../../.pikku/workflow/pikku-workflow-wirings-meta.gen.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.54
|
|
3
|
+
*/
|
|
4
|
+
import { pikkuState } from '@pikku/core/internal';
|
|
5
|
+
const workflowsMeta = {};
|
|
6
|
+
pikkuState('@pikku/addon-woocommerce', 'workflows', 'meta', workflowsMeta);
|
|
7
|
+
//# sourceMappingURL=pikku-workflow-wirings-meta.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-workflow-wirings-meta.gen.js","sourceRoot":"","sources":["../../../.pikku/workflow/pikku-workflow-wirings-meta.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AAGjD,MAAM,aAAa,GAA6B,EAAE,CAAA;AAElD,UAAU,CAAC,0BAA0B,EAAE,WAAW,EAAE,MAAM,EAAE,aAAa,CAAC,CAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.54
|
|
3
|
+
*/
|
|
4
|
+
import { pikkuState } from '@pikku/core/internal'
|
|
5
|
+
import type { SerializedWorkflowGraphs } from '@pikku/inspector/workflow-graph'
|
|
6
|
+
|
|
7
|
+
const workflowsMeta: SerializedWorkflowGraphs = {}
|
|
8
|
+
|
|
9
|
+
pikkuState('@pikku/addon-woocommerce', 'workflows', 'meta', workflowsMeta)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-workflow-wirings.gen.d.ts","sourceRoot":"","sources":["../../../.pikku/workflow/pikku-workflow-wirings.gen.ts"],"names":[],"mappings":";AAAA;;GAEG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-workflow-wirings.gen.js","sourceRoot":"","sources":["../../../.pikku/workflow/pikku-workflow-wirings.gen.ts"],"names":[],"mappings":";AAAA;;GAEG"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const CustomerCreateInput: z.ZodObject<{
|
|
3
|
+
email: z.ZodOptional<z.ZodString>;
|
|
4
|
+
first_name: z.ZodOptional<z.ZodString>;
|
|
5
|
+
last_name: z.ZodOptional<z.ZodString>;
|
|
6
|
+
username: z.ZodOptional<z.ZodString>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
export declare const CustomerCreateOutput: z.ZodObject<{
|
|
9
|
+
id: z.ZodOptional<z.ZodNumber>;
|
|
10
|
+
email: z.ZodOptional<z.ZodString>;
|
|
11
|
+
}, z.core.$strip>;
|
|
12
|
+
export declare const customerCreate: import("#pikku").PikkuFunctionConfig<{
|
|
13
|
+
email?: string | undefined;
|
|
14
|
+
first_name?: string | undefined;
|
|
15
|
+
last_name?: string | undefined;
|
|
16
|
+
username?: string | undefined;
|
|
17
|
+
}, {
|
|
18
|
+
id?: number | undefined;
|
|
19
|
+
email?: string | undefined;
|
|
20
|
+
}, "rpc" | "session", import("#pikku").PikkuFunctionSessionless<{
|
|
21
|
+
email?: string | undefined;
|
|
22
|
+
first_name?: string | undefined;
|
|
23
|
+
last_name?: string | undefined;
|
|
24
|
+
username?: string | undefined;
|
|
25
|
+
}, {
|
|
26
|
+
id?: number | undefined;
|
|
27
|
+
email?: string | undefined;
|
|
28
|
+
}, "rpc" | "session", import("#pikku").Services> | import("#pikku").PikkuFunction<{
|
|
29
|
+
email?: string | undefined;
|
|
30
|
+
first_name?: string | undefined;
|
|
31
|
+
last_name?: string | undefined;
|
|
32
|
+
username?: string | undefined;
|
|
33
|
+
}, {
|
|
34
|
+
id?: number | undefined;
|
|
35
|
+
email?: string | undefined;
|
|
36
|
+
}, "rpc" | "session", import("#pikku").Services>, undefined, undefined>;
|
|
37
|
+
//# sourceMappingURL=customerCreate.function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerCreate.function.d.ts","sourceRoot":"","sources":["../../../src/functions/customerCreate.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,mBAAmB;;;;;iBAK9B,CAAA;AAEF,eAAO,MAAM,oBAAoB;;;iBAG/B,CAAA;AAEF,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;uEAOzB,CAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { pikkuSessionlessFunc } from '#pikku';
|
|
3
|
+
export const CustomerCreateInput = z.object({
|
|
4
|
+
email: z.string().optional(),
|
|
5
|
+
first_name: z.string().optional(),
|
|
6
|
+
last_name: z.string().optional(),
|
|
7
|
+
username: z.string().optional(),
|
|
8
|
+
});
|
|
9
|
+
export const CustomerCreateOutput = z.object({
|
|
10
|
+
id: z.number().optional(),
|
|
11
|
+
email: z.string().optional(),
|
|
12
|
+
});
|
|
13
|
+
export const customerCreate = pikkuSessionlessFunc({
|
|
14
|
+
description: "Create a customer",
|
|
15
|
+
input: CustomerCreateInput,
|
|
16
|
+
output: CustomerCreateOutput,
|
|
17
|
+
func: async ({ woocommerce }, data) => {
|
|
18
|
+
return woocommerce.call("POST", "/customers", data);
|
|
19
|
+
},
|
|
20
|
+
});
|
|
21
|
+
//# sourceMappingURL=customerCreate.function.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerCreate.function.js","sourceRoot":"","sources":["../../../src/functions/customerCreate.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAA;AAE7C,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC5B,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAChC,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAChC,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3C,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACzB,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC7B,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,oBAAoB,CAAC;IACjD,WAAW,EAAE,mBAAmB;IAChC,KAAK,EAAE,mBAAmB;IAC1B,MAAM,EAAE,oBAAoB;IAC5B,IAAI,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE;QACpC,OAAO,WAAW,CAAC,IAAI,CAAC,MAAM,EAAE,YAAY,EAAE,IAAI,CAAQ,CAAA;IAC5D,CAAC;CACF,CAAC,CAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const CustomerDeleteInput: z.ZodObject<{
|
|
3
|
+
customerId: z.ZodString;
|
|
4
|
+
}, z.core.$strip>;
|
|
5
|
+
export declare const CustomerDeleteOutput: z.ZodObject<{
|
|
6
|
+
id: z.ZodOptional<z.ZodNumber>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
export declare const customerDelete: import("#pikku").PikkuFunctionConfig<{
|
|
9
|
+
customerId: string;
|
|
10
|
+
}, {
|
|
11
|
+
id?: number | undefined;
|
|
12
|
+
}, "rpc" | "session", import("#pikku").PikkuFunctionSessionless<{
|
|
13
|
+
customerId: string;
|
|
14
|
+
}, {
|
|
15
|
+
id?: number | undefined;
|
|
16
|
+
}, "rpc" | "session", import("#pikku").Services> | import("#pikku").PikkuFunction<{
|
|
17
|
+
customerId: string;
|
|
18
|
+
}, {
|
|
19
|
+
id?: number | undefined;
|
|
20
|
+
}, "rpc" | "session", import("#pikku").Services>, undefined, undefined>;
|
|
21
|
+
//# sourceMappingURL=customerDelete.function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerDelete.function.d.ts","sourceRoot":"","sources":["../../../src/functions/customerDelete.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,mBAAmB;;iBAE9B,CAAA;AAEF,eAAO,MAAM,oBAAoB;;iBAE/B,CAAA;AAEF,eAAO,MAAM,cAAc;;;;;;;;;;;;uEAOzB,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { pikkuSessionlessFunc } from '#pikku';
|
|
3
|
+
export const CustomerDeleteInput = z.object({
|
|
4
|
+
customerId: z.string(),
|
|
5
|
+
});
|
|
6
|
+
export const CustomerDeleteOutput = z.object({
|
|
7
|
+
id: z.number().optional(),
|
|
8
|
+
});
|
|
9
|
+
export const customerDelete = pikkuSessionlessFunc({
|
|
10
|
+
description: "Delete a customer",
|
|
11
|
+
input: CustomerDeleteInput,
|
|
12
|
+
output: CustomerDeleteOutput,
|
|
13
|
+
func: async ({ woocommerce }, data) => {
|
|
14
|
+
return woocommerce.call("DELETE", "/customers/{customerId}", data);
|
|
15
|
+
},
|
|
16
|
+
});
|
|
17
|
+
//# sourceMappingURL=customerDelete.function.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerDelete.function.js","sourceRoot":"","sources":["../../../src/functions/customerDelete.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAA;AAE7C,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE;CACvB,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3C,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC1B,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,oBAAoB,CAAC;IACjD,WAAW,EAAE,mBAAmB;IAChC,KAAK,EAAE,mBAAmB;IAC1B,MAAM,EAAE,oBAAoB;IAC5B,IAAI,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE;QACpC,OAAO,WAAW,CAAC,IAAI,CAAC,QAAQ,EAAE,yBAAyB,EAAE,IAAI,CAAQ,CAAA;IAC3E,CAAC;CACF,CAAC,CAAA"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const CustomerGetInput: z.ZodObject<{
|
|
3
|
+
customerId: z.ZodString;
|
|
4
|
+
}, z.core.$strip>;
|
|
5
|
+
export declare const CustomerGetOutput: z.ZodObject<{
|
|
6
|
+
id: z.ZodOptional<z.ZodNumber>;
|
|
7
|
+
email: z.ZodOptional<z.ZodString>;
|
|
8
|
+
}, z.core.$strip>;
|
|
9
|
+
export declare const customerGet: import("#pikku").PikkuFunctionConfig<{
|
|
10
|
+
customerId: string;
|
|
11
|
+
}, {
|
|
12
|
+
id?: number | undefined;
|
|
13
|
+
email?: string | undefined;
|
|
14
|
+
}, "rpc" | "session", import("#pikku").PikkuFunctionSessionless<{
|
|
15
|
+
customerId: string;
|
|
16
|
+
}, {
|
|
17
|
+
id?: number | undefined;
|
|
18
|
+
email?: string | undefined;
|
|
19
|
+
}, "rpc" | "session", import("#pikku").Services> | import("#pikku").PikkuFunction<{
|
|
20
|
+
customerId: string;
|
|
21
|
+
}, {
|
|
22
|
+
id?: number | undefined;
|
|
23
|
+
email?: string | undefined;
|
|
24
|
+
}, "rpc" | "session", import("#pikku").Services>, undefined, undefined>;
|
|
25
|
+
//# sourceMappingURL=customerGet.function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerGet.function.d.ts","sourceRoot":"","sources":["../../../src/functions/customerGet.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,gBAAgB;;iBAE3B,CAAA;AAEF,eAAO,MAAM,iBAAiB;;;iBAG5B,CAAA;AAEF,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;uEAOtB,CAAA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { pikkuSessionlessFunc } from '#pikku';
|
|
3
|
+
export const CustomerGetInput = z.object({
|
|
4
|
+
customerId: z.string(),
|
|
5
|
+
});
|
|
6
|
+
export const CustomerGetOutput = z.object({
|
|
7
|
+
id: z.number().optional(),
|
|
8
|
+
email: z.string().optional(),
|
|
9
|
+
});
|
|
10
|
+
export const customerGet = pikkuSessionlessFunc({
|
|
11
|
+
description: "Get a customer",
|
|
12
|
+
input: CustomerGetInput,
|
|
13
|
+
output: CustomerGetOutput,
|
|
14
|
+
func: async ({ woocommerce }, data) => {
|
|
15
|
+
return woocommerce.call("GET", "/customers/{customerId}", data);
|
|
16
|
+
},
|
|
17
|
+
});
|
|
18
|
+
//# sourceMappingURL=customerGet.function.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerGet.function.js","sourceRoot":"","sources":["../../../src/functions/customerGet.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAA;AAE7C,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC;IACvC,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE;CACvB,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC;IACxC,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACzB,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC7B,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,WAAW,GAAG,oBAAoB,CAAC;IAC9C,WAAW,EAAE,gBAAgB;IAC7B,KAAK,EAAE,gBAAgB;IACvB,MAAM,EAAE,iBAAiB;IACzB,IAAI,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE;QACpC,OAAO,WAAW,CAAC,IAAI,CAAC,KAAK,EAAE,yBAAyB,EAAE,IAAI,CAAQ,CAAA;IACxE,CAAC;CACF,CAAC,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const CustomerGetAllInput: z.ZodObject<{
|
|
3
|
+
per_page: z.ZodOptional<z.ZodNumber>;
|
|
4
|
+
page: z.ZodOptional<z.ZodNumber>;
|
|
5
|
+
}, z.core.$strip>;
|
|
6
|
+
export declare const CustomerGetAllOutput: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
7
|
+
export declare const customerGetAll: import("#pikku").PikkuFunctionConfig<{
|
|
8
|
+
per_page?: number | undefined;
|
|
9
|
+
page?: number | undefined;
|
|
10
|
+
}, Record<string, unknown>[], "rpc" | "session", import("#pikku").PikkuFunctionSessionless<{
|
|
11
|
+
per_page?: number | undefined;
|
|
12
|
+
page?: number | undefined;
|
|
13
|
+
}, Record<string, unknown>[], "rpc" | "session", import("#pikku").Services> | import("#pikku").PikkuFunction<{
|
|
14
|
+
per_page?: number | undefined;
|
|
15
|
+
page?: number | undefined;
|
|
16
|
+
}, Record<string, unknown>[], "rpc" | "session", import("#pikku").Services>, undefined, undefined>;
|
|
17
|
+
//# sourceMappingURL=customerGetAll.function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerGetAll.function.d.ts","sourceRoot":"","sources":["../../../src/functions/customerGetAll.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,mBAAmB;;;iBAG9B,CAAA;AAEF,eAAO,MAAM,oBAAoB,oDAA6C,CAAA;AAE9E,eAAO,MAAM,cAAc;;;;;;;;;kGAOzB,CAAA"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { pikkuSessionlessFunc } from '#pikku';
|
|
3
|
+
export const CustomerGetAllInput = z.object({
|
|
4
|
+
per_page: z.number().optional(),
|
|
5
|
+
page: z.number().optional(),
|
|
6
|
+
});
|
|
7
|
+
export const CustomerGetAllOutput = z.array(z.record(z.string(), z.unknown()));
|
|
8
|
+
export const customerGetAll = pikkuSessionlessFunc({
|
|
9
|
+
description: "Get many customers",
|
|
10
|
+
input: CustomerGetAllInput,
|
|
11
|
+
output: CustomerGetAllOutput,
|
|
12
|
+
func: async ({ woocommerce }, data) => {
|
|
13
|
+
return woocommerce.call("GET", "/customers", data);
|
|
14
|
+
},
|
|
15
|
+
});
|
|
16
|
+
//# sourceMappingURL=customerGetAll.function.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerGetAll.function.js","sourceRoot":"","sources":["../../../src/functions/customerGetAll.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAA;AAE7C,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC/B,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC5B,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC,CAAA;AAE9E,MAAM,CAAC,MAAM,cAAc,GAAG,oBAAoB,CAAC;IACjD,WAAW,EAAE,oBAAoB;IACjC,KAAK,EAAE,mBAAmB;IAC1B,MAAM,EAAE,oBAAoB;IAC5B,IAAI,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE;QACpC,OAAO,WAAW,CAAC,IAAI,CAAC,KAAK,EAAE,YAAY,EAAE,IAAI,CAAQ,CAAA;IAC3D,CAAC;CACF,CAAC,CAAA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const CustomerUpdateInput: z.ZodObject<{
|
|
3
|
+
customerId: z.ZodString;
|
|
4
|
+
first_name: z.ZodOptional<z.ZodString>;
|
|
5
|
+
last_name: z.ZodOptional<z.ZodString>;
|
|
6
|
+
}, z.core.$strip>;
|
|
7
|
+
export declare const CustomerUpdateOutput: z.ZodObject<{
|
|
8
|
+
id: z.ZodOptional<z.ZodNumber>;
|
|
9
|
+
}, z.core.$strip>;
|
|
10
|
+
export declare const customerUpdate: import("#pikku").PikkuFunctionConfig<{
|
|
11
|
+
customerId: string;
|
|
12
|
+
first_name?: string | undefined;
|
|
13
|
+
last_name?: string | undefined;
|
|
14
|
+
}, {
|
|
15
|
+
id?: number | undefined;
|
|
16
|
+
}, "rpc" | "session", import("#pikku").PikkuFunctionSessionless<{
|
|
17
|
+
customerId: string;
|
|
18
|
+
first_name?: string | undefined;
|
|
19
|
+
last_name?: string | undefined;
|
|
20
|
+
}, {
|
|
21
|
+
id?: number | undefined;
|
|
22
|
+
}, "rpc" | "session", import("#pikku").Services> | import("#pikku").PikkuFunction<{
|
|
23
|
+
customerId: string;
|
|
24
|
+
first_name?: string | undefined;
|
|
25
|
+
last_name?: string | undefined;
|
|
26
|
+
}, {
|
|
27
|
+
id?: number | undefined;
|
|
28
|
+
}, "rpc" | "session", import("#pikku").Services>, undefined, undefined>;
|
|
29
|
+
//# sourceMappingURL=customerUpdate.function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerUpdate.function.d.ts","sourceRoot":"","sources":["../../../src/functions/customerUpdate.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,mBAAmB;;;;iBAI9B,CAAA;AAEF,eAAO,MAAM,oBAAoB;;iBAE/B,CAAA;AAEF,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;uEAOzB,CAAA"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { pikkuSessionlessFunc } from '#pikku';
|
|
3
|
+
export const CustomerUpdateInput = z.object({
|
|
4
|
+
customerId: z.string(),
|
|
5
|
+
first_name: z.string().optional(),
|
|
6
|
+
last_name: z.string().optional(),
|
|
7
|
+
});
|
|
8
|
+
export const CustomerUpdateOutput = z.object({
|
|
9
|
+
id: z.number().optional(),
|
|
10
|
+
});
|
|
11
|
+
export const customerUpdate = pikkuSessionlessFunc({
|
|
12
|
+
description: "Update a customer",
|
|
13
|
+
input: CustomerUpdateInput,
|
|
14
|
+
output: CustomerUpdateOutput,
|
|
15
|
+
func: async ({ woocommerce }, data) => {
|
|
16
|
+
return woocommerce.call("PUT", "/customers/{customerId}", data);
|
|
17
|
+
},
|
|
18
|
+
});
|
|
19
|
+
//# sourceMappingURL=customerUpdate.function.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerUpdate.function.js","sourceRoot":"","sources":["../../../src/functions/customerUpdate.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAA;AAE7C,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE;IACtB,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACjC,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3C,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC1B,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,oBAAoB,CAAC;IACjD,WAAW,EAAE,mBAAmB;IAChC,KAAK,EAAE,mBAAmB;IAC1B,MAAM,EAAE,oBAAoB;IAC5B,IAAI,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE;QACpC,OAAO,WAAW,CAAC,IAAI,CAAC,KAAK,EAAE,yBAAyB,EAAE,IAAI,CAAQ,CAAA;IACxE,CAAC;CACF,CAAC,CAAA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const OrderCreateInput: z.ZodObject<{
|
|
3
|
+
status: z.ZodOptional<z.ZodString>;
|
|
4
|
+
currency: z.ZodOptional<z.ZodString>;
|
|
5
|
+
customer_id: z.ZodOptional<z.ZodNumber>;
|
|
6
|
+
}, z.core.$strip>;
|
|
7
|
+
export declare const OrderCreateOutput: z.ZodObject<{
|
|
8
|
+
id: z.ZodOptional<z.ZodNumber>;
|
|
9
|
+
}, z.core.$strip>;
|
|
10
|
+
export declare const orderCreate: import("#pikku").PikkuFunctionConfig<{
|
|
11
|
+
status?: string | undefined;
|
|
12
|
+
currency?: string | undefined;
|
|
13
|
+
customer_id?: number | undefined;
|
|
14
|
+
}, {
|
|
15
|
+
id?: number | undefined;
|
|
16
|
+
}, "rpc" | "session", import("#pikku").PikkuFunctionSessionless<{
|
|
17
|
+
status?: string | undefined;
|
|
18
|
+
currency?: string | undefined;
|
|
19
|
+
customer_id?: number | undefined;
|
|
20
|
+
}, {
|
|
21
|
+
id?: number | undefined;
|
|
22
|
+
}, "rpc" | "session", import("#pikku").Services> | import("#pikku").PikkuFunction<{
|
|
23
|
+
status?: string | undefined;
|
|
24
|
+
currency?: string | undefined;
|
|
25
|
+
customer_id?: number | undefined;
|
|
26
|
+
}, {
|
|
27
|
+
id?: number | undefined;
|
|
28
|
+
}, "rpc" | "session", import("#pikku").Services>, undefined, undefined>;
|
|
29
|
+
//# sourceMappingURL=orderCreate.function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orderCreate.function.d.ts","sourceRoot":"","sources":["../../../src/functions/orderCreate.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,gBAAgB;;;;iBAI3B,CAAA;AAEF,eAAO,MAAM,iBAAiB;;iBAE5B,CAAA;AAEF,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;uEAOtB,CAAA"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { pikkuSessionlessFunc } from '#pikku';
|
|
3
|
+
export const OrderCreateInput = z.object({
|
|
4
|
+
status: z.string().optional(),
|
|
5
|
+
currency: z.string().optional(),
|
|
6
|
+
customer_id: z.number().optional(),
|
|
7
|
+
});
|
|
8
|
+
export const OrderCreateOutput = z.object({
|
|
9
|
+
id: z.number().optional(),
|
|
10
|
+
});
|
|
11
|
+
export const orderCreate = pikkuSessionlessFunc({
|
|
12
|
+
description: "Create an order",
|
|
13
|
+
input: OrderCreateInput,
|
|
14
|
+
output: OrderCreateOutput,
|
|
15
|
+
func: async ({ woocommerce }, data) => {
|
|
16
|
+
return woocommerce.call("POST", "/orders", data);
|
|
17
|
+
},
|
|
18
|
+
});
|
|
19
|
+
//# sourceMappingURL=orderCreate.function.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orderCreate.function.js","sourceRoot":"","sources":["../../../src/functions/orderCreate.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAA;AAE7C,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC;IACvC,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC7B,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC/B,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACnC,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC;IACxC,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC1B,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,WAAW,GAAG,oBAAoB,CAAC;IAC9C,WAAW,EAAE,iBAAiB;IAC9B,KAAK,EAAE,gBAAgB;IACvB,MAAM,EAAE,iBAAiB;IACzB,IAAI,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE;QACpC,OAAO,WAAW,CAAC,IAAI,CAAC,MAAM,EAAE,SAAS,EAAE,IAAI,CAAQ,CAAA;IACzD,CAAC;CACF,CAAC,CAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const OrderDeleteInput: z.ZodObject<{
|
|
3
|
+
orderId: z.ZodString;
|
|
4
|
+
}, z.core.$strip>;
|
|
5
|
+
export declare const OrderDeleteOutput: z.ZodObject<{
|
|
6
|
+
id: z.ZodOptional<z.ZodNumber>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
export declare const orderDelete: import("#pikku").PikkuFunctionConfig<{
|
|
9
|
+
orderId: string;
|
|
10
|
+
}, {
|
|
11
|
+
id?: number | undefined;
|
|
12
|
+
}, "rpc" | "session", import("#pikku").PikkuFunctionSessionless<{
|
|
13
|
+
orderId: string;
|
|
14
|
+
}, {
|
|
15
|
+
id?: number | undefined;
|
|
16
|
+
}, "rpc" | "session", import("#pikku").Services> | import("#pikku").PikkuFunction<{
|
|
17
|
+
orderId: string;
|
|
18
|
+
}, {
|
|
19
|
+
id?: number | undefined;
|
|
20
|
+
}, "rpc" | "session", import("#pikku").Services>, undefined, undefined>;
|
|
21
|
+
//# sourceMappingURL=orderDelete.function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orderDelete.function.d.ts","sourceRoot":"","sources":["../../../src/functions/orderDelete.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,gBAAgB;;iBAE3B,CAAA;AAEF,eAAO,MAAM,iBAAiB;;iBAE5B,CAAA;AAEF,eAAO,MAAM,WAAW;;;;;;;;;;;;uEAOtB,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { pikkuSessionlessFunc } from '#pikku';
|
|
3
|
+
export const OrderDeleteInput = z.object({
|
|
4
|
+
orderId: z.string(),
|
|
5
|
+
});
|
|
6
|
+
export const OrderDeleteOutput = z.object({
|
|
7
|
+
id: z.number().optional(),
|
|
8
|
+
});
|
|
9
|
+
export const orderDelete = pikkuSessionlessFunc({
|
|
10
|
+
description: "Delete an order",
|
|
11
|
+
input: OrderDeleteInput,
|
|
12
|
+
output: OrderDeleteOutput,
|
|
13
|
+
func: async ({ woocommerce }, data) => {
|
|
14
|
+
return woocommerce.call("DELETE", "/orders/{orderId}", data);
|
|
15
|
+
},
|
|
16
|
+
});
|
|
17
|
+
//# sourceMappingURL=orderDelete.function.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orderDelete.function.js","sourceRoot":"","sources":["../../../src/functions/orderDelete.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AACvB,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAA;AAE7C,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC;IACvC,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;CACpB,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC;IACxC,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC1B,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,WAAW,GAAG,oBAAoB,CAAC;IAC9C,WAAW,EAAE,iBAAiB;IAC9B,KAAK,EAAE,gBAAgB;IACvB,MAAM,EAAE,iBAAiB;IACzB,IAAI,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE;QACpC,OAAO,WAAW,CAAC,IAAI,CAAC,QAAQ,EAAE,mBAAmB,EAAE,IAAI,CAAQ,CAAA;IACrE,CAAC;CACF,CAAC,CAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const OrderGetInput: z.ZodObject<{
|
|
3
|
+
orderId: z.ZodString;
|
|
4
|
+
}, z.core.$strip>;
|
|
5
|
+
export declare const OrderGetOutput: z.ZodObject<{
|
|
6
|
+
id: z.ZodOptional<z.ZodNumber>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
export declare const orderGet: import("#pikku").PikkuFunctionConfig<{
|
|
9
|
+
orderId: string;
|
|
10
|
+
}, {
|
|
11
|
+
id?: number | undefined;
|
|
12
|
+
}, "rpc" | "session", import("#pikku").PikkuFunctionSessionless<{
|
|
13
|
+
orderId: string;
|
|
14
|
+
}, {
|
|
15
|
+
id?: number | undefined;
|
|
16
|
+
}, "rpc" | "session", import("#pikku").Services> | import("#pikku").PikkuFunction<{
|
|
17
|
+
orderId: string;
|
|
18
|
+
}, {
|
|
19
|
+
id?: number | undefined;
|
|
20
|
+
}, "rpc" | "session", import("#pikku").Services>, undefined, undefined>;
|
|
21
|
+
//# sourceMappingURL=orderGet.function.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orderGet.function.d.ts","sourceRoot":"","sources":["../../../src/functions/orderGet.function.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAGvB,eAAO,MAAM,aAAa;;iBAExB,CAAA;AAEF,eAAO,MAAM,cAAc;;iBAEzB,CAAA;AAEF,eAAO,MAAM,QAAQ;;;;;;;;;;;;uEAOnB,CAAA"}
|