How to use the Sharefox API

Sharefox API introduction

The Sharefox API is a collection of public and authenticated endpoints that allows you to re-create the Sharefox experience using your preferred programming environment and frameworks.

API Documentation

The full Sharefox API documentation is automatically generated when we release a new version and can be found here: https://api.mysharefox.com/docs


Authentication

Most endpoints are public, but some endpoints require an authenticated user. To send an authenticated request, you need to log in as a user, and put a "Bearer" token in the "Authentication" header for the subsequent requests.

Authentication endpoints: https://api.mysharefox.com/docs#tag/auth


Shop user endpoint authentication

Certain endpoints, like "/orders/cart" and similar, must be requested on the behalf of a shop user. A shop user represents a registered customer of the shop.

Log in as a shop user: https://api.mysharefox.com/docs#tag/auth/paths/~1login/post


Admin user endpoint authentication

An admin user is a privileged user that can perform operations across all users of a shop. These endpoints are prefixed with "/admin" in the endpoint path.

Log in as an admin user: https://api.mysharefox.com/docs#tag/admin/paths/~1admin~1login/post


Note: Be aware that the token format and response structure from "/login" and "/admin/login" are different. The token from "/login" is a short lived JWT token, and the one from "/admin/login" is an opaque long lived token. Both are used the same way though, as a Bearer token in the "Authentication" request header.


Using the API to build a production integration or custom storefront

If you plan to use the Sharefox API as part of a custom storefront, application or other production integration, please contact Support to confirm that API usage is included in your subscription and to arrange access.


Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us