Skip to content
This repository has been archived by the owner on Dec 22, 2022. It is now read-only.

Golang Logentries Client

Notifications You must be signed in to change notification settings

depop-archive/archived-logentries

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Logentries client (golang)

Install

$ go get -d github.com/depop/logentries

Usage

Set LOGENTRIES_TOKEN environment variable with your token

package main

import (
   "fmt"
   logentries "github.com/depop/logentries"
)

func main() {
  client := logentries.New("api-key")
  resp, err := client.LogSet.Create(&logentries.LogSetCreateRequest{
  	logentries.LogSetFields{
  		Name: "foobar",
  	},
  })
  if err != nil {
  	panic(err)
  }

  fmt.Println(resp)
}