Skip to content

Commit 7c80b53

Browse files
authored
Merge branch 'master' into feat/paystack-export-transactions
2 parents 38baccb + a28b6b4 commit 7c80b53

File tree

3,581 files changed

+126240
-15518
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,581 files changed

+126240
-15518
lines changed

.github/workflows/pull-request-checks.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,11 @@ jobs:
9696
format: 'csv'
9797
# NOTE: These steps are kept in this workflow to avoid re-rerunning the rest of the lint job
9898
# in the Components Checks workflow
99+
- name: Build TypeScript Components
100+
run: pnpm build
99101
- name: Check component keys
100102
run: node scripts/findBadKeys.js ${{ steps.changed_files.outputs.added_modified }} ${{ steps.changed_files.outputs.renamed }}
101103
- name: Check component app prop
102-
run: node scripts/checkComponentAppProp.js ${{ steps.changed_files.outputs.added_modified }} ${{ steps.changed_files.outputs.renamed }}
104+
run: node --experimental-loader ./scripts/version-strip-loader.mjs scripts/checkComponentAppProp.js ${{ steps.changed_files.outputs.added_modified }} ${{ steps.changed_files.outputs.renamed }}
103105
- name: Check for duplicate component keys
104106
run: node scripts/findDuplicateKeys.js

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,7 @@ docs/.vuepress/dist
1818
components/**/package-lock.json
1919
/packages/evals/
2020
/packages/sdk/examples/.next/
21+
22+
**/.claude/settings.local.json
23+
24+
.cursor

.tool-versions

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
nodejs 18.18.0
1+
nodejs 20.13.1
22
pnpm 9.14.2
33
python 3.11.5
44
poetry 1.6.1

components/_2markdown/_2markdown.app.mjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ export default {
66
propDefinitions: {
77
filePath: {
88
type: "string",
9-
label: "File Path",
10-
description: "The path to an HTML file in the `/tmp` directory. [See the documentation on working with files](https://pipedream.com/docs/code/nodejs/working-with-files/#writing-a-file-to-tmp)",
9+
label: "File Path or URL",
10+
description: "An HTML file. Provide either a file URL or a path to a file in the `/tmp` directory (for example, `/tmp/myFile.html`)",
1111
},
1212
},
1313
methods: {

components/_2markdown/actions/html-file-to-markdown/html-file-to-markdown.mjs

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
import _2markdown from "../../_2markdown.app.mjs";
2-
import fs from "fs";
2+
import { getFileStreamAndMetadata } from "@pipedream/platform";
33
import FormData from "form-data";
44

55
export default {
66
key: "_2markdown-html-file-to-markdown",
77
name: "HTML File to Markdown",
88
description: "Convert an HTML file to Markdown format. [See the documentation](https://2markdown.com/docs#file2md)",
9-
version: "0.0.1",
9+
version: "0.1.0",
1010
type: "action",
1111
props: {
1212
_2markdown,
@@ -20,9 +20,14 @@ export default {
2020
async run({ $ }) {
2121
const form = new FormData();
2222

23-
form.append("document", fs.createReadStream(this.filePath.includes("tmp/")
24-
? this.filePath
25-
: `/tmp/${this.filePath}`));
23+
const {
24+
stream, metadata,
25+
} = await getFileStreamAndMetadata(this.filePath);
26+
form.append("document", stream, {
27+
contentType: metadata.contentType,
28+
knownLength: metadata.size,
29+
filename: metadata.name,
30+
});
2631

2732
const response = await this._2markdown.htmlFileToMarkdown({
2833
$,

components/_2markdown/actions/pdf-to-markdown/pdf-to-markdown.mjs

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
import _2markdown from "../../_2markdown.app.mjs";
2-
import fs from "fs";
2+
import { getFileStreamAndMetadata } from "@pipedream/platform";
33
import FormData from "form-data";
44

55
export default {
66
key: "_2markdown-pdf-to-markdown",
77
name: "PDF to Markdown",
88
description: "Convert a PDF document to Markdown format. [See the documentation](https://2markdown.com/docs#pdf2md)",
9-
version: "0.0.1",
9+
version: "0.1.0",
1010
type: "action",
1111
props: {
1212
_2markdown,
@@ -15,7 +15,7 @@ export default {
1515
_2markdown,
1616
"filePath",
1717
],
18-
description: "The path to a PDF file in the `/tmp` directory. [See the documentation on working with files](https://pipedream.com/docs/code/nodejs/working-with-files/#writing-a-file-to-tmp)",
18+
description: "A PDF file. Provide either a file URL or a path to a file in the `/tmp` directory (for example, `/tmp/myFile.pdf`)",
1919
},
2020
waitForCompletion: {
2121
type: "boolean",
@@ -27,9 +27,14 @@ export default {
2727
async run({ $ }) {
2828
const form = new FormData();
2929

30-
form.append("document", fs.createReadStream(this.filePath.includes("tmp/")
31-
? this.filePath
32-
: `/tmp/${this.filePath}`));
30+
const {
31+
stream, metadata,
32+
} = await getFileStreamAndMetadata(this.filePath);
33+
form.append("document", stream, {
34+
contentType: metadata.contentType,
35+
knownLength: metadata.size,
36+
filename: metadata.name,
37+
});
3338

3439
let response = await this._2markdown.pdfToMarkdown({
3540
$,

components/_2markdown/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@pipedream/_2markdown",
3-
"version": "0.1.0",
3+
"version": "0.2.0",
44
"description": "Pipedream 2markdown Components",
55
"main": "_2markdown.app.mjs",
66
"keywords": [
@@ -13,7 +13,7 @@
1313
"access": "public"
1414
},
1515
"dependencies": {
16-
"@pipedream/platform": "^3.0.3",
16+
"@pipedream/platform": "^3.1.0",
1717
"form-data": "^4.0.1"
1818
}
1919
}

components/twitter/twitter.app.mjs renamed to components/_302_ai/_302_ai.app.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
export default {
22
type: "app",
3-
app: "twitter",
3+
app: "_302_ai",
44
propDefinitions: {},
55
methods: {
66
// this.$auth contains connected account data

components/_302_ai/package.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"name": "@pipedream/_302_ai",
3+
"version": "0.0.1",
4+
"description": "Pipedream 302.ai Components",
5+
"main": "_302_ai.app.mjs",
6+
"keywords": [
7+
"pipedream",
8+
"_302_ai"
9+
],
10+
"homepage": "https://pipedream.com/apps/_302_ai",
11+
"author": "Pipedream <[email protected]> (https://pipedream.com/)",
12+
"publishConfig": {
13+
"access": "public"
14+
}
15+
}
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
import { axios } from "@pipedream/platform";
2+
3+
export default {
4+
type: "app",
5+
app: "accuweather",
6+
propDefinitions: {
7+
locationKey: {
8+
type: "string",
9+
label: "Location Key",
10+
description: "The location key for the desired location. You can get this using the 'Get Location Key' action.",
11+
},
12+
},
13+
methods: {
14+
_baseUrl() {
15+
return "http://dataservice.accuweather.com";
16+
},
17+
_params(params = {}) {
18+
return {
19+
apikey: `${this.$auth.api_key}`,
20+
...params,
21+
};
22+
},
23+
_makeRequest({
24+
$ = this, params, path, ...opts
25+
}) {
26+
return axios($, {
27+
url: this._baseUrl() + path,
28+
params: this._params(params),
29+
...opts,
30+
});
31+
},
32+
searchLocation(opts = {}) {
33+
return this._makeRequest({
34+
path: "/locations/v1/search",
35+
...opts,
36+
});
37+
},
38+
getCurrentConditions({
39+
locationKey, ...opts
40+
}) {
41+
return this._makeRequest({
42+
path: `/currentconditions/v1/${locationKey}`,
43+
...opts,
44+
});
45+
},
46+
getDailyForecast({
47+
days, locationKey, ...opts
48+
}) {
49+
return this._makeRequest({
50+
path: `/forecasts/v1/daily/${days}day/${locationKey}`,
51+
...opts,
52+
});
53+
},
54+
getHourlyForecast({
55+
hours, locationKey, ...opts
56+
}) {
57+
return this._makeRequest({
58+
path: `/forecasts/v1/hourly/${hours}hour/${locationKey}`,
59+
...opts,
60+
});
61+
},
62+
getHistoricalWeather({
63+
locationKey, time, ...opts
64+
}) {
65+
return this._makeRequest({
66+
path: `/currentconditions/v1/${locationKey}/historical${time === 24
67+
? "/24"
68+
: ""}`,
69+
...opts,
70+
});
71+
},
72+
},
73+
};

0 commit comments

Comments
 (0)