Is it a plugin API that can list the local styles and update their values?

I am looking for a way to list all local styles of a file and update their values through the plugin API but not sure if it is even possible. Specifically, I want to see if I can grab the green color and change it to yellow:

image

figma.getLocalPaintStyles()

Thanks! It’s not included in the index section and hard to find…

Hi, I know we can get all the local styles using the plugin api Figma.getLocalPaintStyles(). But is there any API to update or add localStyles? Basically I want to get all the colors from the selected frames using Figma.getSelectionColors(). And then add the colors as variables or color styles. How do I add/update variables or colorstyles using any plugin API?