Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/akevalion/life_cost/llms.txt

Use this file to discover all available pages before exploring further.

The GET /wallet/<id> endpoint fetches a single wallet’s details by its numeric ID. This is useful for displaying wallet metadata in the UI or verifying a wallet’s existence before performing operations against it. The endpoint is protected by @login_required, so an authenticated session cookie must accompany every request.

Method & Path

GET /wallet/<id>

Authentication

This endpoint requires an active login session. Requests without a valid session cookie are rejected and redirected to the login flow. Session cookies are issued automatically upon successful Google OAuth sign-in.

Path Parameter

id
integer
required
The unique numeric ID of the wallet to retrieve. Corresponds to the Wallet.id primary key column in the database. If no wallet with this ID exists, the endpoint returns a 404 Not Found response.

Response Fields

A successful 200 OK response returns a JSON object with the following fields:
id
integer
The unique numeric identifier of the wallet. Mirrors the id primary key stored in the wallet table.
name
string
The display name of the wallet. Unique across all wallets; maximum 150 characters.
description
string
A human-readable description of the wallet’s purpose or contents. Optional — may be null if no description was provided when the wallet was created. Maximum 300 characters.

Example Request

curl -X GET https://your-app.example.com/wallet/1 \
  -H "Cookie: session=<your-session-cookie>"

Example Response

{
  "id": 1,
  "name": "Household Budget",
  "description": "Shared expenses for rent, groceries, and utilities"
}

Error Cases

StatusCondition
404 Not FoundNo wallet exists with the given id. Flask’s get_or_404 helper returns a standard 404 HTML response.
401 UnauthorizedThe request was made without an authenticated session. The server redirects to the Google login flow.
If your client receives a redirect (HTTP 302) instead of a JSON response, it means the session has expired or is missing. Re-authenticate via the Google OAuth flow before retrying.

Build docs developers (and LLMs) love