micro

package module
v0.0.0-...-795d1ad Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2021 License: Apache-2.0 Imports: 29 Imported by: 0

README

Micro Go Client

A typesafe generated Go client for Micro services

package main

import (
	"fmt"
	"os"

	"github.com/micro/micro-go"
)

func main() {
	c := micro.NewClient(os.Getenv("MICRO_TOKEN"))
	rsp, err := c.HelloworldService.Call(micro.HelloworldCallRequest{
		Name: "Janos",
	})
	fmt.Println(rsp, err)
}

Beta warning

This package is highly experimental. You might notice request and response types not matching the APIs found on m3o. In that case let us know.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	AddressService    *address.AddressService
	AnswerService     *answer.AnswerService
	CacheService      *cache.CacheService
	CryptoService     *crypto.CryptoService
	CurrencyService   *currency.CurrencyService
	DbService         *db.DbService
	EmailService      *email.EmailService
	EmojiService      *emoji.EmojiService
	FileService       *file.FileService
	ForexService      *forex.ForexService
	GeocodingService  *geocoding.GeocodingService
	HelloworldService *helloworld.HelloworldService
	IdService         *id.IdService
	ImageService      *image.ImageService
	IpService         *ip.IpService
	LocationService   *location.LocationService
	OtpService        *otp.OtpService
	PostcodeService   *postcode.PostcodeService
	RoutingService    *routing.RoutingService
	RssService        *rss.RssService
	SentimentService  *sentiment.SentimentService
	SmsService        *sms.SmsService
	StockService      *stock.StockService
	StreamService     *stream.StreamService
	ThumbnailService  *thumbnail.ThumbnailService
	TimeService       *time.TimeService
	UrlService        *url.UrlService
	UserService       *user.UserService
	WeatherService    *weather.WeatherService
	// contains filtered or unexported fields
}

func NewClient

func NewClient(token string) *Client

Jump to

Keyboard shortcuts

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