--- title: "Put Trigger" slug: "compute-cloudfunctions-v2-puttrigger" tags: ["Cloud Functions"] updated: 2026-09-17T10:05:57Z published: 2026-09-17T10:05:57Z canonical: "api.ncloud-docs.com/compute-cloudfunctions-v2-puttrigger" --- > ## Documentation Index > Fetch the complete documentation index at: https://api.ncloud-docs.com/llms.txt > Use this file to discover all available pages before exploring further. # Put Trigger Available in Classic and VPC Create or edit a Cloud Functions trigger. ## Request This section describes the request format. The method and URI are as follows: | Method | URI | | --- | --- | | PUT | /ncf/api/v2/triggers/{triggerName} | Note Singapore and Japan Regions are available only in the VPC environment. ### Request headers For information about the headers common to all Cloud Functions APIs, see [Cloud Functions request headers](/docs/en/compute-cloudfunctions#%EC%9A%94%EC%B2%AD%ED%97%A4%EB%8D%94). ### Request path parameters You can use the following path parameters with your request: | Field | Type | Required | Description | | --- | --- | --- | --- | | `triggerName` | String | Required | Trigger name - Enter 1-50 characters, including English letters, numbers, and special characters "-" and "_". - It can't start with "-". - It can't be duplicated with other resource (package, action, trigger) names. | ### Request query parameters You can use the following query parameters with your request: | Field | Type | Required | Description | | --- | --- | --- | --- | | `platform` | String | Optional | Platform type - `vpc` (default) \| `classic` | | `type` | String | Required | Trigger type - `cron` \| `github` \| `insight` \| `object_storage` \| `source_commit` \| `secret_manager` - Can't be changed after creation | ### Request body You can include the following data in the body of your request: If there are no fields in the request body, it should be requested as `{}` empty JSON object. #### Common The following describes the common request body. | Field | Type | Required | Description | | --- | --- | --- | --- | | `description` | String | Optional | Trigger description (byte) - 0-3000 | | `parameters` | Object | Optional | Default parameters of the trigger - JSON in the form of `{"key": "value"}` - Priority of applying parameters when running triggers - 1st priority: Runtime parameters passed at runtime - 2nd priority: Default parameters of connected triggers - 3rd priority: Default parameters in actions - 4th priority: Default parameters of included packages | #### cron trigger The following describes the request body for cron triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `cronOption` | String | Required | cron execution option - See [cron trigger (VPC)](https://guide.ncloud-docs.com/docs/en/cloudfunctions-cron-vpc) and [cron trigger (Classic)](https://guide.ncloud-docs.com/docs/en/cloudfunctions-cron-classic). | #### GitHub trigger The following describes the request body for GitHub triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `credential` | Object | Required | GitHub information | | `credential.username` | String | Required | GitHub username | | `credential.accessToken` | String | Required | GitHub access token | | `credential.repository` | String | Required | GitHub repository - Enter the repository name or in the format `organization/repository name`. | | `events` | String[] | Required | Event to trigger - `*` \| `check_run` \| `check_suite` \| `commit_comment` \| `create` \| `delete` \| `deployment` \| `deployment_status` \| `fork` \| `gollum` \| `issue_comment` \| `issues` \| `label` \| `member` \| `milestone` \| `page_build` \| `project_card` \| `project_column` \| `project` \| `public` \| `pull_request_review_comment` \| `pull_request_review_thread` \| `pull_request_review` \| `pull_request` \| `push` \| `repository` \| `repository_import` \| `repository_vulnerability_alert` \| `release` \| `status` \| `team_add` \| `watch` \| `branch_protection_rule` \| `code_scanning_alert` \| `deploy_key` \| `discussion_comment` \| `discussion` \| `meta` \| `package` \| `registry_package` \| `secret_scanning_alert_location` \| `secret_scanning_alert` \| `security_and_analysis` \| `star` \| `workflow_job` \| `workflow_run` | | `link` | Object | Conditional | API Gateway information - Valid only when creating a trigger and required | | `link.productName` | String | Conditional | API Gateway's product name | | `link.apiName` | String | Conditional | API Gateway API name | | `link.stageName` | String | Conditional | API Gateway's stage name | #### Cloud Insight trigger The following describes the request body for Cloud Insight triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `insightLink` | Array | Optional | Event rule information of Cloud Insight to connect: [insightLink](/docs/en/compute-cloudfunctions-v2-puttrigger#insightLink) | #### `insightLink` The following describes `insightLink`. | Field | Type | Required | Description | | --- | --- | --- | --- | | `prodKey` | String | Conditional | Cloud Insight event rule's prodKey - Required when entering `insightLink` | | `ruleGrpId` | String | Conditional | Cloud Insight event rule's ruleGrpId - Required when entering `insightLink` | | `reminderTime` | Integer | Optional | Cloud Insight event rule's reminder notification frequency (minute) - 5-720 | | `enableNotiWhenEventClose` | Boolean | Optional | Whether to call Cloud Insight event rules at the end of an event - `true` \| `false` (default) | #### Object Storage trigger The following describes the request body for Object Storage triggers. Caution If an action attached to an Object Storage trigger uses the same bucket as an Object Storage event rule, recursive calls can result in increased usage and excessive costs. | Field | Type | Required | Description | | --- | --- | --- | --- | | `objectStorageLink` | Array | Required | Event rule information of Object Storage to connect: [objectStorageLink](/docs/en/compute-cloudfunctions-v2-puttrigger#objectStorageLink) | #### `objectStorageLink` The following describes `objectStorageLink`. | Field | Type | Required | Description | | --- | --- | --- | --- | | `bucketName` | String | Required | Object Storage's bucket name | | `eventRuleName` | String | Required | Object Storage's event rule name | #### SourceCommit trigger The following describes the request body for SourceCommit triggers. Note SourceCommit triggers are supported only on the VPC platform of the Korea Region. | Field | Type | Required | Description | | --- | --- | --- | --- | | `sourceCommitLink` | Array | Required | Webhook information for the SourceCommit repository to connect: [sourceCommitLink](/docs/en/compute-cloudfunctions-v2-puttrigger#sourceCommitLink) | #### `sourceCommitLink` The following describes `sourceCommitLink`. | Field | Type | Required | Description | | --- | --- | --- | --- | | `enable` | Boolean | Optional | Webhook activation status of SourceCommit - `true` (default) \| `false` | | `repositoryName` | String | Required | SourceCommit repository name | | `webhookName` | String | Required | SourceCommit webhook name | #### Secret Manager trigger The following describes the request body for Secret Manager triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `secretManagerLink` | Array | Required | Secret information for Secret Manager to connect: [secretManagerLink](/docs/en/compute-cloudfunctions-v2-puttrigger#secretManagerLink) | #### `sourceCommitLink` The following describes `sourceCommitLink`. | Field | Type | Required | Description | | --- | --- | --- | --- | | `secretName` | String | Required | Secret Manager's secret name | Note - Secret Manager triggers are supported only on the VPC platform of the Korea Region. - A trigger can have multiple secrets associated with it, but only one trigger can be associated with a secret. ### Request example The request example is as follows: ``` curl --location --request PUT 'https://cloudfunctions.apigw.ntruss.com/ncf/api/v2/triggers/trigger001?platform=vpc&type=cron' \ --header 'Content-Type: application/json' \ --header 'x-ncp-apigw-timestamp: {Timestamp}' \ --header 'x-ncp-iam-access-key: {Sub Account Access Key}' \ --header 'x-ncp-apigw-signature-v2: {API Gateway Signature}' \ --data '{ "description": "Cron Trigger", "parameters": { "period": "daily" }, "cronOption": "30 1 * * *" }' ``` ## Response This section describes the response format. ### Response body The response body includes the following data: #### Common The common response body includes the following data: | Field | Type | Required | Description | | --- | --- | --- | --- | | `content` | Object | - | Trigger creation and modification information | | `content.name` | String | - | Trigger name | | `content.resourceId` | String | - | Trigger's resource ID | | `content.triggerType` | String | - | Trigger type | | `content.namespace` | String | - | Namespace of the user | | `content.description` | String | - | Trigger description | | `content.parameters` | Object | - | Default parameters of the trigger | | `content.rules` | Object | - | Trigger action connection information | #### cron trigger The following describes the response body for cron triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `content.cronOption` | String | - | Cron execution option | #### GitHub trigger The following describes the response body for GitHub triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `content.credential` | Object | - | GitHub information | | `content.credential.username` | String | - | GitHub username | | `content.credential.accessToken` | String | - | Trigger type | | `content.namespace` | String | - | GitHub access token | | `content.credential.repository` | String | - | GitHub repository | | `content.events` | String[] | - | Type of events to trigger | #### Cloud Insight trigger The following describes the response body for Cloud Insight triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `content.insightLink` | Array | - | Event rule information of the connected Cloud Insight: [insightLink](/docs/en/compute-cloudfunctions-v2-puttrigger#insightLink1) | #### `insightLink` The following describes `insightLink`. | Field | Type | Required | Description | | --- | --- | --- | --- | | `prodKey` | String | - | Cloud Insight event rule's prodKey | | `ruleGrpId` | String | - | Cloud Insight event's ruleGrpId | | `reminderTime` | Integer | - | Cloud Insight event's reminder notification frequency (minute) | | `enableNotiWhenEventClose` | Boolean | - | Whether to call Cloud Insight event rules at the end of an event | #### Object Storage trigger The following describes the response body for Object Storage triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `content.objectStorageLink` | Array | - | Event rule information of the connected Object Storage: [objectStorageLink](/docs/en/compute-cloudfunctions-v2-puttrigger#objectStorageLink1) | #### `objectStorageLink` The following describes `objectStorageLink`. | Field | Type | Required | Description | | --- | --- | --- | --- | | `bucketName` | String | - | Object Storage's bucket name | | `eventRuleName` | String | - | Object Storage's event rule name | #### SourceCommit trigger The following describes the response body for SourceCommit triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `content.sourceCommitLink` | Array | - | Webhook information for the connected SourceCommit repository: [sourceCommitLink](/docs/en/compute-cloudfunctions-v2-puttrigger#sourceCommitLink1) | #### `sourceCommitLink` The following describes `sourceCommitLink`. | Field | Type | Required | Description | | --- | --- | --- | --- | | `enable` | Boolean | - | SourceCommit webhook activation status | | `repositoryName` | String | - | SourceCommit repository name | | `webhookName` | String | - | SourceCommit webhook name | #### Secret Manager trigger The following describes the response body for Secret Manager triggers. | Field | Type | Required | Description | | --- | --- | --- | --- | | `content.secretManagerLink` | Array | - | Secret information for the connected Secret Manager: [secretManagerLink](/docs/en/compute-cloudfunctions-v2-puttrigger#secretManagerLink1) | #### `secretManagerLink` The following describes `secretManagerLink`. | Field | Type | Required | Description | | --- | --- | --- | --- | | `secretId` | String | - | Secret Manager's secret ID | ### Response status codes For information about the HTTP status codes common to all Cloud Functions APIs, see [Cloud Functions response status codes](/docs/en/compute-cloudfunctions#%EC%9D%91%EB%8B%B5%EC%83%81%ED%83%9C%EC%BD%94%EB%93%9C). ### Response example The response example is as follows: ``` { "content": { "description": "", "name": "trigger001", "namespace": "****YBNz****", "parameters": { "period": "daily" }, "resourceId": "4ci**", "rules": { "****YBNz****/qr98**: { "action": { "name": "action001", "path": "****YBNz****" }, "status": "active" }, "triggerType": "cron" } } ```