Create a payout tag

.md

Add a label to the firm's list of payout tags.

Scopesadmin:write
Permissionmanage_payouts
POST/v1/admin/payout-tags

A new label for the firm's payout tags.

Needs a firm. Our own staff name one with the Propper-Workspace header.

Request

FieldDescription
nameUp to 50 characters, unique within the firm. Required
colorgray, red, orange, amber, emerald, cyan, blue, violet or pink. Required
curl -X POST "https://api.proppertrading.com/v1/admin/payout-tags" \
  -H "Authorization: Bearer ptat_9f2c1a44_3b8e7d2f5c9a1b4e6d8f0a2c4e6b8d1f" \
  -H "Propper-Workspace: acme" \
  -H "Idempotency-Key: 3c9e1f7a-2b4d-4e6f-8a1c-5d7b9e0f2a4c" \
  -H "Content-Type: application/json" \
  -d '{"name": "Escalated", "color": "red"}'

Response

201, with the tag:

{
    "data": {
        "object": "payout_tag",
        "id": "ptag_6v572dpx4czzbab3",
        "name": "Escalated",
        "color": "red",
        "count": 0
    },
    "meta": {
        "request_id": "req_01m50qrk9d7frer7cb2pnaqqg8"
    }
}

Errors

StatusCodeMeaning
400workspace_requiredAsked by our own staff without naming a firm
400missing_idempotency_keyA POST without an Idempotency-Key header
401invalid_tokenNot a token, or the secret does not match
401revoked_tokenSigned out here or from another device
401expired_tokenNinety days without use, or a set expiry passed
403admin_access_requiredThis account no longer helps run the environment
403insufficient_scopeThis device does not hold admin:write
403workspace_not_permittedThe Propper-Workspace header names an environment this account cannot act in
403forbiddenWithout manage_payouts
422validation_failedNo name, a name the firm already has, or an unknown color