---
title: "POST /v2/user/accounts/{server}/{accountId}/favorites"
method: POST
path: "/v2/user/accounts/{server}/{accountId}/favorites"
tags: ["Favorites (v2)"]
---

# POST /v2/user/accounts/{server}/{accountId}/favorites

`POST /v2/user/accounts/{server}/{accountId}/favorites`

## Request

- Base URL: `https://trading-api.oanda.com` (the document declares no server; this is the origin it was published from)
- URL: `https://trading-api.oanda.com/v2/user/accounts/{server}/{accountId}/favorites`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/oanda/apis/up-gateway-v1/docs/v2/user/accounts/:server/:accountId/favorites/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `server` 'oanda' | 'oanda-demo' | 'otms' | 'v20' | 'v20-demo' | 'oj' | 'oj-demo' | 'opt' | 'ftmo-1', required
- `accountId` string, required

## Request body

- object
  - `instrument` string, required

## Response `200`

OK

- object
  - `instruments` string[], required

## Other responses

- `400`: FAIL

---

[API](https://skmtc.dev/oanda/apis/up-gateway-v1.md) - [All operations](https://skmtc.dev/oanda/apis/up-gateway-v1/llms.txt) - [OpenAPI document](https://skmtc.dev/oanda/apis/up-gateway-v1/revisions/395d645513bf?raw)
