Deployment
Deploy your Worker to the CoreClaw platform.
Upload Requirements
Section titled “Upload Requirements”CoreClaw supports two ways to upload your Worker scripts:
Method 1: ZIP Archive Upload
Section titled “Method 1: ZIP Archive Upload”Upload your Worker as a ZIP archive file. This is the quickest way to get started.
- Compress all project files into a ZIP archive
- Ensure the runtime entry is at the root of the ZIP:
main.pyfor Python,main.jsfor Node.js, and the compiled Linux amd64 executablemainfor Go - Upload the ZIP archive to the platform
Method 2: GitHub Import
Section titled “Method 2: GitHub Import”Import your Worker directly from a GitHub repository. This method supports version management, allowing you to track and manage different versions of your Worker.
Supported URL formats:
- HTTPS:
https://github.com/username/repository.git - SSH:
git@github.com:username/repository.git
Version management:
When importing from GitHub, you can specify which version of your code to deploy:
- Branch: Deploy the latest code from a specific branch (e.g.,
main,develop) - Tag: Deploy a specific tagged release (e.g.,
v1.0.0) - Commit: Deploy an exact commit by its SHA hash
This allows you to maintain multiple versions, roll back to previous releases, and manage your Worker’s lifecycle effectively.
All script files must strictly follow platform specifications.
Project Structure
Section titled “Project Structure”Ensure your project includes the required files before packaging:
Python:
├── main.py # Entry file├── requirements.txt # Dependencies├── input_schema.json # Input configuration├── output_schema.json # Output configuration├── sdk.py # CoreClaw SDK - Core functionality module├── sdk_pb2.py # Data processing enhancement module└── sdk_pb2_grpc.py # Network communication moduleNode.js:
├── main.js # Entry file├── package.json # Dependencies├── input_schema.json # Input configuration├── output_schema.json # Output configuration├── sdk.js # CoreClaw SDK├── sdk_pb.js # Protocol buffer definitions└── sdk_grpc_pb.js # gRPC service definitionsGo:
├── main.go # Source entry file├── go.mod # Dependencies├── go.sum # Dependency checksums├── input_schema.json # Input configuration├── output_schema.json # Output configuration└── GoSdk/ # SDK directory ├── sdk.go ├── sdk.pb.go └── sdk_grpc.pb.goFor Go Workers, keep the three layers distinct:
- Source project: contains
main.go,go.mod,go.sum,GoSdk/,input_schema.json, andoutput_schema.json. - Uploaded ZIP: must contain a Linux amd64 executable named
mainat the ZIP root. The source entry ismain.go; the upload/runtime entry is the compiledmain. - Platform runtime: does not guarantee that source files such as
main.go,go.mod,go.sum, orGoSdk/still exist in the current working directory. Only rely on files deliberately included for runtime use.
Packaging
Section titled “Packaging”- Compress all project files into a ZIP archive
- Ensure the runtime entry (
main.py/main.js/ compiled Go executablemain) is at the root of the ZIP - Upload the ZIP archive to the platform, or push to GitHub and import via repository URL
Build Process
Section titled “Build Process”After upload, CoreClaw automatically builds your Worker:
- Installs dependencies
- Sets up the script runtime environment
- Runs build checks
Monitor the build logs for any errors.
Test Environment
Section titled “Test Environment”After a successful build, you can test your Worker before publishing:
- Click Run Worker to start a test run
- Enter test input parameters
- Verify output and check logs
- Iterate on your code as needed