From 7e69e935ad934097d0ae6c52bb6ee35667e4b4a1 Mon Sep 17 00:00:00 2001 From: safenestdev Date: Mon, 21 Sep 2026 11:27:51 +0200 Subject: [PATCH] release: v2.33.0 UsageQuota matches GET /usage/quota (nested limits/current/remaining, optional apiKeyId) and gains the optional resetsInSeconds the API added on 2026-09-21. Types only; runtime values unchanged. --- CHANGELOG.md | 10 ++++++++++ package-lock.json | 4 ++-- package.json | 2 +- 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index dd5c445..f282a6c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,16 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [2.33.0] - 2026-09-21 + +### Fixed + +- **`UsageQuota` now matches what `GET /usage/quota` returns.** The type declared flat `rate_limit` / `remaining` / `reset_in_seconds` fields the API never sent, so every consumer reading them got `undefined` (the MCP server's quota tool printed "undefined/min" and "[object Object]", reported by a customer on 2026-09-21). The type is now the wire shape: `limits.{requestsPerMinute,requestsPerDay,requestsPerMonth}` (`-1` = unlimited), `current.{requestsThisMinute,requestsToday}`, `remaining.{requestsThisMinute,requestsToday}`, and optional `apiKeyId`. Types only; `getUsageQuota()` forwarded the raw response all along, so runtime values are unchanged. Code that read the old flat fields must move to the nested ones (it was reading `undefined` before). + +### Added + +- **`UsageQuota.resetsInSeconds`**, seconds until the per-minute window resets. Optional: absent on API deployments before 2026-09-21. + ## [2.32.0] - 2026-08-28 ### Added diff --git a/package-lock.json b/package-lock.json index 6bb39aa..5856c9b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@tuteliq/sdk", - "version": "2.32.0", + "version": "2.33.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@tuteliq/sdk", - "version": "2.32.0", + "version": "2.33.0", "license": "MIT", "devDependencies": { "@types/node": "^26.2.0", diff --git a/package.json b/package.json index 354f34c..5dddc0e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@tuteliq/sdk", - "version": "2.32.0", + "version": "2.33.0", "description": "TypeScript SDK for Tuteliq AI child safety API - Detect bullying, grooming, and unsafe content", "type": "module", "main": "./dist/index.js",