{ "error": "Invalid or missing API key"}```json 404{ "error": "Agent not found"}
{ "error": "Internal server error"}
Investment History: Retrieves all investments (both active and completed) associated with a specific agent. For active investments, calculates the current value and interest earned based on the principal amount, interest rate, and investment duration. Returns detailed information including investment status and creation timestamp.
All Investment Statuses: This endpoint returns all investments for the agent regardless of status (active, completed, cancelled).
Real-time Calculations: For active investments, current values and interest earned are calculated in real-time based on the current interest rate and investment duration.
Completed Investments: For completed investments, the values shown represent the final amounts at the time of withdrawal.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Mage API Documentation","colors":{"primary":"#FF5722","light":"#FF7043","dark":"#E64A19"},"logo":{"light":"https://mintcdn.com/mage-bank/_nadq0QJn3EnDhRd/logo/logo-light.svg?fit=max\u0026auto=format\u0026n=_nadq0QJn3EnDhRd\u0026q=85\u0026s=219a4c58a03182e18d28e9d2afb98f31","dark":"https://mintcdn.com/mage-bank/_nadq0QJn3EnDhRd/logo/logo-dark.svg?fit=max\u0026auto=format\u0026n=_nadq0QJn3EnDhRd\u0026q=85\u0026s=caaba7488d66d3c05d6c3f621e1d501d"},"favicon":"/logo/favicon.png","api":{"playground":{"display":"interactive"},"mdx":{"server":"https://api.magebank.ai"}},"appearance":{"default":"dark"},"background":{"color":{"light":"#fff","dark":"#000"}},"navbar":{"links":[{"label":"Support","href":"mailto:[email protected]"}],"primary":{"type":"button","label":"Dashboard","href":"https://www.magebank.ai/dashboard"}},"footer":{"socials":{"x":"https://x.com/magebank","github":"https://github.com/magebank","linkedin":"https://linkedin.com/company/magebank"}},"banner":{"content":"🚀 Mage is now live! Visit our [Dashboard](https://www.magebank.ai/dashboard) to start managing your AI agents' finances.","dismissible":true},"contextual":{"options":["copy","view"]},"navigation":{"global":{"anchors":[{"anchor":"Dashboard","icon":"gauge","href":"https://www.magebank.ai/dashboard"},{"anchor":"LLM.txt","icon":"robot","href":"https://raw.githubusercontent.com/MageBankAI/docs/refs/heads/master/LLM.txt"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"mage-bank","hasAudioNarration":false,"actualSubdomain":"mage-bank","customDomains":["docs.magebank.ai"],"gitSource":{"type":"github","owner":"magebankai","repo":"docs","deployBranch":"master","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6a21e6e8328cd78292a4fb44","collectionId":"9cbc1059-e065-4299-9807-cb62384e3d04","schemaVersion":"v2"},"entitlements":{},"buildId":"6ae92843b35e9cea405c8119:success","clientVersion":"0.0.4064","searchFilterCounts":[{"language":"default","tag":"API Reference","count":25},{"language":"default","tag":"Savings","count":8},{"language":"default","tag":"Payments","count":7},{"language":"default","tag":"Guides","count":7},{"language":"default","tag":"Agents","count":6},{"language":"default","tag":"User Guide","count":5},{"language":"default","tag":"Transactions","count":2},{"language":"default","tag":"Users","count":2},{"language":"default","tag":"Get Started","count":2}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"styles.css","content":"body:not(.auth-authenticated)>*:not(#auth-modal):not(script):not(style):not(link){filter:blur(15px)!important;pointer-events:none!important;user-select:none!important}html:not(.auth-authenticated),body:not(.auth-authenticated){overflow:hidden!important}#navbar img,.navbar img,[data-testid=\"navbar\"] img,.navbar-logo img,.logo img{height:36px!important;max-height:36px!important;width:auto!important;transform:translateX(-8px)!important;-webkit-transform:translateX(-8px)!important;-moz-transform:translateX(-8px)!important;-ms-transform:translateX(-8px)!important;-o-transform:translateX(-8px)!important}img[src*=\"logo-light\"],img[src*=\"logo-dark\"]{height:36px!important;max-height:36px!important;width:auto!important;transform:translateX(-8px)!important;-webkit-transform:translateX(-8px)!important;-moz-transform:translateX(-8px)!important;-ms-transform:translateX(-8px)!important;-o-transform:translateX(-8px)!important}body.auth-active{overflow:hidden!important}body.auth-active::-webkit-scrollbar{display:none!important}body.auth-active{-ms-overflow-style:none!important;scrollbar-width:none!important}html.auth-active{overflow:hidden!important}#auth-modal{position:fixed;top:0;left:0;width:100vw;height:100vh;z-index:10000;display:flex;align-items:center;justify-content:center;font-family:-apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif}.auth-overlay{position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(0, 0, 0, 0.5);backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px);display:flex;align-items:center;justify-content:center;padding:16px}.auth-modal{position:relative;background:#1a1a1a;border-radius:16px;box-shadow:0 25px 50px rgba(0, 0, 0, 0.6),\n 0 0 0 1px rgba(255, 255, 255, 0.08);max-width:400px;width:100%;border:1px solid rgba(13, 13, 13, 0.05);overflow:hidden;display:flex;flex-direction:column}#auth-modal[data-theme=\"dark\"] .auth-modal{background:#1a1a1a;box-shadow:0 25px 50px rgba(0, 0, 0, 0.6),\n 0 0 0 1px rgba(255, 255, 255, 0.08);border:1px solid rgba(13, 13, 13, 0.05)}#auth-modal[data-theme=\"light\"] .auth-modal,.light #auth-modal .auth-modal,[data-theme=\"light\"] #auth-modal .auth-modal,body.light #auth-modal .auth-modal{background:#ffffff!important;box-shadow:0 25px 50px rgba(0, 0, 0, 0.15),\n 0 0 0 1px rgba(0, 0, 0, 0.08)!important;border:1px solid rgba(0, 0, 0, 0.08)!important}#auth-modal[data-theme=\"light\"]{background:transparent!important}#auth-modal[data-theme=\"light\"] .auth-overlay{background:rgba(0, 0, 0, 0.3)!important}.auth-header{position:relative;padding:20px;border-bottom:1px solid rgba(230, 230, 232, 0.1);flex-shrink:0}#auth-modal[data-theme=\"dark\"] .auth-header{border-bottom:1px solid rgba(230, 230, 232, 0.1)}#auth-modal[data-theme=\"light\"] .auth-header,.light #auth-modal .auth-header,[data-theme=\"light\"] #auth-modal .auth-header,body.light #auth-modal .auth-header{border-bottom:1px solid rgba(0, 0, 0, 0.1)!important}.auth-header-content{display:flex;align-items:center;gap:8px}.auth-theme-toggle{display:none!important}.auth-icon-container{width:32px;height:32px;background:rgba(255, 122, 0, 0.1);border:1px solid rgba(255, 122, 0, 0.2);border-radius:8px;display:flex;align-items:center;justify-content:center;flex-shrink:0}.auth-logo{height:16px;width:16px;color:#FF7A00}.auth-header-text{flex:1}.auth-header h2{margin:0;font-size:16px;font-weight:700;color:#ffffff;letter-spacing:-0.2px;line-height:1.2}#auth-modal[data-theme=\"dark\"] .auth-header h2{color:#ffffff}#auth-modal[data-theme=\"light\"] .auth-header h2,.light #auth-modal .auth-header h2,[data-theme=\"light\"] #auth-modal .auth-header h2,body.light #auth-modal .auth-header h2{color:#1a1a1a!important}.auth-header p{margin:2px 0 0 0;font-size:12px;color:rgba(255, 255, 255, 0.7);line-height:1.3;font-weight:500}#auth-modal[data-theme=\"dark\"] .auth-header p{color:rgba(255, 255, 255, 0.7)}#auth-modal[data-theme=\"light\"] .auth-header p,.light #auth-modal .auth-header p,[data-theme=\"light\"] #auth-modal .auth-header p,body.light #auth-modal .auth-header p{color:rgba(26, 26, 26, 0.7)!important}.auth-content{flex:1;overflow-y:auto;padding:20px}.auth-form{display:flex;flex-direction:column;gap:24px}.auth-input-group{display:flex;flex-direction:column;gap:8px}.auth-input-label{font-size:12px;font-weight:700;color:#ffffff;display:flex;align-items:center;gap:4px}#auth-modal[data-theme=\"dark\"] .auth-input-label{color:#ffffff}#auth-modal[data-theme=\"light\"] .auth-input-label,.light #auth-modal .auth-input-label,[data-theme=\"light\"] #auth-modal .auth-input-label,body.light #auth-modal .auth-input-label{color:#1a1a1a!important}.auth-label-icon{width:12px;height:12px;color:rgba(255, 255, 255, 0.6)}#auth-modal[data-theme=\"dark\"] .auth-label-icon{color:rgba(255, 255, 255, 0.6)}#auth-modal[data-theme=\"light\"] .auth-label-icon,.light #auth-modal .auth-label-icon,[data-theme=\"light\"] #auth-modal .auth-label-icon,body.light #auth-modal .auth-label-icon{color:rgba(26, 26, 26, 0.6)!important}#auth-password{width:100%;border:1px solid rgba(230, 230, 232, 0.2);border-radius:8px;padding:8px 12px;font-size:14px;font-weight:500;color:#ffffff;background:rgba(45, 45, 45, 0.7);outline:none;box-sizing:border-box;transition:border-color 0.2s ease, box-shadow 0.2s ease}#auth-modal[data-theme=\"dark\"] #auth-password{color:#ffffff;background:rgba(45, 45, 45, 0.7);border:1px solid rgba(230, 230, 232, 0.2)}#auth-modal[data-theme=\"light\"] #auth-password,.light #auth-modal #auth-password,[data-theme=\"light\"] #auth-modal #auth-password,body.light #auth-modal #auth-password{color:#1a1a1a!important;background:rgba(245, 245, 245, 0.8)!important;border:1px solid rgba(0, 0, 0, 0.15)!important}#auth-password:hover{border-color:#FF7A00}#auth-password:focus{border-color:#FF7A00;box-shadow:0 0 0 1px rgba(255, 122, 0, 0.2);background:rgba(45, 45, 45, 0.9)}#auth-modal[data-theme=\"dark\"] #auth-password:focus{background:rgba(45, 45, 45, 0.9)}#auth-modal[data-theme=\"light\"] #auth-password:focus,.light #auth-modal #auth-password:focus,[data-theme=\"light\"] #auth-modal #auth-password:focus,body.light #auth-modal #auth-password:focus{background:rgba(245, 245, 245, 1)!important}#auth-password::placeholder{color:rgba(255, 255, 255, 0.5);font-weight:400}#auth-modal[data-theme=\"dark\"] #auth-password::placeholder{color:rgba(255, 255, 255, 0.5)}#auth-modal[data-theme=\"light\"] #auth-password::placeholder,.light #auth-modal #auth-password::placeholder,[data-theme=\"light\"] #auth-modal #auth-password::placeholder,body.light #auth-modal #auth-password::placeholder{color:rgba(26, 26, 26, 0.5)!important}#auth-password.error{border-color:#ef4444;animation:shake 0.3s ease-in-out}@keyframes shake{0%,100%{transform:translateX(0)}25%{transform:translateX(-4px)}75%{transform:translateX(4px)}}.auth-footer{padding:20px;border-top:1px solid rgba(230, 230, 232, 0.1);background:rgba(249, 249, 249, 0.02);display:flex;justify-content:flex-end;gap:8px;flex-shrink:0}#auth-modal[data-theme=\"dark\"] .auth-footer{border-top:1px solid rgba(230, 230, 232, 0.1);background:rgba(249, 249, 249, 0.02)}#auth-modal[data-theme=\"light\"] .auth-footer,.light #auth-modal .auth-footer,[data-theme=\"light\"] #auth-modal .auth-footer,body.light #auth-modal .auth-footer{border-top:1px solid rgba(0, 0, 0, 0.1)!important;background:rgba(0, 0, 0, 0.02)!important}.auth-submit{display:flex;gap:6px;justify-content:center;align-items:center;background:#2D2D2D;padding:10px 16px;color:white;font-size:13px;border-radius:8px;border:none;border-bottom:2px solid rgba(255, 255, 255, 0.2);font-weight:600;cursor:pointer;transition:all 0.2s ease;min-height:40px;position:relative;overflow:hidden}#auth-modal[data-theme=\"dark\"] .auth-submit{background:#2D2D2D;color:white;border-bottom:2px solid rgba(255, 255, 255, 0.2)}#auth-modal[data-theme=\"light\"] .auth-submit,.light #auth-modal .auth-submit,[data-theme=\"light\"] #auth-modal .auth-submit,body.light #auth-modal .auth-submit{background:#f0f0f0!important;color:#1a1a1a!important;border-bottom:2px solid rgba(0, 0, 0, 0.15)!important}.auth-submit:hover{background:#1a1a1a;border-bottom-color:rgba(255, 255, 255, 0.3);transform:translateY(-1px)}#auth-modal[data-theme=\"dark\"] .auth-submit:hover{background:#1a1a1a;border-bottom-color:rgba(255, 255, 255, 0.3)}#auth-modal[data-theme=\"light\"] .auth-submit:hover,.light #auth-modal .auth-submit:hover,[data-theme=\"light\"] #auth-modal .auth-submit:hover,body.light #auth-modal .auth-submit:hover{background:#e0e0e0!important;border-bottom-color:rgba(0, 0, 0, 0.25)!important}.auth-submit:active{transform:translateY(0);border-bottom-width:1px}.auth-submit:disabled{opacity:0.5;cursor:not-allowed;transform:none}.auth-submit:disabled:hover{background:#2D2D2D;border-bottom-color:rgba(255, 255, 255, 0.2);transform:none}#auth-modal[data-theme=\"dark\"] .auth-submit:disabled:hover{background:#2D2D2D;border-bottom-color:rgba(255, 255, 255, 0.2)}#auth-modal[data-theme=\"light\"] .auth-submit:disabled:hover,.light #auth-modal .auth-submit:disabled:hover,[data-theme=\"light\"] #auth-modal .auth-submit:disabled:hover,body.light #auth-modal .auth-submit:disabled:hover{background:#f0f0f0!important;border-bottom-color:rgba(0, 0, 0, 0.15)!important}.auth-submit-icon{width:14px;height:14px;flex-shrink:0}.auth-error{background:rgba(239, 68, 68, 0.1);border:1px solid rgba(239, 68, 68, 0.2);color:#ef4444;padding:8px 12px;border-radius:8px;display:flex;align-items:flex-start;gap:8px;margin-top:12px}.auth-error-icon{width:16px;height:16px;margin-top:2px;flex-shrink:0;color:#ef4444}.auth-error-text{font-size:12px;font-weight:500}@media (max-width: 480px){.auth-overlay{padding:8px}.auth-modal{max-width:100%}.auth-header{padding:12px}.auth-content{padding:12px}.auth-footer{padding:12px}.auth-header h2{font-size:14px}.auth-header p{font-size:11px}}"}],"page":{"pagePath":"api-reference/savings/get-agent-investments","slug":"/api-reference/savings/get-agent-investments","pageMetadata":{"title":"Get Agent Investments","api":"GET /savings/{agentId}","description":"Get all investments for a specific agent","href":"/api-reference/savings/get-agent-investments"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Get all investments for a specific agent\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={p:`p`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{Expandable,Heading,Info,Note,ParamField,ResponseField,Table}=_components;if(!Expandable)_missingMdxReference(`Expandable`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Info)_missingMdxReference(`Info`,true);if(!Note)_missingMdxReference(`Note`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!ResponseField)_missingMdxReference(`ResponseField`,true);if(!Table)_missingMdxReference(`Table`,true);return _jsxs(_Fragment,{children:[_jsx(Note,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Investment History`}),`: Retrieves all investments (both active and completed) associated with a specific agent. For active investments, calculates the current value and interest earned based on the principal amount, interest rate, and investment duration. Returns detailed information including investment status and creation timestamp.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`path-parameters`,children:`Path Parameters`}),`\n`,_jsx(ParamField,{path:`agentId`,type:`string`,required:true,id:`param-agent-id`,children:_jsx(_components.p,{children:`The short ID or UUID of the agent`})}),`\n`,_jsx(Heading,{level:`2`,id:`request-headers`,children:`Request Headers`}),`\n`,_jsx(ParamField,{header:`x-api-key`,type:`string`,required:true,id:`param-x-api-key`,children:_jsx(_components.p,{children:`Your API key for authentication`})}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsx(ResponseField,{name:`investments`,type:`array`,id:`param-investments`,children:_jsxs(Expandable,{title:`Investment Object`,children:[_jsx(ResponseField,{name:`id`,type:`string`,id:`param-id`,children:_jsx(_components.p,{children:`Unique investment identifier in short ID format`})}),_jsx(ResponseField,{name:`agent_id`,type:`string`,id:`param-agent-id-1`,children:_jsx(_components.p,{children:`ID of the agent associated with this investment`})}),_jsx(ResponseField,{name:`amount`,type:`number`,id:`param-amount`,children:_jsx(_components.p,{children:`Principal amount invested`})}),_jsx(ResponseField,{name:`invested_at`,type:`string`,id:`param-invested-at`,children:_jsx(_components.p,{children:`Timestamp when the investment was created`})}),_jsx(ResponseField,{name:`status`,type:`string`,id:`param-status`,children:_jsx(_components.p,{children:`Current status of the investment (active, completed, cancelled)`})}),_jsx(ResponseField,{name:`current_value`,type:`string`,id:`param-current-value`,children:_jsx(_components.p,{children:`Current value of the investment including earned interest`})}),_jsx(ResponseField,{name:`interest_earned`,type:`string`,id:`param-interest-earned`,children:_jsx(_components.p,{children:`Interest earned on the investment to date`})})]})}),`\n`,`\n`,_jsx(Heading,{level:`2`,id:`status-codes`,children:`Status Codes`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Status Code`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`200`}),_jsx(_components.td,{children:`List of investments retrieved successfully`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`400`}),_jsx(_components.td,{children:`Bad Request - Invalid agent ID format`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`401`}),_jsx(_components.td,{children:`Unauthorized - Invalid or missing API key`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`404`}),_jsx(_components.td,{children:`Not Found - Agent not found`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`500`}),_jsx(_components.td,{children:`Internal Server Error`})]})]})]}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`All Investment Statuses`}),`: This endpoint returns all investments for the agent regardless of status (active, completed, cancelled).`]})}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Real-time Calculations`}),`: For active investments, current values and interest earned are calculated in real-time based on the current interest rate and investment duration.`]})}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Completed Investments`}),`: For completed investments, the values shown represent the final amounts at the time of withdrawal.`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Get Agent Investments","api":"GET /savings/{agentId}","description":"Get all investments for a specific agent","href":"/api-reference/savings/get-agent-investments"}}},"mdxSourceWithNoJs":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{CodeBlock,Expandable,Heading,Info,Note,ParamField,ResponseExample,ResponseField,Table}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Expandable)_missingMdxReference(`Expandable`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Info)_missingMdxReference(`Info`,true);if(!Note)_missingMdxReference(`Note`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!ResponseExample)_missingMdxReference(`ResponseExample`,true);if(!ResponseField)_missingMdxReference(`ResponseField`,true);if(!Table)_missingMdxReference(`Table`,true);return _jsxs(_Fragment,{children:[_jsx(Note,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Investment History`}),`: Retrieves all investments (both active and completed) associated with a specific agent. For active investments, calculates the current value and interest earned based on the principal amount, interest rate, and investment duration. Returns detailed information including investment status and creation timestamp.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`path-parameters`,children:`Path Parameters`}),`\n`,_jsx(ParamField,{path:`agentId`,type:`string`,required:true,id:`param-agent-id`,children:_jsx(_components.p,{children:`The short ID or UUID of the agent`})}),`\n`,_jsx(Heading,{level:`2`,id:`request-headers`,children:`Request Headers`}),`\n`,_jsx(ParamField,{header:`x-api-key`,type:`string`,required:true,id:`param-x-api-key`,children:_jsx(_components.p,{children:`Your API key for authentication`})}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsx(ResponseField,{name:`investments`,type:`array`,id:`param-investments`,children:_jsxs(Expandable,{title:`Investment Object`,children:[_jsx(ResponseField,{name:`id`,type:`string`,id:`param-id`,children:_jsx(_components.p,{children:`Unique investment identifier in short ID format`})}),_jsx(ResponseField,{name:`agent_id`,type:`string`,id:`param-agent-id-1`,children:_jsx(_components.p,{children:`ID of the agent associated with this investment`})}),_jsx(ResponseField,{name:`amount`,type:`number`,id:`param-amount`,children:_jsx(_components.p,{children:`Principal amount invested`})}),_jsx(ResponseField,{name:`invested_at`,type:`string`,id:`param-invested-at`,children:_jsx(_components.p,{children:`Timestamp when the investment was created`})}),_jsx(ResponseField,{name:`status`,type:`string`,id:`param-status`,children:_jsx(_components.p,{children:`Current status of the investment (active, completed, cancelled)`})}),_jsx(ResponseField,{name:`current_value`,type:`string`,id:`param-current-value`,children:_jsx(_components.p,{children:`Current value of the investment including earned interest`})}),_jsx(ResponseField,{name:`interest_earned`,type:`string`,id:`param-interest-earned`,children:_jsx(_components.p,{children:`Interest earned on the investment to date`})})]})}),`\n`,_jsxs(ResponseExample,{children:[_jsx(CodeBlock,{filename:`200`,numberOfLines:`22`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`22`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"investments\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"inv_k77NTwxp2Ym3JCmVsKtXQA\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"agent_k77NTwxp2Ym3JCmVsKtXQA\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"amount\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1000`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"invested_at\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"2025-04-15T11:00:08.432269+00:00\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"status\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"active\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"current_value\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"1050.00\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"interest_earned\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"50.00\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"inv_p99QTaxp3Zm3KDnWtLuRrD\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"agent_k77NTwxp2Ym3JCmVsKtXQA\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"amount\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`500`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"invested_at\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"2025-03-10T09:15:22.123456+00:00\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"status\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"completed\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"current_value\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"515.25\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"interest_earned\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"15.25\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`400`,numberOfLines:`3`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`3`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Bad request\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`401`,numberOfLines:`7`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`7`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Invalid or missing API key\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:\"```json \"}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`404`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Agent not found\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`500`,numberOfLines:`3`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`3`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"error\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Internal server error\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})]}),`\n`,_jsx(Heading,{level:`2`,id:`status-codes`,children:`Status Codes`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Status Code`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`200`}),_jsx(_components.td,{children:`List of investments retrieved successfully`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`400`}),_jsx(_components.td,{children:`Bad Request - Invalid agent ID format`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`401`}),_jsx(_components.td,{children:`Unauthorized - Invalid or missing API key`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`404`}),_jsx(_components.td,{children:`Not Found - Agent not found`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`500`}),_jsx(_components.td,{children:`Internal Server Error`})]})]})]}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`All Investment Statuses`}),`: This endpoint returns all investments for the agent regardless of status (active, completed, cancelled).`]})}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Real-time Calculations`}),`: For active investments, current values and interest earned are calculated in real-time based on the current interest rate and investment duration.`]})}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Completed Investments`}),`: For completed investments, the values shown represent the final amounts at the time of withdrawal.`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Get Agent Investments","api":"GET /savings/{agentId}","description":"Get all investments for a specific agent","href":"/api-reference/savings/get-agent-investments"}}}},"mdxExtracts":{"tableOfContents":[{"title":"Path Parameters","slug":"path-parameters","depth":2,"children":[]},{"title":"Request Headers","slug":"request-headers","depth":2,"children":[]},{"title":"Response","slug":"response","depth":2,"children":[]},{"title":"Status Codes","slug":"status-codes","depth":2,"children":[]}],"codeExamples":{"response":{"type":"ResponseExample","children":[{"filename":"200","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"22\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"investments\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: [\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"id\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"inv_k77NTwxp2Ym3JCmVsKtXQA\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"agent_id\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"agent_k77NTwxp2Ym3JCmVsKtXQA\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"amount\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">1000\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"invested_at\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"2025-04-15T11:00:08.432269+00:00\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"status\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"active\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"current_value\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"1050.00\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"interest_earned\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"50.00\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> },\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"id\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"inv_p99QTaxp3Zm3KDnWtLuRrD\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"agent_id\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"agent_k77NTwxp2Ym3JCmVsKtXQA\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"amount\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">500\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"invested_at\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"2025-03-10T09:15:22.123456+00:00\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"status\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"completed\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"current_value\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"515.25\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"interest_earned\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"15.25\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> }\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> ]\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"400","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"3\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"error\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Bad request\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"401","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"7\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"error\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Invalid or missing API key\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">```json \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">404\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"error\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Agent not found\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"500","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"3\">\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#116329;--shiki-dark:#9CDCFE\"> \"error\"\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">\"Internal server error\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"}],"attributes":[]}},"endpoint":{"title":"Get Agent Investments","path":"/savings/{agentId}","servers":[{"url":"https://api.magebank.ai"}],"method":"get","request":{"security":[],"parameters":{"query":{},"header":{"x-api-key":{"schema":[{"type":"string","description":"Your API key for authentication","required":true}]}},"cookie":{},"path":{"agentId":{"schema":[{"type":"string","description":"The short ID or UUID of the agent","required":true}]}}},"body":{}},"response":{"200":{"application/json":{"schemaArray":[{"type":"object","properties":{"investments":[{"type":"array","items":[{"type":"object","properties":{"id":[{"type":"string","description":"Unique investment identifier in short ID format"}],"agent_id":[{"type":"string","description":"ID of the agent associated with this investment"}],"amount":[{"type":"number","description":"Principal amount invested"}],"invested_at":[{"type":"string","description":"Timestamp when the investment was created"}],"status":[{"type":"string","description":"Current status of the investment (active, completed, cancelled)"}],"current_value":[{"type":"string","description":"Current value of the investment including earned interest"}],"interest_earned":[{"type":"string","description":"Interest earned on the investment to date"}]}}]}]}}],"examples":{"example":{"value":{"investments":[{"id":"\u003cstring>","agent_id":"\u003cstring>","amount":123,"invested_at":"\u003cstring>","status":"\u003cstring>","current_value":"\u003cstring>","interest_earned":"\u003cstring>"}]}}}}}},"deprecated":false}},"jsLinks":["/_mintlify/custom/mage-bank/1e4b99045996c61b/auth.js"],"subdomain":"mage-bank","siteName":"Mage API Documentation","title":"Get Agent Investments - Mage API Documentation","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-01-07T08:07:26.415Z","originalFileLocation":"api-reference/savings/get-agent-investments.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Get all investments for a specific agent\">\u003cmeta data-mint-head name=\"application-name\" content=\"Mage API Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Get Agent Investments - Mage API Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Get all investments for a specific agent\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Mage API Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.magebank.ai/api-reference/savings/get-agent-investments\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://mage-bank.mintlify.app/_mintlify/api/og/v2?division=Savings\u0026amp;title=Get+Agent+Investments\u0026amp;description=Get+all+investments+for+a+specific+agent\u0026amp;theme=dee5e68ffd04fa1fff3d24df\u0026amp;signature=afe9455fa46bba53419f4671f3006a6dc91140a882bb450fdf6b5cbeb6038f87\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Get Agent Investments - Mage API Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Get all investments for a specific agent\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://mage-bank.mintlify.app/_mintlify/api/og/v2?division=Savings\u0026amp;title=Get+Agent+Investments\u0026amp;description=Get+all+investments+for+a+specific+agent\u0026amp;theme=dee5e68ffd04fa1fff3d24df\u0026amp;signature=afe9455fa46bba53419f4671f3006a6dc91140a882bb450fdf6b5cbeb6038f87\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/mage-bank/g0X0PUMQLAKhbfWc/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Mage API Documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#FF5722\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.magebank.ai/api-reference/savings/get-agent-investments\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/savings/get-agent-investments.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.magebank.ai/#organization\",\"name\":\"Mage API Documentation\",\"url\":\"https://docs.magebank.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/mage-bank/_nadq0QJn3EnDhRd/logo/logo-light.svg?fit=max\u0026auto=format\u0026n=_nadq0QJn3EnDhRd\u0026q=85\u0026s=219a4c58a03182e18d28e9d2afb98f31\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.magebank.ai#website\",\"name\":\"Mage API Documentation\",\"url\":\"https://docs.magebank.ai\",\"publisher\":{\"@id\":\"https://docs.magebank.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.magebank.ai/api-reference/savings/get-agent-investments#webpage\",\"url\":\"https://docs.magebank.ai/api-reference/savings/get-agent-investments\",\"name\":\"Get Agent Investments\",\"description\":\"Get all investments for a specific agent\",\"dateModified\":\"2026-01-07T08:07:26.415Z\",\"isPartOf\":{\"@id\":\"https://docs.magebank.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.magebank.ai/api-reference/savings/get-agent-investments#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.magebank.ai/api-reference/savings/get-agent-investments#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Savings\",\"item\":\"https://docs.magebank.ai/api-reference/savings/introduction\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Get Agent Investments\",\"item\":\"https://docs.magebank.ai/api-reference/savings/get-agent-investments\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.magebank.ai/api-reference/savings/get-agent-investments#apireference\",\"headline\":\"Get Agent Investments\",\"name\":\"Get Agent Investments\",\"description\":\"Get all investments for a specific agent\",\"url\":\"https://docs.magebank.ai/api-reference/savings/get-agent-investments\",\"mainEntityOfPage\":{\"@id\":\"https://docs.magebank.ai/api-reference/savings/get-agent-investments#webpage\"},\"dateModified\":\"2026-01-07T08:07:26.415Z\",\"publisher\":{\"@id\":\"https://docs.magebank.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.magebank.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Mage API Documentation\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Mage API Documentation","nav":{"global":{"anchors":[{"anchor":"Dashboard","icon":"gauge","href":"https://www.magebank.ai/dashboard"},{"anchor":"LLM.txt","icon":"robot","href":"https://raw.githubusercontent.com/MageBankAI/docs/refs/heads/master/LLM.txt"}]},"tabs":[{"tab":"Guides","pages":[{"title":"Guides","href":""}]},{"tab":"API Reference","groups":[{"group":"Users","pages":[{"title":"Introduction","href":"/api-reference/users/introduction"},{"title":"Get Wallet Balance","api":"GET /user/wallet-balance","href":"/api-reference/users/get-wallet-balance"}]},{"group":"Agents","pages":[{"title":"Introduction","href":"/api-reference/agents/introduction"},{"title":"Get Agent","api":"GET /agentsWith/{id}","href":"/api-reference/agents/get-agent"},{"title":"Create Agent","api":"POST /agents/create","href":"/api-reference/agents/create-agent"},{"title":"List User Agents","api":"GET /agents/{id}","href":"/api-reference/agents/get-user-agents"},{"title":"Deposit to Agent","api":"POST /agents/deposit","href":"/api-reference/agents/deposit"},{"title":"Withdraw from Agent","api":"POST /agents/withdraw","href":"/api-reference/agents/withdraw"}]},{"group":"Payments","pages":[{"title":"Introduction","href":"/api-reference/payments/introduction"},{"title":"Register Payment","api":"POST /payments/register","href":"/api-reference/payments/register-payment"},{"title":"Approve Payment","api":"POST /payments/setApprove","href":"/api-reference/payments/approve-payment"},{"title":"Decline Payment","api":"POST /payments/setDecline","href":"/api-reference/payments/decline-payment"},{"title":"Get Payment","api":"GET /payments/{id}","href":"/api-reference/payments/get-payment"},{"title":"List User Payments","api":"GET /user/payments","href":"/api-reference/payments/get-user-payments"},{"title":"Export Payments","api":"POST /payments/export","href":"/api-reference/payments/export-payments"}]},{"group":"Transactions","pages":[{"title":"Introduction","href":"/api-reference/transactions/introduction"},{"title":"Transaction Summary","api":"GET /transactions/summary","href":"/api-reference/transactions/get-transaction-summary"}]},{"group":"Savings","pages":[{"title":"Introduction","href":"/api-reference/savings/introduction"},{"title":"Get Interest Rate","api":"GET /investment/interest-rate","href":"/api-reference/savings/get-interest-rate"},{"title":"Calculate Interest","api":"POST /investment/calculator","href":"/api-reference/savings/calculate-interest"},{"title":"Deposit Savings","api":"POST /savings/deposit","href":"/api-reference/savings/deposit"},{"title":"Withdraw Savings","api":"POST /savings/withdraw","href":"/api-reference/savings/withdraw"},{"title":"Get Savings Dashboard","api":"GET /savings/dashboard","description":"Get a comprehensive overview of the user's savings portfolio","href":"/api-reference/savings/get-dashboard"},{"title":"Get Agent Investments","api":"GET /savings/{agentId}","href":"/api-reference/savings/get-agent-investments"},{"title":"Get User Investments","api":"GET /savings/myinvestments","description":"Get all active investments for the authenticated user","href":"/api-reference/savings/get-user-investments"}]}]}]},"basePath":"","title":"Get Agent Investments - Mage API Documentation","buildId":"dpl_2gSLkbMoF5kkLsBqYzq9KWtDyJRo","deploymentId":"dpl_2gSLkbMoF5kkLsBqYzq9KWtDyJRo","dynamics":["10e4515597","c2aa737661","2b790eda92","b0f84f53ff"],"chunks":["BannerMarkdown-CiLHwMiK.js","dist-CjboTi0T.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","clsx-v8ssfMzu.js","html-void-elements-mCSPHezU.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","OpenApiReferenceProvider-hfTk6MZX.js","utils-Bfp7HcY4.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-D8dSW7yV.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-CFgQXcZO.js","snippetPresets-dMW1-pV3.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-DyrCOido.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-Bwwdcyh3.js","shallow-drVXTg79.js","getApiPlaygroundDisplay-GMPxUzWV.js","CodeSnippet-wTmV0wP6.js","CodeSnippets-D_QxCJEq.js","Page-BsZAA8xk.js","getPastedJson-Dev-X0Xy.js","icon-7L2WL0jD.js","MethodPill-Ble59Dl_.js","DuplicateIcon-r-98uLGh.js","createIcon-DaFzipjW.js","DynamicMarkdown-Jk8YAWGN.js","SectionHeading-nLgrCDOg.js","axios-vUo_bRtp.js"]}