Adobe Document Generation API

Create business-critical documents like invoices, contracts, sales proposals, and work orders automatically.

Integrate the Adobe Document Generation API API with the Snowflake API

Setup the Adobe Document Generation API API trigger to run a workflow which integrates with the Snowflake API. Pipedream's integration platform allows you to integrate Adobe Document Generation API and Snowflake remarkably fast. Free for developers.

Trusted by 1,000,000+ developers from startups to Fortune 500 companies

Adyen logo
Appcues logo
Bandwidth logo
Checkr logo
ChartMogul logo
Dataminr logo
Gopuff logo
Gorgias logo
LinkedIn logo
Logitech logo
Replicated logo
Rudderstack logo
SAS logo
Scale AI logo
Webflow logo
Warner Bros. logo
Adyen logo
Appcues logo
Bandwidth logo
Checkr logo
ChartMogul logo
Dataminr logo
Gopuff logo
Gorgias logo
LinkedIn logo
Logitech logo
Replicated logo
Rudderstack logo
SAS logo
Scale AI logo
Webflow logo
Warner Bros. logo
New Row from the Snowflake API

Emit new event when a row is added to a table

 
Try it
New Query Results from the Snowflake API

Run a SQL query on a schedule, triggering a workflow for each row of results

 
Try it
Failed Task in Schema from the Snowflake API

Emit new events when a task fails in a database schema

 
Try it
New Database from the Snowflake API

Emit new event when a database is created

 
Try it
New Deleted Role from the Snowflake API

Emit new event when a role is deleted

 
Try it
Execute SQL Query with the Snowflake API

Execute a custom Snowflake query. See our docs to learn more about working with SQL in Pipedream.

 
Try it
Insert Multiple Rows with the Snowflake API

Insert multiple rows into a table

 
Try it
Insert Single Row with the Snowflake API

Insert a row into a table

 
Try it
Query SQL Database with the Snowflake API

Execute a SQL Query. See our docs to learn more about working with SQL in Pipedream.

 
Try it

Connect Adobe Document Generation API

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
import fs from "fs";
import axios from "axios";
import {
	ServicePrincipalCredentials,
	PDFServices,
	MimeType,
	DocumentMergeParams,
	OutputFormat,
	DocumentMergeJob,
	DocumentMergeResult
} from "@adobe/pdfservices-node-sdk";

export default defineComponent({
  props: {
    adobe_document_generation_api: {
      type: "app",
      app: "adobe_document_generation_api",
    }
  },
  async run({steps, $}) {
		// Configuration constants
		const PDF_SERVICES_CLIENT_ID = this.adobe_document_generation_api.$auth.client_id;
		const PDF_SERVICES_CLIENT_SECRET = this.adobe_document_generation_api.$auth.client_secret;

			try {
				// Initial setup, create credentials instance
				const credentials = new ServicePrincipalCredentials({
					clientId: PDF_SERVICES_CLIENT_ID,
					clientSecret: PDF_SERVICES_CLIENT_SECRET
				});

				// Creates a PDF Services instance
				const pdfServices = new PDFServices({ credentials });

				// Creates an asset(s) from source file(s) and upload
        const response = await axios.get("https://developer.adobe.com/document-services/docs/receiptTemplate.docx", { responseType: 'stream' });
        const readStream = response.data;
				const inputAsset = await pdfServices.upload({
					readStream,
					mimeType: MimeType.DOCX
				});

				// Setup input data for the document merge process
      const jsonDataForMerge = {
        "author": "Gary Lee",
        "Company": {
          "Name": "Projected",
          "Address": "19718 Mandrake Way",
          "PhoneNumber": "+1-100000098"
        },
        "Invoice": {
          "Date": "January 15, 2021",
          "Number": 123,
          "Items": [
            {
              "item": "Gloves",
              "description": "Microwave gloves",
              "UnitPrice": 5,
              "Quantity": 2,
              "Total": 10
            },
            {
              "item": "Bowls",
              "description": "Microwave bowls",
              "UnitPrice": 10,
              "Quantity": 2,
              "Total": 20
            }
          ]
        },
        "Customer": {
          "Name": "Collins Candy",
          "Address": "315 Dunning Way",
          "PhoneNumber": "+1-200000046",
          "Email": "cc@abcdef.co.dw"
        },
        "Tax": 5,
        "Shipping": 5,
        "clause": {
          "overseas": "The shipment might take 5-10 more than informed."
        },
        "paymentMethod": "Cash"
      };

				// Create parameters for the job
				const params = new DocumentMergeParams({
					jsonDataForMerge,
					outputFormat: OutputFormat.PDF
				});

				// Creates a new job instance
				const job = new DocumentMergeJob({ inputAsset, params });

				// Submit the job and get the job result
				const pollingURL = await pdfServices.submit({ job });
				const pdfServicesResponse = await pdfServices.getJobResult({
					pollingURL,
					resultType: DocumentMergeResult
				});

				// Get content from the resulting asset(s)
				const resultAsset = pdfServicesResponse.result.asset;
				const streamAsset = await pdfServices.getContent({ asset: resultAsset });

				// Creates a write stream and copy stream asset's content to it
				const outputFilePath = "/tmp/generatePDFOutput.pdf";
				console.log(`Saving asset at ${outputFilePath}`);

				return new Promise((resolve, reject) => {
					const writeStream = fs.createWriteStream(outputFilePath);
					streamAsset.readStream.pipe(writeStream);
					writeStream.on('finish', () => resolve(outputFilePath));
					writeStream.on('error', reject);
				});
			} catch(err) {
				console.error('Error generating PDF:', err);
				throw err;
			}
  },
})

Overview of Snowflake

Snowflake offers a cloud database and related tools to help developers create robust, secure, and scalable data warehouses. See Snowflake's Key Concepts & Architecture.

Getting Started

1. Create a user, role and warehouse in Snowflake

Snowflake recommends you create a new user, role, and warehouse when you integrate a third-party tool like Pipedream. This way, you can control permissions via the user / role, and separate Pipedream compute and costs with the warehouse. You can do this directly in the Snowflake UI.

We recommend you create a read-only account if you only need to query Snowflake. If you need to insert data into Snowflake, add permissions on the appropriate objects after you create your user.

2. Enter those details in Pipedream

Visit https://pipedream.com/accounts. Click the button to Connect an App. Enter the required Snowflake account data.

You'll only need to connect your account once in Pipedream. You can connect this account to multiple workflows to run queries against Snowflake, insert data, and more.

3. Build your first workflow

Visit https://pipedream.com/new to build your first workflow. Pipedream workflows let you connect Snowflake with 1,000+ other apps. You can trigger workflows on Snowflake queries, sending results to Slack, Google Sheets, or any app that exposes an API. Or you can accept data from another app, transform it with Python, Node.js, Go or Bash code, and insert it into Snowflake.

Learn more at Pipedream University.

Connect Snowflake

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import snowflake from '@pipedream/snowflake';

export default defineComponent({
  props: {
    snowflake,
  },
  async run({ $ }) {
    // Component source code:
    // https://github.com/PipedreamHQ/pipedream/tree/master/components/snowflake
    
    return this.snowflake.executeQuery({
      sqlText: `SELECT CURRENT_TIMESTAMP()`,
      binds: [],
    });
  },
});

Trusted by 1,000,000+ developers from startups to Fortune 500 companies

Adyen logo
Appcues logo
Bandwidth logo
Checkr logo
ChartMogul logo
Dataminr logo
Gopuff logo
Gorgias logo
LinkedIn logo
Logitech logo
Replicated logo
Rudderstack logo
SAS logo
Scale AI logo
Webflow logo
Warner Bros. logo
Adyen logo
Appcues logo
Bandwidth logo
Checkr logo
ChartMogul logo
Dataminr logo
Gopuff logo
Gorgias logo
LinkedIn logo
Logitech logo
Replicated logo
Rudderstack logo
SAS logo
Scale AI logo
Webflow logo
Warner Bros. logo