ncloud-cloudfunctions
v1.0.3
Published
Cloud Functions Client for Naver Cloud Platform
Downloads
6
Readme
api
Api - JavaScript client for api Cloud Functions Open APIhttps://cloudfunctions.apigw.ntruss.com/api/v2 This SDK is automatically generated by the Swagger Codegen project:
- API version: 2022-08-18T08:02:31Z
- Package version: 1.0.0
- Build package: io.swagger.codegen.languages.NcpJavascriptForNcloudClientCodegen
Installation
For Node.js
npm
To publish the library as a npm, please follow the procedure in "Publishing npm packages".
Then install it via:
npm install api --save
git
If the library is hosted at a git repository, e.g. https://github.com/YOUR_USERNAME/api then install it via:
npm install YOUR_USERNAME/api --save
For browser
The library also works in the browser environment via npm and browserify. After following
the above steps with Node.js and installing browserify with npm install -g browserify
,
perform the following (assuming main.js is your entry file):
browserify main.js > bundle.js
Then include bundle.js in the HTML pages.
Webpack Configuration
Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module", most certainly you should disable AMD loader. Add/merge the following section to your webpack config:
module: {
rules: [
{
parser: {
amd: false
}
}
]
}
Getting Started
Please follow the installation instruction and execute the following JS code:
var Api = require('api');
var defaultClient = Api.ApiClient.instance;
// Configure API key authorization: x-ncp-iam
var x-ncp-iam = defaultClient.authentications['x-ncp-iam'];
x-ncp-iam.apiKey = "YOUR API KEY"
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//x-ncp-iam.apiKeyPrefix['x-ncp-iam'] = "Token"
var api = new Api.V2Api()
var packageName = "packageName_example"; // {String} packageName
var actionName = "actionName_example"; // {String} actionName
var opts = {
'platform': "platform_example" // {String} platform
};
api.deleteAction(packageName, actionName, opts).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Documentation for API Endpoints
All URIs are relative to https://cloudfunctions.apigw.ntruss.com/api/v2
Class | Method | HTTP request | Description ------------ | ------------- | ------------- | ------------- Api.V2Api | deleteAction | DELETE /packages/{packageName}/actions/{actionName} | Api.V2Api | deletePackage | DELETE /packages/{packageName} | Api.V2Api | deleteTrigger | DELETE /triggers/{triggerName} | Api.V2Api | deleteTriggerLinkAction | DELETE /triggers/{triggerName}/link-action | Api.V2Api | getAction | GET /packages/{packageName}/actions/{actionName} | Api.V2Api | getActionActivationDetail | GET /packages/{packageName}/actions/{actionName}/activations/{activationId} | Api.V2Api | getActionActivationList | GET /packages/{packageName}/actions/{actionName}/activations | Api.V2Api | getActionList | GET /packages/{packageName}/actions | Api.V2Api | getActivationList | GET /activations | Api.V2Api | getPackage | GET /packages/{packageName} | Api.V2Api | getPackageList | GET /packages | Api.V2Api | getTrigger | GET /triggers/{triggerName} | Api.V2Api | getTriggerActivationDetail | GET /triggers/{triggerName}/activations/{activationId} | Api.V2Api | getTriggerActivationList | GET /triggers/{triggerName}/activations | Api.V2Api | getTriggerList | GET /triggers | Api.V2Api | postAction | POST /packages/{packageName}/actions/{actionName} | Api.V2Api | postActionExternalLink | POST /packages/{packageName}/actions/{actionName}/external-link-url | Api.V2Api | postTrigger | POST /triggers/{triggerName} | Api.V2Api | postTriggerExternalLink | POST /triggers/{triggerName}/external-link-url | Api.V2Api | postTriggerLinkAction | POST /triggers/{triggerName}/link-action | Api.V2Api | putAction | PUT /packages/{packageName}/actions/{actionName} | Api.V2Api | putPackage | PUT /packages/{packageName} |
Documentation for Models
- Api.ActionExec
- Api.ActionLimits
- Api.ActionMeta
- Api.ActionPath
- Api.ActivationResult
- Api.ActivationStatus
- Api.BasicTrigger
- Api.CloudIotCoreTrigger
- Api.CronTrigger
- Api.DeleteTriggerLinkActionRequest
- Api.GetActionListResponse
- Api.GetActionResponse
- Api.GetActivationDetailResponse
- Api.GetActivationListResponse
- Api.GetPackageListResponse
- Api.GetPackageResponse
- Api.GetTriggerListResponse
- Api.GetTriggerResponse
- Api.GithubCredential
- Api.GithubTrigger
- Api.InsightLink
- Api.InsightTrigger
- Api.IotLink
- Api.Link
- Api.ObjectStorageLink
- Api.ObjectStorageTrigger
- Api.PackageMeta
- Api.PostActionExternalLinkRequest
- Api.PostActionExternalLinkResponse
- Api.PostActionResponse
- Api.PostTriggerExternalLinkRequest
- Api.PostTriggerExternalLinkResponse
- Api.PostTriggerLinkActionRequest
- Api.PostTriggerLinkActionResponse
- Api.PutActionRequest
- Api.PutActionResponse
- Api.PutBasicTriggerRequest
- Api.PutBasicTriggerResponse
- Api.PutCloudInsightTriggerRequest
- Api.PutCloudInsightTriggerResponse
- Api.PutCloudIoTCoreTriggerRequest
- Api.PutCloudIoTCoreTriggerResponse
- Api.PutCronTriggerRequest
- Api.PutCronTriggerResponse
- Api.PutGithubTriggerRequest
- Api.PutGithubTriggerResponse
- Api.PutObjectStorageTriggerRequest
- Api.PutObjectStorageTriggerResponse
- Api.PutSourceCommitTriggerRequest
- Api.PutSourceCommitTriggerResponse
- Api.PutPackageRequest
- Api.PutPackageResponse
- Api.TriggerMeta
- Api.TriggerPath
- Api.VPC
Documentation for Authorization
x-ncp-iam
- Type: API key
- API key parameter name: x-ncp-iam
- Location: HTTP header