You need to enable JavaScript to run this app.
Volcano Engine Function as a Service

Volcano Engine Function as a Service

Copy page
Download PDF
Timer trigger
CreateTimer
Copy page
Download PDF
CreateTimer
Call the CreateTimer interface to create a Timer Trigger in the specified function.​
Request description​
  • Request method: POST​
  • Request address: http://open.volcengineapi.com/?Action=CreateTimer&Version=2024-06-06​
Debugging​
API Explorer
You can initiate calls online through API Explorer without paying attention to the signature generation process and quickly obtain the call results.
​
Request parameter​
​
Parameter​
Type​
Required or Not​
Sample value​
Description​
Action​
String​
Yes​
CreateTimer​
Interface name. The current API is called CreateTimer.​
Version​
String​
Yes​
2024-06-06​
Interface version. The current version of the API is 2024-06-06.​
FunctionId​
String​
Yes​
qtqzj***​
Specify a function ID, and create a Timer Trigger in this function.​
Name​
String​
Yes​
doc-timer​
Custom settings for the name of the Timer Trigger.​
  • Supports uppercase and lowercase letters, numbers, and dashes (-), and can only start with letters.​
  • The length is between 4 and 64 characters.​
Description​
String​
No​
Timer Trigger​
The remarks information for the Timer Trigger.​
Enabled​
Boolean​
No​
true​
Whether the Timer Trigger is enabled or not.​
  • true: Default, enabled​
  • false: Turned off​
Crontab​
String​
Yes​
*/5 * * * *​
Set the timed triggering time for Timer Triggers. The time format is a crontab expression. You can access crontab guru to view the meanings of the crontab expression.​
Payload​
String​
No​
{"body": "create event payload"}​
The Timer Trigger sends the requested content payload, which is the trigger message. The length should not exceed 1,000 unicode characters.​
EnableConcurrency​
Boolean​
No​
false​
Whether the Timer Trigger allows concurrency.​
  • true: Concurrency is allowed. After turning on, when the specific trigger has not finished the last request, it will not wait until the last request is finished and directly processes the next request in concurrency.​
  • false: Default, prohibits concurrency.​
Retries​
Integer​
No​
0​
The number of retries for the Timer Trigger.​
​
Sample request​
​
POST http://open.volcengineapi.com/?Action=CreateTimer&Version=2024-06-06 HTTP/1.1​
Content-Type: application/json​
{​
"FunctionId": "qtqzj **",​
"Name": "doc-timer",​
"Description": "Timer Trigger",​
"Enabled": true,​
"Crontab": "*/5 * * * *",​
"EnableConcurrency": false​
}​
​
Response parameter​
​
Parameter​
Type​
Sample value​
Description​
FunctionId​
String​
qtqzj**​
Function ID.​
Id​
String​
v02ww8**​
Timer Trigger ID.​
Name​
String​
doc-timer​
Timer Trigger name.​
Description​
String​
Timer Trigger​
The remarks information for the Timer Trigger.​
Enabled​
Boolean​
true​
Timer Trigger whether enabled or not, true means enabled.​
Crontab​
String​
*/5 * * * *​
The triggering time of the Timer Trigger in the format of a crontab expression.​
Payload​
String​
{"body": "update event payload"}​
The Timer Trigger sends the requested payload, which is the trigger message.​
CreationTime​
String​
2024-06-14 15:31:07.143863441 +0800 CST m=+88714.902440864​
Timer Trigger creation time.​
LastUpdateTime​
String​
2024-06-14 15:31:07.143863441 +0800 CST m=+88714.902440864​
Timer Trigger update time.​
EnableConcurrency​
Boolean​
true​
Whether the Timer Trigger allows concurrency, true means concurrency is allowed.​
Retries​
Integer​
0​
The number of retries for the Timer Trigger.​
​
Sample response​
​
HTTP/1.1 200 OK​
Content-Type: application/json​
{​
"ResponseMetadata": {​
"RequestId": "202411291616311B603AD90**",​
"Action": "CreateTimer",​
"Version": "2024-06-06",​
"Service": "vefaas",​
"Region": "cn-Beijing"​
},​
"Result": {​
"FunctionId": "qtqzj **",​
"Id": "ing3qa2 **",​
"Name": "doc-timer",​
"Description": "Timer Trigger",​
"Enabled": true,​
"Crontab": "*/5 * * * *",​
"Payload": "",​
"CreationTime": "2024-11-29 16:16:31.540584873 + 0800 CST m =+ 65768.359252459",​
"LastUpdateTime": "2024-11-29 16:16:31.540584953 + 0800 CST m =+ 65768.359252522",​
"EnableConcurrency": false,​
"Retries": 0​
}​
}​
​
Error code​
The current interface temporarily has no independent error code. If the interface calls back abnormally, you can refer to the Public error code to troubleshoot.​
Last updated: 2025.06.30 11:48:53