nifcloud-sdk-go

module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 30, 2020 License: Apache-2.0

README

NIFCLOUD SDK for Go

build

nifcloud-sdk-go is data-driven SDK for the Go programming language. It works by feeding AWS-SDK-compatible model JSONs to github.com/aws/aws-sdk-go-v2.

Features

  • ✔ Support for NIFCLOUD Computing / RDB / NAS / Script / Hatoba APIs
  • ✔ AWS-SDK-compatible data-driven architecture

Getting started

Requirements

  • Go 1.13 or later.

Installing

go get -u github.com/nifcloud/nifcloud-sdk-go

Example

This example shows DescribeInstances.

package main

import (
        "fmt"
        "context"

        "github.com/nifcloud/nifcloud-sdk-go/nifcloud"
        "github.com/nifcloud/nifcloud-sdk-go/nifcloud/endpoints"
        "github.com/nifcloud/nifcloud-sdk-go/service/computing"
)

func main() {
        // Create config with credentials and region.
        cfg := nifcloud.NewConfig(
                "YOUR_ACCESS_KEY_ID",
                "YOUR_SECRET_ACCESS_KEY",
                "jp-east-1",
        )

        // Create the Computing client with Config value.
        svc := computing.New(cfg)
        req := svc.DescribeInstancesRequest(nil)

        // Send the request
        resp, err := req.Send(context.TODO())
        if err != nil {
                panic(err)
        }
        fmt.Println(resp)
}

Resources

LICENCES

See LICENSE.

Directories

Path Synopsis
internal
nifcloudtesting/unit
Package unit performs initialization and validation for unit tests
Package unit performs initialization and validation for unit tests
models
endpoints
Package endpoints contains the models for endpoints that should be used to generate endpoint definition files for the SDK.
Package endpoints contains the models for endpoints that should be used to generate endpoint definition files for the SDK.
private
protocol/computing
Package computing provides serialization of NIFCLOUD Computing requests and responses.
Package computing provides serialization of NIFCLOUD Computing requests and responses.
protocol/nas
Package nas provides serialization of NIFCLOUD NAS requests and responses.
Package nas provides serialization of NIFCLOUD NAS requests and responses.
protocol/rdb
Package rdb provides serialization of NIFCLOUD RDB requests and responses.
Package rdb provides serialization of NIFCLOUD RDB requests and responses.
protocol/script
Package script provides serialization of NIFCLOUD Script requests and responses.
Package script provides serialization of NIFCLOUD Script requests and responses.
computing
Package computing provides the client and types for making API requests to computing.
Package computing provides the client and types for making API requests to computing.
computing/computingiface
Package computingiface provides an interface to enable mocking the NIFCLOUD Computing service client for testing your code.
Package computingiface provides an interface to enable mocking the NIFCLOUD Computing service client for testing your code.
hatoba
Package hatoba provides the client and types for making API requests to hatoba.
Package hatoba provides the client and types for making API requests to hatoba.
hatoba/hatobaiface
Package hatobaiface provides an interface to enable mocking the NIFCLOUD Hatoba beta service client for testing your code.
Package hatobaiface provides an interface to enable mocking the NIFCLOUD Hatoba beta service client for testing your code.
nas
Package nas provides the client and types for making API requests to nas.
Package nas provides the client and types for making API requests to nas.
nas/nasiface
Package nasiface provides an interface to enable mocking the NIFCLOUD NAS service client for testing your code.
Package nasiface provides an interface to enable mocking the NIFCLOUD NAS service client for testing your code.
rdb
Package rdb provides the client and types for making API requests to rdb.
Package rdb provides the client and types for making API requests to rdb.
rdb/rdbiface
Package rdbiface provides an interface to enable mocking the NIFCLOUD RDB service client for testing your code.
Package rdbiface provides an interface to enable mocking the NIFCLOUD RDB service client for testing your code.
script
Package script provides the client and types for making API requests to script.
Package script provides the client and types for making API requests to script.
script/scriptiface
Package scriptiface provides an interface to enable mocking the NIFCLOUD Script service client for testing your code.
Package scriptiface provides an interface to enable mocking the NIFCLOUD Script service client for testing your code.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL