Skip to content

MT-22147: Document search param on GET /api/contacts/lists#45

Open
Rabsztok wants to merge 2 commits into
mainfrom
MT-22147-contact-lists-search
Open

MT-22147: Document search param on GET /api/contacts/lists#45
Rabsztok wants to merge 2 commits into
mainfrom
MT-22147-contact-lists-search

Conversation

@Rabsztok

@Rabsztok Rabsztok commented Jun 18, 2026

Copy link
Copy Markdown

Motivation

https://railsware.atlassian.net/browse/MT-22147

Changes

  • Document the optional search query param (case-insensitive partial name match) on GET /api/contacts/lists, with a matching cURL example
  • Spec side of the falcon implementation: railsware/falcon#10470

How to test

  • In the rendered Contact Lists docs, GET /api/contacts/lists shows an optional search query param described as "Filter contact lists by name (case-insensitive partial match)."

Summary by CodeRabbit

  • New Features
    • The contacts list endpoint now supports an optional search query parameter to filter contact lists by name using a case-insensitive prefix match.
  • Documentation
    • Updated the example cURL command for fetching contact lists to include a filtered request using ?search=....

Add the optional `search` query param (case-insensitive partial name
match) to the Get all Contact Lists operation, mirroring the search
parameter convention used elsewhere, plus a ?search= cURL example.

Note: this path still documents a 500 response, which violates the
api-creator "no 500" rule. Left as-is to keep this PR focused;
flagged as a follow-up cleanup.
@coderabbitai

coderabbitai Bot commented Jun 18, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The GET /api/contacts/lists operation in specs/contacts.openapi.yml gains an optional search query parameter (string, example: news) for case-insensitive name filtering. The existing cURL code sample is extended with a second request demonstrating ?search=news.

Changes

Search parameter for contact lists endpoint

Layer / File(s) Summary
search query param declaration and cURL example
specs/contacts.openapi.yml
Adds a parameters block declaring the optional search string query param and appends a ?search=news cURL request to the shell code sample.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

A bunny hops through contacts with care,
Searching for lists hidden somewhere.
?search=news in the query it sends,
The OpenAPI spec neatly extends!
🐇✨ Now filtering lists is a breeze!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the main change: documenting a search parameter on a specific API endpoint.
Description check ✅ Passed The description covers motivation, changes, and testing sections as required by the template, though the Images/GIFs section is omitted (acceptable for documentation updates).
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch MT-22147-contact-lists-search

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@Rabsztok Rabsztok marked this pull request as ready for review June 18, 2026 11:45

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@specs/contacts.openapi.yml`:
- Around line 1245-1246: The cURL examples in the contacts.openapi.yml file
contain hardcoded token placeholders (YOUR_API_TOKEN) in the Authorization
header, which should be replaced with environment variable references according
to repo guidelines. Update both instances of the curl commands (around lines
1245-1246 and 1249-1250) where the -H 'Authorization: Bearer YOUR_API_TOKEN'
header appears to use an environment variable syntax instead of the hardcoded
placeholder string.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9ffa9385-27ac-4329-badb-99f6e368e43e

📥 Commits

Reviewing files that changed from the base of the PR and between e343df3 and 46e4a34.

📒 Files selected for processing (1)
  • specs/contacts.openapi.yml

Comment thread specs/contacts.openapi.yml
@Rabsztok Rabsztok requested review from DagonWat and mklocek June 19, 2026 06:58
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.

2 participants