UNPKG

@pipedream/tookan

Version:

Pipedream Tookan Components

70 lines (69 loc) 1.73 kB
import { Pipedream } from "@pipedream/types"; interface ActionRequestParams { $: Pipedream; } export interface HttpRequestParams extends ActionRequestParams { endpoint: string; data?: object; method?: string; } declare type CreateTaskParams = ActionRequestParams & { data: { timezone: string; has_delivery: 0 | 1; has_pickup: 0 | 1; layout_type: 0 | 1 | 2; }; }; interface HasDeliveryParams { data: { customer_address: string; job_delivery_datetime: string; }; } interface HasPickupDate { data: { job_pickup_datetime: string; }; } interface HasPickupAddress { data: { job_pickup_address: string; }; } export declare type CreateAppointmentTaskParams = CreateTaskParams & HasDeliveryParams & HasPickupDate & { data: { has_delivery: 0; has_pickup: 0; layout_type: 1; }; }; export declare type CreateDeliveryTaskParams = CreateTaskParams & HasDeliveryParams & { data: { has_delivery: 1; has_pickup: 0; layout_type: 0; }; }; export declare type CreateFieldWorkforceTaskParams = CreateTaskParams & HasDeliveryParams & HasPickupDate & { data: { has_delivery: 0; has_pickup: 0; layout_type: 2; }; }; export declare type CreatePickupTaskParams = CreateTaskParams & HasPickupDate & HasPickupAddress & { data: { has_delivery: 0; has_pickup: 1; layout_type: 0; }; }; export declare type CreatePickupAndDeliveryTaskParams = CreateTaskParams & HasPickupDate & HasDeliveryParams & HasPickupAddress & { data: { has_delivery: 1; has_pickup: 1; layout_type: 0; }; }; export {};