The Locksmith REST API
Accessing Locksmith's API requires two headers:
x-shopify-shop-domain– must be of the format "example.myshopify.com"
x-locksmith-access-token– must be an enabled access token, generated in your Locksmith settings
Using cURL, one might access the API this way:
--header "x-shopify-shop-domain: example.myshopify.com" \
--header "x-locksmith-access-token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \
- GET https://uselocksmith.com/api/:version/shop.json This endpoint returns Locksmith's entire configuration for your store.
- GET https://uselocksmith.com/api/:version/locks.json This endpoint returns an array of all locks in your Locksmith account.
- GET https://uselocksmith.com/api/:version/locks/:id.json This endpoint returns data for a single lock in your Locksmith account.
- POST https://uselocksmith.com/api/:version/install This endpoint requests a full Locksmith installation, in the currently published theme
- Do not rely upon data keys that are prefixed with an underscore (e.g. "_foobar"). They are subject to change or removal at any time.
To access this API, generate an access token. You can find these toward the end of your settings area:
Use the "Add access token" link to add your first token.
Once created, an access token may be edited to enable/disable it, or to change its name. It may also be deleted.