Skip to content

OpenAPI schema missing investment_loan account type and TransactionAccount fields #16

@poodle64

Description

@poodle64

The OpenAPI schema in this repo is missing fields that the live API returns, causing deserialisation failures when using generated API clients.

We discovered these discrepancies while auditing our generated PocketSmith API client using Claude Code, which validated the generated client against the live API and identified fields present in responses but absent from the schema.

1. Missing investment_loan account type

The Account.type enum lists 11 values but the API returns investment_loan as a valid type. This value is not present in any of the type enums in the schema (Account, TransactionAccount, or the request bodies for PUT/POST account endpoints).

Reproduction:
```bash
curl -H "Authorization: Token <api_key>"
https://api.pocketsmith.com/v2/users/<user_id>/accounts
```

Response includes accounts with "type": "investment_loan".

Expected: investment_loan should be listed in the type enum alongside bank, credits, cash, stocks, mortgage, loans, vehicle, property, insurance, other_asset, other_liability.

2. Missing TransactionAccount properties

The TransactionAccount schema is missing several properties that the API returns:

Field Type Description
account_id integer The parent account ID
latest_feed_name string (nullable) Name of the latest data feed
offline boolean Whether the account is offline
is_net_worth boolean Whether included in net worth
include_in_net_worth boolean Whether should be included in net worth
current_balance_source string (nullable) Source of balance data (e.g. `"data_feed"`)

Reproduction:
```bash
curl -H "Authorization: Token <api_key>"
https://api.pocketsmith.com/v2/users/<user_id>/transaction_accounts
```

All six fields are present in every TransactionAccount object in the response.

Impact

Generated API clients (using openapi-generator or similar tools) cannot access these fields as typed attributes because they are not in the schema. Clients must work around this using raw response data or additional_properties handling.

Environment

  • API version: v2
  • Tested: 2026-04-11
  • Schema commit: 8e964ca (2025-12-03)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions