Add JS code

Adds JS code to the "Ecwid Admin > Website > Custom JavaScript code" section.

Headers

NameTypeDescription
AuthorizationstringoAuth token with mandatory Bearer before it. Example: Bearer e***s0, where e***s0 should be replaced with your oAuth token.

Request

A JSON object with the following fields:

CustomCode

FieldTypeDescription
customBodyScriptCodestringYour custom script. Example: <script>alert(\"added from APIs\")</script>

Response

A JSON object of type 'storeID' with the following fields:

FieldTypeDescription
idnumberstore ID
Language
Authorization
Query