packages/platform/examples/base/README.md
Example apps using atoms - customizable UI components to integrate scheduling into your product.
Cal's backend is required to run example apps, so clone https://github.com/calcom/cal.com and follow setup instructions in the readme. Importantly, you need to have Google credentials setup by following this section in the docs.
Open "apps/api/v2/.env" and copy environment variables below, and then copy NEXTAUTH_SECRET from the root ".env" of repository cloned in step 1.
NODE_ENV="development"
API_PORT=5555
DATABASE_READ_URL="postgresql://postgres:@localhost:5450/calendso"
DATABASE_WRITE_URL="postgresql://postgres:@localhost:5450/calendso"
API_URL="http://localhost"
NEXTAUTH_SECRET="copy from .env of root of repository cloned in step 1"
DATABASE_URL="postgresql://postgres:@localhost:5450/calendso"
JWT_SECRET="asjdijI1JIO12I3O89198jojioSAJDU"
REDIS_URL="redis://localhost:6379"
yarn dev.yarn dev.yarn dx.[email protected] and password ADMINadmin2022!.http://localhost:3000/settings/organizations/new and create a sample organization. When asked for phone verification code enter 111111.http://localhost:3000/settings/organizations/platform/oauth-clients and create a new oAuth client - give all permissions and set redirect uri to http://localhost:4321 which points to example app.NEXT_PUBLIC_X_CAL_ID and client secret in X_CAL_SECRET_KEY. If in step 2 you used the same environment variables, then NEXT_PUBLIC_CALCOM_API_URL can stay as is. Otherwise adjust the port to point to the same API_PORT as you used in step 2.rm -f prisma/dev.db && yarn prisma db push.yarn dev and go to http://localhost:4321.https://console.cloud.google.com/apis/credentials open web project setup in step 1 and add http://localhost:5555/v2/gcal/oauth/save to the authorized redirect URIs.