Socket
Socket
Sign inDemoInstall

@google-cloud-suite/cloud-functions-storage-upload

Package Overview
Dependencies
95
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @google-cloud-suite/cloud-functions-storage-upload

@google-cloud-suite/cloud-functions-storage-upload


Version published
Maintainers
1
Created

Readme

Source

@google-cloud-suite/cloud-functions-storage-upload

Upload file to storage via functions

  1. Install
npm install @google-cloud-suite/cloud-functions-cloud-functions-storage-upload
  1. Handle stroage trigger

You can use handle(params?: InitParams) to initialize trigger. The followings are the property of InitParams:

  • bucketName: string
  • clientSecret?: string
    • defaults: undefined
  • keyPrefix?: string
    • defaults: undefined

Examples:

  • Using event target bucket for both source and destination.
const storageUpload = require("@google-cloud-suite/cloud-functions-storage-upload");
exports.upload = storageUpload.handle();
  1. Deploy
gcloud functions deploy upload \
--runtime nodejs14 \
--project YOUR_PROJECT

FAQs

Last updated on 02 Dec 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc