AWS

On-demand cloud computing platforms and APIs

Go to site

Integrate the AWS API with the Go API

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

Connect AWS

module.exports = defineComponent({
  props: {
    aws: {
      type: "app",
      app: "aws",
    }
  },
  async run({steps, $}) {
    const AWS = require("aws-sdk")
    const { accessKeyId, secretAccessKey } = this.aws.$auth
    
    /* Now, pass the accessKeyId and secretAccessKey to the constructor for your desired service. For example:
    
    const dynamodb = new AWS.DynamoDB({
      accessKeyId, 
      secretAccessKey,
      region: 'us-east-1',
    })
    
    */
  },
})

Connect Go

package main

import (
	"fmt"

	pd "github.com/PipedreamHQ/pipedream-go"
)

func main() {
	// Access previous step data using pd.Steps
	fmt.Println(pd.Steps)

	// Export data using pd.Export
	data := make(map[string]interface{})
	data["name"] = "Luke"
	pd.Export("data", data)
}