Custom Storefronts

Custom Storefronts

Build your own storefront for your Phasio store with the Auth API and the Customer API

A custom storefront is your own website or application for your Phasio store. Your customers use it to upload parts, get prices, place orders, and follow their orders. You control the design and the user experience. Phasio supplies the data, the prices, and the order processing through two APIs.

Is a custom storefront right for you?

Phasio gives you three ways to let customers order from you. A custom storefront gives you the most control, and it is also the most work.

OptionWhat you getWho builds it
Phasio storefrontA complete storefront that Phasio hosts, with your brandingNobody. Configure it in the dashboard.
Embedded storefrontThe Phasio storefront inside a page of your websiteYou paste an embed code into your website and whitelist your domain.
Custom storefrontYour own screens, design, and user experience, with Phasio prices and order processingA developer. A server is necessary.

Choose a custom storefront when the Phasio storefront or the embed does not give you the experience that you want.

Who does what

TaskWhoWhere
Configure the store settings that your storefront readsYour organisationPhasio dashboard. Refer to Configure Storefront settings.
Create the storefront credentialsOwner or admin of the organisationYour Phasio account page. Refer to Quick start.
Build and host the storefrontYour developerYour server. Start with the storefront starter.

How it works

                      ┌──────────────────────────┐
                      │   Your storefront server │
 Customer's browser ─▶│  (holds the credentials) │
                      └──────┬────────────┬──────┘
                             │            │
              client ID + secret          access token
                             ▼            ▼
                      ┌───────────┐  ┌──────────────┐
                      │ Auth API  │  │ Customer API │
                      └───────────┘  └──────────────┘
APIPurposeHow your storefront authenticates
Auth APISigns customers in. Gives access tokens for guests and customers.Storefront credentials (client ID and client secret), from your server only
Customer APIStore settings, parts, prices, carts, orders, paymentsThe access token, and the X-Store-Name header

What you need

  1. A Phasio store, and an account that is an owner or admin of the organisation.
  2. Your store name: the unique name of your store, as in the URL of your Phasio-hosted storefront. It is case-sensitive.
  3. The base URLs of the two APIs for your region. Refer to Base URLs.
  4. A server (or serverless functions) for your storefront. A site that has only browser code cannot keep the client secret safe.

Base URLs

RegionAUTH_SERVERAPI_BASE
Europe (EU)https://auth.eu.phas.iohttps://c-api.eu.phas.io
United States (US)https://auth.us.phas.iohttps://c-api.us.phas.io

Use the region of your Phasio account. The address of your Phasio dashboard shows it: app.eu.phas.io or app.us.phas.io.

Use the two URLs of one region together. Credentials and tokens from one region do not work in the other region.

Next steps

Last updated on

On this page