Skip to content

Conversation

@HavenDV
Copy link
Contributor

@HavenDV HavenDV commented Sep 19, 2025

Summary by CodeRabbit

  • Documentation
    • Clarified image handling examples: image_url now explicitly supports base64 data URIs and web URLs across TypeScript, Python, Java, and Go samples.
  • Chores
    • Marked several API endpoints as deprecated in the specification.
    • Deprecated two query parameters: conversation_id and search_queries_only.
    • Deprecations are reflected in the OpenAPI spec to improve visibility in generated SDKs and tools; no runtime behavior change.

@coderabbitai
Copy link

coderabbitai bot commented Sep 19, 2025

Walkthrough

Deprecation flags were added to multiple endpoints and two query parameters (conversation_id, search_queries_only) in src/libs/Cohere/openapi.yaml. Documentation code samples for Images were updated to clarify that image_url accepts either a base64 data URI or a web URL across TypeScript, Python, Java, and Go.

Changes

Cohort / File(s) Summary
OpenAPI spec updates
src/libs/Cohere/openapi.yaml
Marked several path operations as deprecated: true; marked parameters conversation_id and search_queries_only as deprecated; updated Images code samples’ comments to state image_url can be base64 data URI or web URL (TS, Python, Java, Go).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Poem

A bunny taps the spec with care,
Flags of “deprecated” everywhere.
Two params hop to sunset’s glow,
Image URLs now clearly show.
Docs refreshed, the paths are neat—
Carrots count each tidy feat.
Thump-thump: another merge complete!

Pre-merge checks and finishing touches

❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Title Check ❓ Inconclusive The PR title "feat:@coderabbitai" is too vague and does not describe the primary changes (deprecations in src/libs/Cohere/openapi.yaml and updates to image samples), so a reviewer cannot tell the main change from the title alone. Rename the PR to a concise, descriptive title such as "chore(Cohere): deprecate conversation_id and search_queries_only in openapi.yaml and clarify image sample usage" and update the PR description to briefly summarize the key changes.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.
✨ Finishing touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch bot/update-openapi_202509191520

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.

@HavenDV HavenDV enabled auto-merge (squash) September 19, 2025 15:21
@coderabbitai coderabbitai bot changed the title feat:@coderabbitai feat:Add deprecation flags; clarify Images image_url data URI or URL Sep 19, 2025
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 111c2a6 and b9d1286.

⛔ Files ignored due to path filters (21)
  • src/libs/Cohere/Generated/Cohere.CohereClient.Chat.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.CohereClient.Classify.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.CohereClient.Generate.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.CohereClient.Summarize.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ConnectorsClient.CreateConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ConnectorsClient.DeleteConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ConnectorsClient.GetConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ConnectorsClient.ListConnectors.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ConnectorsClient.OAuthAuthorizeConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ConnectorsClient.UpdateConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ICohereClient.Chat.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ICohereClient.Classify.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ICohereClient.Generate.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.ICohereClient.Summarize.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.IConnectorsClient.CreateConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.IConnectorsClient.DeleteConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.IConnectorsClient.GetConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.IConnectorsClient.ListConnectors.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.IConnectorsClient.OAuthAuthorizeConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.IConnectorsClient.UpdateConnector.g.cs is excluded by !**/generated/**
  • src/libs/Cohere/Generated/Cohere.Models.ChatRequest.g.cs is excluded by !**/generated/**
📒 Files selected for processing (1)
  • src/libs/Cohere/openapi.yaml (12 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Test / Build, test and publish
🔇 Additional comments (4)
src/libs/Cohere/openapi.yaml (4)

66-66: LGTM! Proper deprecation marking for connectors parameter.

The connectors parameter is correctly marked as deprecated, which aligns with the API evolution strategy.


171-171: LGTM! Proper deprecation marking for search_queries_only parameter.

The search_queries_only parameter is correctly marked as deprecated with appropriate documentation preserved.


1007-1007: LGTM! Consistent deprecation marking across multiple endpoints.

All endpoints are properly marked as deprecated following OpenAPI specification standards. The deprecation flags are consistently placed after error response definitions and before audience specifications.

Also applies to: 1131-1131, 1201-1201, 1274-1274, 1346-1346, 1424-1424, 1504-1504, 6626-6626, 7181-7181


8775-8786: LGTM! Improved documentation with helpful clarifications.

The code samples now include clear comments indicating that image_url/url fields accept both base64 data URIs and web URLs. This enhancement improves developer experience across all supported languages (TypeScript, Python, Java, Go).

items:
$ref: '#/components/schemas/ChatConnector'
description: "Accepts `{\"id\": \"web-search\"}`, and/or the `\"id\"` for a custom [connector](https://docs.cohere.com/docs/connectors), if you've [created](https://docs.cohere.com/v1/docs/creating-and-deploying-a-connector) one.\n\nWhen specified, the model's reply will be enriched with information found by querying each of the connectors (RAG).\n\nCompatible Deployments: Cohere Platform\n"
deprecated: true
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue

🧩 Analysis chain

Verify that deprecated endpoints and parameters are documented in migration guides.

With multiple endpoints and parameters being deprecated, ensure that:

  1. Migration documentation is available for users
  2. Alternative endpoints/parameters are clearly specified
  3. Deprecation timeline is communicated

Also applies to: 171-171, 1007-1007, 1131-1131, 1201-1201, 1274-1274, 1346-1346, 1424-1424, 1504-1504, 6626-6626, 7181-7181


🏁 Script executed:

#!/bin/bash
# Description: Check for migration documentation and alternative endpoints for deprecated items

# Search for migration guides or deprecation notices in documentation
echo "=== Searching for migration guides ==="
fd -t f -e md -e rst -e txt . | head -20 | xargs rg -l -i "(migration|deprecat|alternative)" 2>/dev/null || echo "No migration docs found in common locations"

# Check if there are newer versions of deprecated endpoints
echo "=== Checking for v2 or newer API versions ==="
rg -A 3 -B 3 "(/v[2-9]/|/api/v[2-9]/)" src/libs/Cohere/openapi.yaml | head -20

# Look for CHANGELOG or similar files
echo "=== Checking for changelog files ==="
fd -t f "(CHANGELOG|CHANGES|HISTORY|NEWS)" . 

# Check for any replacement endpoints mentioned in descriptions
echo "=== Searching for replacement mentions in OpenAPI spec ==="
rg -i -A 2 -B 2 "(replac|instead|use.*instead|migrat|alternative)" src/libs/Cohere/openapi.yaml | head -20

Length of output: 11344


Add migration guide and changelog entries for deprecated Cohere endpoints

No migration docs or CHANGELOG were found; src/libs/Cohere/openapi.yaml has deprecated items at lines 66, 171, 1007, 1131, 1201, 1274, 1346, 1424, 1504, 6626, 7181 but contains no replacement/migration notes. Add a migration guide that lists alternative endpoints/parameters, update the OpenAPI descriptions to reference those replacements, and publish a deprecation timeline (also add a CHANGELOG entry).

🤖 Prompt for AI Agents
In src/libs/Cohere/openapi.yaml around lines 66, 171, 1007, 1131, 1201, 1274,
1346, 1424, 1504, 6626, 7181, several endpoints are marked deprecated but lack
migration guidance or changelog entries; add a new migration guide document
(e.g., docs/migration/cohere-deprecations.md) listing each deprecated
endpoint/parameter with the recommended replacement endpoints/parameters,
example request/response mappings, and a proposed deprecation timeline (dates
for soft-deprecation, removal, and recommended migration window); update the
OpenAPI spec descriptions for each deprecated item to reference the migration
guide and the exact replacement (use description fields and/or standard OpenAPI
x-deprecated or deprecationMetadata extensions), and create/update a
CHANGELOG.md entry describing the deprecations, replacements, timeline, and any
breaking changes so consumers can act on the migration instructions.

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