The Wayback Machine - http://web.archive.org/web/20221117221742/https://github.com/apex/logs
Skip to content

apex/logs

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Go client for Apex Logs.

Example

Error handling is omitted for brevity.

c := logs.Client{
  URL: "<ENDPOINT>",
  AuthToken: "<TOKEN>",
}

res, _ := c.GetProjects()

for _, project := range res.Projects {
  stats, _ := c.GetProjectStats(logs.GetProjectStatsInput{
    ProjectID: project.ID,
  })

  fmt.Printf("%s has %d logs\n", project.Name, stats.EventsTotal)
}

Resources

To learn more about Apex Logs visit the documentation, and to contribute to this client visit the github.com/apex/rpc project which is used to generate this client.