Skip to content

Colors

All items can have one or more associated colors:

Color
type Color = {
id: string;
name: string;
displayName: string;
hexValue?: string;
hslValue?: string;
userSubmitted: boolean;
enabled: boolean;
createdAt: string;
updatedAt: string;
}
  • id : a unique id in CUID format (generated by paralleldrive)
  • name : a unique-within-family internal name, no whitespace i.e. ‘rose-gold’
  • displayName : Title-cased name for UI / Display, i.e. ‘Rose Gold’
  • hexValue : color value in hex format (optional) i.e. ‘#FFC67D’
  • hslValue : color value in HSL format (optional) i.e. ‘29, 90%, 75%’
  • userSubmitted : was the value submitted by a user? defaults to false
  • enabled : only items with enabled: true are included in API responses
  • createdAt : item creation timestamp, ISO-8601 string format
  • updatedAt : item updated timestamp, ISO-8601 string format

All colors belong to one or more Color Families:

Color Family
type ColorFamily = {
id: string;
name: string;
displayName: string;
enabled: boolean;
createdAt: string;
updatedAt: string;
colors: Array<Color>;
}
  • id : a unique id in CUID format (generated by paralleldrive)
  • name : a unique-within-family internal name, no whitespace i.e. ‘animal-print’
  • displayName : Title-cased name for UI / Display, i.e. ‘Animal Print’
  • userSubmitted : was the value submitted by a user? defaults to false
  • enabled : only items with enabled: true are included in API responses
  • createdAt : item creation timestamp, ISO-8601 string format
  • updatedAt : item updated timestamp, ISO-8601 string format
  • colors : array of associated Colors
Color Families Endpoint
$ curl /resources/color-families | jq .
[
{
"id": "kuv81kpng5c5c5cw4z4r3kdx",
"name": "blue",
"displayName": "Blue",
"enabled": true,
"createdAt": "2024-06-18 23:00:33.88306+00",
"updatedAt": "2024-06-18 23:00:33.88306+00",
"colors": [
{
"id": "y1z9liksnn2iyasdqj6qjtl0",
"name": "blue",
"displayName": "Blue",
"hexValue": "#0000FF",
"hslValue": "240, 100%, 50%",
"userSubmitted": false,
"createdAt": "2024-06-18T23:00:33.883689+00:00",
"updatedAt": "2024-06-18T23:00:33.883689+00:00"
},
{
"id": "nwcbqb1m54cmvqh7tbspvh9w",
"name": "sapphire",
"displayName": "Sapphire",
"hexValue": "#0066CC",
"hslValue": "213, 66%, 55%",
"userSubmitted": false,
"createdAt": "2024-06-18T23:00:33.884973+00:00",
"updatedAt": "2024-06-18T23:00:33.884973+00:00"
},
],
...
},
]