New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

alifc

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

alifc

Minimal aliyun fc util

latest
Source
npmnpm
Version
0.2.3
Version published
Maintainers
1
Created
Source

Minimal Aliyun FC Utility

For those who prefer a simpler http client than @alicloud/fc2.

Install

npm i alifc

Usage

HttpBase is wrapper of aixos that set the '/version/proxy/' baseURL for you.
HttpFunc also sign the request to pass function Authorization.

const { HttpBase, HttpFunc } = require('alifc')
const func = new HttpFunc(
  accessKey,
  accessKeySecret
  endpoint
)

func.get('/service/func') // axios Promise

Test requirements

  • A fc service named 'test'
  • 2 functions under 'test:
    • foo: which use function authorization
    • bar: which accept anonymous request
  • 3 environment variables (or set them via .env):
    • FC_ACCESS_KEY: accessKey,
    • FC_ACCESS_KEY_SEC: accessKeySecret,
    • FC_ACCESS_EP: endpoint

Reference

  • fc-nodejs-sdk
  • Create a trigger
  • Authorization

Keywords

axios

FAQs

Package last updated on 10 Jun 2022

Did you know?

Socket

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