Skip to content

speakeasy-sdks/singlestore-sample-sdk

Repository files navigation

Golang SDK for Singlestore Management API

SDK Installation

go get github.com/speakeasy-sdks/singlestore-sample-sdk

SDK Example Usage

package main

import (
	"context"
	"log"

	singlestoresamplesdk "github.com/speakeasy-sdks/singlestore-sample-sdk"
	"github.com/speakeasy-sdks/singlestore-sample-sdk/pkg/models/operations"
)

func main() {
	s := singlestoresamplesdk.New(
		singlestoresamplesdk.WithSecurity("api-auth-key"),
	)

	endTime := ""
	startTime := ""
	aggregateBy := operations.ListBillingUsageAggregateByHour
	metric := operations.ListBillingUsageMetricComputeCredit

	ctx := context.Background()
	res, err := s.Billing.List(ctx, endTime, startTime, &aggregateBy, &metric)
	if err != nil {
		log.Fatal(err)
	}

	if res.BillingUsage != nil {
		// handle response
	}
}

Available Resources and Operations

  • List - Lists the compute and storage usage of a organization
  • Get - Gets information about the current organization
  • Create - Creates a new private connection
  • Delete - Deletes a private connection
  • Get - Gets information about a private connection
  • Update - Updates a private connection
  • List - Lists all of the regions for the user that support workspaces
  • Create - Creates a new folder or uploads a file
  • Delete - Deletes a file or folder
  • Get - Gets information about a folder or downloads a file
  • Update - Modifies a file or folder in Stages

Dev Containers

Experience our SDK in an enhanced sandbox environment. Try it now in GitHub Codespaces!

Development

Maturity

This SDK is in beta, and there may be breaking changes between versions without a major version update. Therefore, we recommend pinning usage to a specific package version. This way, you can install the same version each time without breaking changes unless you are intentionally looking for the latest version.

Contributions

While we value open-source contributions to this SDK, this library is generated programmatically. Feel free to open a PR or a Github issue as a proof of concept and we'll do our best to include it in a future release!

SDK Created by Speakeasy