Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/jupiterone/jupiterone-client-go


https://github.com/jupiterone/jupiterone-client-go

Last synced: 7 days ago
JSON representation

Awesome Lists containing this project

README

        

# JupiterOne Client Go

## Requirements

- [Go](https://golang.org/doc/install)

## Usage

```go
package main

import (
"fmt"

j1 "github.com/jupiterone/jupiterone-client-go/jupiterone"
)

func main() {
var entityProps j1.EntityProperties

// Set configuration
config := j1.Config{
APIKey: "api_key",
AccountID: "accountid",
Region: "dev",
}

entityProps.Key = "go-client-key"
entityProps.Type = "go_client_type"
entityProps.Class = "Record"

//Initialize client
client, err := j1.NewClient(&config)

if err != nil {
fmt.Println("failed to create JupiterOne client: %s", err.Error())
}

//Do stuffs
// fmt.Print(client)
fmt.Print(client.Entity.Create(entityProps))
}

```