- Add Activepieces fork with SmoothSchedule custom piece - Create integrations app with Activepieces service layer - Add embed token endpoint for iframe integration - Create Automations page with embedded workflow builder - Add sidebar visibility fix for embed mode - Add list inactive customers endpoint to Public API - Include SmoothSchedule triggers: event created/updated/cancelled - Include SmoothSchedule actions: create/update/cancel events, list resources/services/customers 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
33 lines
924 B
TypeScript
33 lines
924 B
TypeScript
import { Property } from '@activepieces/pieces-framework';
|
|
import { httpClient, HttpMethod } from '@activepieces/pieces-common';
|
|
import { CAPTAIN_DATA_BASE_URL, captainDataAuth } from '..';
|
|
|
|
export const workflowProp = Property.Dropdown({
|
|
auth: captainDataAuth,
|
|
displayName: 'Workflow',
|
|
required: true,
|
|
refreshers: [],
|
|
options: async ({ auth }) => {
|
|
if (!auth) {
|
|
return {
|
|
disabled: true,
|
|
options: [],
|
|
};
|
|
}
|
|
const response = await httpClient.sendRequest({
|
|
url: `${CAPTAIN_DATA_BASE_URL}/workflows`,
|
|
method: HttpMethod.GET,
|
|
headers: {
|
|
Authorization: `x-api-key ${auth.props.apiKey}`,
|
|
'x-project-id': auth.props.projectId,
|
|
},
|
|
});
|
|
return {
|
|
disabled: false,
|
|
options: response.body.map((workflow: { uid: string; name: string }) => {
|
|
return { label: workflow.name, value: workflow.uid };
|
|
}),
|
|
};
|
|
},
|
|
});
|