trmnl-api 0.10.0 → 0.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 168b5086d30774ef88cc9d12ae187ffa4da349bfe10456c64a5e2fe7e94372a3
4
- data.tar.gz: d7c785269f0ddf0238d399a352cef774c9081bb6706a238cf9ead6bcc413ff0e
3
+ metadata.gz: ff7ecb483d86f9e68a550342e7e923e08ac1ef5d7330a12f4631e94e7a517438
4
+ data.tar.gz: a249a3fd8c173416d35fb2da4a15be7accf19e29e6505e667c90b4f440866047
5
5
  SHA512:
6
- metadata.gz: 4b6cdd52fa7cc10214220a4906298a1d2243d1da94f8854d1dd1eb67cdcd70a761655a717630bb561151e84c01b8926e7b9fac65e1cd84c9fb7590cddc164f7e
7
- data.tar.gz: 732532ba60f51c994898d1a982f404ba0d38b419ccc2c6cc95b46548234c51e1b40eedeeda6b4047d81b46f03408b4fccaa8dc8bef3b85dbcef70c0a4a355576
6
+ metadata.gz: 40d5b26f6f84761379eb2078048ed792eb376506c3e7bc4d59bd05f08215008be16ccff61548cbd63a302350b357174c479fefcce692cd0d34c6fac3d280dd05
7
+ data.tar.gz: c8ac0a599cf3743f67f58ac0e9021277b08327110b952b4b7c0aabf45ad3679eeae05b0bfe44dc2ea39e191c6370a857558b3422193d01edb82d49c2b4b2d4d3
checksums.yaml.gz.sig CHANGED
Binary file
data/README.adoc CHANGED
@@ -2,8 +2,8 @@
2
2
  :toclevels: 5
3
3
  :figure-caption!:
4
4
 
5
- :trmnl_link: link:https://usetrmnl.com[TRMNL]
6
- :trmnl_api_link: link:https://usetrmnl.com/api-docs/index.html[TRMNL API]
5
+ :trmnl_link: link:https://trmnl.com[TRMNL]
6
+ :trmnl_api_link: link:https://trmnl.com/api-docs/index.html[TRMNL API]
7
7
  :dry_monads_link: link:https://dry-rb.org/gems/dry-monads[Dry Monads]
8
8
 
9
9
  = TRMNL API
@@ -113,7 +113,7 @@ client.current_screen token: "secret"
113
113
  # Success(
114
114
  # #<data TRMNL::API::Models::CurrentScreen
115
115
  # refresh_rate=1773,
116
- # image_url="https://usetrmnl.com/plugin-2025-04-10T11-34-38Z-380c77",
116
+ # image_url="https://trmnl.com/plugin-2025-04-10T11-34-38Z-380c77",
117
117
  # filename="plugin-2025-04-10T11-34-38Z-380c77"
118
118
  # >
119
119
  # )
@@ -132,6 +132,7 @@ client.display token: "secret"
132
132
  # #<struct TRMNL::API::Models::Display
133
133
  # filename="plugin-1745348489",
134
134
  # firmware_url="https://trmnl-fw.s3.us-east-2.amazonaws.com/FW1.4.8.bin",
135
+ # firmware_version="1.4.8",
135
136
  # image_url="https://trmnl.s3.us-east-2.amazonaws.com/plugin-1745348489",
136
137
  # image_url_timeout=0,
137
138
  # refresh_rate=1771,
@@ -302,11 +303,11 @@ Success(
302
303
 
303
304
  ==== Recipes
304
305
 
305
- Allows you to obtain information about link:https://usetrmnl.com/recipes[Recipes]. Example:
306
+ Allows you to obtain information about link:https://trmnl.com/recipes[Recipes]. Example:
306
307
 
307
308
  [source,ruby]
308
309
  ----
309
- client = TRMNL::API.new { |settings| settings.uri = "https://usetrmnl.com" }
310
+ client = TRMNL::API.new { |settings| settings.uri = "https://trmnl.com" }
310
311
 
311
312
  client.recipes # Answers first page.
312
313
  client.recipes page: 10 # Answers page ten.
@@ -376,7 +377,7 @@ client.recipes sort: "popularity" # Answers first page sorted by popularity.
376
377
  # )
377
378
  ----
378
379
 
379
- ⚠️ This _does not_ use the {trmnl_api_link} like every other endpoint documented here. Instead, you must customize the settings URI to point to the root of the TRMNL application (i.e. `https://usetrmnl.com`) instead of using the default API endpoint.
380
+ ⚠️ This _does not_ use the {trmnl_api_link} like every other endpoint documented here. Instead, you must customize the settings URI to point to the root of the TRMNL application (i.e. `https://trmnl.com`) instead of using the default API endpoint.
380
381
 
381
382
  You'll always get a `data` array which may or may not be filled and `meta` (metadata) for handling pagination information. You can also combine the `page`, `search`, and `page` parameters as you see fit.
382
383
 
@@ -393,7 +394,7 @@ client.setup id: "A1:B2:C3:D4:E5:F6"
393
394
  # #<data TRMNL::API::Models::Setup
394
395
  # api_key="secret",
395
396
  # friendly_id="F51FDE",
396
- # image_url="https://usetrmnl.com/images/setup/setup-logo.bmp",
397
+ # image_url="https://trmnl.com/images/setup/setup-logo.bmp",
397
398
  # message="Register at usetrmnl.com/signup with Device ID 'F51FDE'"
398
399
  # >
399
400
  # )
@@ -429,4 +430,4 @@ bin/rake
429
430
  == Credits
430
431
 
431
432
  * Built with link:https://alchemists.io/projects/gemsmith[Gemsmith].
432
- * Engineered by link:https://usetrmnl.com/developers[TRMNL].
433
+ * Engineered by link:https://trmnl.com/developers[TRMNL].
@@ -13,7 +13,7 @@ module TRMNL
13
13
  def call
14
14
  model[
15
15
  content_type: environment.fetch("TRMNL_API_CONTENT_TYPE", "application/json"),
16
- uri: environment.fetch("TRMNL_API_URI", "https://usetrmnl.com/api")
16
+ uri: environment.fetch("TRMNL_API_URI", "https://trmnl.com/api")
17
17
  ]
18
18
  end
19
19
 
@@ -9,6 +9,7 @@ module TRMNL
9
9
  Display = Dry::Schema.JSON do
10
10
  required(:filename).filled :string
11
11
  required(:firmware_url).filled :string
12
+ optional(:firmware_version).maybe :string
12
13
  required(:image_url).filled :string
13
14
  required(:refresh_rate).filled :integer
14
15
  required(:reset_firmware).filled :bool
@@ -7,6 +7,7 @@ module TRMNL
7
7
  Display = Struct.new(
8
8
  :filename,
9
9
  :firmware_url,
10
+ :firmware_version,
10
11
  :image_url,
11
12
  :image_url_timeout,
12
13
  :refresh_rate,
data/trmnl-api.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "trmnl-api"
5
- spec.version = "0.10.0"
5
+ spec.version = "0.11.0"
6
6
  spec.authors = ["TRMNL"]
7
7
  spec.email = ["engineering@usetrmnl.com"]
8
8
  spec.homepage = "https://github.com/usetrmnl/trmnl-api"
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trmnl-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.0
4
+ version: 0.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - TRMNL
metadata.gz.sig CHANGED
Binary file