PATCH /accounts/{account_id}/builds/workers/{script_tag}
Update the build configuration for a Worker script. Supports partial updates to git repository settings and production build settings.
Servers
- https://api.cloudflare.com/client/v4
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
account_id |
String | Yes | |
script_tag |
String | Yes |
The Worker script tag (external script ID) |
Request headers
| Name | Type | Required | Description |
|---|---|---|---|
Content-Type |
String | Yes |
The media type of the request body.
Default value: "application/json" |
Request body fields
| Name | Type | Required | Description |
|---|---|---|---|
git_repository |
Object | No |
Git repository settings to update |
git_repository.branch |
String | No |
New git branch to watch for builds |
production_settings |
Object | No |
Partial build settings for updating a Worker build configuration |
production_settings.path_excludes[] |
Array | No | |
production_settings.path_includes[] |
Array | No | |
production_settings.deploy_command |
String | No | |
production_settings.build_caching_enabled |
Boolean | No |
Default value: false |
production_settings.root_directory |
String | No |
Root directory path. |
production_settings.build_token_uuid |
String | No |
Build token UUID. |
production_settings.environment_variables |
Object | No |
Environment variable updates. Set the variable entry to null to delete it. |
production_settings.environment_variables.name |
Object | No | |
production_settings.environment_variables.name.is_secret |
Boolean | Yes | |
production_settings.environment_variables.name.value |
String | Yes | |
production_settings.build_command |
String | No |
How to start integrating
- Add HTTP Task to your workflow definition.
- Search for the API you want to integrate with and click on the name.
- This loads the API reference documentation and prepares the Http request settings.
- Click Test request to test run your request to the API and see the API's response.