Endpoint
GET https://requiems.xyz/v1/technology/color
Convert Color
Convert a color value from one format to another. The response always includes all four formats.
Parameters
| Name |
Type |
Required |
Location |
Description |
from |
string |
yes |
query |
Source color format: hex, rgb, hsl, or cmyk |
to |
string |
yes |
query |
Target color format: hex, rgb, hsl, or cmyk |
value |
string |
yes |
query |
Color value in the source format (e.g. #ff5733, rgb(255,87,51), hsl(11,100%,60%), cmyk(0%,66%,80%,0%)) |
Response Example
{
"data": {
"input": "#ff5733",
"result": "hsl(11, 100%, 60%)",
"formats": {
"hex": "#ff5733",
"rgb": "rgb(255, 87, 51)",
"hsl": "hsl(11, 100%, 60%)",
"cmyk": "cmyk(0%, 66%, 80%, 0%)"
}
},
"metadata": {
"timestamp": "2026-01-01T00:00:00Z"
}
}
Response Fields
| Field |
Type |
Description |
input |
string |
The original value passed in the value parameter |
result |
string |
The color expressed in the requested to format |
formats.hex |
string |
HEX representation (#rrggbb) |
formats.rgb |
string |
RGB representation (rgb(r, g, b)) |
formats.hsl |
string |
HSL representation (hsl(h, s%, l%)) |
formats.cmyk |
string |
CMYK representation (cmyk(c%, m%, y%, k%)) |
Errors
400 bad_request — One or more of from, to, or value parameters is missing or the from/to value is not one of: hex, rgb, hsl, cmyk.
422 invalid_color — The value cannot be parsed in the specified from format.
500 internal_error — Unexpected server error.
1---2name: color-conversion-get-color3description: Convert a color value from one format to another. The response always includes all four formats.4---5
6## Endpoint
7
8**GET https://requiems.xyz/v1/technology/color**
9
10## Convert Color
11
12Convert a color value from one format to another. The response always includes all four formats.
13
14## Parameters
15
16| Name | Type | Required | Location | Description |
17| ---- | ---- | -------- | -------- | ----------- |
18| `from` | string | yes | query | Source color format: hex, rgb, hsl, or cmyk |
19| `to` | string | yes | query | Target color format: hex, rgb, hsl, or cmyk |
20| `value` | string | yes | query | Color value in the source format (e.g. #ff5733, rgb(255,87,51), hsl(11,100%,60%), cmyk(0%,66%,80%,0%)) |
21
22## Response Example
23
24```json
25{
26 "data": {
27 "input": "#ff5733",
28 "result": "hsl(11, 100%, 60%)",
29 "formats": {
30 "hex": "#ff5733",
31 "rgb": "rgb(255, 87, 51)",
32 "hsl": "hsl(11, 100%, 60%)",
33 "cmyk": "cmyk(0%, 66%, 80%, 0%)"
34 }
35 },
36 "metadata": {
37 "timestamp": "2026-01-01T00:00:00Z"
38 }
39}
40```
41
42## Response Fields
43
44| Field | Type | Description |
45| ----- | ---- | ----------- |
46| `input` | string | The original value passed in the value parameter |
47| `result` | string | The color expressed in the requested to format |
48| `formats.hex` | string | HEX representation (#rrggbb) |
49| `formats.rgb` | string | RGB representation (rgb(r, g, b)) |
50| `formats.hsl` | string | HSL representation (hsl(h, s%, l%)) |
51| `formats.cmyk` | string | CMYK representation (cmyk(c%, m%, y%, k%)) |
52
53## Errors
54
55- `400` **bad_request** — One or more of from, to, or value parameters is missing or the from/to value is not one of: hex, rgb, hsl, cmyk.
56- `422` **invalid_color** — The value cannot be parsed in the specified from format.
57- `500` **internal_error** — Unexpected server error.