1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "brand": {
12 "name": "ExampleStudio",
13 "background": "#101827",
14 "text": "#F8FAFC",
15 "accent": "#FBBF24"
16 },
17 "carousels": [
18 {
19 "id": "weekly-tip",
20 "caption": "Approved demo copy. Review before posting.",
21 "slides": [
22 {
23 "title": "๋ฐ๋ณต ์ ์์ ์๋ํํ์ธ์",
24 "body": "์น์ธํ ๊ธ์ ๋ธ๋๋ ์นด๋๋ด์ค๋ก ๋ง๋ญ๋๋ค.\nํ๊ธ ๋ฌธ์ฅ์ ๊ทธ๋๋ก ์ ์งํฉ๋๋ค."
25 },
26 {
27 "title": "๋ธ๋๋ ๊ท์น์ ํ ๋ฒ๋ง",
28 "body": "์์๊ณผ ๊ธ๊ผด ๊ท์น์ ๊ฐ์ ๋ฌถ์์ ์ ์ฉํฉ๋๋ค.\n์นด๋๋ง๋ค ๋ค์ ๋์์ธํ์ง ์์ต๋๋ค."
29 },
30 {
31 "title": "๊ฒํ ํ ์ง์ ๊ฒ์ํ์ธ์",
32 "body": "PNG์ ์บก์
์ ZIP์ผ๋ก ๋ฐ์ต๋๋ค.\n์๋ ๊ฒ์๋ ๋ด์ฉ ์์ฑ์ ์ํํ์ง ์์ต๋๋ค."
33 }
34 ]
35 }
36 ]
37};
38
39
40const run = await client.actor("bread-kim/brand-carousel-batch-renderer").call(input);
41
42
43console.log('Results from dataset');
44console.log(`๐พ Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
45const { items } = await client.dataset(run.defaultDatasetId).listItems();
46items.forEach((item) => {
47 console.dir(item);
48});
49
50