Skip to content

Yohan460/go-jamf-api

Repository files navigation

Jamf API in Go

Mostly implemented Golang library for the Jamf Pro API.

The Classic API support is written manually, UAPI support is written programmatically using the OpenAPI Generator based upon the publicly available swagger docs.

Classic API Usage

Example Code

package main

import (
	"fmt"
	"time"
    "log"

	"github.com/yohan460/go-jamf-api"
)

func main() {
	url := "https://example.jamfcloud.com"
	client, err := jamf.NewClient(
        url,
        jamf.WithOAuth("client-id", "client-secret"),
    )
	if err != nil {
		log.Fatal(err)
	}

	// Use the client to make requests to the Jamf API
}

UAPI Usage

See Usage docs

UAPI Regeneration

When there is a Jamf UAPI schema upgrade the generate-api.sh file can be run with the new swagger schema as the first parameter to re-generate it

The script contains a couple of patches to ensure it is syntactically correct go code.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published