Skip to main content
This quickstart walks you through the CLI with demo data. You fill your organization with sample products, look at them, watch events as they happen, upload an image, and remove everything again.
The quickstart writes to your organization. Use a test or sandbox organization if you have one.

Before you start

Install the CLI and sign in:
1

Seed demo data

See the demo profiles and the sources each one creates:
The ecommerce profile creates products, variants, prices and stock. Seed it with 50 products and the default number of entries for the other sources:
In a terminal you can also run occtoo demo seed and pick a profile and entry counts from prompts. Every demo source id starts with demo, and seeding again overwrites the same entries instead of adding new ones.
2

Look at a source

Show the products source and its properties:
Read a few entries by id, exactly as they are stored. Demo products are numbered from product-00001:
Add --output json to any of these commands to get JSON instead of a table.
3

Watch events

Open a second terminal and start watching for new entries in a media source called demoImages, which you create in the next step:
The command keeps running and prints one line per event until you press Ctrl-C. Leave out --filter to see every event, and run occtoo events types to see what you can filter on.
4

Upload an image

Back in the first terminal, create a media source:
Upload an image. The file name without its extension becomes the entry key, so hero.jpg becomes hero:
The event shows up in the second terminal. Check the state and public address of the asset:
5

Clean up

Remove the demo sources and their entries:
demo cleanup only removes sources that demo seed created, so delete the media source yourself:
Press Ctrl-C in the second terminal to stop watching events.

Next steps