Skip to content

wolveix/openxbl-go

Repository files navigation

OpenXBL Go SDK

Interface with OpenXBL's API using Go.

Note: This is in an experimental state. PRs are always welcome!

Setup

  1. Create an account with OpenXBL
  2. Verify your email
  3. Create an API key

Login and Retrieve Account Info

package main

import (
	"fmt"
	"log"
	"time"

	"github.com/wolveix/openxbl-go"
)

func main() {
	client := openxbl.NewClient("your-api-token-here", time.Second*3)

	account, err := client.GetAccount()
	if err != nil {
		log.Fatalf("Failed to query account info: %v", err)
	}

	fmt.Println(account)
}

Roadmap

  • Implement testing for all functions
  • Support all API endpoints