---
title: "PNG behind a signed chart link"
method: GET
path: "/charts/{token}.png"
tags: ["patterns"]
---

# PNG behind a signed chart link

`GET /charts/{token}.png`

## Request

- Base URL: `https://api.tradingpal.io/api/v1`
- URL: `https://api.tradingpal.io/api/v1/charts/{token}.png`
- Auth: one of:
  - none
  - HTTP bearer
  - OAuth 2 (authorization code, authorization URL `https://api.tradingpal.io/oauth/authorize`, token URL `https://api.tradingpal.io/oauth/token`, scopes: `patterns`)

Returns the PNG a signed chart link points at. Chart links come from the agent tools and nowhere else: `io.tradingpal/chart_url` in the `_meta` of a get_pattern_chart or demo result, which an app card loads as an image because a card cannot send the key. The token names one current setup; the link needs no key, is limited per IP, and stops working when the setup is no longer current or a week after it was issued, whichever comes first.

## Path parameters

- `token` string, required

## Response `200`

PNG image of the setup: candles, both lines, trigger, stop and target.

## Other responses

- `404`: chart_link_expired (the link is not valid or has expired) or setup_not_found (the setup is no longer current)
- `429`: rate_limited; wait details.retry_after_seconds

---

[API](https://skmtc.dev/tradingpal/apis/tradingpal-pattern-api.md) · [All operations](https://skmtc.dev/tradingpal/apis/tradingpal-pattern-api/llms.txt) · [OpenAPI document](https://skmtc.dev/tradingpal/apis/tradingpal-pattern-api/revisions/e96e1f20c1ce?raw)
