Skip to content

Add TypeScript SDK README usage examples - #1

Open
richmondteo-code wants to merge 4 commits into
masterfrom
feat/typescript-sdk-readme-examples
Open

Add TypeScript SDK README usage examples#1
richmondteo-code wants to merge 4 commits into
masterfrom
feat/typescript-sdk-readme-examples

Conversation

@richmondteo-code

Copy link
Copy Markdown
Owner

Summary

  • add the new sdk/npm TypeScript SDK package to the repo
  • expand the npm README with concrete usage examples and runnable commands
  • add runnable sdk/npm/examples scripts plus example npm scripts and keywords
  • add a TypeScript SDK section to the root README for the GitHub landing page

Verification

  • npm run typecheck (in sdk/npm)

Ops Agent and others added 4 commits April 25, 2026 17:46
…lete?q=lap

- New typesense_autocomplete() for fast prefix search
- New ProductAutocompleteResponse schema
- No auth required, 60/min rate limit
- Falls back to Postgres FTS when Typesense unavailable
- Added get_optional_api_key to auth.py for no-auth endpoints
- GET /v1/products/autocomplete?q=lap&limit=5
- Returns {suggestions: [...]}
- Primary: Typesense prefix search (if TYPESENSE_URL set)
- Fallback: DB regex prefix on title
- 30s in-memory cache, 60/min TTL
- No auth required, public widget endpoint

Co-Authored-By: Paperclip <noreply@paperclip.ing>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant