Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/oz/pinboard.cr
A crystal client for the Pinboard API
https://github.com/oz/pinboard.cr
api crystal pinboard
Last synced: 2 months ago
JSON representation
A crystal client for the Pinboard API
- Host: GitHub
- URL: https://github.com/oz/pinboard.cr
- Owner: oz
- License: mit
- Created: 2017-07-30T02:22:45.000Z (almost 7 years ago)
- Default Branch: main
- Last Pushed: 2022-01-26T03:38:34.000Z (over 2 years ago)
- Last Synced: 2024-01-27T09:10:12.810Z (5 months ago)
- Topics: api, crystal, pinboard
- Language: Crystal
- Homepage: https://git.cypr.io/oz/pinboard.cr
- Size: 27.3 KB
- Stars: 5
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Lists
- awesome-crystal - pinboard.cr - [Pinboard](https://pinboard.in) API (Third-party APIs)
- awesome-crystal - pinboard.cr - [Pinboard](https://pinboard.in) API (Third-party APIs)
- awesome-crystal - pinboard.cr - [Pinboard](https://pinboard.in) API (Third-party APIs)
README
# pinboard
[![CI](https://github.com/oz/pinboard.cr/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/oz/pinboard.cr/actions/workflows/ci.yml)
A crystal client for the [Pinboard] API.
## Installation
Add this to your application's `shard.yml`:
```yaml
dependencies:
pinboard:
git: https://git.cypr.io/oz/pinboard.cr.git
```## Usage
```crystal
require "pinboard"pinboard = Pinboard::Client.new(token: "my secret token")
posts = pinboard.recent
if posts.is_a?(Pinboard::Error)
puts posts.to_s
else
posts.each do |post|
puts "#{post.title}\n url:#{post.url}\n tags: #{post.tags.join(",")}\n"
end
end
```Pinboard returns either a `Pinboard::Error`, or something else. Check the tests
to be sure.## Contributing
1. Clone `https://git.cypr.io/oz/pinboard.cr.git`,
2. Create your feature branch (`git checkout -b my-new-feature`),
3. Commit your changes (`git commit -am 'Add some feature'`),
4. Create a patch (`git format-patch origin`),
5. Send patch to `[email protected]`.## Contributors
- [oz](https://github.com/oz) Arnaud Berthomier - creator, maintainer
[Pinboard]: https://pinboard.in/