From cb8baf4da694a0f96d1b8ad98315d14b59ffa22e Mon Sep 17 00:00:00 2001 From: Brooke Kuhlmann Date: Mon, 26 Jan 2026 10:27:21 -0700 Subject: [PATCH] Updated to using new TRMNL domain name Necessary to use the new domain and remove usage of `usetrmnl` altogether. Milestone: minor --- README.adoc | 16 ++++++++-------- lib/trmnl/api/configuration/loader.rb | 2 +- spec/lib/trmnl/api/configuration/loader_spec.rb | 6 +++--- spec/lib/trmnl/api/endpoints/recipe_spec.rb | 2 +- spec/lib/trmnl/api/endpoints/setup_spec.rb | 4 ++-- spec/lib/trmnl/api/models/setup_spec.rb | 2 +- 6 files changed, 16 insertions(+), 16 deletions(-) diff --git a/README.adoc b/README.adoc index 162e0b1..e321573 100644 --- a/README.adoc +++ b/README.adoc @@ -2,8 +2,8 @@ :toclevels: 5 :figure-caption!: -:trmnl_link: link:https://usetrmnl.com[TRMNL] -:trmnl_api_link: link:https://usetrmnl.com/api-docs/index.html[TRMNL API] +:trmnl_link: link:https://trmnl.com[TRMNL] +:trmnl_api_link: link:https://trmnl.com/api-docs/index.html[TRMNL API] :dry_monads_link: link:https://dry-rb.org/gems/dry-monads[Dry Monads] = TRMNL API @@ -113,7 +113,7 @@ client.current_screen token: "secret" # Success( # # # ) @@ -302,11 +302,11 @@ Success( ==== Recipes -Allows you to obtain information about link:https://usetrmnl.com/recipes[Recipes]. Example: +Allows you to obtain information about link:https://trmnl.com/recipes[Recipes]. Example: [source,ruby] ---- -client = TRMNL::API.new { |settings| settings.uri = "https://usetrmnl.com" } +client = TRMNL::API.new { |settings| settings.uri = "https://trmnl.com" } client.recipes # Answers first page. client.recipes page: 10 # Answers page ten. @@ -376,7 +376,7 @@ client.recipes sort: "popularity" # Answers first page sorted by popularity. # ) ---- -⚠️ 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. +⚠️ 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. 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. @@ -393,7 +393,7 @@ client.setup id: "A1:B2:C3:D4:E5:F6" # # # ) @@ -429,4 +429,4 @@ bin/rake == Credits * Built with link:https://alchemists.io/projects/gemsmith[Gemsmith]. -* Engineered by link:https://usetrmnl.com/developers[TRMNL]. +* Engineered by link:https://trmnl.com/developers[TRMNL]. diff --git a/lib/trmnl/api/configuration/loader.rb b/lib/trmnl/api/configuration/loader.rb index 204cde3..70bc293 100644 --- a/lib/trmnl/api/configuration/loader.rb +++ b/lib/trmnl/api/configuration/loader.rb @@ -13,7 +13,7 @@ module TRMNL def call model[ content_type: environment.fetch("TRMNL_API_CONTENT_TYPE", "application/json"), - uri: environment.fetch("TRMNL_API_URI", "https://usetrmnl.com/api") + uri: environment.fetch("TRMNL_API_URI", "https://trmnl.com/api") ] end diff --git a/spec/lib/trmnl/api/configuration/loader_spec.rb b/spec/lib/trmnl/api/configuration/loader_spec.rb index 8beb242..c6f4178 100644 --- a/spec/lib/trmnl/api/configuration/loader_spec.rb +++ b/spec/lib/trmnl/api/configuration/loader_spec.rb @@ -10,7 +10,7 @@ RSpec.describe TRMNL::API::Configuration::Loader do expect(loader.call).to eq( TRMNL::API::Configuration::Content[ content_type: "application/json", - uri: "https://usetrmnl.com/api" + uri: "https://trmnl.com/api" ] ) end @@ -18,13 +18,13 @@ RSpec.describe TRMNL::API::Configuration::Loader do it "answers custom configuration when environment is set" do loader = described_class.new environment: { "TRMNL_API_CONTENT_TYPE" => "application/xml", - "TRMNL_API_URI" => "https://usetrmnl.com" + "TRMNL_API_URI" => "https://trmnl.com" } expect(loader.call).to eq( TRMNL::API::Configuration::Content[ content_type: "application/xml", - uri: "https://usetrmnl.com" + uri: "https://trmnl.com" ] ) end diff --git a/spec/lib/trmnl/api/endpoints/recipe_spec.rb b/spec/lib/trmnl/api/endpoints/recipe_spec.rb index 367e3a5..53f2084 100644 --- a/spec/lib/trmnl/api/endpoints/recipe_spec.rb +++ b/spec/lib/trmnl/api/endpoints/recipe_spec.rb @@ -9,7 +9,7 @@ RSpec.describe TRMNL::API::Endpoints::Recipe do let :requester do TRMNL::API::Requester.new http: do |settings| - settings.uri = "https://usetrmnl.com" + settings.uri = "https://trmnl.com" end end diff --git a/spec/lib/trmnl/api/endpoints/setup_spec.rb b/spec/lib/trmnl/api/endpoints/setup_spec.rb index 9d9f031..6bd6f8e 100644 --- a/spec/lib/trmnl/api/endpoints/setup_spec.rb +++ b/spec/lib/trmnl/api/endpoints/setup_spec.rb @@ -21,7 +21,7 @@ RSpec.describe TRMNL::API::Endpoints::Setup do { "api_key": "abc", "friendly_id": "10CBAF", - "image_url": "https://usetrmnl.com/images/logo.bmp", + "image_url": "https://trmnl.com/images/logo.bmp", "message": "Welcome!" } JSON @@ -36,7 +36,7 @@ RSpec.describe TRMNL::API::Endpoints::Setup do TRMNL::API::Models::Setup[ api_key: "abc", friendly_id: "10CBAF", - image_url: "https://usetrmnl.com/images/logo.bmp", + image_url: "https://trmnl.com/images/logo.bmp", message: "Welcome!" ] ) diff --git a/spec/lib/trmnl/api/models/setup_spec.rb b/spec/lib/trmnl/api/models/setup_spec.rb index e1174b4..92a7814 100644 --- a/spec/lib/trmnl/api/models/setup_spec.rb +++ b/spec/lib/trmnl/api/models/setup_spec.rb @@ -8,7 +8,7 @@ RSpec.describe TRMNL::API::Models::Setup do attributes = { api_key: "abc", friendly_id: "10CBAF", - image_url: "https://usetrmnl.com/images/logo.bmp", + image_url: "https://trmnl.com/images/logo.bmp", message: "Welcome!" }