Skip to content

lll-lll-lll-lll/go-connpass

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

申請

個人の利用ではIPアドレスをを1つに固定し、申請を出せば無償で利用できるのでこちらから申請をしてみましょう。

Install

go get github.com/lll-lll-lll-lll/go-connpass@v1.2.0

Introduction

simple request

client := &connpass.Client{}
req := &connpass.EventRequest{}
req.SetURL(connpass.CONNPASSAPI_EVENT_V1 + "?")
req.NickName = []string{"your connpass nickname"}
ctx, cancel := context.WithTimeout(context.Background(), 10*time.Second)
defer cancel()
res, _ := client.Do(ctx, req)
defer res.Body.Close()

var cRes connpass.EventResponse
body, _ := io.ReadAll(res.Body)
if err := json.Unmarshal(body, &cRes); err != nil {
	log.Fatal(err)
}
fmt.Println(cRes)

Reference

https://connpass.com/about/api/