Go
Add Dependency
Add the SDK dependency.
go get github.com/hackle-io/hackle-go-sdkSDK Initialization
hackle.Client is the class that provides methods for using SDK features.
To use the SDK, you need to initialize hackle.Client.
Instantiation
Instantiate hackle.Client by passing the SDK Key.
hackle.Client periodically synchronizes with the Hackle server as a background task to obtain the necessary information.
You can find the SDK Key in SDK Integration Info located inside the Hackle Service Dashboard.
import "github.com/hackle-io/hackle-go-sdk/hackle"
// YOUR_SERVER_SDK_KEY 자리에 SDK 키를 넣습니다.
hackleClient := hackle.NewClient(YOUR_SERVER_SDK_KEY, nil)Shutdown
You must call the close() method when the application shuts down.
This releases resources in use and sends any remaining events.
Last updated