### Clone Sharetribe Integration API Examples Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-integration-api.md Clones the Sharetribe Integration API examples repository from GitHub using Git. ```bash git clone https://github.com/sharetribe/integration-api-examples.git ``` -------------------------------- ### Clone Sharetribe Integration API Examples Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-integration-api.md Clones the Sharetribe Integration API examples repository from GitHub using Git. ```bash git clone https://github.com/sharetribe/integration-api-examples.git ``` -------------------------------- ### Install Dependencies with Yarn Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-integration-api.md Installs all project dependencies using Yarn, typically for Node.js projects. ```bash yarn install ``` -------------------------------- ### Install Sharetribe Web Template Dependencies Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-web-template.md This command installs all the necessary dependency libraries for the Sharetribe Web Template project using Yarn. ```bash yarn install ``` -------------------------------- ### Install Sharetribe Web Template Dependencies Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-web-template.md This command installs all the necessary dependency libraries for the Sharetribe Web Template project using Yarn. ```bash yarn install ``` -------------------------------- ### Install Dependencies with Yarn Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-integration-api.md Installs all project dependencies using Yarn, typically for Node.js projects. ```bash yarn install ``` -------------------------------- ### Install Sharetribe CLI with Yarn Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-sharetribe-cli.md Installs the Sharetribe CLI globally using Yarn. This command requires Node.js and Yarn to be installed. ```bash yarn global add flex-cli ``` -------------------------------- ### Verify Sharetribe CLI Installation Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-sharetribe-cli.md Checks if the Sharetribe CLI has been installed correctly by displaying its version and available commands. This is a basic verification step. ```bash flex-cli ``` -------------------------------- ### Install Sharetribe CLI with Yarn Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-sharetribe-cli.md Installs the Sharetribe CLI globally using Yarn. This command requires Node.js and Yarn to be installed. ```bash yarn global add flex-cli ``` -------------------------------- ### Verify Sharetribe CLI Installation Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-sharetribe-cli.md Checks if the Sharetribe CLI has been installed correctly by displaying its version and available commands. This is a basic verification step. ```bash flex-cli ``` -------------------------------- ### Get Sharetribe Process List Help Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-sharetribe-cli.md Displays help information for the 'process list' command, including required parameters like MARKETPLACE_ID and optional parameters like --process. ```bash flex-cli help process list ``` -------------------------------- ### Get Sharetribe CLI Help Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-sharetribe-cli.md Displays a list of all available commands for the Sharetribe CLI. This is the primary command for discovering CLI functionality. ```bash flex-cli help ``` -------------------------------- ### Navigate to Cloned Directory Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-integration-api.md Changes the current directory to the cloned 'integration-api-examples' repository. ```bash cd integration-api-examples ``` -------------------------------- ### Get Started with Sharetribe Integration API Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/introduction-1.md This guide serves as the starting point for developing custom integrations utilizing the Sharetribe Integration API. It outlines the initial steps and concepts for building integrations. ```javascript // Example of making a request to the Sharetribe Integration API // const response = await fetch('https://api.sharetribe.com/v1/listings', { // method: 'GET', // headers: { // 'Authorization': 'Bearer YOUR_API_TOKEN' // } // }); // const data = await response.json(); ``` -------------------------------- ### Get Started with Sharetribe Integration API Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/introduction-1.md This guide serves as the starting point for developing custom integrations utilizing the Sharetribe Integration API. It outlines the initial steps and concepts for building integrations. ```javascript // Example of making a request to the Sharetribe Integration API // const response = await fetch('https://api.sharetribe.com/v1/listings', { // method: 'GET', // headers: { // 'Authorization': 'Bearer YOUR_API_TOKEN' // } // }); // const data = await response.json(); ``` -------------------------------- ### Install Sharetribe CLI with Yarn Modern Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-sharetribe-cli.md Installs the Sharetribe CLI using Yarn Modern's dlx command. This is an alternative installation method for users of Yarn Modern. ```bash yarn dlx add flex-cli ``` -------------------------------- ### Navigate to Cloned Directory Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-integration-api.md Changes the current directory to the cloned 'integration-api-examples' repository. ```bash cd integration-api-examples ``` -------------------------------- ### Install Sharetribe CLI with Yarn Modern Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-sharetribe-cli.md Installs the Sharetribe CLI using Yarn Modern's dlx command. This is an alternative installation method for users of Yarn Modern. ```bash yarn dlx add flex-cli ``` -------------------------------- ### Get Started with Sharetribe CLI Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/introduction-1.md This tutorial demonstrates how to begin using the Sharetribe Command Line Interface (CLI). It covers essential commands such as logging in with an API key and utilizing the help command. ```bash sharetribe login --api-key YOUR_API_KEY sharetribe help ``` -------------------------------- ### Get Started with Sharetribe CLI Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/introduction-1.md This tutorial demonstrates how to begin using the Sharetribe Command Line Interface (CLI). It covers essential commands such as logging in with an API key and utilizing the help command. ```bash sharetribe login --api-key YOUR_API_KEY sharetribe help ``` -------------------------------- ### Get Sharetribe Process List Help Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-sharetribe-cli.md Displays help information for the 'process list' command, including required parameters like MARKETPLACE_ID and optional parameters like --process. ```bash flex-cli help process list ``` -------------------------------- ### Clone Sharetribe Web Template Repository Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-web-template.md This command clones the Sharetribe Web Template repository from GitHub to your local machine using Git. ```bash git clone https://github.com/sharetribe/web-template.git ``` -------------------------------- ### Get Sharetribe CLI Help Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-sharetribe-cli.md Displays a list of all available commands for the Sharetribe CLI. This is the primary command for discovering CLI functionality. ```bash flex-cli help ``` -------------------------------- ### Clone Sharetribe Web Template Repository Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-web-template.md This command clones the Sharetribe Web Template repository from GitHub to your local machine using Git. ```bash git clone https://github.com/sharetribe/web-template.git ``` -------------------------------- ### Start Sharetribe Server with Yarn Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/how-to-deploy-template-to-production.md This snippet shows the command to start the Sharetribe server. It requires Yarn to be installed and configured for the project. ```bash yarn start ``` -------------------------------- ### Get Sharetribe CLI Subcommand Help Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-sharetribe-cli.md Retrieves detailed help information for a specific Sharetribe CLI subcommand, such as 'login'. This helps in understanding the usage and options of individual commands. ```bash flex-cli help login ``` -------------------------------- ### Get Sharetribe CLI Subcommand Help Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-sharetribe-cli.md Retrieves detailed help information for a specific Sharetribe CLI subcommand, such as 'login'. This helps in understanding the usage and options of individual commands. ```bash flex-cli help login ``` -------------------------------- ### Log In to Sharetribe CLI Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-sharetribe-cli.md Logs the user into the Sharetribe CLI using their API key. The command prompts for the API key and authenticates the user with the Sharetribe platform. ```bash flex-cli login ``` -------------------------------- ### Navigate to Sharetribe Web Template Directory Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-web-template.md This command changes the current directory to the cloned 'web-template' directory in your terminal. ```bash cd web-template/ ``` -------------------------------- ### Copy Environment Configuration Template Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-integration-api.md Copies the environment configuration template file to a new file named '.env'. This is a common practice for setting up application-specific configurations. ```bash cp env-template .env ``` -------------------------------- ### Navigate to Sharetribe Web Template Directory Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-web-template.md This command changes the current directory to the cloned 'web-template' directory in your terminal. ```bash cd web-template/ ``` -------------------------------- ### Log In to Sharetribe CLI Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-sharetribe-cli.md Logs the user into the Sharetribe CLI using their API key. The command prompts for the API key and authenticates the user with the Sharetribe platform. ```bash flex-cli login ``` -------------------------------- ### List Sharetribe Processes Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-sharetribe-cli.md Lists all transaction processes within a specified Sharetribe marketplace. Requires the MARKETPLACE_ID, which can be found in the Sharetribe Console. ```bash flex-cli process list -m my-marketplace-dev ``` -------------------------------- ### Copy Environment Configuration Template Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-integration-api.md Copies the environment configuration template file to a new file named '.env'. This is a common practice for setting up application-specific configurations. ```bash cp env-template .env ``` -------------------------------- ### Start Sharetribe Server with Yarn Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/how-to-deploy-template-to-production.md This snippet shows the command to initiate the Sharetribe server. It requires the Yarn package manager to be installed and configured for the project. ```bash yarn start ``` -------------------------------- ### List Sharetribe Processes Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-sharetribe-cli.md Lists all transaction processes within a specified Sharetribe marketplace. Requires the MARKETPLACE_ID, which can be found in the Sharetribe Console. ```bash flex-cli process list -m my-marketplace-dev ``` -------------------------------- ### Setup Stripe for Sharetribe Marketplace Payments Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/how-to.md This guide assists in setting up a Stripe account and integrating Stripe API keys into your Sharetribe Console and Web Template. This is essential for enabling payments and collecting commissions. -------------------------------- ### Run Analytics Script Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-integration-api.md Executes a JavaScript script named 'analytics.js' using Node.js to generate a marketplace analytics report. ```javascript node scripts/analytics.js ``` -------------------------------- ### Sharetribe CLI for Marketplace Configuration Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/introducing-sharetribe-developer-platform.md The Sharetribe CLI is a command-line tool used to modify advanced marketplace settings, such as transaction workflows and email templates. Refer to the 'Getting started with Sharetribe CLI' guide for detailed instructions. ```bash sharetribe cli --help # Example command to update transaction processes: sharetribe cli update transaction-processes --file processes.json # Example command to edit email templates: sharetribe cli edit email-templates --template welcome_email ``` -------------------------------- ### Sharetribe CLI for Marketplace Configuration Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/introducing-sharetribe-developer-platform.md The Sharetribe CLI is a command-line tool used to modify advanced marketplace settings, such as transaction workflows and email templates. Refer to the 'Getting started with Sharetribe CLI' guide for detailed instructions. ```bash sharetribe cli --help # Example command to update transaction processes: sharetribe cli update transaction-processes --file processes.json # Example command to edit email templates: sharetribe cli edit email-templates --template welcome_email ``` -------------------------------- ### Run Analytics Script Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-integration-api.md Executes a JavaScript script named 'analytics.js' using Node.js to generate a marketplace analytics report. ```javascript node scripts/analytics.js ``` -------------------------------- ### Example Process for SCA Support Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/enable-payment-intents.md Provides a link to example processes on GitHub that support SCA, which is crucial for implementing PaymentIntents. ```bash git clone https://github.com/sharetribe/example-processes.git ``` -------------------------------- ### Example Asset Structure Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/assets.md Illustrates a typical directory structure for Sharetribe assets, showing how configuration and translation files can be organized. ```shell ├── content │ └── translations.json └── design └── branding.json ``` -------------------------------- ### Example Asset Structure Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/assets.md Illustrates a typical directory structure for Sharetribe assets, showing how configuration and translation files can be organized. ```shell ├── content │ └── translations.json └── design └── branding.json ``` -------------------------------- ### Build Project Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/how-to-test-template.md Compiles and bundles the project for deployment. This command ensures that the build process completes successfully. ```bash yarn run build ``` -------------------------------- ### Setup OpenID Connect Proxy for GitHub in Sharetribe Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/how-to.md This guide demonstrates setting up an OpenID Connect (OIDC) proxy for Sharetribe Web Template, specifically for GitHub. This enables support for identity providers not natively supported by Sharetribe. -------------------------------- ### Build Sharetribe App for Production Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/how-to-deploy-template-to-production.md This command builds the Sharetribe Web Template for production, optimizing React for performance and creating a production-ready build folder. ```bash yarn build ``` -------------------------------- ### Build Sharetribe App for Production Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/how-to-deploy-template-to-production.md This command builds the Sharetribe Web Template for production, optimizing React for performance and creating a production-ready build folder. ```bash yarn build ``` -------------------------------- ### Using Stripe Publishable Key in Frontend Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-web-template.md The publishable key is used in the frontend application, such as the Sharetribe Web Template, to interact with Stripe.js for client-side operations like saving sensitive information and fraud detection. ```JavaScript const publishableKey = "pk_test"; // Example publishable key ``` -------------------------------- ### Using Stripe Publishable Key in Frontend Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-web-template.md The publishable key is used in the frontend application, such as the Sharetribe Web Template, to interact with Stripe.js for client-side operations like saving sensitive information and fraud detection. ```JavaScript const publishableKey = "pk_test"; // Example publishable key ``` -------------------------------- ### Example Process for SCA Support Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/enable-payment-intents.md Provides a link to example processes on GitHub that support SCA, which is crucial for implementing PaymentIntents. ```bash git clone https://github.com/sharetribe/example-processes.git ``` -------------------------------- ### Using Stripe Secret Key in Sharetribe Console Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/getting-started-with-web-template.md The secret key is required for server-side requests made by the Sharetribe API to process payments and manage transactions. It should be added to the Sharetribe Console for secure communication with Stripe. ```Text Add secret key (with prefix sk) to Console. ``` -------------------------------- ### Build Project Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/how-to-test-template.md Compiles and bundles the project for deployment. This command ensures that the build process completes successfully. ```bash yarn run build ``` -------------------------------- ### Download Flex Design Toolkit PPTX Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/your-user-journey-a-guide.md Provides a link to download the Sharetribe Flex Design Toolkit in PPTX format, which can be used to document user journeys for marketplace development. ```Markdown [download them here](/docs/flex-design-toolkit.pptx) ``` -------------------------------- ### Using Stripe Secret Key in Sharetribe Console Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/getting-started-with-web-template.md The secret key is required for server-side requests made by the Sharetribe API to process payments and manage transactions. It should be added to the Sharetribe Console for secure communication with Stripe. ```Text Add secret key (with prefix sk) to Console. ``` -------------------------------- ### Install Project Dependencies Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/how-to-customize-template.md This command installs all the necessary dependency libraries for the project using Yarn, ensuring all required packages are available for development. ```shell yarn install ``` -------------------------------- ### Filter Listings by Availability and Date Range Source: https://github.com/alejandrotrevi/sharetribe-developer-docs/blob/main/markdown-exports/how-the-listing-search-works.md This example shows how to filter Sharetribe listings based on availability within a specific date range. It uses the 'availability' parameter set to 'full' along with 'start' and 'end' date parameters. ```javascript sdk.listings.query({ availability: "full", start: "Sat Oct 22 2022 01:00:00 GMT+0100", end: "Sat Oct 29 2022 01:00:00 GMT+0100" }) ```