~timharek/openlibrary-go

chore: Add license
docs: Add contributing

clone

read-only
https://git.sr.ht/~timharek/openlibrary-go
read/write
git@git.sr.ht:~timharek/openlibrary-go

You can also use your local clone with git send-email.

#OpenLibrary API client in Go

API client for OpenLibrary's API for searching books, authors etc.

#Supported APIs

Feel free to submit patches to extend API coverage.

#Books

  • [x] Search
  • [x] Get by ID
  • [x] Get by ISBN

#Authors

  • [x] Get by ID
  • [ ] Search

#Subjects

  • [x] Get by ID or name
  • [ ] Search

#Usage

go get git.sr.ht/~timharek/openlibrary-go

Create a new client:

import (
	"git.sr.ht/~timharek/openlibrary-go"
	"git.sr.ht/~timharek/openlibrary-go/book"
)


func something() (*book.SearchResult, error) {
  ol := openlibrary.New()

  searchResult, err := ol.Book.Search("sapiens")
  if err != nil {
    return nil, err
  }

  return searchResult, nil
}

#Contributing

Anyone can contribute to openlibrary-go. Please refer to the contribution guidelines.

Send patches to the mailing list, report bugs on the issue tracker.