Add Activepieces integration for workflow automation
- 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>
This commit is contained in:
@@ -0,0 +1,145 @@
|
||||
import { createAction, Property } from '@activepieces/pieces-framework';
|
||||
import { makeRequest } from '../common/client';
|
||||
import { HttpMethod } from '@activepieces/pieces-common';
|
||||
import { MagicSlidesAuth } from '../common/auth';
|
||||
|
||||
|
||||
export const createPptFromSummary = createAction({
|
||||
auth: MagicSlidesAuth,
|
||||
name: 'createPptFromText',
|
||||
displayName: 'Create PPT from Text/Summary',
|
||||
description: 'Generates a PPT presentation from provided text or summary.',
|
||||
props: {
|
||||
msSummaryText: Property.LongText({
|
||||
displayName: "Summary Text",
|
||||
required: true,
|
||||
}),
|
||||
slideCount: Property.Number({
|
||||
displayName: "Number of Slides",
|
||||
required: false,
|
||||
defaultValue: 10,
|
||||
}),
|
||||
language: Property.StaticDropdown({
|
||||
displayName: "Language",
|
||||
required: false,
|
||||
defaultValue: "en",
|
||||
options: {
|
||||
options: [
|
||||
{ label: "English", value: "en" },
|
||||
{ label: "Hindi", value: "hi" },
|
||||
{ label: "Spanish", value: "es" },
|
||||
{ label: "French", value: "fr" },
|
||||
{ label: "German", value: "de" },
|
||||
{ label: "Chinese", value: "zh" },
|
||||
],
|
||||
},
|
||||
}),
|
||||
template: Property.StaticDropdown({
|
||||
displayName: "Template",
|
||||
required: false,
|
||||
defaultValue: "bullet-point1",
|
||||
options: {
|
||||
options: [
|
||||
{ label: "Bullet Point 1 (default)", value: "bullet-point1" },
|
||||
{ label: "Bullet Point 2", value: "bullet-point2" },
|
||||
{ label: "Bullet Point 4", value: "bullet-point4" },
|
||||
{ label: "Bullet Point 5", value: "bullet-point5" },
|
||||
{ label: "Bullet Point 6", value: "bullet-point6" },
|
||||
{ label: "Bullet Point 7", value: "bullet-point7" },
|
||||
{ label: "Bullet Point 8", value: "bullet-point8" },
|
||||
{ label: "Bullet Point 9", value: "bullet-point9" },
|
||||
{ label: "Bullet Point 10", value: "bullet-point10" },
|
||||
{ label: "Pitch Deck Original", value: "pitchdeckorignal" },
|
||||
{ label: "Pitch Deck 2", value: "pitch-deck-2" },
|
||||
{ label: "Pitch Deck 3", value: "pitch-deck-3" },
|
||||
{ label: "Custom 2", value: "custom2" },
|
||||
{ label: "Custom 3", value: "custom3" },
|
||||
{ label: "Vertical Bullet Point 1", value: "verticalBulletPoint1" },
|
||||
{ label: "Vertical Custom 1", value: "verticalCustom1" },
|
||||
],
|
||||
},
|
||||
}),
|
||||
model: Property.StaticDropdown({
|
||||
displayName: "AI Model",
|
||||
required: false,
|
||||
defaultValue: "gpt-4",
|
||||
options: {
|
||||
options: [
|
||||
{ label: "GPT-4", value: "gpt-4" },
|
||||
{ label: "GPT-3.5", value: "gpt-3.5" },
|
||||
],
|
||||
},
|
||||
}),
|
||||
aiImages: Property.Checkbox({
|
||||
displayName: "Use AI Images",
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
imageForEachSlide: Property.Checkbox({
|
||||
displayName: "Image for Each Slide",
|
||||
required: false,
|
||||
defaultValue: true,
|
||||
}),
|
||||
googleImage: Property.Checkbox({
|
||||
displayName: "Use Google Images",
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
googleText: Property.Checkbox({
|
||||
displayName: "Use Google Text",
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
presentationFor: Property.ShortText({
|
||||
displayName: "Presentation For (Audience)",
|
||||
required: false,
|
||||
}),
|
||||
watermark: Property.Json({
|
||||
displayName: 'Watermark',
|
||||
description:
|
||||
'Optional watermark e.g., {"width":"48","height":"48","brandURL":"https://...png","position":"BottomRight"}',
|
||||
required: false,
|
||||
}),
|
||||
},
|
||||
async run(context) {
|
||||
const {
|
||||
msSummaryText,
|
||||
|
||||
slideCount,
|
||||
language,
|
||||
template,
|
||||
model,
|
||||
aiImages,
|
||||
imageForEachSlide,
|
||||
googleImage,
|
||||
googleText,
|
||||
presentationFor,
|
||||
watermark,
|
||||
} = context.propsValue;
|
||||
|
||||
const payload: any = {
|
||||
accessId: context.auth.props.accessId,
|
||||
email: context.auth.props.email,
|
||||
msSummaryText,
|
||||
slideCount,
|
||||
language,
|
||||
template,
|
||||
model,
|
||||
aiImages,
|
||||
imageForEachSlide,
|
||||
googleImage,
|
||||
googleText,
|
||||
presentationFor,
|
||||
watermark,
|
||||
};
|
||||
|
||||
const result = await makeRequest(
|
||||
|
||||
HttpMethod.POST,
|
||||
'/ppt_from_summery',
|
||||
payload
|
||||
);
|
||||
|
||||
return result;
|
||||
},
|
||||
});
|
||||
@@ -0,0 +1,156 @@
|
||||
import { createAction, Property } from '@activepieces/pieces-framework';
|
||||
import { MagicSlidesAuth } from '../common/auth';
|
||||
import { makeRequest } from '../common/client';
|
||||
import { HttpMethod } from '@activepieces/pieces-common';
|
||||
|
||||
export const createPptFromTopic = createAction({
|
||||
auth: MagicSlidesAuth,
|
||||
name: 'createPptFromTopic',
|
||||
displayName: 'Create PPT from Topic',
|
||||
description: 'Generates a PPT presentation from a given topic.',
|
||||
props: {
|
||||
topic: Property.ShortText({
|
||||
displayName: 'Topic',
|
||||
required: true,
|
||||
}),
|
||||
slideCount: Property.Number({
|
||||
displayName: 'Number of slides',
|
||||
required: false,
|
||||
defaultValue: 10,
|
||||
}),
|
||||
language: Property.StaticDropdown({
|
||||
displayName: 'Language',
|
||||
required: false,
|
||||
defaultValue: 'en',
|
||||
options: {
|
||||
options: [
|
||||
{ label: 'English', value: 'en' },
|
||||
{ label: 'Hindi', value: 'hi' },
|
||||
{ label: 'Spanish', value: 'es' },
|
||||
{ label: 'French', value: 'fr' },
|
||||
{ label: 'German', value: 'de' },
|
||||
{ label: 'Chinese', value: 'zh' },
|
||||
],
|
||||
},
|
||||
}),
|
||||
template: Property.StaticDropdown({
|
||||
displayName: 'Template',
|
||||
required: false,
|
||||
defaultValue: 'bullet-point1',
|
||||
options: {
|
||||
options: [
|
||||
{ label: 'Bullet Point 1 (default)', value: 'bullet-point1' },
|
||||
{ label: 'Bullet Point 2', value: 'bullet-point2' },
|
||||
{ label: 'Bullet Point 4', value: 'bullet-point4' },
|
||||
{ label: 'Bullet Point 5', value: 'bullet-point5' },
|
||||
{ label: 'Bullet Point 6', value: 'bullet-point6' },
|
||||
{ label: 'Bullet Point 7', value: 'bullet-point7' },
|
||||
{ label: 'Bullet Point 8', value: 'bullet-point8' },
|
||||
{ label: 'Bullet Point 9', value: 'bullet-point9' },
|
||||
{ label: 'Bullet Point 10', value: 'bullet-point10' },
|
||||
{ label: 'Pitch Deck Original', value: 'pitchdeckorignal' },
|
||||
{ label: 'Pitch Deck 2', value: 'pitch-deck-2' },
|
||||
{ label: 'Pitch Deck 3', value: 'pitch-deck-3' },
|
||||
{ label: 'Custom 2', value: 'custom2' },
|
||||
{ label: 'Custom 3', value: 'custom3' },
|
||||
{ label: 'Vertical Bullet Point 1', value: 'verticalBulletPoint1' },
|
||||
{ label: 'Vertical Custom 1', value: 'verticalCustom1' },
|
||||
],
|
||||
},
|
||||
}),
|
||||
model: Property.StaticDropdown({
|
||||
displayName: 'AI Model',
|
||||
required: false,
|
||||
defaultValue: 'gpt-4',
|
||||
options: {
|
||||
options: [
|
||||
{ label: 'GPT-4', value: 'gpt-4' },
|
||||
{ label: 'GPT-3.5', value: 'gpt-3.5' },
|
||||
],
|
||||
},
|
||||
}),
|
||||
extraInfoSource: Property.ShortText({
|
||||
displayName: 'Extra Information Source',
|
||||
description:
|
||||
'Provide a URL or text to give additional context for the presentation.',
|
||||
required: false,
|
||||
}),
|
||||
aiImages: Property.Checkbox({
|
||||
displayName: 'Use AI Images',
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
imageForEachSlide: Property.Checkbox({
|
||||
displayName: 'Image for Each Slide',
|
||||
required: false,
|
||||
defaultValue: true,
|
||||
}),
|
||||
googleImage: Property.Checkbox({
|
||||
displayName: 'Use Google Images',
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
googleText: Property.Checkbox({
|
||||
displayName: 'Use Google Text',
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
include_images: Property.Checkbox({
|
||||
displayName: 'Include images',
|
||||
required: false,
|
||||
defaultValue: true,
|
||||
}),
|
||||
presentationFor: Property.ShortText({
|
||||
displayName: 'Presentation For (Audience)',
|
||||
required: false,
|
||||
}),
|
||||
watermark: Property.Json({
|
||||
displayName: 'Watermark',
|
||||
description:
|
||||
'Add a watermark to the presentation. e.g., {"width": "48", "height": "48", "brandURL": "https://...png", "position": "BottomRight"}',
|
||||
required: false,
|
||||
}),
|
||||
},
|
||||
async run(context) {
|
||||
const {
|
||||
topic,
|
||||
|
||||
slideCount,
|
||||
language,
|
||||
template,
|
||||
model,
|
||||
aiImages,
|
||||
imageForEachSlide,
|
||||
googleImage,
|
||||
googleText,
|
||||
presentationFor,
|
||||
watermark,
|
||||
extraInfoSource,
|
||||
} = context.propsValue;
|
||||
|
||||
const payload: any = {
|
||||
topic,
|
||||
accessId: context.auth.props.accessId,
|
||||
email: context.auth.props.email,
|
||||
slideCount,
|
||||
language,
|
||||
template,
|
||||
model,
|
||||
aiImages,
|
||||
imageForEachSlide,
|
||||
googleImage,
|
||||
googleText,
|
||||
presentationFor,
|
||||
watermark,
|
||||
extraInfoSource,
|
||||
};
|
||||
|
||||
const result = await makeRequest(
|
||||
HttpMethod.POST,
|
||||
'/ppt_from_topic',
|
||||
payload
|
||||
);
|
||||
|
||||
return result;
|
||||
},
|
||||
});
|
||||
@@ -0,0 +1,117 @@
|
||||
import { HttpMethod } from '@activepieces/pieces-common';
|
||||
import { createAction, Property } from '@activepieces/pieces-framework';
|
||||
import { MagicSlidesAuth } from '../common/auth';
|
||||
import { makeRequest } from '../common/client';
|
||||
|
||||
export const createPptFromYoutubeVideo = createAction({
|
||||
auth: MagicSlidesAuth,
|
||||
name: 'createPptFromYoutube',
|
||||
displayName: 'Create PPT from YouTube Video',
|
||||
description: 'Generates a PPT presentation from a YouTube video link.',
|
||||
props: {
|
||||
youtubeURL: Property.ShortText({
|
||||
displayName: 'YouTube Video URL',
|
||||
required: true,
|
||||
}),
|
||||
|
||||
template: Property.StaticDropdown({
|
||||
displayName: 'Template',
|
||||
required: false,
|
||||
defaultValue: 'bullet-point1',
|
||||
options: {
|
||||
options: [
|
||||
{ label: 'Bullet Point 1', value: 'bullet-point1' },
|
||||
{ label: 'Bullet Point 2', value: 'bullet-point2' },
|
||||
{ label: 'Bullet Point 4', value: 'bullet-point4' },
|
||||
{ label: 'Pitch Deck 3', value: 'pitch-deck-3' },
|
||||
{ label: 'Pitch Deck 2', value: 'pitch-deck-2' },
|
||||
{ label: 'Custom Dark 1', value: 'custom Dark 1' },
|
||||
{ label: 'Vertical Bullet Point 1', value: 'verticalBulletPoint1' },
|
||||
],
|
||||
},
|
||||
}),
|
||||
language: Property.ShortText({
|
||||
displayName: 'Language',
|
||||
required: false,
|
||||
defaultValue: 'en',
|
||||
}),
|
||||
slideCount: Property.Number({
|
||||
displayName: 'Number of slides',
|
||||
required: false,
|
||||
defaultValue: 10,
|
||||
}),
|
||||
aiImages: Property.Checkbox({
|
||||
displayName: 'Enable AI Images',
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
imageForEachSlide: Property.Checkbox({
|
||||
displayName: 'Include Image on Every Slide',
|
||||
required: false,
|
||||
defaultValue: true,
|
||||
}),
|
||||
googleImage: Property.Checkbox({
|
||||
displayName: 'Use Google Images',
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
googleText: Property.Checkbox({
|
||||
displayName: 'Enhance Content with Google Search',
|
||||
required: false,
|
||||
defaultValue: false,
|
||||
}),
|
||||
model: Property.StaticDropdown({
|
||||
displayName: 'AI Model',
|
||||
required: false,
|
||||
defaultValue: 'gpt-4',
|
||||
options: {
|
||||
options: [
|
||||
{ label: 'GPT-4', value: 'gpt-4' },
|
||||
{ label: 'GPT-3.5', value: 'gpt-3.5' },
|
||||
],
|
||||
},
|
||||
}),
|
||||
presentationFor: Property.ShortText({
|
||||
displayName: 'Presentation For (Audience)',
|
||||
required: false,
|
||||
}),
|
||||
watermark: Property.Json({
|
||||
displayName: 'Watermark',
|
||||
description:
|
||||
'Optional watermark e.g., {"width":"48","height":"48","brandURL":"https://...png","position":"BottomRight"}',
|
||||
required: false,
|
||||
}),
|
||||
},
|
||||
async run(context) {
|
||||
const {
|
||||
youtubeURL,
|
||||
template,
|
||||
language,
|
||||
slideCount,
|
||||
aiImages,
|
||||
imageForEachSlide,
|
||||
googleImage,
|
||||
googleText,
|
||||
model,
|
||||
presentationFor,
|
||||
watermark,
|
||||
} = context.propsValue;
|
||||
|
||||
const payload: any = {
|
||||
youtubeURL,
|
||||
accessId: context.auth.props.accessId,
|
||||
email: context.auth.props.email,
|
||||
template,
|
||||
language,
|
||||
slideCount,
|
||||
aiImages,
|
||||
imageForEachSlide,
|
||||
googleImage,
|
||||
googleText,
|
||||
model,
|
||||
presentationFor,
|
||||
watermark,
|
||||
};
|
||||
return await makeRequest(HttpMethod.POST, '/ppt_from_youtube', payload);
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user