PipedreamHQ / PipedreamHQ/pipedream
[BUG] In the Pipedream SDK, "app" is missing from the ConfigurableProp types
- Dominant language
- JavaScript
- Stars
- 11.7k
- Forks
- 5.8k
- Avg merge
- 3d 10h
- Merged PRs (30d)
- 102
Description
**Describe the bug**
In the Pipedream Typescript SDK, "app" is missing from the ConfigurableProp types, this causes linter errors despite the value being present in API responses
**To Reproduce**
```
export interface ConfigurableProp {
/** When building `configuredProps`, make sure to use this field as the key when setting the prop value */
name: string;
type: Pipedream.ConfigurablePropType;
/** Value to use as an input label. In cases where `type` is "app", should load the app via `getApp`, etc. and show `app.name` instead. */
label?: string;
/** A description of the prop, shown to the user when configuring the component. */
description?: string;
/** If true, this prop does not need to be specified. */
optional?: boolean;
/** If true, this prop will be ignored. */
disabled?: boolean;
/** If true, should not expose this prop to the user */
hidden?: boolean;
/** If true, call `configureComponent` for this prop to load remote options. It is safe, and preferred, given a returned list of { label: string; value: any } objects to set the prop value to { __lv: { label: string; value: any } }. This way, on load, you can access label for the value without necessarily reloading these options */
remoteOptions?: boolean;
/** If true, calls to `configureComponent` for this prop support receiving a `query` parameter to filter remote options */
useQuery?: boolean;
/** If true, after setting a value for this prop, a call to `reloadComponentProps` is required as the component has dynamic configurable props dependent on this one */
reloadProps?: boolean;
/** If true, you must save the configured prop value as a "label-value" object which should look like: { __lv: { label: string; value: any } } because the execution needs to access the label */
withLabel?: boolean;
}
```
Note in API docs, how "app" is always returned in API responses for app type. This is important for later running pipedream SDK / connect to connect to said app, since it is the appId.
```
backend-1 | configuredProps [
backend-1 | {
backend-1 | "name": "schedule",
backend-1 | "type": "app",
backend-1 | "app": "schedule"
backend-1 | },
backend-1 | {
backend-1 | "name": "cron",
backend-1 | "label": "Cron Schedule",
backend-1 | "type": "$.interface.timer",
backend-1 | "description": "Enter a cron expression"
backend-1 | }
backend-1 | ]
```
**Expected behavior**
Typescript types exist for "app"
**Screenshots**
Contributor guide
Assessment
This issue has not been assessed yet.