Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default {
key: "customjs-convert-html-to-pdf",
name: "Convert HTML to PDF",
description: "Converts an HTML string to a PDF document. [See the documentation](https://www.customjs.space/api/docs#_1-html-to-pdf)",
version: "0.0.2",
version: "0.0.3",
type: "action",
props: {
customjs,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default {
key: "customjs-convert-html-to-png",
name: "Convert HTML to PNG",
description: "Converts an HTML string to a PNG image. [See the documentation](https://www.customjs.space/api/docs#_4-html-to-png)",
version: "0.0.1",
version: "0.0.2",
type: "action",
props: {
customjs,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default {
key: "customjs-create-screenshot",
name: "Create Screenshot",
description: "Create a screenshot of a website. [See the documentation](https://www.customjs.space/api/docs#_3-create-screenshot)",
version: "0.0.2",
version: "0.0.3",
type: "action",
props: {
customjs,
Expand Down
2 changes: 1 addition & 1 deletion components/customjs/actions/merge-pdfs/merge-pdfs.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default {
key: "customjs-merge-pdfs",
name: "Merge PDFs",
description: "Merges multiple PDF documents into one. [See the documentation](https://www.customjs.space/api/docs#_2-merge-pdfs)",
version: "0.0.2",
version: "0.0.3",
type: "action",
props: {
customjs,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default {
key: "customjs-run-puppeteer",
name: "Run Puppeteer",
description: "Run Puppeteer. [See the documentation](https://www.customjs.space/api/docs#_5-run-puppeteer)",
version: "0.0.1",
version: "0.0.2",
type: "action",
props: {
customjs,
Expand Down
11 changes: 9 additions & 2 deletions components/customjs/customjs.app.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,26 @@ export default {
},
},
methods: {
_getBaseHeaders() {
return {
"Content-Type": "application/json",
"customjs-origin": "pipedream",
};
},
_makeRequest(opts = {}) {
const {
$ = this,
headers,
headers = {},
...otherOpts
} = opts;

return axios($, {
...otherOpts,
method: "POST",
url: `https://e.customjs.io/__js1-${this.$auth.api_key}`,
headers: {
...this._getBaseHeaders(),
...headers,
"Content-Type": "application/json",
},
responseType: "arraybuffer",
});
Expand Down
2 changes: 1 addition & 1 deletion components/customjs/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@pipedream/customjs",
"version": "0.2.0",
"version": "0.2.1",
"description": "Pipedream CustomJS Components",
"main": "customjs.app.mjs",
"keywords": [
Expand Down
9 changes: 3 additions & 6 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading