
Product
Introducing Webhook Events for Alert Changes
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.
npm i --save @aird/sdk
# 或
yarn add @aird/sdk
除get外,默认application/x-www-form-urlencoded
const SDK = require('@aird/sdk');
const sdk = new SDK({
SecretId: 'xxxx',
SecretKey: 'xxxx',
// 访问的域名:
// Domain: 'api.airdwing.com',
// 是否启用HTTPS:
// Secure: true,
// 自定义预处理方法
// filter: x => x.data,
// 自定义异常捕获方法
// catch: (err) => { throw err; }
});
(async () => {
const result = await sdk.get('/user/check', {
username: '13212341234'
});
console.log(result);
})();
需要稍微注意一下的接口:
const SDK = require('@aird/sdk');
const fs = require('fs');
const sdk = new SDK({
SecretId: 'xxxx',
SecretKey: 'xxxx'
});
(async () => {
const result = await sdk.upload({
auth: 'xxxx',
type: 'orgverify',
file: fs.createReadStream('PATH/TO/xxx.jpg') // 注意这里, 本地文件可以用 path.join 拼装地址,或者直接用Stream
});
console.log(result);
})();
Demo:
const SDK = require('@aird/sdk');
const cvm = new SDK({
SecretId: 'xxxx',
SecretKey: 'xxxx',
Domain: 'cvm.api.qcloud.com'
});
(async () => {
const result = await cvm.get('/v2/index.php', {
Action: 'DescribeInstances',
Region: 'gz'
});
console.log(result);
})();
Apache 2.0
FAQs
AirDwing SDK
We found that @aird/sdk demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
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.

Product
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.

Security News
ENISA has become a CVE Program Root, giving the EU a central authority for coordinating vulnerability reporting, disclosure, and cross-border response.

Product
Socket now scans OpenVSX extensions, giving teams early detection of risky behaviors, hidden capabilities, and supply chain threats in developer tools.