Skip to content

Commit cf42d44

Browse files
committed
migrate from Gelato guide
1 parent d044424 commit cf42d44

File tree

5 files changed

+782
-0
lines changed

5 files changed

+782
-0
lines changed

src/config/sidebar.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -461,6 +461,11 @@ export const SIDEBAR: Partial<Record<Sections, SectionEntry[]>> = {
461461
title: "CRE Templates Hub",
462462
url: "https://docs.chain.link/cre-templates",
463463
},
464+
{
465+
title: "Custom Data Feed Template",
466+
url: "cre/templates/running-demo-workflow",
467+
highlightAsCurrent: ["cre/templates/running-demo-workflow-ts", "cre/templates/running-demo-workflow-go"],
468+
},
464469
],
465470
},
466471
{
@@ -562,6 +567,11 @@ export const SIDEBAR: Partial<Record<Sections, SectionEntry[]>> = {
562567
},
563568
],
564569
},
570+
{
571+
title: "Migrate from Gelato",
572+
url: "cre/reference/gelato-migration",
573+
highlightAsCurrent: ["cre/reference/gelato-migration-ts", "cre/reference/gelato-migration-go"],
574+
},
565575
],
566576
},
567577
],

src/content/cre/llms-full-go.txt

Lines changed: 183 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13984,6 +13984,189 @@ The typical project setup flow for Go workflows:
1398413984

1398513985
---
1398613986

13987+
# Migrate from Gelato Web3 Functions to Chainlink CRE
13988+
Source: https://docs.chain.link/cre/reference/gelato-migration-go
13989+
Last Updated: 2026-02-16
13990+
13991+
<Aside type="note" title="SDK Language: Go">
13992+
You're viewing the **Go** version of this guide. If you prefer TypeScript, use the language selector in the left
13993+
sidebar to switch to the TypeScript version.
13994+
</Aside>
13995+
13996+
This page provides a concise mapping of Gelato Web3 Functions concepts to their CRE equivalents.
13997+
13998+
[CRE](/cre) runs your code across a [Decentralized Oracle Network (DON)](/cre/key-terms#decentralized-oracle-network-don) — a group of independent nodes that each execute your workflow and reach [consensus](/cre/concepts/consensus-computing) on the result.
13999+
14000+
Unlike a single-executor model, every operation — API calls, blockchain reads, onchain writes — is cryptographically verified by multiple nodes, giving your workflows institutional-grade security and reliability with no single point of failure.
14001+
14002+
If any term below is unfamiliar, see the [Key Terms](/cre/key-terms) glossary.
14003+
14004+
## Terminology
14005+
14006+
The core concepts map closely between platforms, but the names differ:
14007+
14008+
| Gelato | CRE | Notes |
14009+
| ------------------------------ | ------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------- |
14010+
| **Web3 Function** | **Workflow** | Your compiled application. In CRE, workflows are WASM binaries deployed to a [DON](/cre/key-terms#decentralized-oracle-network-don). |
14011+
| **`onRun` function** | **Callback** | The function containing your business logic, invoked when a trigger fires. |
14012+
| **Task** | **Handler** | The binding of a trigger to a callback: `cre.Handler(trigger, callback)`. |
14013+
| **Trigger (time/event/block)** | **Trigger (cron/EVM log/HTTP)** | The event that starts execution. CRE adds HTTP triggers. |
14014+
| **Gelato Executor** | **Workflow DON** | The infrastructure that runs your code. CRE uses a Decentralized Oracle Network instead of a single executor. |
14015+
| **Gelato Relay** | **Capability DON** | The service that performs specific operations (chain writes, HTTP fetches). Each [capability](/cre/capabilities) runs on its own DON with consensus. |
14016+
| **`userArgs` / `schema.json`** | **Config / `config.json`** | Runtime parameters. CRE uses typed Go structs for configuration schemas. |
14017+
| **`context.secrets`** | **`runtime.GetSecret()`** | Secret access at runtime. CRE uses a `secrets.yaml` manifest + [Vault DON](/cre/guides/workflow/secrets/using-secrets-deployed) for deployed workflows. |
14018+
14019+
## Configuration
14020+
14021+
**Gelato** uses a combination of the Gelato UI, SDK, and IPFS for task creation and deployment. Configuration is split between `schema.json` (for `userArgs`), the UI (for triggers and secrets), and your function code.
14022+
14023+
**CRE** consolidates everything into files within your code repository:
14024+
14025+
| File | Purpose |
14026+
| ---------------------- | --------------------------------------------------------------------------------------- |
14027+
| `main.go` | Your workflow code (triggers, callbacks, business logic) |
14028+
| `config.<target>.json` | Runtime parameters per target (e.g., `config.staging.json`). Replaces Gelato `userArgs` |
14029+
| `secrets.yaml` | Declares secret names; values come from `.env` (simulation) or Vault DON (deployed) |
14030+
| `project.yaml` | Project-level configuration (project name, shared settings) |
14031+
| `workflow.yaml` | Per-workflow configuration (workflow name, paths to artifacts and config files) |
14032+
14033+
All deployment and management is done through the CRE CLI (`cre workflow simulate`, `cre workflow deploy`, etc.), not a separate UI or IPFS.
14034+
14035+
## Triggers
14036+
14037+
### Time-based
14038+
14039+
**Gelato**: Time intervals (e.g., "every 5 minutes") or cron expressions, configured through the UI or SDK.
14040+
14041+
**CRE**: Standard cron expressions (5 or 6 fields) configured directly in your code. Supports timezone prefixes (e.g., `TZ=America/New_York 0 9 * * 1-5`). Minimum interval is 30 seconds.
14042+
14043+
```go
14044+
// CRE cron trigger
14045+
cronTrigger := cron.Trigger(&cron.Config{Schedule: "0 */5 * * * *"})
14046+
cre.Handler(cronTrigger, onCronTrigger)
14047+
```
14048+
14049+
See the [Cron Trigger guide](/cre/guides/workflow/using-triggers/cron-trigger) for full details.
14050+
14051+
### HTTP triggers
14052+
14053+
**Gelato**: Not natively supported as a trigger type.
14054+
14055+
**CRE**: Start a workflow execution in response to an external HTTP request. Supports authentication and passes the request body to your callback.
14056+
14057+
See the [HTTP Trigger guide](/cre/guides/workflow/using-triggers/http-trigger/overview) for details.
14058+
14059+
### Onchain events
14060+
14061+
**Gelato**: Event-based triggers that watch for smart contract events, configured in the UI.
14062+
14063+
**CRE**: `evm.LogTrigger()` watches for specific contract events. You specify contract addresses and optionally filter by event topics, directly in your workflow code.
14064+
14065+
See the [EVM Log Trigger guide](/cre/guides/workflow/using-triggers/evm-log-trigger) for details.
14066+
14067+
### Per-block triggers
14068+
14069+
**Gelato**: Native "every block" trigger type.
14070+
14071+
**CRE**: No direct equivalent. Use a short cron interval (e.g., every 30 seconds) or an EVM log trigger to achieve similar behavior.
14072+
14073+
## Task authoring and output
14074+
14075+
### Language and runtime
14076+
14077+
**Gelato**: TypeScript running in a Deno-like Node.js environment. Full access to `fetch()`, npm packages, and ethers.js.
14078+
14079+
**CRE**: Go compiled to WASM. Your workflow code is compiled to a WebAssembly binary and executed by DON nodes. The Go SDK provides built-in clients for all common operations (HTTP, EVM, secrets).
14080+
14081+
### HTTP / API calls
14082+
14083+
**Gelato**: `fetch()` or axios, running on a single executor.
14084+
14085+
**CRE**: `http.SendRequest()` — each DON node fetches independently, and results are aggregated via [consensus](/cre/concepts/consensus-computing). Your API data is validated across multiple nodes before your workflow uses it.
14086+
14087+
CRE also offers a [Confidential HTTP](/cre/capabilities/confidential-http) capability for privacy-preserving API calls — secrets are injected inside a secure enclave and responses can be optionally encrypted.
14088+
14089+
### Onchain reads
14090+
14091+
**Gelato**: `multiChainProvider.default()` with ethers.js.
14092+
14093+
**CRE**: `evm.Client` with [generated bindings](/cre/guides/workflow/using-evm-client/generating-bindings) for type-safe ABI encoding/decoding and contract interactions. A single workflow can read from and write to [multiple chains](/cre/reference/sdk/evm-client) — no need for separate infrastructure per chain.
14094+
14095+
See the [Onchain Read guide](/cre/guides/workflow/using-evm-client/onchain-read) for details.
14096+
14097+
### Onchain writes
14098+
14099+
**Gelato**: Return `{ canExec: true, callData: [...] }` from your function. Gelato relays the transaction.
14100+
14101+
**CRE**: Two-step process with consensus verification:
14102+
14103+
1. Generate a [signed report](/cre/guides/workflow/using-evm-client/onchain-write/overview) with `runtime.GenerateReport()`
14104+
2. Submit it onchain with `evm.Client.WriteReport()`
14105+
14106+
```go
14107+
// 1. Generate a signed report
14108+
report, err := runtime.GenerateReport(&cre.ReportRequest{
14109+
EncodedPayload: encodedValue,
14110+
}).Await()
14111+
14112+
// 2. Submit the report onchain (using generated binding helper)
14113+
txResult, err := contract.WriteReportFromMyResult(runtime, report, &evm.GasConfig{
14114+
GasLimit: gasLimit,
14115+
}).Await()
14116+
```
14117+
14118+
The **[KeystoneForwarder](/cre/guides/workflow/using-evm-client/onchain-write/overview)** contract verifies the DON's signatures before calling your [consumer contract](/cre/guides/workflow/using-evm-client/onchain-write/building-consumer-contracts). This is the biggest architectural difference — CRE writes are cryptographically verified by the decentralized network, not relayed by a single executor.
14119+
14120+
See the [Onchain Write guide](/cre/guides/workflow/using-evm-client/onchain-write/overview) and [Building Consumer Contracts](/cre/guides/workflow/using-evm-client/onchain-write/building-consumer-contracts).
14121+
14122+
### Secrets
14123+
14124+
**Gelato**: `context.secrets.get("KEY")`, configured in the UI.
14125+
14126+
**CRE**: Declare secrets in `secrets.yaml`, provide values via `.env` (simulation) or Vault DON (deployed), access via `runtime.GetSecret()` in your code. The API is the same regardless of environment.
14127+
14128+
See the [Secrets guide](/cre/guides/workflow/secrets) for details.
14129+
14130+
## Monitoring
14131+
14132+
**Gelato**: Task dashboard in the Gelato UI showing execution history, logs, and status.
14133+
14134+
**CRE**: The [CRE UI](https://cre.chain.link) provides:
14135+
14136+
- Workflow status and lifecycle management (active, paused, etc.)
14137+
- Detailed execution logs and events
14138+
- Performance metrics and debugging tools
14139+
14140+
See the [Monitoring & Debugging guide](/cre/guides/operations/monitoring-workflows) for details.
14141+
14142+
## Deployment and lifecycle
14143+
14144+
| Action | Gelato | CRE |
14145+
| ------------------ | --------------------------------------- | -------------------------------------------------- |
14146+
| **Test locally** | Gelato CLI | `cre workflow simulate` |
14147+
| **Deploy** | Upload to IPFS + create task via UI/SDK | `cre workflow deploy` |
14148+
| **Pause / Resume** | UI | `cre workflow activate` / `cre workflow pause` |
14149+
| **Update** | Redeploy to IPFS + update task | Redeploy with `cre workflow deploy` |
14150+
| **Delete** | UI | `cre workflow delete` |
14151+
| **Monitor** | Gelato dashboard | CRE UI at [cre.chain.link](https://cre.chain.link) |
14152+
14153+
## Pricing
14154+
14155+
CRE is currently in Early Access. For pricing details, reach out via the in-app support on the CRE platform at <a href="https://cre.chain.link" target="_blank" rel="noopener noreferrer">cre.chain.link</a>.
14156+
14157+
## Get started
14158+
14159+
You can have a working CRE workflow running locally in minutes:
14160+
14161+
1. **[Start the Getting Started tutorial](/cre/getting-started/overview)** — build your first workflow from scratch, step by step
14162+
2. **[Create your CRE account](https://cre.chain.link)** — [Account setup guide](/cre/account/creating-account)
14163+
3. **[Install the CRE CLI](/cre/getting-started/cli-installation)**
14164+
4. **[Run a demo](/cre/templates/running-demo-workflow)** — see a complete workflow in
14165+
action with a single command
14166+
5. **[Browse the templates](/cre/templates)** — see complete workflow examples you can clone and customize
14167+
14168+
---
14169+
1398714170
# Project Configuration
1398814171
Source: https://docs.chain.link/cre/reference/project-configuration-go
1398914172
Last Updated: 2026-02-03

0 commit comments

Comments
 (0)