module
Version:
v0.1.1
Opens a new window with list of versions in this module.
Published: Aug 3, 2023
License: Apache-2.0
Opens a new window with license information.
README
¶
spice-functions-go
Spice.xyz Go Function handler
Getting Started
- Get the spice-functions-go package.
go get github.com/spiceai/spice-functions-go
- Wrap the function handler with the spice-functions-go handler.
// main.go
package main
import (
"fmt"
"github.com/spiceai/spice-functions-go/function"
"github.com/spiceai/gospice/v2"
)
func hello(ctx *function.FunctionCtx, duckDb *sql.DB, client *gospice.SpiceClient) error {
fmt.Println("Hello Spice Functions!")
return nil
}
func main() {
function.Run(hello)
}
Directories
¶
Click to show internal directories.
Click to hide internal directories.