https://github.com/vetspire-vsp/ex_printnode
Small HTTPoison based wrapper around PrintNode API.
https://github.com/vetspire-vsp/ex_printnode
elixir printnode
Last synced: about 2 months ago
JSON representation
Small HTTPoison based wrapper around PrintNode API.
- Host: GitHub
- URL: https://github.com/vetspire-vsp/ex_printnode
- Owner: Vetspire-VSP
- License: mit
- Created: 2020-10-21T19:52:08.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2025-05-02T14:33:36.000Z (12 months ago)
- Last Synced: 2026-02-12T23:36:57.294Z (2 months ago)
- Topics: elixir, printnode
- Language: Elixir
- Homepage:
- Size: 24.4 KB
- Stars: 4
- Watchers: 6
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PrintNode
[](https://hex.pm/packages/ex_printnode)
[](https://hexdocs.pm/ex_printnode/)
[](https://hex.pm/packages/ex_printnode)
[](https://hex.pm/packages/ex_printnode)
[](https://github.com/Vetspire-VSP/ex_printnode/commits/master)
Small [HTTPoison](https://github.com/edgurgel/httpoison) based wrapper around [PrintNode API](https://www.printnode.com/en/docs/api/curl).
## Installation
Add `ex_printnode` to your list of dependencies in `mix.exs`:
```elixir
def deps do
[
{:ex_printnode, "~> 0.1.2"}
]
end
```
## Usage
Available methods - use with your API key:
```elixir
PrintNode.Computers.list(api_key: printnode_api_key)
PrintNode.Computers.get(computer_set, api_key: printnode_api_key)
PrintNode.Printers.list(api_key: printnode_api_key)
PrintNode.Printers.list_by_computer(computer_set, api_key: printnode_api_key)
PrintNode.Printers.get(printer_set, api_key: printnode_api_key)
PrintNode.PrintJobs.list(api_key: printnode_api_key)
PrintNode.PrintJobs.get(printjob_set, api_key: printnode_api_key)
```
### Creating a Print Job
```elixir
%PrintNode.Resources.PrintJob{
title: "Test",
content: "https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf",
contentType: "pdf_uri",
source: "printjob-test",
printer: 123456
}
|> PrintNode.PrintJobs.create(api_key: printnode_api_key)
```