---
title: "Reads a portfolio product's book: settings, metrics and value."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.sherpo.io/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Sherpo merchant API › portfolio

`GET /v1/stores/{store}/products/{product}/portfolio`

## Authentication

- `bearer`, http, header `Authorization`, scopes: `portfolio:read`

## Path parameters

- `store` (`getPortfolio.path.store`; string, required) — The store's id.
- `product` (`getPortfolio.path.product`; string, required) — An id, or `slug:<slug>`.
  - minLength 1

## Code samples

### cURL

```bash
curl --request GET \
  --url 'https://api.sherpo.io/merchant/v1/stores/<store>/products/<product>/portfolio' \
  --header 'Authorization: Bearer <token>'
```

### TypeScript

```typescript
const url = 'https://api.sherpo.io/merchant/v1/stores/<store>/products/<product>/portfolio';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.sherpo.io/merchant/v1/stores/<store>/products/<product>/portfolio"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
```

## Responses

### 200

Reads a portfolio product's book: settings, metrics and value.

#### Example

```json
{
  "product": {
    "id": "string",
    "slug": "string",
    "path": "string",
    "url": "string",
    "title": "string",
    "category": "string",
    "deleted": true
  },
  "holdings": {
    "items": [
      {
        "id": "string",
        "portfolio_id": "string",
        "symbol": "string",
        "shares": 0,
        "avg_cost": 0,
        "cost_currency": "string",
        "cost_exponent": 0,
        "price_currency": "string",
        "price_exponent": 0,
        "name": "string",
        "symbol_type": "string",
        "currency": "string",
        "note": "string",
        "removed_note": "string",
        "removed_at": "string",
        "updated_at": "string",
        "metadata": {
          "property1": true,
          "property2": true
        }
      }
    ],
    "total": 0
  },
  "events": 0,
  "snapshots": 0,
  "id": "string",
  "product_id": "string",
  "currency": "string",
  "exponent": 0,
  "settings": {
    "show_absolute_values": true,
    "locked_chart_delay": "string",
    "property1": true,
    "property2": true
  },
  "created_at": "string"
}
```

- `product` (`getPortfolio.response.200.product`; object, required)
  - `id` (`getPortfolio.response.200.product.id`; string, required)
  - `slug` (`getPortfolio.response.200.product.slug`; string, required)
  - `path` (`getPortfolio.response.200.product.path`; any of, required) — The product's storefront path, or null once deleted, since another product may take its slug.
    - any of: `string`, `null`
  - `url` (`getPortfolio.response.200.product.url`; any of, required) — The absolute URL on the store's verified hostname, or null before it has one or once deleted.
    - any of: `string`, `null`
  - `title` (`getPortfolio.response.200.product.title`; string, required)
  - `category` (`getPortfolio.response.200.product.category`; string, required)
  - `deleted` (`getPortfolio.response.200.product.deleted`; boolean, required)
- `holdings` (`getPortfolio.response.200.holdings`; object, required)
  - `items` (`getPortfolio.response.200.holdings.items`; array<object>, required)
    - `id` (`getPortfolio.response.200.holdings.items.id`; string, required)
    - `portfolio_id` (`getPortfolio.response.200.holdings.items.portfolio_id`; string, required)
    - `symbol` (`getPortfolio.response.200.holdings.items.symbol`; string, required)
    - `shares` (`getPortfolio.response.200.holdings.items.shares`; number, required)
    - `avg_cost` (`getPortfolio.response.200.holdings.items.avg_cost`; any of, required)
      - any of: `number`, `null`
    - `cost_currency` (`getPortfolio.response.200.holdings.items.cost_currency`; string, required)
    - `cost_exponent` (`getPortfolio.response.200.holdings.items.cost_exponent`; any of, required)
      - any of: `number`, `null`
    - `price_currency` (`getPortfolio.response.200.holdings.items.price_currency`; string, required)
    - `price_exponent` (`getPortfolio.response.200.holdings.items.price_exponent`; any of, required)
      - any of: `number`, `null`
    - `name` (`getPortfolio.response.200.holdings.items.name`; string, required)
    - `symbol_type` (`getPortfolio.response.200.holdings.items.symbol_type`; any of, required)
      - any of: `string`, `null`
    - `currency` (`getPortfolio.response.200.holdings.items.currency`; any of, required)
      - any of: `string`, `null`
    - `note` (`getPortfolio.response.200.holdings.items.note`; any of, required)
      - any of: `string`, `null`
    - `removed_note` (`getPortfolio.response.200.holdings.items.removed_note`; any of, required)
      - any of: `string`, `null`
    - `removed_at` (`getPortfolio.response.200.holdings.items.removed_at`; any of, required)
      - any of: `string`, `null`
    - `updated_at` (`getPortfolio.response.200.holdings.items.updated_at`; any of, required)
      - any of: `string`, `null`
    - `metadata` (`getPortfolio.response.200.holdings.items.metadata`; map<any of>, required)
  - `total` (`getPortfolio.response.200.holdings.total`; number, required)
- `events` (`getPortfolio.response.200.events`; number, required)
- `snapshots` (`getPortfolio.response.200.snapshots`; number, required)
- `id` (`getPortfolio.response.200.id`; string, required)
- `product_id` (`getPortfolio.response.200.product_id`; string, required)
- `currency` (`getPortfolio.response.200.currency`; string, required)
- `exponent` (`getPortfolio.response.200.exponent`; any of, required)
  - any of: `number`, `null`
- `settings` (`getPortfolio.response.200.settings`; object, required)
  - `show_absolute_values` (`getPortfolio.response.200.settings.show_absolute_values`; boolean, optional) — Amounts, not only percentages.
  - `locked_chart_delay` (`getPortfolio.response.200.settings.locked_chart_delay`; string, optional)
- `created_at` (`getPortfolio.response.200.created_at`; any of, required)
  - any of: `string`, `null`

### default

A problem; see https://api.sherpo.io/merchant/docs/errors.

#### Example

```json
{
  "type": "http://example.com",
  "title": "string",
  "status": 0,
  "detail": "string",
  "code": "string",
  "context": {},
  "reached_core": true,
  "core_answer": "string"
}
```

- `type` (`getPortfolio.response.default.type`; string, required)
  - format `uri`
- `title` (`getPortfolio.response.default.title`; string, required)
- `status` (`getPortfolio.response.default.status`; integer, required)
- `detail` (`getPortfolio.response.default.detail`; string, required)
- `code` (`getPortfolio.response.default.code`; string, optional)
- `context` (`getPortfolio.response.default.context`; object, optional)
- `reached_core` (`getPortfolio.response.default.reached_core`; boolean, optional)
- `core_answer` (`getPortfolio.response.default.core_answer`; string, optional)


Source: https://docs.sherpo.io/merchant-api/reference/get-portfolio/index.md
