Skip to content
These docs describe Tradr v0.17.0. Running an older release? Check the release notes for what changed.

Add one leg to an existing group.

POST
/api/position-groups/{id}/legs
curl --request POST \
--url https://api.tradr.cloud/api/position-groups/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/legs \
--header 'Content-Type: application/json' \
--data '{ "positionId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" }'

Authed. Adds one ungrouped, non-draft position to the group, subject to the same checks as linking and the 8-leg cap. A 9th leg is refused with 400, naming the cap, and carries no leg index.

id
required
string format: uuid
Media typeapplication/json
object
positionId
required
string format: uuid
Examplegenerated
{
"positionId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"
}

The group

Validation error

The group or the position was not found (or not owned by the user).

The position is a draft or already grouped