Managing site customization via API

Hey guys, I was wondering if there is a way of managing CSS/HTML customization via API. This means to fetch/update items here: admin/customize/css_html/

I’ve read this and didn’t had too much luck:

  • GETting this in POSTMAN {{base_url}}/admin/site_customizations/22?api_key={{api_key}}&api_username={{api_username}} returns nothing;
  • GETting this in POSTMAN {{base_url}}/admin/site_customizations/ will return Oops! That page doesn’t exist or is private.


Are you using the system api key?

Yeah, i did, but now i tried with an (admin) user API key and still not working.

1 Like

devtools says this is working:

curl ''

My guess is you have issues with your api keys or something.

1 Like

I feel dumb today :smiley: Can you please give me a full curl sample?

My Postman cURL looks like this

curl -X GET 
-H "Cache-Control: no-cache" -H "Postman-Token: xxx" 

And the response looks like this:

(The username has administrator rights)

If i use postman to make a request that requires auth, it works:


Works just fine.

My guess is that the controller is checking for XHR, maybe try adding:



That was it! Thanks! (mark as solved? :D)

1 Like