# Wallet investment amount chart

## GET /wallets/{address}/charts/investment\_amount

> Returns wallet investment amount chart data.\
> Require period or custom time to be set. \
> To set custom time interval use \`from\_time\` and \`to\_time\` params.<br>

```json
{"openapi":"3.1.0","info":{"title":"Analytics API","version":"1.0.4"},"tags":[{"name":"wallet","description":"Wallet"}],"servers":[{"url":"https://definest.ai/api/analytics/v1","description":"Production server"}],"security":[{"xApiKey":[]}],"components":{"securitySchemes":{"xApiKey":{"type":"apiKey","in":"header","name":"X-API-Key","description":"API key for authentication"}},"parameters":{"WalletAddressPathParam":{"name":"address","in":"path","description":"Wallet address","required":true,"schema":{"$ref":"#/components/schemas/Wallet/properties/address"}},"BlockchainNetworkQueryParam":{"name":"network","in":"query","description":"Blockchain network","required":true,"schema":{"$ref":"#/components/schemas/BlockchainNetwork"}},"PeriodQueryParam":{"name":"period","in":"query","description":"Time period","schema":{"$ref":"#/components/schemas/Period"}},"FromTimeQueryParam":{"name":"from_time","in":"query","description":"Timestamp in seconds. \nMinimum time for the deal's first trade.\nDeals started before this time will be excluded from result and calculations.\n","schema":{"type":["integer","number"],"minimum":1}},"ToTimeQueryParam":{"name":"to_time","in":"query","description":"Timestamp in seconds. \nMaximum time for deal trades. \nTrades executed after this time will be excluded from result and calculations.\n","schema":{"type":["integer","number"],"minimum":1}}},"schemas":{"Wallet":{"properties":{"address":{"type":"string","description":"Wallet address"}}},"BlockchainNetwork":{"type":"string","enum":["eth","sol"],"description":"Supported blockchain networks"},"Period":{"type":"string","description":"Time period","enum":["12h","24h","2d","3d","7d","10d","14d","20d","1m","2m","3m","6m","1y","2y"]},"InvestmentAmountChart":{"type":"object","description":"Investment amount chart data","properties":{"timestamps":{"$ref":"#/components/schemas/ChartTimestampsArray"},"values":{"type":"array","description":"Array of investment amount values corresponding to each timestamp. In USD ($)","items":{"type":["integer"],"description":"Investment amount in USD ($) at the given timestamp"}},"period":{"$ref":"#/components/schemas/ChartPeriod"}},"required":["timestamps","values","period"]},"ChartTimestampsArray":{"type":"array","description":"Array of timestamps for each data point","items":{"type":["integer"],"description":"UNIX timestamp in seconds"}},"ChartPeriod":{"type":"object","properties":{"start":{"type":["integer"],"description":"Start timestamp of the chart period in seconds"},"end":{"type":["integer"],"description":"End timestamp of the chart period in seconds"}},"required":["start","end"]},"ResponseCredits":{"type":"object","description":"Credits data after request","properties":{"spent":{"type":"integer","description":"Credits spent on the request"},"remaining":{"type":"integer","description":"Remaining credits"}},"required":["spent","remaining"]}},"responses":{"400BadRequest":{"description":"Request fail","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error short code"},"detail":{"description":"Detailed error description"}},"required":["code"]}}}},"401Unauthorized":{"description":"API Key invalid or missing"},"403Forbidden":{"description":"API access forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Error short code"},"detail":{"description":"Detailed error description"}},"required":["code"]}}}}}},"paths":{"/wallets/{address}/charts/investment_amount":{"get":{"description":"Returns wallet investment amount chart data.\nRequire period or custom time to be set. \nTo set custom time interval use `from_time` and `to_time` params.\n","tags":["wallet"],"parameters":[{"$ref":"#/components/parameters/WalletAddressPathParam"},{"$ref":"#/components/parameters/BlockchainNetworkQueryParam"},{"$ref":"#/components/parameters/PeriodQueryParam"},{"$ref":"#/components/parameters/FromTimeQueryParam"},{"$ref":"#/components/parameters/ToTimeQueryParam"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"result":{"type":"object","properties":{"chart":{"$ref":"#/components/schemas/InvestmentAmountChart"}},"required":["chart"]},"credits":{"$ref":"#/components/schemas/ResponseCredits"}},"required":["result","credits"]}}}},"400":{"$ref":"#/components/responses/400BadRequest"},"401":{"$ref":"#/components/responses/401Unauthorized"},"403":{"$ref":"#/components/responses/403Forbidden"}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.definest.ai/api/wallet-analytics/wallet-investment-amount-chart.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
