REST API: 400: Bad Request when trying to set color

I have turned on the smart light to a color successfully from the Developer Tools Services tab on the web interface. I am now trying to do it from REST API using curl. I have tried

curl -X POST -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{"entity_id": "light.<id>",  "rgb_color": "[0, 0, 255]"}' \
  http://localhost:8123/api/services/light/turn_on

but it just returns 400: Bad Request and light stays off. It turns on if I don’t include rgb_color. What am I doing wrong?

EDIT: It was simply because I put quotes where the RGB color values are. I removed them and now it’s working.