Skip to content

Conversation

@pengying
Copy link
Contributor

@pengying pengying commented Jan 24, 2026

TL;DR

Updated the response schema for external accounts endpoint to use data instead of accounts as the property name.

What changed?

Changed the required property name in the external accounts API response from accounts to data. This affects the schema definition in the OpenAPI specification across multiple files:

  • mintlify/openapi.yaml
  • openapi.yaml
  • openapi/paths/platform/platform_external_accounts.yaml

How to test?

  1. Make a request to the external accounts endpoint
  2. Verify that the response contains a data array instead of an accounts array
  3. Ensure all client code that consumes this API is updated to reference the new property name

Why make this change?

This change standardizes the API response format to be consistent with other endpoints in the system that use data as the top-level property for array responses. This improves API consistency and makes client integration more predictable.

@greptile-apps
Copy link

greptile-apps bot commented Jan 24, 2026

Greptile Overview

Greptile Summary

Renamed the response property from accounts to data in the platform external accounts list endpoint (GET /platform/external-accounts). This brings the endpoint in line with other list endpoints in the API (customers external accounts, internal accounts, transactions, etc.) which already use data as the top-level array property name.

Key changes:

  • Updated response schema in openapi/paths/platform/platform_external_accounts.yaml (source file)
  • Regenerated bundled specs (openapi.yaml and mintlify/openapi.yaml)
  • Changed required property from accounts to data in the 200 response

Breaking change: This is a breaking change for existing API consumers. Any clients currently accessing response.accounts will need to update to response.data.

Consistency achieved: This change standardizes the API to use data consistently across all list endpoints, improving developer experience and API predictability.

Confidence Score: 5/5

  • This PR is safe to merge with high confidence - it's a clean, well-scoped breaking change
  • The change is straightforward, consistent, and properly implemented across all relevant files. The source file was edited and the bundled specs were correctly regenerated. The change aligns with existing API patterns (customer external accounts already uses data), improving overall API consistency. No logical errors or security concerns.
  • No files require special attention - all changes are intentional and consistent

Important Files Changed

Filename Overview
openapi/paths/platform/platform_external_accounts.yaml Renamed response property from accounts to data for API consistency
openapi.yaml Bundled OpenAPI spec with updated data property (auto-generated from source)
mintlify/openapi.yaml Mintlify copy of bundled spec with updated data property (auto-generated)

Sequence Diagram

sequenceDiagram
    participant Client
    participant API as Grid API
    participant DB as Database
    
    Note over Client,DB: List Platform External Accounts Request
    
    Client->>API: GET /platform/external-accounts
    activate API
    Note right of Client: Authentication via Basic Auth
    
    API->>DB: Query external accounts
    activate DB
    DB-->>API: Return account records
    deactivate DB
    
    API->>API: Build response with "data" property
    Note right of API: Changed from "accounts" to "data"<br/>for consistency with other endpoints
    
    API-->>Client: 200 OK
    deactivate API
    Note left of API: Response:<br/>{<br/>  "data": [...]<br/>}<br/>(previously "accounts")
Loading

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