Account setup
To optimize your media with TwicPics, you first need an account. If you don't already have one, you can easily register for free.
Once your account is successfully created, follow these steps to set it up:
Create a workspace
A workspace allows you to collaborate with your team on a dedicated project. Having a workspace is required to create a domain that will deliver your optimized assets.
Once logged into your account, click the "New workspace" or "Create workspace" button:
You will be asked to enter a name for your workspace:
After setting up your workspace, you can create a domain.
Create a domain
It's time to create your first domain.
A domain is the host that will deliver your optimized media and is required to create one or more paths that will know where to fetch your original assets.
Depending on your needs, you can choose between two domain types:
- Create a TwicPics domain — your optimized media will be served from a TwicPics domain (i.e. twic.pics), using the TwicPics CDN.
- Create a custom domain — your optimized media will be served from your own domain, using the TwicPics CDN. Note that only Business and Enterprise plans can use a custom domain.
Create a TwicPics domain
By creating a TwicPics domain, your optimized media will be served from a TwicPics domain, using the TwicPics CDN.
A TwicPics domain takes the form of https://<subdomain>.twic.pics
where <subdomain>
is a subdomain of your choice, generally the name of your company (e.g. https://my-company.twic.pics
).
To create a TwicPics domain, click the "Create a TwicPics domain" button displayed on your dashboard interface:
Then, set a subdomain for your TwicPics domain:
Once you have successfully created your TwicPics domain, create a path to complete your setup.
Create a custom domain
By creating a custom domain, your optimized media will be served from your own domain, using the TwicPics CDN. Only Business and Enterprise plans can use a custom domain.
A custom domain takes the form of https://<subdomain>.<domain>.com
, using a domain that you own (e.g. https://media.my-domain.com
).
To create a custom domain, open the drop-down menu next to the "Create a TwicPics domain" button, displayed on your dashboard interface. Then click the "Create a custom domain" item:
You will be asked to fill in your domain:
Once you have successfully created your custom domain, create a path to complete your setup.
Create a path
A domain path points to a Source URL, a storage from which your original assets will be retrieved.
A Source URL can be your web server, cloud storage, DAM, PIM, or whatever accessible HTTP resource.
Associated with your domain, whether it is a TwicPics domain or a custom domain, a path is part of the output URL from which your optimized media will be served, e.g. https://<subdomain>.twic.pics/<path>/image.jpeg
.
To create a domain path, click the "Create path" button from your dashboard:
You will be asked to:
- Choose between an
image path
or avideo path
, depending on the type of media to optimize. Note that video paths are only accessible to Business and Enterprise plans. - Give a name to your path.
- Enter a Source URL to define your original assets storage.
Give a name to your path
You don't have to give a name to an image path
. In this case, your path will automatically point your Source URL to the root of your domain (/
):
Domain | Path | Source URL |
---|---|---|
https://<subdomain>.twic.pics | / | https://media.my-company.com/ |
https://<custom-twicpics-domain> | / | https://media.my-company.com/ |
You can also name your paths after the type of your original media:
Domain | Path | Source URL |
---|---|---|
https://<subdomain>.twic.pics | /media/ | https://media.my-company.com/web/ |
https://<custom-twicpics-domain> | /logos/ | https://media.my-company.com/images/logos/ |
As for video paths
, they work just like image paths, except they must start with the word video
, no matter what comes next:
Domain | Path | Source URL |
---|---|---|
https://<subdomain>.twic.pics | /video/ | https://media.my-company.com/videos/ |
https://<subdomain>.twic.pics | /videos/ | https://media.my-company.com/videos/ |
https://<subdomain>.twic.pics | /video-products/ | https://media.my-company.com/videos/ |
Apply path options
Please refer to the path options section if you need advanced path features. You will see for example how to:
Make your first request
At this point, you should be ready to test your setup by making your first request through TwicPics.
Depending on your setup, you should be able to request one of your images by filling your browser address bar with a URL of this format:
https://<your-twicpics-domain>/<your-path>/<your-image-filename>
And make your first transformation thanks to the URL-based API:
https://<your-twicpics-domain>/<your-path>/<your-image-filename>?twic=v1/resize=200
It's now time to proceed with integrating TwicPics on your website!