From 35dbcfb3bc5c809472ab800979a6516e761255ef Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 24 Jul 2026 15:21:00 +0000 Subject: [PATCH 1/2] Use blueprint omitUndocumented instead of manual filters Bump @seamapi/blueprint to ^0.61.0 (and @seamapi/types to 1.975.0, the minimum that satisfies blueprint 0.61.0's undocumented-reference validation) and build the blueprint with the omitUndocumented option so undocumented routes, namespaces, endpoints, parameters, resources, and properties are dropped before codegen runs. The @seamapi/smith blueprint plugin does not forward omitUndocumented to createBlueprint, so smith.ts now calls createBlueprint directly. With undocumented entities already stripped from the blueprint, the manual isUndocumented filters in the route codegen are removed. This also drops undocumented resource classes and properties that the previous codegen emitted (resources were never filtered before), matching the documented API surface. Co-Authored-By: Claude Opus 4.8 Claude-Session: https://claude.ai/code/session_01AQChf9iyLCNXNhNbfH5rB2 --- codegen/lib/routes.ts | 29 +++++++------------ codegen/smith.ts | 24 +++++++++++++-- .../routes/resources/acs_credential_pool.rb | 11 ------- .../acs_credential_provisioning_automation.rb | 11 ------- lib/seam/routes/resources/acs_user.rb | 2 +- lib/seam/routes/resources/batch.rb | 2 +- .../routes/resources/bridge_client_session.rb | 13 --------- .../resources/bridge_connected_systems.rb | 11 ------- lib/seam/routes/resources/connect_webview.rb | 2 +- lib/seam/routes/resources/customer.rb | 11 ------- .../routes/resources/customization_profile.rb | 11 ------- .../routes/resources/enrollment_automation.rb | 11 ------- lib/seam/routes/resources/event.rb | 2 +- lib/seam/routes/resources/index.rb | 13 --------- lib/seam/routes/resources/magic_link.rb | 11 ------- lib/seam/routes/resources/phone_session.rb | 9 ------ lib/seam/routes/resources/space.rb | 2 +- lib/seam/routes/resources/staff_member.rb | 9 ------ .../resources/unmanaged_acs_access_group.rb | 14 --------- .../resources/unmanaged_acs_credential.rb | 14 --------- .../routes/resources/unmanaged_acs_user.rb | 14 --------- package-lock.json | 16 +++++----- package.json | 4 +-- 23 files changed, 47 insertions(+), 199 deletions(-) delete mode 100644 lib/seam/routes/resources/acs_credential_pool.rb delete mode 100644 lib/seam/routes/resources/acs_credential_provisioning_automation.rb delete mode 100644 lib/seam/routes/resources/bridge_client_session.rb delete mode 100644 lib/seam/routes/resources/bridge_connected_systems.rb delete mode 100644 lib/seam/routes/resources/customer.rb delete mode 100644 lib/seam/routes/resources/customization_profile.rb delete mode 100644 lib/seam/routes/resources/enrollment_automation.rb delete mode 100644 lib/seam/routes/resources/magic_link.rb delete mode 100644 lib/seam/routes/resources/phone_session.rb delete mode 100644 lib/seam/routes/resources/staff_member.rb delete mode 100644 lib/seam/routes/resources/unmanaged_acs_access_group.rb delete mode 100644 lib/seam/routes/resources/unmanaged_acs_credential.rb delete mode 100644 lib/seam/routes/resources/unmanaged_acs_user.rb diff --git a/codegen/lib/routes.ts b/codegen/lib/routes.ts index 74c8d3ec..80fc2d8d 100644 --- a/codegen/lib/routes.ts +++ b/codegen/lib/routes.ts @@ -158,7 +158,6 @@ const getClients = (blueprint: Blueprint): ClientModel[] => { // Namespaces without a route of their own (e.g. /acs) become clients that // only expose child clients. for (const namespace of blueprint.namespaces) { - if (namespace.isUndocumented) continue sources.set(namespace.path, { name: namespace.name, parentPath: namespace.parentPath, @@ -167,7 +166,6 @@ const getClients = (blueprint: Blueprint): ClientModel[] => { } for (const route of blueprint.routes) { - if (route.isUndocumented) continue sources.set(route.path, { name: route.name, parentPath: route.parentPath, @@ -185,9 +183,7 @@ const getClients = (blueprint: Blueprint): ClientModel[] => { clients.set(path, { name: pascalCase(namespace), namespace, - methods: source.endpoints - .filter((endpoint) => !endpoint.isUndocumented) - .map(createClientMethod), + methods: source.endpoints.map(createClientMethod), childClientIdentifiers: [], }) } @@ -209,10 +205,7 @@ const getClientNamespace = (path: string): string => path.slice(1).split('/').join('_') const getTopLevelClientNamespaces = (blueprint: Blueprint): string[] => { - const namespaces = [ - ...blueprint.namespaces.filter((namespace) => !namespace.isUndocumented), - ...blueprint.routes.filter((route) => !route.isUndocumented), - ] + const namespaces = [...blueprint.namespaces, ...blueprint.routes] .filter(({ parentPath }) => parentPath == null) .map(({ path }) => getClientNamespace(path)) return [...new Set(namespaces)].sort() @@ -224,16 +217,14 @@ const createClientMethod = (endpoint: Endpoint): ClientMethod => { return { methodName: endpoint.name, path: endpoint.path, - parameters: endpoint.request.parameters - .filter((parameter) => !parameter.isUndocumented) - .map((parameter) => ({ - name: parameter.name, - required: parameter.isRequired, - position: - endpoint.name === 'get' && parameter.name === `${returnPath}_id` - ? 0 - : undefined, - })), + parameters: endpoint.request.parameters.map((parameter) => ({ + name: parameter.name, + required: parameter.isRequired, + position: + endpoint.name === 'get' && parameter.name === `${returnPath}_id` + ? 0 + : undefined, + })), returnPath, returnResource, } diff --git a/codegen/smith.ts b/codegen/smith.ts index af369a2b..047e61ae 100644 --- a/codegen/smith.ts +++ b/codegen/smith.ts @@ -2,7 +2,8 @@ import { dirname } from 'node:path' import { fileURLToPath } from 'node:url' import layouts from '@metalsmith/layouts' -import { blueprint, getHandlebarsPartials } from '@seamapi/smith' +import { createBlueprint, TypesModuleSchema } from '@seamapi/blueprint' +import { getHandlebarsPartials } from '@seamapi/smith' import * as types from '@seamapi/types/connect' import { deleteAsync } from 'del' import Metalsmith from 'metalsmith' @@ -15,11 +16,30 @@ await Promise.all([deleteAsync('./lib/seam/routes')]) const partials = await getHandlebarsPartials(`${rootDir}/layouts/partials`) +// Build the blueprint with omitUndocumented so undocumented routes, +// namespaces, endpoints, parameters, resources, and properties are dropped +// before codegen runs. This replaces the @seamapi/smith blueprint plugin, +// which does not forward the omitUndocumented option to createBlueprint. +const setBlueprint = async ( + _files: Metalsmith.Files, + metalsmith: Metalsmith, +): Promise => { + const typesModule = TypesModuleSchema.parse({ + ...types, + codeSampleDefinitions: [], + resourceSampleDefinitions: [], + }) + const blueprint = await createBlueprint(typesModule, { + omitUndocumented: true, + }) + Object.assign(metalsmith.metadata(), { blueprint }) +} + Metalsmith(rootDir) .source('./content') .destination('../') .clean(false) - .use(blueprint({ types })) + .use(setBlueprint) .use(routes) .use( layouts({ diff --git a/lib/seam/routes/resources/acs_credential_pool.rb b/lib/seam/routes/resources/acs_credential_pool.rb deleted file mode 100644 index 3c5586d9..00000000 --- a/lib/seam/routes/resources/acs_credential_pool.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class AcsCredentialPool < BaseResource - attr_accessor :acs_credential_pool_id, :acs_system_id, :display_name, :external_type, :external_type_display_name, :workspace_id - - date_accessor :created_at - end - end -end diff --git a/lib/seam/routes/resources/acs_credential_provisioning_automation.rb b/lib/seam/routes/resources/acs_credential_provisioning_automation.rb deleted file mode 100644 index ac0a2e10..00000000 --- a/lib/seam/routes/resources/acs_credential_provisioning_automation.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class AcsCredentialProvisioningAutomation < BaseResource - attr_accessor :acs_credential_provisioning_automation_id, :credential_manager_acs_system_id, :user_identity_id, :workspace_id - - date_accessor :created_at - end - end -end diff --git a/lib/seam/routes/resources/acs_user.rb b/lib/seam/routes/resources/acs_user.rb index b59e48a4..e5e4f4de 100644 --- a/lib/seam/routes/resources/acs_user.rb +++ b/lib/seam/routes/resources/acs_user.rb @@ -5,7 +5,7 @@ module Resources class AcsUser < BaseResource attr_accessor :access_schedule, :acs_system_id, :acs_user_id, :connected_account_id, :display_name, :email, :email_address, :external_type, :external_type_display_name, :full_name, :hid_acs_system_id, :is_managed, :is_suspended, :pending_mutations, :phone_number, :salto_ks_metadata, :salto_space_metadata, :user_identity_email_address, :user_identity_full_name, :user_identity_id, :user_identity_phone_number, :workspace_id - date_accessor :created_at, :last_successful_sync_at + date_accessor :created_at include Seam::Resources::ResourceErrorsSupport include Seam::Resources::ResourceWarningsSupport diff --git a/lib/seam/routes/resources/batch.rb b/lib/seam/routes/resources/batch.rb index bdb60293..190e4ccb 100644 --- a/lib/seam/routes/resources/batch.rb +++ b/lib/seam/routes/resources/batch.rb @@ -3,7 +3,7 @@ module Seam module Resources class Batch < BaseResource - attr_accessor :access_codes, :access_grants, :access_methods, :acs_access_groups, :acs_credentials, :acs_encoders, :acs_entrances, :acs_systems, :acs_users, :action_attempts, :client_sessions, :connect_webviews, :connected_accounts, :customization_profiles, :devices, :events, :instant_keys, :noise_thresholds, :spaces, :thermostat_daily_programs, :thermostat_schedules, :unmanaged_access_codes, :unmanaged_acs_access_groups, :unmanaged_acs_credentials, :unmanaged_acs_users, :unmanaged_devices, :user_identities, :workspaces + attr_accessor :access_codes, :access_grants, :access_methods, :acs_access_groups, :acs_credentials, :acs_encoders, :acs_entrances, :acs_systems, :acs_users, :action_attempts, :client_sessions, :connect_webviews, :connected_accounts, :devices, :events, :instant_keys, :noise_thresholds, :spaces, :thermostat_daily_programs, :thermostat_schedules, :unmanaged_access_codes, :unmanaged_devices, :user_identities, :workspaces end end end diff --git a/lib/seam/routes/resources/bridge_client_session.rb b/lib/seam/routes/resources/bridge_client_session.rb deleted file mode 100644 index 78650138..00000000 --- a/lib/seam/routes/resources/bridge_client_session.rb +++ /dev/null @@ -1,13 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class BridgeClientSession < BaseResource - attr_accessor :bridge_client_machine_identifier_key, :bridge_client_name, :bridge_client_session_id, :bridge_client_session_token, :bridge_client_time_zone, :pairing_code, :tailscale_auth_key, :tailscale_hostname, :telemetry_token, :telemetry_url - - date_accessor :created_at, :pairing_code_expires_at, :telemetry_token_expires_at - - include Seam::Resources::ResourceErrorsSupport - end - end -end diff --git a/lib/seam/routes/resources/bridge_connected_systems.rb b/lib/seam/routes/resources/bridge_connected_systems.rb deleted file mode 100644 index e22a0201..00000000 --- a/lib/seam/routes/resources/bridge_connected_systems.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class BridgeConnectedSystems < BaseResource - attr_accessor :acs_system_display_name, :acs_system_id, :bridge_id, :connected_account_id, :workspace_display_name, :workspace_id - - date_accessor :bridge_created_at, :connected_account_created_at - end - end -end diff --git a/lib/seam/routes/resources/connect_webview.rb b/lib/seam/routes/resources/connect_webview.rb index 6d9e8047..f872b88d 100644 --- a/lib/seam/routes/resources/connect_webview.rb +++ b/lib/seam/routes/resources/connect_webview.rb @@ -3,7 +3,7 @@ module Seam module Resources class ConnectWebview < BaseResource - attr_accessor :accepted_capabilities, :accepted_devices, :accepted_providers, :any_device_allowed, :any_provider_allowed, :automatically_manage_new_devices, :connect_webview_id, :connected_account_id, :custom_metadata, :custom_redirect_failure_url, :custom_redirect_url, :customer_key, :device_selection_mode, :login_successful, :selected_provider, :status, :url, :wait_for_device_creation, :workspace_id + attr_accessor :accepted_capabilities, :accepted_providers, :any_provider_allowed, :automatically_manage_new_devices, :connect_webview_id, :connected_account_id, :custom_metadata, :custom_redirect_failure_url, :custom_redirect_url, :customer_key, :device_selection_mode, :login_successful, :selected_provider, :status, :url, :wait_for_device_creation, :workspace_id date_accessor :authorized_at, :created_at end diff --git a/lib/seam/routes/resources/customer.rb b/lib/seam/routes/resources/customer.rb deleted file mode 100644 index 89cc1a23..00000000 --- a/lib/seam/routes/resources/customer.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class Customer < BaseResource - attr_accessor :customer_key, :workspace_id - - date_accessor :created_at - end - end -end diff --git a/lib/seam/routes/resources/customization_profile.rb b/lib/seam/routes/resources/customization_profile.rb deleted file mode 100644 index 1faffd12..00000000 --- a/lib/seam/routes/resources/customization_profile.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class CustomizationProfile < BaseResource - attr_accessor :customer_portal_theme, :customization_profile_id, :logo_url, :message_overrides, :name, :primary_color, :secondary_color, :workspace_id - - date_accessor :created_at - end - end -end diff --git a/lib/seam/routes/resources/enrollment_automation.rb b/lib/seam/routes/resources/enrollment_automation.rb deleted file mode 100644 index 91ed104f..00000000 --- a/lib/seam/routes/resources/enrollment_automation.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class EnrollmentAutomation < BaseResource - attr_accessor :credential_manager_acs_system_id, :enrollment_automation_id, :user_identity_id, :workspace_id - - date_accessor :created_at - end - end -end diff --git a/lib/seam/routes/resources/event.rb b/lib/seam/routes/resources/event.rb index 332f86c4..d449fdfd 100644 --- a/lib/seam/routes/resources/event.rb +++ b/lib/seam/routes/resources/event.rb @@ -3,7 +3,7 @@ module Seam module Resources class SeamEvent < BaseResource - attr_accessor :access_code_errors, :access_code_id, :access_code_is_managed, :access_code_warnings, :access_grant_id, :access_grant_ids, :access_grant_key, :access_grant_keys, :access_method_id, :acs_access_group_id, :acs_credential_id, :acs_encoder_id, :acs_entrance_id, :acs_entrance_ids, :acs_system_errors, :acs_system_id, :acs_system_warnings, :acs_user_id, :action_attempt_id, :action_type, :activation_reason, :backup_access_code_id, :battery_level, :battery_status, :change_reason, :changed_properties, :client_session_id, :climate_preset_key, :code, :connect_webview_id, :connected_account_custom_metadata, :connected_account_errors, :connected_account_id, :connected_account_type, :connected_account_warnings, :cooling_set_point_celsius, :cooling_set_point_fahrenheit, :customer_key, :description, :desired_temperature_celsius, :desired_temperature_fahrenheit, :device_custom_metadata, :device_errors, :device_id, :device_ids, :device_name, :device_warnings, :ends_at, :enrollment_automation_id, :error_code, :error_message, :event_description, :event_id, :event_type, :fan_mode_setting, :from, :heating_set_point_celsius, :heating_set_point_fahrenheit, :hvac_mode_setting, :image_url, :is_backup_code, :is_fallback_climate_preset, :is_via_bluetooth, :is_via_nfc, :lower_limit_celsius, :lower_limit_fahrenheit, :method, :minut_metadata, :missing_device_ids, :motion_sub_type, :noise_level_decibels, :noise_level_nrs, :noise_threshold_id, :noise_threshold_name, :noiseaware_metadata, :reason, :requested_mutations, :space_id, :space_key, :starts_at, :status, :temperature_celsius, :temperature_fahrenheit, :thermostat_schedule_id, :to, :upper_limit_celsius, :upper_limit_fahrenheit, :user_identity_id, :video_url, :workspace_id + attr_accessor :access_code_errors, :access_code_id, :access_code_is_managed, :access_code_warnings, :access_grant_id, :access_grant_ids, :access_grant_key, :access_grant_keys, :access_method_id, :acs_access_group_id, :acs_credential_id, :acs_encoder_id, :acs_entrance_id, :acs_entrance_ids, :acs_system_errors, :acs_system_id, :acs_system_warnings, :acs_user_id, :action_attempt_id, :action_type, :activation_reason, :backup_access_code_id, :battery_level, :battery_status, :change_reason, :changed_properties, :client_session_id, :climate_preset_key, :code, :connect_webview_id, :connected_account_custom_metadata, :connected_account_errors, :connected_account_id, :connected_account_type, :connected_account_warnings, :cooling_set_point_celsius, :cooling_set_point_fahrenheit, :customer_key, :description, :desired_temperature_celsius, :desired_temperature_fahrenheit, :device_custom_metadata, :device_errors, :device_id, :device_ids, :device_name, :device_warnings, :ends_at, :error_code, :error_message, :event_description, :event_id, :event_type, :fan_mode_setting, :from, :heating_set_point_celsius, :heating_set_point_fahrenheit, :hvac_mode_setting, :image_url, :is_backup_code, :is_fallback_climate_preset, :is_via_bluetooth, :is_via_nfc, :lower_limit_celsius, :lower_limit_fahrenheit, :method, :minut_metadata, :missing_device_ids, :motion_sub_type, :noise_level_decibels, :noise_level_nrs, :noise_threshold_id, :noise_threshold_name, :noiseaware_metadata, :reason, :requested_mutations, :space_id, :space_key, :starts_at, :status, :temperature_celsius, :temperature_fahrenheit, :thermostat_schedule_id, :to, :upper_limit_celsius, :upper_limit_fahrenheit, :user_identity_id, :video_url, :workspace_id date_accessor :created_at, :occurred_at end diff --git a/lib/seam/routes/resources/index.rb b/lib/seam/routes/resources/index.rb index fe4befeb..43c6b35a 100644 --- a/lib/seam/routes/resources/index.rb +++ b/lib/seam/routes/resources/index.rb @@ -10,40 +10,27 @@ require_relative "access_method" require_relative "acs_access_group" require_relative "acs_credential" -require_relative "acs_credential_pool" -require_relative "acs_credential_provisioning_automation" require_relative "acs_encoder" require_relative "acs_entrance" require_relative "acs_system" require_relative "acs_user" require_relative "action_attempt" require_relative "batch" -require_relative "bridge_client_session" -require_relative "bridge_connected_systems" require_relative "client_session" require_relative "connect_webview" require_relative "connected_account" -require_relative "customer" require_relative "customer_portal" -require_relative "customization_profile" require_relative "device" require_relative "device_provider" -require_relative "enrollment_automation" require_relative "event" require_relative "instant_key" -require_relative "magic_link" require_relative "noise_threshold" require_relative "pagination" require_relative "phone" -require_relative "phone_session" require_relative "space" -require_relative "staff_member" require_relative "thermostat_daily_program" require_relative "thermostat_schedule" require_relative "unmanaged_access_code" -require_relative "unmanaged_acs_access_group" -require_relative "unmanaged_acs_credential" -require_relative "unmanaged_acs_user" require_relative "unmanaged_device" require_relative "user_identity" require_relative "webhook" diff --git a/lib/seam/routes/resources/magic_link.rb b/lib/seam/routes/resources/magic_link.rb deleted file mode 100644 index e1c3cbc9..00000000 --- a/lib/seam/routes/resources/magic_link.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class MagicLink < BaseResource - attr_accessor :customer_key, :url, :workspace_id - - date_accessor :created_at, :expires_at - end - end -end diff --git a/lib/seam/routes/resources/phone_session.rb b/lib/seam/routes/resources/phone_session.rb deleted file mode 100644 index 1881e3b9..00000000 --- a/lib/seam/routes/resources/phone_session.rb +++ /dev/null @@ -1,9 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class PhoneSession < BaseResource - attr_accessor :is_sandbox_workspace, :provider_sessions, :user_identity, :workspace_id - end - end -end diff --git a/lib/seam/routes/resources/space.rb b/lib/seam/routes/resources/space.rb index 6bb05b21..2fac3d55 100644 --- a/lib/seam/routes/resources/space.rb +++ b/lib/seam/routes/resources/space.rb @@ -3,7 +3,7 @@ module Seam module Resources class Space < BaseResource - attr_accessor :acs_entrance_count, :customer_data, :customer_key, :device_count, :display_name, :geolocation, :name, :parent_space_id, :parent_space_key, :space_id, :space_key, :workspace_id + attr_accessor :acs_entrance_count, :customer_data, :customer_key, :device_count, :display_name, :geolocation, :name, :space_id, :space_key, :workspace_id date_accessor :created_at end diff --git a/lib/seam/routes/resources/staff_member.rb b/lib/seam/routes/resources/staff_member.rb deleted file mode 100644 index a445a912..00000000 --- a/lib/seam/routes/resources/staff_member.rb +++ /dev/null @@ -1,9 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class StaffMember < BaseResource - attr_accessor :building_keys, :common_area_keys, :email_address, :facility_keys, :listing_keys, :name, :phone_number, :property_keys, :property_listing_keys, :room_keys, :site_keys, :space_keys, :staff_member_key, :unit_keys - end - end -end diff --git a/lib/seam/routes/resources/unmanaged_acs_access_group.rb b/lib/seam/routes/resources/unmanaged_acs_access_group.rb deleted file mode 100644 index 2c3e68cd..00000000 --- a/lib/seam/routes/resources/unmanaged_acs_access_group.rb +++ /dev/null @@ -1,14 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class UnmanagedAcsAccessGroup < BaseResource - attr_accessor :access_group_type, :access_group_type_display_name, :access_schedule, :acs_access_group_id, :acs_system_id, :connected_account_id, :display_name, :external_type, :external_type_display_name, :is_managed, :name, :pending_mutations, :workspace_id - - date_accessor :created_at - - include Seam::Resources::ResourceErrorsSupport - include Seam::Resources::ResourceWarningsSupport - end - end -end diff --git a/lib/seam/routes/resources/unmanaged_acs_credential.rb b/lib/seam/routes/resources/unmanaged_acs_credential.rb deleted file mode 100644 index 2752914f..00000000 --- a/lib/seam/routes/resources/unmanaged_acs_credential.rb +++ /dev/null @@ -1,14 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class UnmanagedAcsCredential < BaseResource - attr_accessor :access_method, :acs_credential_id, :acs_credential_pool_id, :acs_system_id, :acs_user_id, :assa_abloy_vostio_metadata, :card_number, :code, :connected_account_id, :display_name, :ends_at, :external_type, :external_type_display_name, :is_issued, :is_latest_desired_state_synced_with_provider, :is_managed, :is_multi_phone_sync_credential, :is_one_time_use, :parent_acs_credential_id, :starts_at, :user_identity_id, :visionline_metadata, :workspace_id - - date_accessor :created_at, :issued_at, :latest_desired_state_synced_with_provider_at - - include Seam::Resources::ResourceErrorsSupport - include Seam::Resources::ResourceWarningsSupport - end - end -end diff --git a/lib/seam/routes/resources/unmanaged_acs_user.rb b/lib/seam/routes/resources/unmanaged_acs_user.rb deleted file mode 100644 index 1cf9a6e6..00000000 --- a/lib/seam/routes/resources/unmanaged_acs_user.rb +++ /dev/null @@ -1,14 +0,0 @@ -# frozen_string_literal: true - -module Seam - module Resources - class UnmanagedAcsUser < BaseResource - attr_accessor :access_schedule, :acs_system_id, :acs_user_id, :connected_account_id, :display_name, :email, :email_address, :external_type, :external_type_display_name, :full_name, :hid_acs_system_id, :is_managed, :is_suspended, :pending_mutations, :phone_number, :salto_ks_metadata, :salto_space_metadata, :user_identity_email_address, :user_identity_full_name, :user_identity_id, :user_identity_phone_number, :workspace_id - - date_accessor :created_at, :last_successful_sync_at - - include Seam::Resources::ResourceErrorsSupport - include Seam::Resources::ResourceWarningsSupport - end - end -end diff --git a/package-lock.json b/package-lock.json index d3352f2d..53616ba9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6,10 +6,10 @@ "": { "name": "@seamapi/ruby", "devDependencies": { - "@seamapi/blueprint": "^0.59.0", + "@seamapi/blueprint": "^0.61.0", "@seamapi/fake-seam-connect": "1.86.0", "@seamapi/smith": "^0.5.2", - "@seamapi/types": "1.970.0", + "@seamapi/types": "1.975.0", "change-case": "^5.4.4", "markdown-toc": "^1.2.0", "prettier": "^3.2.5" @@ -771,9 +771,9 @@ "license": "MIT" }, "node_modules/@seamapi/blueprint": { - "version": "0.59.0", - "resolved": "https://registry.npmjs.org/@seamapi/blueprint/-/blueprint-0.59.0.tgz", - "integrity": "sha512-4wRGuNx8FYF1m0nQyeMZIe/Ab7cNwm3yslLTlij3uRfB8QpoqFuaphGbMzQVNtGH3d2NkSY/kUGny8kqJLDssQ==", + "version": "0.61.0", + "resolved": "https://registry.npmjs.org/@seamapi/blueprint/-/blueprint-0.61.0.tgz", + "integrity": "sha512-fNjl/4N6Up3quVPYrU4j9Bb34A/ib4a0EDm9g34H9phpMxc4ta7T2l0hGiz6jRY+CizQZNom8n+kDfOR+uHaIA==", "dev": true, "license": "MIT", "dependencies": { @@ -915,9 +915,9 @@ } }, "node_modules/@seamapi/types": { - "version": "1.970.0", - "resolved": "https://registry.npmjs.org/@seamapi/types/-/types-1.970.0.tgz", - "integrity": "sha512-l3LIG47qP0VRj7D0BRnNrkfuzSqp8W7kVGEVbrcLDTZeePYNFhq3z18rVV7ZHNoSbSQUpSWa5gWZJcSBp0+OLw==", + "version": "1.975.0", + "resolved": "https://registry.npmjs.org/@seamapi/types/-/types-1.975.0.tgz", + "integrity": "sha512-u9oMHzPIE1yN8IlKrn6t96zGWc0+YdTr3nb5zW2NpyaSpoiE6lbJ1JTqobp4f8lJmytKUfkDoXJMt+d2lxUlDQ==", "dev": true, "license": "MIT", "engines": { diff --git a/package.json b/package.json index 796accf8..cfb29b4e 100644 --- a/package.json +++ b/package.json @@ -14,10 +14,10 @@ "start": "fake-seam-connect --seed" }, "devDependencies": { - "@seamapi/blueprint": "^0.59.0", + "@seamapi/blueprint": "^0.61.0", "@seamapi/fake-seam-connect": "1.86.0", "@seamapi/smith": "^0.5.2", - "@seamapi/types": "1.970.0", + "@seamapi/types": "1.975.0", "change-case": "^5.4.4", "markdown-toc": "^1.2.0", "prettier": "^3.2.5" From 69dc691c59340cabd6ad3e6d7832d99447d1f26c Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 24 Jul 2026 16:24:30 +0000 Subject: [PATCH 2/2] Use smith omitUndocumented option instead of inline workaround Bump @seamapi/blueprint and @seamapi/smith to ^1.0.0. The smith blueprint plugin now forwards omitUndocumented to createBlueprint, so smith.ts passes omitUndocumented: true to the plugin instead of calling createBlueprint directly. Generated output is unchanged. Co-Authored-By: Claude Opus 4.8 Claude-Session: https://claude.ai/code/session_01AQChf9iyLCNXNhNbfH5rB2 --- codegen/smith.ts | 24 ++---------------------- package-lock.json | 36 ++++++++++++++++++------------------ package.json | 4 ++-- 3 files changed, 22 insertions(+), 42 deletions(-) diff --git a/codegen/smith.ts b/codegen/smith.ts index 047e61ae..cd19c96b 100644 --- a/codegen/smith.ts +++ b/codegen/smith.ts @@ -2,8 +2,7 @@ import { dirname } from 'node:path' import { fileURLToPath } from 'node:url' import layouts from '@metalsmith/layouts' -import { createBlueprint, TypesModuleSchema } from '@seamapi/blueprint' -import { getHandlebarsPartials } from '@seamapi/smith' +import { blueprint, getHandlebarsPartials } from '@seamapi/smith' import * as types from '@seamapi/types/connect' import { deleteAsync } from 'del' import Metalsmith from 'metalsmith' @@ -16,30 +15,11 @@ await Promise.all([deleteAsync('./lib/seam/routes')]) const partials = await getHandlebarsPartials(`${rootDir}/layouts/partials`) -// Build the blueprint with omitUndocumented so undocumented routes, -// namespaces, endpoints, parameters, resources, and properties are dropped -// before codegen runs. This replaces the @seamapi/smith blueprint plugin, -// which does not forward the omitUndocumented option to createBlueprint. -const setBlueprint = async ( - _files: Metalsmith.Files, - metalsmith: Metalsmith, -): Promise => { - const typesModule = TypesModuleSchema.parse({ - ...types, - codeSampleDefinitions: [], - resourceSampleDefinitions: [], - }) - const blueprint = await createBlueprint(typesModule, { - omitUndocumented: true, - }) - Object.assign(metalsmith.metadata(), { blueprint }) -} - Metalsmith(rootDir) .source('./content') .destination('../') .clean(false) - .use(setBlueprint) + .use(blueprint({ types, omitUndocumented: true })) .use(routes) .use( layouts({ diff --git a/package-lock.json b/package-lock.json index 53616ba9..b6f3ac6a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6,9 +6,9 @@ "": { "name": "@seamapi/ruby", "devDependencies": { - "@seamapi/blueprint": "^0.61.0", + "@seamapi/blueprint": "^1.0.0", "@seamapi/fake-seam-connect": "1.86.0", - "@seamapi/smith": "^0.5.2", + "@seamapi/smith": "^1.0.0", "@seamapi/types": "1.975.0", "change-case": "^5.4.4", "markdown-toc": "^1.2.0", @@ -771,9 +771,9 @@ "license": "MIT" }, "node_modules/@seamapi/blueprint": { - "version": "0.61.0", - "resolved": "https://registry.npmjs.org/@seamapi/blueprint/-/blueprint-0.61.0.tgz", - "integrity": "sha512-fNjl/4N6Up3quVPYrU4j9Bb34A/ib4a0EDm9g34H9phpMxc4ta7T2l0hGiz6jRY+CizQZNom8n+kDfOR+uHaIA==", + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@seamapi/blueprint/-/blueprint-1.0.0.tgz", + "integrity": "sha512-tQLylewWRJL1PWNxt9fXH/NWKIY0oA4NaQnRtRul0Dewy5yFqQy1fdi5IRPa7G3v+D9rrEiCwVA/omWrfrPZ+Q==", "dev": true, "license": "MIT", "dependencies": { @@ -882,13 +882,13 @@ } }, "node_modules/@seamapi/smith": { - "version": "0.5.2", - "resolved": "https://registry.npmjs.org/@seamapi/smith/-/smith-0.5.2.tgz", - "integrity": "sha512-PRDe6Aa9bELyFyVyWp4UuWhmUtw80Hxr5u9jYB6ewKAHq8xePnoBpS3eZSiW1R8SN6UybLTzCWNepOpFRFRQjQ==", + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@seamapi/smith/-/smith-1.0.0.tgz", + "integrity": "sha512-ZmwOJgSbyfEKit02/YPbklwecjIX1KT96ivc7KjY4IyDDoH9hqFflOngdm4GJwIKNCjN5g0fPExL67cUHJ1FPQ==", "dev": true, "license": "MIT", "dependencies": { - "@types/node": "^22.15.21", + "@types/node": "^24.10.9", "change-case": "^5.4.4", "eslint-plugin-import": "^2.32.0", "eslint-plugin-simple-import-sort": "^12.1.1", @@ -897,8 +897,8 @@ "neostandard": "^0.12.2" }, "engines": { - "node": ">=20.9.0", - "npm": ">=10.1.0" + "node": ">=22.11.0", + "npm": ">=10.9.4" }, "peerDependencies": { "@metalsmith/layouts": "^2.7.0", @@ -1010,13 +1010,13 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "22.20.1", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.20.1.tgz", - "integrity": "sha512-EANqOCF9QFyra+4pfxUcX9STKJpCLjMbObVzljIJomAWSnuSIEAvyzEU53GaajbXJEgdh0iEcPL+DGvpUd4k1Q==", + "version": "24.13.3", + "resolved": "https://registry.npmjs.org/@types/node/-/node-24.13.3.tgz", + "integrity": "sha512-Dh8vAsV36ig5wa9OX4pXvMc9D3Veibfw2wix0CUwYODLD8nkj9UsLjASr49nPg+2eKzxhBV+v7L8pXvT4e639Q==", "dev": true, "license": "MIT", "dependencies": { - "undici-types": "~6.21.0" + "undici-types": "~7.18.0" } }, "node_modules/@typescript-eslint/eslint-plugin": { @@ -6730,9 +6730,9 @@ } }, "node_modules/undici-types": { - "version": "6.21.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", - "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", + "version": "7.18.2", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.18.2.tgz", + "integrity": "sha512-AsuCzffGHJybSaRrmr5eHr81mwJU3kjw6M+uprWvCXiNeN9SOGwQ3Jn8jb8m3Z6izVgknn1R0FTCEAP2QrLY/w==", "dev": true, "license": "MIT" }, diff --git a/package.json b/package.json index cfb29b4e..74c7eb0b 100644 --- a/package.json +++ b/package.json @@ -14,9 +14,9 @@ "start": "fake-seam-connect --seed" }, "devDependencies": { - "@seamapi/blueprint": "^0.61.0", + "@seamapi/blueprint": "^1.0.0", "@seamapi/fake-seam-connect": "1.86.0", - "@seamapi/smith": "^0.5.2", + "@seamapi/smith": "^1.0.0", "@seamapi/types": "1.975.0", "change-case": "^5.4.4", "markdown-toc": "^1.2.0",