Skip to main content
POST
/
colors
Create a color preset
curl --request POST \
  --url https://api.autoprintfarm.com/public/v1/colors \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "color_name": "<string>",
  "hex_code": "<string>",
  "filament_type": "<string>"
}
'
{
  "success": true,
  "data": {
    "id": "<string>",
    "color_name": "<string>",
    "hex_code": "<string>",
    "filament_type": "<string>",
    "is_active": true,
    "created_at": "<string>"
  }
}

Authorizations

Authorization
string
header
required

API keys are minted in the AutoPrintFarm web app under Settings → API Keys. Send as Authorization: Bearer apf_live_.... Keys are shown exactly once at creation and can be revoked at any time.

Body

application/json
color_name
string
required
Required string length: 1 - 100
hex_code
string
required
Pattern: ^#[0-9A-Fa-f]{6}$
filament_type
string
required
Required string length: 1 - 50

Response

Color preset created

success
enum<boolean>
required
Available options:
true
data
object
required