id
stringlengths
12
53
messages
listlengths
3
3
code_marketplace-financial-commission-cron_dd6891b8
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of marketplace-financial-commission-cron/manifest.json from the marketplace-financial-commission-cron VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"marketplace-financial-commission-cron\",\n \"vendor\": \"vtex\",\n \"version\": \"1.1.4\",\n \"title\": \"Financial commission for Marketplace Cron\",\n \"description\": \"\",\n \"categories\": [],\n \"dependencies\": {},\n \"builders\": {\n \"node\": \"6.x\",\n \"docs\": \"0.x\"\n },\n \"credentialType\": \"absolute\",\n \"billingOptions\": {\n \"termsURL\": \"https://compliance.vtex.com/gdpr/policies/vtex-privacy-policy\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true,\n \"type\": \"free\",\n \"availableCountries\": [\"*\"]\n },\n \"policies\": [\n {\n \"name\": \"colossus-fire-event\"\n },\n {\n \"name\": \"colossus-write-logs\"\n },\n {\n \"name\": \"ADMIN_DS\"\n },\n {\n \"name\": \"vbase-read-write\"\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"portal.vtexcommercestable.com.br\",\n \"path\": \"*\"\n }\n }\n ],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_product-summary-context_b9db7d50
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of product-summary-context/README.md from the product-summary-context VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Product Summary Context\n\n> Provides the product context to the product-summary child blocks.\n\n```" } ]
code_product-summary-context_36f1b077
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of product-summary-context/manifest.json from the product-summary-context VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"product-summary-context\",\n \"vendor\": \"vtex\",\n \"version\": \"0.13.0\",\n \"title\": \"VTEX Product Summary Context\",\n \"description\": \"\",\n \"settingsSchema\": {},\n \"dependencies\": {\n \"vtex.product-group-context\": \"0.x\"\n },\n \"builders\": {\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_product-identifier_cbcd0d79
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of product-identifier/manifest.json from the product-identifier VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"product-identifier\",\n \"version\": \"0.5.1\",\n \"title\": \"IO Base Component\",\n \"description\": \"IO Base component\",\n \"defaultLocale\": \"pt-BR\",\n \"builders\": {\n \"messages\": \"1.x\",\n \"store\": \"0.x\",\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"mustUpdateAt\": \"2019-04-02\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.product-context\": \"0.x\",\n \"vtex.product-summary-context\": \"0.x\",\n \"vtex.native-types\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_cookiebot_8bc5a5b3
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of cookiebot/package.json from the cookiebot VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"cookiebot\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.1.3\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.2.1\",\n \"eslint-config-vtex-react\": \"^6.2.1\",\n \"husky\": \"^4.2.0\",\n \"lint-staged\": \"^10.0.2\",\n \"prettier\": \"^1.19.1\",\n \"typescript\": \"^3.7.5\"\n }\n}\n\n```" } ]
code_cookiebot_974b7642
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of cookiebot/manifest.json from the cookiebot VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"cookiebot\",\n \"vendor\": \"vtex\",\n \"version\": \"2.0.8\",\n \"title\": \"Cookiebot\",\n \"description\": \"With a few clicks configure and preview your own cookie declaration and consent dialog.\",\n \"billingOptions\": {\n \"termsURL\": \"https://compliance.vtex.com/gdpr/policies/vtex-privacy-policy\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true,\n \"type\": \"free\",\n \"availableCountries\": [\n \"*\"\n ]\n },\n \"builders\": {\n \"pixel\": \"0.x\",\n \"docs\": \"0.x\",\n \"store\": \"0.x\",\n \"react\": \"3.x\",\n \"messages\": \"1.x\"\n },\n \"dependencies\": {\n \"vtex.store\": \"2.x\"\n },\n \"settingsSchema\": {\n \"title\": \"Cookiebot\",\n \"type\": \"object\",\n \"properties\": {\n \"cbid\": {\n \"title\": \"Domain Group ID\",\n \"type\": \"string\"\n },\n \"gcm\": {\n \"title\": \"Google Consent Mode\",\n \"type\": \"string\",\n \"default\": \"enabled\",\n \"enum\": [\n \"enabled\",\n \"disabled\"\n ],\n \"enumNames\": [\n \"enabled\",\n \"disabled\"\n ]\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_checkout-coupon_28380d28
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of checkout-coupon/package.json from the checkout-coupon VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"coupon\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.1.3\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.2.1\",\n \"eslint-config-vtex-react\": \"^6.2.1\",\n \"husky\": \"^4.2.0\",\n \"lint-staged\": \"^10.0.2\",\n \"prettier\": \"^1.19.1\",\n \"typescript\": \"^3.7.5\"\n }\n}\n\n```" } ]
code_checkout-coupon_af8982c8
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of checkout-coupon/manifest.json from the checkout-coupon VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"coupon\",\n \"version\": \"0.11.0\",\n \"title\": \"Coupon\",\n \"description\": \"Checkout coupon component\",\n \"defaultLocale\": \"pt-BR\",\n \"builders\": {\n \"messages\": \"1.x\",\n \"store\": \"0.x\",\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"mustUpdateAt\": \"2019-04-02\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.styleguide\": \"9.x\",\n \"vtex.order-coupon\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_ki-532487_55df73ce
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of ki-532487/index.js from the ki-532487 VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```javascript\n$(window).on(\"orderFormUpdated.vtex\", function (evt, orderForm) {\n setTimeout(() => {\n shippingValue(orderForm);\n }, 1000);\n});\n\nwindow.addEventListener(\"load\", function (event) {\n if ($(\".srp-toggle__delivery\").hasClass(\"blue\")) {\n setTimeout(() => {\n shippingValue(vtexjs.checkout.orderForm);\n }, 1000);\n }\n\n $(\".srp-toggle__delivery\").click(function () {\n setTimeout(() => {\n shippingValue(vtexjs.checkout.orderForm);\n }, 1000);\n });\n});\n\nfunction shippingValue(orderForm) {\n if (\n window.location.hash === \"#/cart\" &&\n $(\".srp-shipping-current-single__price\").length > -1 &&\n orderForm.shippingData.selectedAddresses != null &&\n orderForm.totalizers.length > 1 &&\n $(\".srp-toggle__delivery\").hasClass(\"blue\")\n ) {\n let price = orderForm.totalizers[1].value;\n const locale = orderForm.clientPreferencesData.locale;\n const currency = orderForm.storePreferencesData.currencyCode;\n const formattedPrice = formatValue(price, locale, currency);\n\n if (formattedPrice) {\n $(\"#shipping-preview-container .srp-shipping-current-single__price\").html(\n \"$ \" + formattedPrice\n );\n }\n }\n}\n\nfunction formatValue(value, locale, currency) {\n try {\n let shippingPrice = value.toString().slice(0, -2);\n shippingPrice = shippingPrice.toLocaleString(locale, {\n style: \"currency\",\n currency: currency,\n });\n return shippingPrice;\n } catch (error) {\n console.error(error);\n return value;\n }\n}\n\n```" } ]
code_ki-532487_9fd64347
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of ki-532487/README.md from the ki-532487 VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# KI-532487\n\nThis script is a workaround to KI https://vtexhelp.zendesk.com/agent/tickets/532487.\n\nYou need to add the script to the checkout at the `checkout6-custom.js`.\n\nThis script takes local store configuration from `orderForm.clientPreferencesData.locale` and `orderForm.storePreferencesData.currencyCode` and apply these setting to the shipping price presented in `../checkout/#/cart`.\n\n![screenshot](image.png)\n\nAdditionally, this script takes the last two decimals out from the shipping preview.\n\n```" } ]
code_sidecar-pixel_96bd720e
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of sidecar-pixel/manifest.json from the sidecar-pixel VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"sidecar-pixel\",\n \"vendor\": \"vtex\",\n \"version\": \"1.0.5\",\n \"title\": \"Sidecar\",\n \"description\": \"Sidecar first party integration.\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"billingOptions\": {\n \"termsURL\": \"\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true\n },\n \"builders\": {\n \"pixel\": \"0.x\",\n \"store\": \"0.x\",\n \"react\": \"3.x\"\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"settingsSchema\": {\n \"title\": \"Sidecar\",\n \"type\": \"object\",\n \"properties\": {\n \"domain\": {\n \"title\": \"Site Domain\",\n \"type\": \"string\"\n },\n \"id\": {\n \"title\": \"Site ID\",\n \"type\": \"string\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_example-payment-authorization-app_28de4885
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of example-payment-authorization-app/README.md from the example-payment-authorization-app VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Payment app\n\nThe *Payment* app adds a verification step to the checkout process, responsible for allowing or forbidding an order placement.\n\nTo implement this feature in your store, you'll need to develop your own *Payment app*, but don't worry! This repository provides the necessary structure for that, and the following step by step will guide you.\n\n## Step by step\n\n> ℹ️ Please, keep in mind that in this step by step you'll be using the [VTEX IO](https://developers.vtex.com/vtex-developer-docs/docs/what-is-vtex-io) development platform.\n\n### Step 1: Setting up the basic development environment\n\n1. Using the terminal, [install the VTEX IO CLI](https://vtex.io/docs/recipes/development/vtex-io-cli-installation-and-command-reference/) (Command Line Interface) known as **Toolbelt** .\n2. Using the terminal and the Toolbelt, log in to your VTEX account by running the following command:\n\n```shell\nvtex login {account}\n```\n\n> ⚠️ Remember to replace the values between the curly brackets according to your scenario\n\nOnce you run this command, a window will open in your browser asking for your credentials.\n\n3. Once you provide your credentials, run the following command in the terminal to create a [Development workspace](https://vtex.io/docs/recipes/development/creating-a-development-workspace/) and to start developing your *Payment* app.\n\n```shell\nvtex use {examplename}\n```\n\n> ⚠️ Replace `{examplename}` with a name of your choosing. This name will be given to the workspace in which you will develop.\n\n> ℹ️ If you're used to working with GitHub, think of workspaces as branches.\n\n### Step 2: Editing the Payment app\n\n> ⚠️ This app is deprecated, step 2 should only be taken in case of deploying the app in a production environment.\n\n1. Using your terminal, clone the *Payment* app boilerplate repository to your local files by running:\n\n```shell\ngit clone https://github.com/vtex-apps/example-payment-authorization-app\n```\n\n2. Then, using any code editor of your choice, open the boilerplate repository's directory.\n3. Open the `manifest.json` file and update its metadata, according to your scenario. It's essential that you update the following fields:\n\n- `vendor` - The app owner. That is, the VTEX account responsible for the app development, maintenance, and distribution.\n- `name` - The app name. It should concisely express the app's purpose. They must be comprised of lowercase letters separated by hyphens. Special characters, such as `*` and `@`, and numbers at the beginning of the name are not recommended.\n\n4. Open the `pages/pages.json` file and replace `{example-payment-auth-app}` with the app `name` set in step 3.\n5. Using your terminal, go to the app's directory and run the following command:\n\n```shell\nvtex link\n```\n\n> ℹ️ Once you [link the app](https://vtex.io/docs/recipes/development/linking-an-app/), your computer's local files will sync to our cloud development environment. This means that any change done locally in the code you are working on will be sent to the cloud and then reflected in the workspace in which you are working.\n\n### Step 3: Running the *Payment* app\n\n> ⚠️ When testing in a workspace do not change the app name and vendor. You must keep all params in the boilerplate unchanged\n\n1. Using your browser, go to `http://{workspace}--{account}.myvtex.com/checkout?workspace={workspace}`.\n\n> ⚠️ Remember to replace the values between the curly brackets according to your scenario\n\n2. Open the *browser Developer tools* and run the following command:\n\n```javascript\nwindow.transactionAppName = '{app-name}'\n```\n* When testing in your workspace:\n```\nwindow.transactionAppName = 'example-payment-auth-app'\n```\n\nNow, if you go through the *checkout process*, you'll notice an additional verification step (set in our *Payment* app) after the *Order confirmation*.\n\n3. Testing a Payment app flow:\n\nBy following the next steps, a Payment app will appear on the checkout screen allowing you to test the Payment app general flow.\n\n> ℹ️ Proceed with the following steps only with you want to test a Payment app flow, otherwise, skip to [Step 4: Deploying the Payment app](#step-4-deploying-the-payment-app).\n\n   3.1. Make sure you have the Test Connector with the VTEX Example Payment app configured in your account. If you do not have it yet, contact the [VTEX Support Team](https://help.vtex.com/en/tutorial/opening-tickets-to-vtex-support) to help you with the installation process.\n\n   3.2. Fill in the last name of the personal information with the word \"Application\".\n\n   3.3. Select the payment condition associated with the Test Connector and finish the purchase in order to test the flow.\n\n> ⚠️ It is not possible to test the specific flow of each Payment app built.\n\n\n### Step 4: Deploying the *Payment* app\n\n> ℹ️ Before deploying your app, we recommend that you perform tests and check if everything is as expected. For that, go to `http://{workspace}--{store}.myvtex.com`. Add products to your store's cart and go to the shopping cart page. Open your browser DevTools and run the following command to get the `orderFormId` value: `vtexjs.checkout.orderFormId`. Now, inject the `orderFormId` value in `vtexcommercestable`, using:\n`http://{workspace}--{account}.myvtex.com/checkout?workspace={workspace}&orderFormId={orderFormId}`.\n\nOnce you're happy with the changes, follow our documentation on [making your new app version publicly available](https://vtex.io/docs/recipes/development/making-your-new-app-version-publicly-available/) to run your app on master.\n\n## Modus Operandi\n\nAfter developing and implementing the *Payment* app, your store will profit from having an additional verification step in its checkout process.\n\nTo make the best use of the *Payment* app, this section discusses the following topics:\n\n- Understanding the checkout response.\n- Handling the order payload.\n- Injecting external scripts.\n\n### Understanding the checkout response\n\nAfter the order placement, there's a validation step to check whether the transaction is approved or not.\n\nIf the transaction is approved, the checkout UI redirects to the *Order Placed* page. Otherwise, it shows a warning pop-up.\n\nIn our *Payment* app, this validation is performed through the `transactionValidation.vtex` event, which, when triggered, sends the payment status to the checkout UI according to the following [method](https://github.com/vtex-apps/payment-authorization-app-example/blob/3e5742c87a2771998009cff4fecacb092bb3362b/react/index.js#L22):\n\n```javascript\nrespondTransaction = (status) => {\n window.$(window).trigger('transactionValidation.vtex', [status])\n}\n```\n\nNotice that the `respondTransaction` function receives the `status` boolean value, which resolves (`status == true`) or rejects (`status == false`) an order placement.\n\nHence, whenever the `transactionValidation.vtex` event occurs, the Checkout UI checks the payment status and is redirected according to the `status` value provided to the `respondTransaction` function\n\n### Handling the order payload\n\nThe `appPayload` is what the *Payment* app receives as `props` and it consists of a serialized JSON of the order payload.\n\nThus, to access this information, just run the following command:\n\n```javascript\nconst { appPayload } = this.props // This appPayload is a serialized JSON (as string).\n```\n\nThe expected response is a JSON object consisting of the data needed for the Payment app to allow or deny an order placement. Thus, depending on the payment processes implemented in your store, the `appPayload` fields may vary.\n\nTake the following example:\n\n```json\n{\n \"timeToCancel\": 300,\n \"transactionApproveLink\": \"https://...\"\n}\n```\n\n### Injecting external scripts\n\nTo run external scripts on your *Payment* app, you need to inject the following script on the head of the checkout `html`. \n\nTo do so, you have to do a DOM injection. For that, you should do:\n\n```javascript\nconst head = document.getElementsByTagName('head')[0]\n\nconst js = document.createElement('script')\njs.id = {{script-id}}\njs.src = {{script-src}}\njs.async = true;\njs.defer = true;\njs.onload = {{callback-onload}}\n\nhead.appendChild(js)\n```\n\nThere is an example for the script injection [here](https://github.com/vtex-apps/payment-authorization-app-example/blob/3e5742c87a2771998009cff4fecacb092bb3362b/react/index.js#L41)\n\n> ℹ️ Keep in mind that if the external `js` script handles DOM manipulation, then you should use React's [`ref`](https://reactjs.org/docs/refs-and-the-dom.html) to create a `div` container and hand it over to the library. There's also an [example](https://github.com/vtex-apps/payment-authorization-app-example/blob/3e5742c87a2771998009cff4fecacb092bb3362b/react/index.js#L11) for doing so in this repo.\n\n```" } ]
code_example-payment-authorization-app_a6fa4071
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of example-payment-authorization-app/package.json from the example-payment-authorization-app VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"version\": \"1.0.7\",\n \"devDependencies\": {\n \"@types/node\": \"12.6.2\",\n \"@vtex/prettier-config\": \"^1.0.0\",\n \"typescript\": \"3.9.7\"\n }\n}\n\n```" } ]
code_example-payment-authorization-app_caa504c4
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of example-payment-authorization-app/manifest.json from the example-payment-authorization-app VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"example-payment-auth-app\",\n \"vendor\": \"example-vendor\",\n \"version\": \"1.1.0\",\n \"title\": \"Example Payment Authentication App\",\n \"description\": \"Example Payment Authentication App\",\n \"defaultLocale\": \"en\",\n \"mustUpdateAt\": \"2019-01-08\",\n \"dependencies\": {},\n \"builders\": {\n \"react\": \"2.x\",\n \"pages\": \"0.x\",\n \"messages\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"scripts\": {\n \"postreleasy\": \"vtex publish --public\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_device-detector_c93687db
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of device-detector/README.md from the device-detector VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Device Detector\n\nUse this app's HOC or hook to find out current device's viewport size.\n\n### Usage\n\n#### useDevice\n\nReturns an object with the format of `DeviceInfo` defined as:\n```js\ninterface DeviceInfo {\n device: Device\n isMobile: boolean\n}\n\nenum Device {\n phone = 'phone',\n tablet = 'tablet',\n desktop = 'desktop',\n}\n```\n\n```js\nimport { useDevice } from 'vtex.device-detector'\nconst MyComponent = props => {\n const { isMobile } = useDevice()\n if (isMobile) { \n // is phone or tablet!\n }\n return ...\n}\n```\n\nor\n\n```js\nimport { useDevice } from 'vtex.device-detector'\nconst MyComponent = props => {\n const { device } = useDevice()\n if (device === 'tablet') { \n //is tablet!\n }\n return ...\n}\n```\n\n#### withDevice\n\nIt is a HOC, it injects two props (`isMobile` and `device`) into your component's props:\n\n```js\ntype WithDeviceProps = Props & {\n isMobile: boolean\n device: Device\n}\nenum Device {\n phone = 'phone',\n tablet = 'tablet',\n desktop = 'desktop',\n}\n```\n\n```js\nimport { withDevice } from 'vtex.device-detector'\nconst MyComponent = props => {\n if (props.isMobile) { \n // is phone or tablet!\n }\n return ...\n}\n\nexport default withDevice(MyComponent)\n```\n\nor\n\n```js\nimport { useDevice } from 'vtex.device-detector'\nconst MyComponent = props => {\n if (props.device === 'tablet') { \n //is tablet!\n }\n return ...\n}\n\nexport default withDevice(MyComponent)\n```\n\n```" } ]
code_device-detector_0ee56786
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of device-detector/package.json from the device-detector VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"device-detector\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.1.3\",\n \"eslint\": \"^7.15.0\",\n \"eslint-config-vtex\": \"^12.2.1\",\n \"eslint-config-vtex-react\": \"^6.9.1\",\n \"husky\": \"^4.2.0\",\n \"lint-staged\": \"^10.0.2\",\n \"prettier\": \"^2.2.1\",\n \"typescript\": \"^3.7.5\"\n }\n}\n\n```" } ]
code_device-detector_81147095
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of device-detector/manifest.json from the device-detector VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"device-detector\",\n \"version\": \"0.2.6\",\n \"title\": \"Device Detector\",\n \"description\": \"Consistent device detection across SSR and CSR\",\n \"defaultLocale\": \"pt-BR\",\n \"builders\": {\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"mustUpdateAt\": \"2019-04-02\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_partytown_6e511e9c
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of partytown/package.json from the partytown VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"partytown\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\",\n \"build\": \"partytown copylib public/~partytown && node utils/build.js\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@builder.io/partytown\": \"^0.7.4\",\n \"@vtex/prettier-config\": \"^0.1.4\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.3.2\",\n \"eslint-config-vtex-react\": \"^6.3.2\",\n \"html-minifier\": \"^4.0.0\",\n \"husky\": \"^4.2.3\",\n \"lint-staged\": \"^10.1.1\",\n \"mustache\": \"^4.2.0\",\n \"prettier\": \"^2.0.2\",\n \"typescript\": \"^3.8.3\"\n },\n \"dependencies\": {}\n}\n\n```" } ]
code_partytown_22b78613
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of partytown/manifest.json from the partytown VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"partytown\",\n \"vendor\": \"vtex\",\n \"version\": \"1.0.1-beta.0\",\n \"title\": \"Partytown\",\n \"description\": \"Partytown\",\n \"billingOptions\": {\n \"termsURL\": \"https://compliance.vtex.com/gdpr/policies/vtex-privacy-policy\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true,\n \"type\": \"free\",\n \"availableCountries\": [\"*\"]\n },\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"pixel\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"settingsSchema\": {\n \"title\": \"Partytown\",\n \"type\": \"object\",\n \"properties\": {\n \"forward\": {\n \"title\": \"Forward\",\n \"description\": \"Forwarding events and triggers separated by `,`.\",\n \"type\": \"string\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_css-handles_cf1e18bb
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of css-handles/package.json from the css-handles VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"css-handles\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.3.3\",\n \"eslint\": \"^7.13.0\",\n \"eslint-config-vtex\": \"^12.8.8\",\n \"eslint-config-vtex-react\": \"^6.7.10\",\n \"husky\": \"^4.3.0\",\n \"lint-staged\": \"^10.5.1\",\n \"prettier\": \"^2.1.2\",\n \"typescript\": \"^3.8.3\"\n },\n \"version\": \"0.0.0\"\n}\n\n```" } ]
code_css-handles_fb731c26
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of css-handles/manifest.json from the css-handles VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"css-handles\",\n \"version\": \"1.0.1\",\n \"title\": \"CSS Handles\",\n \"description\": \"Utility for creating CSS Handles on store components\",\n \"builders\": {\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {},\n \"registries\": [\n \"smartcheckout\"\n ],\n \"policies\": [],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_minicart_b5ef0e9e
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of minicart/package.json from the minicart VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"minicart\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.1.4\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.3.2\",\n \"eslint-config-vtex-react\": \"^6.3.2\",\n \"husky\": \"^4.2.3\",\n \"lint-staged\": \"^10.1.1\",\n \"prettier\": \"^2.0.2\",\n \"typescript\": \"^3.8.3\"\n }\n}\n```" } ]
code_minicart_c4dbfc63
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of minicart/manifest.json from the minicart VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"minicart\",\n \"title\": \"Mini Cart\",\n \"version\": \"2.68.0\",\n \"builders\": {\n \"messages\": \"1.x\",\n \"store\": \"0.x\",\n \"react\": \"3.x\",\n \"docs\": \"0.x\",\n \"styles\": \"2.x\"\n },\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.product-summary\": \"2.x\",\n \"vtex.store-resources\": \"0.x\",\n \"vtex.store-components\": \"3.x\",\n \"vtex.styleguide\": \"9.x\",\n \"vtex.store-icons\": \"0.x\",\n \"vtex.pixel-manager\": \"1.x\",\n \"vtex.react-portal\": \"0.x\",\n \"vtex.store-graphql\": \"2.x\",\n \"vtex.sandbox\": \"0.x\",\n \"vtex.css-handles\": \"1.x\",\n \"vtex.order-manager\": \"0.x\",\n \"vtex.order-items\": \"0.x\",\n \"vtex.product-list\": \"0.x\",\n \"vtex.device-detector\": \"0.x\",\n \"vtex.store-drawer\": \"0.x\",\n \"vtex.checkout-summary\": \"0.x\",\n \"vtex.checkout-resources\": \"0.x\",\n \"vtex.flex-layout\": \"0.x\",\n \"vtex.rich-text\": \"0.x\",\n \"vtex.responsive-values\": \"0.x\",\n \"vtex.checkout-graphql\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_instore-stone-fields_1ff79640
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of instore-stone-fields/manifest.json from the instore-stone-fields VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"instore-stone-fields\",\n \"version\": \"0.1.5\",\n \"title\": \"Instore extra customer fields\",\n \"description\": \"\",\n \"defaultLocale\": \"pt-BR\",\n \"builders\": {\n \"pages\": \"0.x\",\n \"react\": \"2.x\",\n \"messages\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.instore-form-fields\": \"0.x\"\n },\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n }\n}\n```" } ]
code_external-prices-node-template_f8d19d1f
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of external-prices-node-template/package.json from the external-prices-node-template VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"external-prices-app\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^12.12.21\",\n \"@vtex/prettier-config\": \"^0.3.6\",\n \"@vtex/tsconfig\": \"^0.6.0\",\n \"eslint\": \"^7.16.0\",\n \"eslint-config-vtex\": \"^12.9.3\",\n \"husky\": \"^4.3.6\",\n \"lint-staged\": \"^10.5.3\",\n \"prettier\": \"^2.2.1\",\n \"typescript\": \"^3.7.5\"\n },\n \"dependencies\": {\n \"@vtex/api\": \"^6.45.19\"\n }\n}\n\n```" } ]
code_external-prices-node-template_4d2eb15e
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of external-prices-node-template/manifest.json from the external-prices-node-template VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"external-prices-node\",\n \"vendor\": \"vtex\",\n \"version\": \"0.3.2\",\n \"title\": \"External Prices Node App\",\n \"description\": \"A reference app for consulting external prices.\",\n \"categories\": [],\n \"dependencies\": {},\n \"builders\": {\n \"node\": \"6.x\",\n \"docs\": \"0.x\"\n },\n \"scripts\": {\n \"prereleasy\": \"bash lint.sh\"\n },\n \"credentialType\": \"absolute\",\n \"policies\": [\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"YOUR_SERVICE_DOMAIN\",\n \"path\": \"*\"\n }\n },\n {\n \"name\": \"colossus-fire-event\"\n },\n {\n \"name\": \"colossus-write-logs\"\n }\n ],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_store-sitemap_6a2c3063
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of store-sitemap/policies.json from the store-sitemap VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n[\n {\n \"name\": \"resolve-graphql\",\n \"description\": \"Allows access to resolve a graphql request\",\n \"statements\": [\n {\n \"actions\": [\"post\", \"get\"],\n \"effect\": \"allow\",\n \"resources\": [\n \"vrn:vtex.store-sitemap:{{region}}:{{account}}:{{workspace}}:/_v/graphql\"\n ]\n }\n ]\n }\n]\n\n```" } ]
code_store-sitemap_028a8167
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of store-sitemap/package.json from the store-sitemap VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"store-sitemap\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,js,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^12.12.21\",\n \"@vtex/prettier-config\": \"^0.1.3\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.2.1\",\n \"husky\": \"^4.2.0\",\n \"lint-staged\": \"^10.0.2\",\n \"prettier\": \"^1.19.1\",\n \"typescript\": \"^3.7.5\"\n },\n \"dependencies\": {\n \"@types/route-parser\": \"^0.1.3\",\n \"route-parser\": \"^0.0.5\"\n }\n}\n\n```" } ]
code_store-sitemap_f999ad18
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of store-sitemap/manifest.json from the store-sitemap VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\",\n \"name\": \"store-sitemap\",\n \"vendor\": \"vtex\",\n \"version\": \"2.18.3\",\n \"title\": \"Sitemap\",\n \"description\": \"Sitemap for vtex.store\",\n \"mustUpdateAt\": \"2019-08-01\",\n \"builders\": {\n \"node\": \"6.x\",\n \"graphql\": \"1.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.messages\": \"1.x\",\n \"gocommerce.sitemap-app\": \"1.x\",\n \"vtex.catalog-api-proxy\": \"0.x\",\n \"vtex.rewriter\": \"1.x\",\n \"vtex.catalog-graphql\": \"1.x\",\n \"vtex.routes-bootstrap\": \"0.x\",\n \"vtex.graphql-server\": \"1.x\"\n },\n \"policies\": [\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"portal.vtexcommercestable.com.br\",\n \"path\": \"/api/tenant/tenants\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"{{account}}.vtexcommercestable.com.br\",\n \"path\": \"/api/catalog_system/*\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"{{account}}.vtexcommercestable.com.br\",\n \"path\": \"/sitemap.xml\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"{{account}}.vtexcommercestable.com.br\",\n \"path\": \"/sitemap/*\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"janus-edge.vtex.com.br\",\n \"path\": \"/robots.txt\"\n }\n },\n {\n \"name\": \"vtex.catalog-graphql:resolve-graphql\"\n },\n {\n \"name\": \"colossus-fire-event\"\n },\n {\n \"name\": \"colossus-write-logs\"\n },\n {\n \"name\": \"read-workspace-apps\"\n },\n {\n \"name\": \"read-write-user-routes\"\n },\n {\n \"name\": \"vbase-read-write\"\n },\n {\n \"name\": \"read-public-registry-assets\"\n },\n {\n \"name\": \"read-private-registry-assets\"\n },\n {\n \"name\": \"gocommerce.sitemap-app:sitemap-read\"\n },\n {\n \"name\": \"vtex.catalog-api-proxy:catalog-proxy\"\n },\n {\n \"name\": \"vtex.rewriter:resolve-graphql\"\n },\n {\n \"name\": \"vtex.messages:graphql-save-translation-messages\"\n },\n {\n \"name\": \"vtex.graphql-server:resolve-graphql\"\n },\n {\n \"name\": \"sphinx-is-admin\"\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"vtexid.vtex.com.br\",\n \"path\": \"/api/vtexid/pub/authenticated/user\"\n }\n }\n ],\n \"credentialType\": \"absolute\",\n \"scripts\": {\n \"prereleasy\": \"bash lint.sh\"\n },\n \"settingsSchema\": {\n \"title\": \"VTEX Store sitemap\",\n \"type\": \"object\",\n \"properties\": {\n \"enableProductRoutes\": {\n \"title\": \"Enable product routes source\",\n \"description\": \"This will enable the product routes source, generating product routes for the final sitemap.\",\n \"type\": \"boolean\",\n \"default\": true\n },\n \"enableNavigationRoutes\": {\n \"title\": \"Enable navigation routes source\",\n \"description\": \"This will enable the navigation routes source, generating navigation routes for the final sitemap.\",\n \"type\": \"boolean\",\n \"default\": true\n },\n \"enableAppsRoutes\": {\n \"title\": \"Enable apps routes source\",\n \"description\": \"This will enable the app routes source, adding to the final sitemap routes defined and exported by the routes.json files from apps built by the store@0.x builder.\",\n \"type\": \"boolean\",\n \"default\": true\n },\n \"disableRoutesTerm\": {\n \"title\": \"Disable routes from userRoutes with the following string\",\n \"description\": \"Routes that include the string below will be excluded from the sitemap. Useful for selecting which pages will be in that folder.\",\n \"default\": \"\",\n \"type\": \"string\"\n },\n \"ignoreBindings\": {\n \"title\": \"Ignore bindings\",\n \"description\": \"Generate a single sitemap even if store has multiple bindings - for example if bindings are in the process of being set up\",\n \"type\": \"boolean\",\n \"default\": false\n }\n }\n }\n}\n\n```" } ]
code_events-example_f932089e
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of events-example/dangerfile.js from the events-example VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```javascript\n// dangerfile.js\nconst { verify } = require('@vtex/danger')\n\nconst config = {\n // Set to true to enforce keepachangelog rules.\n keepachangelog: {\n changeVersion: false,\n },\n rules: {\n description: ['fail', { minLength: 20 }],\n assignee: 'fail',\n reviewers: 'fail',\n pr_size: ['warn', { additionLimit: 800, deletionLimit: -1 }],\n lock_file: 'warn',\n no_ignored_test: ['fail', { pattern: /test|spec/i }],\n no_debugger: ['fail', { pattern: /\\.[tj]sx?$/i }],\n enforce_graphql_provider: 'off',\n },\n}\n\nverify(config)\n\n```" } ]
code_events-example_b92d28bf
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of events-example/package.json from the events-example VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"CHANGE_ME\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^12.12.21\",\n \"@vtex/prettier-config\": \"^0.3.1\",\n \"@vtex/danger\": \"^0.2.7\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.7.0\",\n \"husky\": \"^4.2.0\",\n \"lint-staged\": \"^10.0.2\",\n \"prettier\": \"^2.0.5\",\n \"typescript\": \"^3.9.6\"\n }\n}\n\n```" } ]
code_events-example_b837eb42
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of events-example/manifest.json from the events-example VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"events-example\",\n \"vendor\": \"vtex\",\n \"version\": \"0.0.1\",\n \"title\": \"Events Example\",\n \"description\": \"Reference app for VTEX IO Services\",\n \"dependencies\": {},\n \"builders\": {\n \"node\": \"6.x\",\n \"docs\": \"0.x\"\n },\n \"scripts\": {\n \"prereleasy\": \"bash lint.sh\"\n },\n \"credentialType\": \"absolute\",\n \"policies\": [\n {\n \"name\": \"colossus-fire-event\"\n },\n {\n \"name\": \"colossus-write-logs\"\n },\n {\n \"name\": \"vbase-read-write\"\n }\n ],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_product-bookmark-interfaces_a3ebbace
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of product-bookmark-interfaces/manifest.json from the product-bookmark-interfaces VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"product-bookmark-interfaces\",\n \"version\": \"1.0.1\",\n \"title\": \"Product Bookmark Interfaces\",\n \"description\": \"Interfaces for a wishlist or list app\",\n \"builders\": {\n \"store\": \"0.x\",\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {},\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_native-types_2f721ad2
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of native-types/package.json from the native-types VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"native-types\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,js,json}\\\"\",\n \"test\": \"cd ./react && yarn test\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.3.3\",\n \"eslint\": \"^7.13.0\",\n \"eslint-config-vtex\": \"^12.8.8\",\n \"eslint-config-vtex-react\": \"^6.7.10\",\n \"husky\": \"^4.3.0\",\n \"lint-staged\": \"^10.5.1\",\n \"prettier\": \"^2.1.2\",\n \"typescript\": \"^4.0.5\"\n }\n}\n\n```" } ]
code_native-types_09021834
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of native-types/manifest.json from the native-types VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"native-types\",\n \"version\": \"0.10.1\",\n \"builders\": {\n \"messages\": \"1.x\",\n \"pages\": \"1.x\",\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.css-handles\": \"0.x\"\n },\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"title\": \"Native Types\",\n \"description\": \"Native types\",\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_splunk-log-forwarder_828a017c
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of splunk-log-forwarder/README.md from the splunk-log-forwarder VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Logs Stream Client Example\n\nBasic implementation that consumed VTEX IO Logs Stream to foward for Splunk.\n\n## Architecture Overview\n\n![Overview](https://github.com/vtex-apps/splunk-log-forwarder/blob/main/docs/architecture-overview.png?raw=true \"High level architecture\")\n\nVTEX IO Logs API is implemented using [Server-sent events](https://en.wikipedia.org/wiki/Server-sent_events). It enables servers to stream messages to clients through HTTP.\n\nThis is a simple client implementation that receives VTEX Logs in a stream through server-sent events, bulk them, to send to a Splunk HTTP Event Collector.\n\n## Implementation details\n\nThis example is implemented using [Koa Web Framework](https://koajs.com/).\n\nThere are 3 Koa middlewares registered at Koa server, those middleware define the basic pipeline for the application `[setup, fetchAppToken, logsForwarder]`. \n\n1. `setup` Reads required envvars to create a context that will be used by the application. Env vars could be defined by creating a `.env` file at the src directory. \n \n -- Example:\n ```.env\n VTEX_ACCOUNT=<account>\n VTEX_WORKSPACE=<workspace>\n VTEX_APP_KEY=<app-key>\n VTEX_APP_TOKEN=<app-token>\n SPLUNK_HOST=<splunk-http-event-host>\n SPLUNK_PORT=<splunk-http-event-port>\n SPLUNK_TOKEN=<splunk-token>\n ```\n2. `fetchAppToken` Makes the authentication request and adds the auth token to the context.\n\n3. `logsForwarder` Reads the logs from VTEX IO Logs Stream and forwards them to Splunk\n\n#### Usage: \n\n1. `yarn watch` This will start the server at localhost\n2. `curl -X POST http://localhost:8080/forwarder/start`. This will start the pipeline described above.\n\n## VTEX Logs Stream API\n\n### Authorization\n\nAuthorization is needed, for a client to call Logs Stream API\n\nFirst thing required is to have Application Credentials that allow logs to be consumed from stream.\n\nTo make this, go to your VTEX Account admin, at the Roles panel and create a new Role for Logs consumption. This role should have `Application Logs Stream` as product added, with `Read logs stream` permission.\n\n![new role panel](https://github.com/vtex-apps/splunk-log-forwarder/blob/main/docs/VTEX%20new%20roles%20panel.png?raw=true \"New role panel\")\n\nWith the new role created, an application key could be created using the given role as following.\n\n![add app key](https://github.com/vtex-apps/splunk-log-forwarder/blob/main/docs/VTEX%20add%20aplication%20key%20panel.png?raw=true \"Add Applicaton Key\")\n\nApplication Key and Token generated previously, can now be used to authenticate your client, so requests to the Logs Stream API is authorized.\n\nTo authenticate your client the following API could be used.\n\n```\ncurl --location --request POST 'https://api.vtexcommercestable.com.br/api/vtexid/apptoken/login?an={{account}}' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n \"appkey\": \"<appKey>\",\n \"apptoken\": \"<appToken>\"\n}'\n```\n\nThis call will return a similar payload. Where the token value is the one needed to for this API to work.\n\n```\n{\n \"authStatus\": \"Success\",\n \"token\": <token>\n \"expires\": 1666838733\n}\n```\n\n### Requests to the Logs stream\n\n\nWith the proper Auth token set `TOKEN=<token>`. API calls could be made as following.\n\n```\ncurl http://infra.io.vtex.com/skidder/v1/{{account}}/{{workspace}}/logs/stream -H \"Authorization: $TOKEN\" -H 'User-Agent: test' -H 'Accept: text/event-stream'\n```\n\nReturing data example\n\n```\nevent:message\ndata:{\"level\":\"warn\",\"app\":\"<app-vendor>.<app-name>@<app-version>\",\"account\":\"<account>\",\"workspace\":\"<workspace>\",\"production\":true,\"data\":{\"signal\":\"SIGTERM\"},\"operationId\":\"\",\"requestId\":\"\"}\n```\n\nServer will keep sending those events to the client as long as logs are available at the stream.\nIf connection is aborted by the client, the server will stop sending the data. \n\nClients could resume the stream at the point they stopped consuming. The server keep this state reading the `User-Agent` header. User-Agent could be changed to get all events from the begin.\n\nLogs have different log levels, that could be defined by the application developer, as described [here](https://developers.vtex.com/vtex-developer-docs/docs/vtex-io-documentation-managing-application-logs#implementing-the-vtex-io-logging-service).\n\n## Scripts\n\nFollowing scripts are available to be used with [yarn](https://classic.yarnpkg.com/en/docs/install/):\n\n- `yarn build` - Builds the service generating final files in the `dist` folder. This will use `tsc` to convert the `TypeScript` files to pure `JavaScript`\n- `yarn start` - Builds the service and start it on `localhost` in `prodution` mode\n- `yarn dev` - Builds the service and start it service on `localhost` in `development` mode\n- `yarn watch` - Starts the service on `localhost` with [nodemon](https://github.com/remy/nodemon) and [ts-node](https://typestrong.org/ts-node/), and automatically restarts the server when `src` files are changed\n- `yarn debug` - Starts the service on `localhost` ready for debugging the execution\n- `yarn lint` - Lints and formats the code\n\n```" } ]
code_splunk-log-forwarder_1125d170
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of splunk-log-forwarder/package.json from the splunk-log-forwarder VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"vtex-app-node-server-template\",\n \"version\": \"0.0.17\",\n \"scripts\": {\n \"start\": \"tsc && NODE_ENV=production node dist/index.js\",\n \"build\": \"tsc\",\n \"dev\": \"tsc && NODE_ENV=development nodemon dist/index.js\",\n \"watch\": \"NODE_ENV=development nodemon --watch 'src/**/*' -e ts,tsx --exec 'ts-node' src/index.ts\",\n \"debug\": \"tsc && NODE_ENV=development nodemon --inspect dist/index.js\",\n \"lint\": \"eslint --fix src && prettier --write 'src/**/*.ts'\"\n },\n \"dependencies\": {\n \"eventsource\": \"^2.0.2\",\n \"dotenv\": \"^14.3.2\",\n \"axios\": \"^1.1.3\",\n \"koa\": \"^2.13.4\",\n \"koa-bodyparser\": \"^4.3.0\",\n \"koa-router\": \"^12.0.0\"\n },\n \"devDependencies\": {\n \"@types/koa\": \"^2.13.5\",\n \"@types/koa-bodyparser\": \"^4.3.8\",\n \"@types/koa-router\": \"^7.4.4\",\n \"@types/node\": \"^16.4.13\",\n \"@types/eventsource\":\"^1.1.10\",\n \"@vtex/prettier-config\": \"^0.3.6\",\n \"eslint\": \"7.32.0\",\n \"eslint-config-vtex\": \"^14.1.0\",\n \"lint-staged\": \">=10\",\n \"nodemon\": \"^2.0.12\",\n \"prettier\": \"^2.3.2\",\n \"ts-node\": \"^10.9.1\",\n \"typescript\": \"^4.8.4\"\n },\n \"prettier\": \"@vtex/prettier-config\"\n}\n\n```" } ]
code_reskyt-pixel_76d2ddda
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of reskyt-pixel/package.json from the reskyt-pixel VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"reskyt-pixel\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.3.6\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.9.4\",\n \"eslint-config-vtex-react\": \"^6.9.4\",\n \"husky\": \"^4.2.3\",\n \"lint-staged\": \"^10.1.1\",\n \"prettier\": \"^2.2.1\",\n \"typescript\": \"^3.8.3\"\n },\n \"dependencies\": {}\n}\n\n```" } ]
code_reskyt-pixel_3ab38da7
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of reskyt-pixel/manifest.json from the reskyt-pixel VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"reskyt-pixel\",\n \"vendor\": \"vtex\",\n \"version\": \"0.0.2\",\n \"title\": \"Reskyt Pixel\",\n \"description\": \"Reskyt Pixel creates a banner with a link to the app store\",\n \"billingOptions\": {\n \"termsURL\": \"https://compliance.vtex.com/gdpr/policies/vtex-privacy-policy\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true,\n \"type\": \"free\",\n \"availableCountries\": [\n \"*\"\n ]\n },\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"pixel\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"settingsSchema\": {\n \"title\": \"Reskyt Pixel\",\n \"bindingBounded\": true,\n \"type\": \"object\",\n \"properties\": {\n \"htmlTitle\": {\n \"title\": \"HTML title name\",\n \"description\": \"The HTML title for the pixel\",\n \"type\": \"string\"\n },\n \"appName\": {\n \"title\": \"App Name\",\n \"description\": \"Name of the app that the user will download\",\n \"type\": \"string\"\n },\n \"fabName\": {\n \"title\": \"Developer name\",\n \"description\": \"Name of the developer of the app\",\n \"type\": \"string\"\n },\n \"downloadLink\": {\n \"title\": \"App download link\",\n \"description\": \"Link to store where the app is hosted\",\n \"type\": \"string\"\n },\n \"appImage\": {\n \"title\": \"App image\",\n \"description\": \"Image of the app that will be shown in the banner\",\n \"type\": \"string\"\n },\n \"appImageAlt\": {\n \"title\": \"Image alt\",\n \"description\": \"Image alternative text, for accesibility purposes\",\n \"type\": \"string\"\n },\n \"storePrefix\": {\n \"title\": \"Store name prefix\",\n \"description\": \"A prefix to the store where the application is hosted. i.e 'Free on'\",\n \"type\": \"string\"\n },\n \"downloadCTA\": {\n \"title\": \"Download CTA\",\n \"description\": \"Download link call to action\",\n \"type\": \"string\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_rfcs_f896b3ea
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of rfcs/README.md from the rfcs VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Store Framework RFCs\n\nMany changes, including bug fixes and documentation improvements can be implemented and reviewed via the normal GitHub pull request workflow.\n\nSome changes though are \"substantial\", and we ask that these be put through a bit of a design process and produce a consensus among the Store Framework core team.\n\nThe \"RFC\" (request for comments) process is intended to provide a consistent and controlled path for new features to enter the project.\n\n[Active RFC List](https://github.com/vtex-apps/rfcs/pulls)\n\nStore Framework is still **actively developing** this process, and it will still change as more features are implemented and the community settles on specific approaches to feature development.\n\n## When to follow this process\n\nYou should consider using this process if you intend to make \"substantial\" changes to Store Framework or its documentation. Some examples that would benefit from an RFC are:\n\n- A new feature that creates new API surface area, and would require a feature flag if introduced.\n- The removal of features that already shipped as part of the release channel.\n- The introduction of new idiomatic usage or conventions, even if they do not include code changes to Store Framework itself.\n\nThe RFC process is a great opportunity to get more eyeballs on your proposal before it becomes a part of the Store Framework. Quite often, even proposals that seem \"obvious\" can be significantly improved once a wider group of interested people have a chance to weigh in.\n\nThe RFC process can also be helpful to encourage discussions about a proposed feature as it is being designed, and incorporate important constraints into the design while it's easier to change, before the design has been fully implemented.\n\nSome changes do not require an RFC:\n\n- Rephrasing, reorganizing or refactoring\n- Addition or removal of warnings\n- Additions that strictly improve objective, numerical quality criteria (speedup, better browser support)\n- Additions only likely to be _noticed by_ other implementors-of-Store Framework, invisible to users-of-Store Framework.\n\n## What the process is\n\nIn short, to get a major feature added to Store Framework, one usually first gets the RFC merged into the RFC repo as a markdown file. At that point the RFC is 'active' and may be implemented with the goal of eventual inclusion into Store Framework.\n\n* Fork the RFC repo http://github.com/vtex-apps/rfcs\n* Copy `0000-template.md` to `text/0000-my-feature.md` (where 'my-feature' is descriptive. Don't assign an RFC number yet).\n* Fill in the RFC. Put care into the details: **RFCs that do not present convincing motivation, demonstrate understanding of the impact of the design, or are disingenuous about the drawbacks or alternatives tend to be poorly-received**.\n* Submit a pull request. As a pull request the RFC will receive design feedback from the larger community, and the author should be prepared to revise it in response.\n* Build consensus and integrate feedback. RFCs that have broad support are much more likely to make progress than those that don't receive any comments.\n* Eventually, the team will decide whether the RFC is a candidate for inclusion in Store Framework.\n* RFCs that are candidates for inclusion in Store Framework will enter a \"final comment period\" lasting 3 calendar days. The beginning of this period will be signaled with a comment and tag on the RFCs pull request.\n* An RFC can be modified based upon feedback from the team and community. Significant modifications may trigger a new final comment period.\n* An RFC may be rejected by the team after public discussion has settled and comments have been made summarizing the rationale for rejection. A member of the team should then close the RFCs associated pull request.\n* An RFC may be accepted at the close of its final comment period. A team member will merge the RFCs associated pull request, at which point the RFC will become 'active'.\n\n## The RFC life-cycle\n\nOnce an RFC becomes active, then authors may implement it and submit the feature as a pull request to the respective Store Framework repo. Becoming 'active' is not a rubber stamp, and in particular still does not mean the feature will ultimately be merged; it does mean that the core team has agreed to it in principle and are amenable to merging it.\n\nFurthermore, the fact that a given RFC has been accepted and is 'active' implies nothing about what priority is assigned to its implementation, nor whether anybody is currently working on it.\n\nModifications to active RFCs can be done in followup PRs. We strive to write each RFC in a manner that it will reflect the final design of the feature; but the nature of the process means that we cannot expect every merged RFC to actually reflect what the end result will be at the time of the next major release; therefore we try to keep each RFC document somewhat in sync with the language feature as planned, tracking such changes via followup pull requests to the document.\n\n## Implementing an RFC\n\nThe author of an RFC is not obligated to implement it. Of course, the RFC author (like any other developer) is welcome to post an implementation for review after the RFC has been accepted.\n\nIf you are interested in working on the implementation for an 'active 'RFC, but cannot determine if someone else is already working on it, feel free to ask (e.g. by leaving a comment on the associated issue).\n\n## Reviewing RFCs\n\nEach week the team will attempt to review some set of open RFC pull requests.\n\nWe try to make sure that any RFC that we accept is accepted at the weekly team meeting. Every accepted feature should have a core team champion, who will represent the feature and its progress.\n\n**Store Framework's RFC process owes its inspiration to the [React RFC process], [Yarn RFC process], [Rust RFC process], and [Ember RFC process]**\n\n[React RFC process]: https://github.com/reactjs/rfcs\n[Yarn RFC process]: https://github.com/yarnpkg/rfcs\n[Rust RFC process]: https://github.com/rust-lang/rfcs\n[Ember RFC process]: https://github.com/emberjs/rfcs\n\n```" } ]
code_shopify_1f02d146
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of shopify/next.config.js from the shopify VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```javascript\nconst { parsed: localEnv } = require(\"dotenv\").config();\n\nconst webpack = require(\"webpack\");\nconst apiKey = JSON.stringify(process.env.SHOPIFY_API_KEY);\n\nmodule.exports = {\n webpack: (config) => {\n const env = { API_KEY: apiKey };\n config.plugins.push(new webpack.DefinePlugin(env));\n\n // Add ESM support for .mjs files in webpack 4\n config.module.rules.push({\n test: /\\.mjs$/,\n include: /node_modules/,\n type: \"javascript/auto\",\n });\n\n return config;\n },\n};\n\n```" } ]
code_shopify_cc810b57
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of shopify/README.md from the shopify VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Shopify VTEX seller connector App\n\nUsing this custom connector will allow VTEX stores to become marketplaces themselves and sell products from an external shopify seller.\n\n## Installation Guide\n\n### 1. Shopify configuration\n\n1) Install the app. This is a private app, so you will need to manually install it by following these steps: \n* download the project in a local folder\n* install `shopify-cli` by following the instructions https://shopify.dev/apps/tools/cli/installation\n* login to your store `shopify login {{storename}}`\n* install the app with `shopify node serve` and follow the onscreen instructions to complete the installation.\n\n2) In the shopify admin section we navigate to `Apps`, find and click the `VTEX Seller Connector` app in the `Installed apps` section.\n Here we fill out and save:\n* `Marketplace account` (required) - represents the VTEX marketplace account name\n* `App key` and `App token` (required) - required for the API calls made to the marketplace\n* `Seller ID` (required) - used when configuring the seller in the marketplace\n* `Fulfillment API Access Token` (required) - this will be your `FULFILLMENT_API_KEY` used by the marketplace to access the app.\n\n### 2. VTEX configuration\n\nThen we need to set up a new seller in the VTEX marketplace admin section.<br>\nWe navigate to `Marketplace -> Sellers -> Management` and click de `New seller` button.<br>\nWhen prompted `Choose the type of Seller you want to register`, choose `Others`, fill out the form and save:\n* `Seller ID` - is the `Seller ID` configured in shopify\n* `Other Name` - desired name\n* `Admin Email` - an email address\n* `Fulfillment EndPoint` - represents the seller endpoint (see bellow)\n* make sure `Active?` is checked\n\nThe `Fulfillment EndPoint` should be `https://{shopifyBaseURl}/api/fulfillment?token=FULFILLMENT_API_KEY`<br>\n\n#### <u>Marketplace trade policies</u>\nIn the VTEX marketplace got to `Store Setup -> Trade policies`, edit a desired policy, and next to `Sellers` check the newly created seller so that the policy will also apply to them.<br>\nHere you can also set the currency to match the seller store, or change it in the seller store to match the policy.\n\n#### <u>Shipping Rates</u>\n\nShipping rates are configured in Shopify under `Settings > Shipping and delivery > Shipping (panel) > Manage rates`.\n\n#### <u>Products specifications</u>\n\nIn order to correctly retrieve product specifications from Shopify into VTEX, the following conditions must be met before approving new products:\n* in VTEX, under `MARKETPLACE -> Sellers -> Categories and Brands` the `Specifications mapping` needs to be filled out.<br>\n On the `Seller` side will be the specification's label from Shopify and on the `Marketplace` side will be the specification's VTEX name.<br>\n* When you approve a new product with specifications from Shopify, you need to make sure that those specifications exists on the VTEX category where you approve the product.<br>\n* In VTEX, category specifications can be found under `PRODUCTS -> Catalog -> Categories`, select the category in question\n and from the `ACTIONS` tab select `Field (Sku)`.<br>\n Here you can edit or add a new specification.<br>\n Always make sure `Active` is checked, even after editing/creating a specification.\n* The specification name is used in the `Marketplace` side when doing `Specifications mapping`.\n\n<hr>\n\n## How does it work?\n\nFollowing the [external seller connector](https://developers.vtex.com/vtex-rest-api/docs/external-seller-integration-connector) documentation, there are nine different API requests. Five of these are calls that the seller should make to the marketplace. The other four are requests that the marketplace will need to make to the seller.\n\n### 1. Catalog notification, registration, update\n\nThe seller, in this case shopify, is responsible for suggesting new SKUs to be sold in the marketplace and also for informing the marketplace about changes in their SKUs that already exist in the marketplace.\n\nWhen changing product information, in shopify, the `PRODUCTS_UPDATE` webhook is called.<br>\n\nHere the first step is to check if the sku exists in the marketplace by calling the [Change Notification endpoint](https://developers.vtex.com/vtex-rest-api/reference/catalog-api-sku-seller#catalog-api-get-seller-sku-notification) with two possible responses:\n* Status 404, means that the SKU does not yet exist in the marketplace. The seller will push the SKU offer to the marketplace using [Send SKU Suggestion](https://developers.vtex.com/vtex-rest-api/reference/manage-suggestions-1)\n* Status 200, means that the SKU exist in the marketplace. The marketplace will make a request to the seller to get updated sku information using [Fulfillment Simulation](https://developers.vtex.com/vtex-rest-api/reference/external-seller#fulfillment-simulation)\n\nAll SKUs provided by the [Send SKU Suggestion](https://developers.vtex.com/vtex-rest-api/reference/manage-suggestions-1) endpoint can be found in the store admin area under `Marketplace -> Sellers -> Received SKUs`.<br>\nOnce approved, the SKUs will become available in the `Products -> Catalog` section and from here on out only price and inventory will be updated via [Fulfillment Simulation](https://developers.vtex.com/vtex-rest-api/reference/external-seller#fulfillment-simulation).\n\nDuring the order flow, the marketplace storefront needs to be constantly fetching the updated price and inventory of each SKU in the cart. This is essential to guarantee that the customer will always be presented with the most updated information possible.\nThis information is provided by the seller through the [Fulfillment Simulation](https://developers.vtex.com/vtex-rest-api/reference/external-seller#fulfillment-simulation) endpoint.\n\n### 2. Order placement and dispatching\n\nOnce the customer finishes their checkout, the marketplace needs to let the seller know there is a newly placed order through the [Order Placement](https://developers.vtex.com/vtex-rest-api/reference/external-seller#order-placement) endpoint. The marketplace will send all data required for the seller to be able to create the order in their own store.\n\nAfter payment is approved, the marketplace sends a request to the seller through the [Ready For Handling](https://developers.vtex.com/vtex-rest-api/reference/external-seller#order-dispatching) endpoint, to notify it that the fulfillment process can be started.\n\n### 3. Order invoicing\n\nShopify does not support natively invoicing.\nIn this case, when capturing/approving payments, the invoice data must be sent to the marketplace.\nThe seller sends this information through the [Order Invoice Notification](https://developers.vtex.com/vtex-rest-api/reference/invoice#invoicenotification) request.<br>\nIn shopify, the `ORDERS_PAID` webhook is called.\n\n### 4. Order cancellation\n\nThe order can be cancelled by either the seller or the marketplace.\n\nWhen the marketplace cancels an order, a request is made to the seller through the [Marketplace Order Cancellation](https://developers.vtex.com/vtex-rest-api/reference/external-seller#mkp-order-cancellation) endpoint.\n\nWhen the seller (shopify) cancels an order, the `ORDERS_CANCELLED` webhook is called.<br>\nIf the order state is `canceled`, the seller makes a request to the seller through the [Cancel Order](https://developers.vtex.com/vtex-rest-api/reference/orders#cancelorder) endpoint.\n\n### 5. Fulfillment EndPoints\n\nThe shopify default endpoint is `https://{shopifyBaseURl}`.<br>\nThe following endpoints where added to shopify in order to accept request from the marketplace:\n* `/api/fulfillment/pvt/orderForms/simulation` - [Fulfillment Simulation](https://developers.vtex.com/vtex-rest-api/reference/external-seller#fulfillment-simulation)\n* `/api//fulfillment/pvt/orders` - [Order Placement](https://developers.vtex.com/vtex-rest-api/reference/external-seller#order-placement)\n* `/api//fulfillment/pvt/orders/:orderId/fulfill` - [Ready For Handling](https://developers.vtex.com/vtex-rest-api/reference/external-seller#order-dispatching)\n* `/api//fulfillment/pvt/orders/:orderId/cancel` - [Cancel Order](https://developers.vtex.com/vtex-rest-api/reference/orders#cancelorder)\n\n```" } ]
code_shopify_025c3aa8
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of shopify/package.json from the shopify VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"shopify-app-node\",\n \"version\": \"1.0.0\",\n \"description\": \"Shopify's node app for CLI tool\",\n \"scripts\": {\n \"test\": \"jest\",\n \"dev\": \"cross-env NODE_ENV=development nodemon ./server/index.js --watch ./server/index.js\",\n \"build\": \"NEXT_TELEMETRY_DISABLED=1 next build\",\n \"start\": \"cross-env NODE_ENV=production node ./server/index.js\"\n },\n \"browser\": {\n \"fs\": false,\n \"path\": false,\n \"os\": false\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/Shopify/shopify-app-node.git\"\n },\n \"author\": \"Shopify Inc.\",\n \"license\": \"MIT\",\n \"bugs\": {\n \"url\": \"https://github.com/shopify/shopify-app-node/issues\"\n },\n \"dependencies\": {\n \"@apollo/client\": \"^3.4.1\",\n \"@babel/core\": \"7.12.10\",\n \"@babel/polyfill\": \"^7.6.0\",\n \"@babel/preset-env\": \"^7.12.11\",\n \"@babel/register\": \"^7.12.10\",\n \"@shopify/app-bridge-react\": \"^2.0.2\",\n \"@shopify/app-bridge-utils\": \"^2.0.2\",\n \"@shopify/koa-shopify-auth\": \"^4.1.2\",\n \"@shopify/polaris\": \"^6.2.0\",\n \"apollo-boost\": \"^0.4.9\",\n \"cross-env\": \"^7.0.3\",\n \"dotenv\": \"^8.2.0\",\n \"express\": \"^4.17.1\",\n \"graphql\": \"^14.5.8\",\n \"isomorphic-fetch\": \"^3.0.0\",\n \"koa\": \"^2.13.1\",\n \"koa-body\": \"^4.2.0\",\n \"koa-logger\": \"^3.2.1\",\n \"koa-router\": \"^10.0.0\",\n \"koa-session\": \"^6.1.0\",\n \"next\": \"^10.0.4\",\n \"next-env\": \"^1.1.0\",\n \"node-fetch\": \"^2.6.1\",\n \"pg\": \"^8.6.0\",\n \"pg-hstore\": \"^2.3.4\",\n \"react\": \"^16.10.1\",\n \"react-apollo\": \"^3.1.3\",\n \"react-dom\": \"^16.14.0\",\n \"sequelize\": \"^6.6.5\",\n \"shopify-token\": \"^4.0.4\",\n \"sqlite3\": \"^5.0.2\",\n \"webpack\": \"^4.44.1\"\n },\n \"devDependencies\": {\n \"@babel/plugin-transform-runtime\": \"^7.12.10\",\n \"@babel/preset-stage-3\": \"^7.0.0\",\n \"babel-jest\": \"26.6.3\",\n \"babel-register\": \"^6.26.0\",\n \"enzyme\": \"3.11.0\",\n \"enzyme-adapter-react-16\": \"1.15.5\",\n \"husky\": \"^4.3.6\",\n \"jest\": \"26.6.3\",\n \"lint-staged\": \"^10.5.3\",\n \"nodemon\": \"^2.0.0\",\n \"prettier\": \"2.2.1\",\n \"react-addons-test-utils\": \"^15.6.2\",\n \"react-test-renderer\": \"16.14.0\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{js,css,json,md}\": [\n \"prettier --write\"\n ]\n }\n}\n\n```" } ]
code_bing-ads_0fe5b47a
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of bing-ads/manifest.json from the bing-ads VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"bing\",\n \"vendor\": \"vtex\",\n \"version\": \"1.1.0\",\n \"title\": \"bing\",\n \"description\": \"bing\",\n \"billingOptions\": {\n \"termsURL\": \"\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true\n },\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"pixel\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"settingsSchema\": {\n \"title\": \"Bing uet Options\",\n \"type\": \"object\",\n \"bindingBounded\": true,\n \"properties\": {\n \"bingId\": {\n \"title\": \"Bing Key\",\n \"description\": \"Enter your 7 digits key Bing\",\n \"type\": \"string\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_buyer-org-supplier_74436d35
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of buyer-org-supplier/package.json from the buyer-org-supplier VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"buyer-org-supplier\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\",\n \"lint:locales\": \"intl-equalizer\",\n \"test\": \"cd ./react && yarn test\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ],\n \"messages/*.json\": [\n \"yarn lint:locales\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^12.12.21\",\n \"@vtex/intl-equalizer\": \"^2.5.0\",\n \"@vtex/prettier-config\": \"^0.3.5\",\n \"eslint\": \"^7.14.0\",\n \"eslint-config-vtex\": \"^12.8.11\",\n \"eslint-config-vtex-react\": \"^6.8.3\",\n \"husky\": \"^4.3.0\",\n \"lint-staged\": \"^10.5.1\",\n \"prettier\": \"^2.2.0\",\n \"typescript\": \"^3.9.6\"\n },\n \"version\": \"0.0.0\",\n \"intl-equalizer\": {\n \"referenceLocale\": \"en\",\n \"localeDirectory\": \"messages\"\n }\n}\n```" } ]
code_buyer-org-supplier_73ab7539
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of buyer-org-supplier/manifest.json from the buyer-org-supplier VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"buyer-org-supplier\",\n \"version\": \"0.6.0\",\n \"title\": \"Buyer Organization Supplier\",\n \"description\": \"A app for handle buyer organizations feature for suppliers\",\n \"builders\": {\n \"docs\": \"0.x\",\n \"node\": \"6.x\"\n },\n \"dependencies\": {},\n \"registries\": [\n \"smartcheckout\"\n ],\n \"credentialType\": \"absolute\",\n \"policies\": [\n {\n \"name\": \"ADMIN_DS\"\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"kubernetes.default.svc.cluster.local\",\n \"path\": \"*\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"portal.vtexcommercestable.com.br\",\n \"path\": \"/api/profile-system/*\"\n }\n }\n ],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_rebuy_b277c6b7
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of rebuy/manifest.json from the rebuy VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"rebuy\",\n \"vendor\": \"vtex\",\n \"version\": \"1.7.0\",\n \"title\": \"Rebuy\",\n \"description\": \"VTEX Rebuy app\",\n \"mustUpdateAt\": \"2019-10-26\",\n \"categories\": [],\n \"registries\": [\n \"smartcheckout\"\n ],\n \"builders\": {\n \"store\": \"0.x\",\n \"react\": \"3.x\",\n \"messages\": \"1.x\",\n \"docs\": \"0.x\"\n },\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.styleguide\": \"9.x\",\n \"vtex.store-components\": \"3.x\",\n \"vtex.store-graphql\": \"2.x\",\n \"vtex.store-resources\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_shareasale_6a6dd476
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of shareasale/manifest.json from the shareasale VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"shareasale\",\n \"version\": \"1.0.3\",\n \"title\": \"Shareasale\",\n \"description\": \"Shareasale\",\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"pixel\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"mustUpdateAt\": \"2019-10-01\",\n \"billingOptions\": {\n \"termsURL\": \"\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"settingsSchema\": {\n \"title\": \"Shareasale\",\n \"type\": \"object\",\n \"properties\": {\n \"merchantId\": {\n \"title\": \"Merchant ID\",\n \"description\": \"Enter your Merchant ID\",\n \"type\": \"string\"\n },\n \"transtype\": {\n \"title\": \"Type of Transaction\",\n \"type\": \"string\",\n \"enum\": [\n \"sale\",\n \"lead\"\n ]\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_iodas-bookstore-theme_81edab33
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of iodas-bookstore-theme/README.md from the iodas-bookstore-theme VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Store theme\nOur boilerplate theme to create stores in the VTEX IO platform.\n\n## Preview\n![](https://user-images.githubusercontent.com/1354492/63937047-e8d81c80-ca37-11e9-86fc-61e88847bbfb.png)\n\n## Tutorial\nTo understand how things work check our tutorial [Build a store using VTEX IO](https://help.vtex.com/en/tracks/build-a-store-using-vtex-io)\n\n## Dependencies\nAll store components that you see on this document are open source too. Production ready, you can found those apps in this GitHub organization. \n \nStore framework is the baseline to create any store using _VTEX IO Web Framework_.\n- [Store](https://github.com/vtex-apps/store/blob/master/README.md)\n\nStore GraphQL is a middleware to access all VTEX APIs.\n- [Store GraphQL](https://github.com/vtex-apps/store-graphql/blob/master/README.md)\n\n### Store Component Apps \n- [Header](https://github.com/vtex-apps/store-header/blob/master/README.md)\n- [Footer](https://github.com/vtex-apps/store-footer/blob/master/README.md)\n- [Carousel](https://github.com/vtex-apps/carousel/blob/master/README.md)\n- [Shelf](https://github.com/vtex-apps/shelf/blob/master/README.md)\n- [Telemarketing](https://github.com/vtex-apps/telemarketing/blob/master/README.md)\n- [Menu](https://github.com/vtex-apps/menu/blob/master/README.md)\n- [Login](https://github.com/vtex-apps/login/blob/master/README.md)\n- [Minicart](https://github.com/vtex-apps/minicart/blob/master/README.md)\n- [Category Menu](https://github.com/vtex-apps/category-menu/blob/master/README.md)\n- [Product Summary](https://github.com/vtex-apps/product-summary/blob/master/README.md)\n- [Breadcrumb](https://github.com/vtex-apps/breadcrumb/blob/master/README.md)\n- [Search Result](https://github.com/vtex-apps/search-result/blob/master/README.md)\n- [Product Details](https://github.com/vtex-apps/product-details/blob/master/README.md)\n- [Storecomponents](https://github.com/vtex-apps/store-components/blob/master/README.md)\n- [Product Kit](https://github.com/vtex-apps/product-kit/blob/master/README.md) :construction: under construction\n- [WishList](https://github.com/vtex-apps/wishlist/blob/master/README.md) :construction: under construction\n- [Order Placed](https://github.com/vtex-apps/order-placed/blob/master/README.md) :construction: under construction\n\n### Store Pixel Apps\n \n - [Facebook Pixel](https://github.com/vtex-apps/facebook-pixel/blob/master/README.md)\n - [Google Analytics](https://github.com/vtex-apps/google-analytics/blob/master/README.md)\n - [Google Tag Manager](https://github.com/vtex-apps/google-tag-manager/blob/master/README.md)\n\n## Contributing\n\nCheck it out [how to contribute](https://github.com/vtex-apps/awesome-io#contributing) with this project. \n\n```" } ]
code_iodas-bookstore-theme_39f85d6c
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of iodas-bookstore-theme/manifest.json from the iodas-bookstore-theme VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"bookstoretheme\",\n \"name\": \"iodas-bookstore-theme\",\n \"version\": \"0.1.0\",\n \"builders\": {\n \"styles\": \"1.x\",\n \"store\": \"0.x\",\n \"sitemap\": \"0.x\"\n },\n \"mustUpdateAt\": \"2020-10-31\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.store\": \"2.x\",\n \"vtex.store-header\": \"2.x\",\n \"vtex.product-summary\": \"2.x\",\n \"vtex.store-footer\": \"2.x\",\n \"vtex.store-components\": \"3.x\",\n \"vtex.styleguide\": \"9.x\",\n \"vtex.slider\": \"0.x\",\n \"vtex.carousel\": \"2.x\",\n \"vtex.shelf\": \"1.x\",\n \"vtex.menu\": \"2.x\",\n \"vtex.minicart\": \"2.x\",\n \"vtex.product-details\": \"1.x\",\n \"vtex.product-kit\": \"1.x\",\n \"vtex.search-result\": \"3.x\",\n \"vtex.login\": \"2.x\",\n \"vtex.my-account\": \"1.x\",\n \"vtex.flex-layout\": \"0.x\",\n \"vtex.rich-text\": \"0.x\",\n \"vtex.store-drawer\": \"0.x\",\n \"vtex.locale-switcher\": \"0.x\",\n \"vtex.product-quantity\": \"1.x\",\n \"vtex.product-identifier\": \"0.x\",\n \"vtex.breadcrumb\": \"1.x\",\n \"vtex.sticky-layout\": \"0.x\",\n \"vtex.product-customizer\": \"2.x\",\n \"vtex.stack-layout\": \"0.x\",\n \"vtex.product-specification-badges\": \"0.x\",\n \"vtex.slider-layout\": \"0.x\",\n \"vtex.store-image\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\",\n \"title\": \"Store Theme\",\n \"description\": \"VTEX IO Store Theme\",\n \"registries\": [\n \"smartcheckout\"\n ]\n}\n\n```" } ]
code_kelkoo_23719099
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of kelkoo/package.json from the kelkoo VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"kelkoo\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.1.4\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.3.2\",\n \"eslint-config-vtex-react\": \"^6.3.2\",\n \"husky\": \"^4.2.3\",\n \"lint-staged\": \"^10.1.1\",\n \"prettier\": \"^2.0.2\",\n \"typescript\": \"^3.8.3\"\n }\n}\n\n```" } ]
code_kelkoo_7ea4778b
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of kelkoo/manifest.json from the kelkoo VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"kelkoo\",\n \"vendor\": \"vtex\",\n \"version\": \"1.0.0\",\n \"title\": \"Kelkoo first party integration\",\n \"description\": \"\",\n \"billingOptions\": {\n \"termsURL\": \"https://compliance.vtex.com/gdpr/policies/vtex-privacy-policy\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true,\n \"type\": \"free\",\n \"availableCountries\": [\n \"*\"\n ]\n },\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"pixel\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"settingsSchema\": {\n \"title\": \"Kelkoo\",\n \"type\": \"object\",\n \"properties\": {\n \"merchantId\": {\n \"title\": \"Shop ID\",\n \"description\": \"Enter the unique ID representing your shop within the Kelkoo system (COMID_VALUE)\",\n \"type\": \"string\"\n },\n \"countryCode\": {\n \"title\": \"Product country identifier\",\n \"description\": \"Enter the 2-letter country code (lower case) for the country on which your products are listed on Kelkoo (COUNTRY_CODE)\",\n \"type\": \"string\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_konduto-antifraud_13476072
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of konduto-antifraud/manifest.json from the konduto-antifraud VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"antifraud-pixel\",\n \"vendor\": \"konduto\",\n \"version\": \"0.4.2\",\n \"title\": \"Konduto Antifraud Pixel\",\n \"description\": \"Konduto Antifraud Pixel\",\n \"mustUpdateAt\": \"2019-04-03\",\n \"builders\": {\n \"pixel\": \"0.x\",\n \"react\": \"3.x\",\n \"store\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"policies\": [\n {\n \"name\": \"pixel\"\n }\n ],\n \"billingOptions\": {\n \"free\": true\n },\n \"settingsSchema\": {\n \"title\": \"Konduto Antifraud Pixel\",\n \"type\": \"object\",\n \"properties\": {\n \"kondutoId\": {\n \"title\": \"Konduto ID\",\n \"description\": \"Enter the public_key informed by Konduto\",\n \"type\": \"string\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_onesignal_42d6fe20
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of onesignal/package.json from the onesignal VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"service-example\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^12.12.21\",\n \"@vtex/prettier-config\": \"^0.3.1\",\n \"eslint\": \"^7.4.0\",\n \"eslint-config-vtex\": \"^12.7.0\",\n \"husky\": \"^4.2.5\",\n \"lint-staged\": \"^10.2.11\",\n \"prettier\": \"^2.0.5\",\n \"typescript\": \"^3.9.6\"\n }\n}\n\n```" } ]
code_onesignal_ea0f815b
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of onesignal/manifest.json from the onesignal VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"onesignal\",\n \"vendor\": \"vtex\",\n \"version\": \"1.1.0\",\n \"title\": \"OneSignal\",\n \"description\": \"\",\n \"categories\": [],\n \"dependencies\": {},\n \"builders\": {\n \"node\": \"6.x\",\n \"docs\": \"0.x\",\n \"pixel\": \"0.x\",\n \"service-worker\": \"0.x\"\n },\n \"credentialType\": \"absolute\",\n \"policies\": [\n {\n \"name\": \"colossus-fire-event\"\n },\n {\n \"name\": \"colossus-write-logs\"\n }\n ],\n \"settingsSchema\": {\n \"title\": \"OneSignal\",\n \"type\": \"object\",\n \"properties\": {\n \"appId\": {\n \"title\": \"App ID\",\n \"type\": \"string\",\n \"default\": \"\",\n \"description\": \"Enter the App ID (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_overlay-layout_d9df566d
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of overlay-layout/package.json from the overlay-layout VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"version\": \"0.0.0\",\n \"devDependencies\": {\n \"@types/node\": \"^13.1.8\",\n \"@vtex/intl-equalizer\": \"^2.3.0\",\n \"@vtex/prettier-config\": \"^0.0.1\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^11.2.1\",\n \"eslint-config-vtex-react\": \"^5.1.0\",\n \"husky\": \"^2.4.1\",\n \"prettier\": \"^1.19.1\",\n \"typescript\": \"^3.7.5\"\n },\n \"scripts\": {\n \"lint\": \"eslint --quiet --fix --ext ts,tsx ./react\",\n \"test\": \"cd ./react && yarn test\",\n \"verify\": \"yarn lint && yarn test\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"yarn lint\",\n \"pre-push\": \"yarn verify\"\n }\n },\n \"intl-equalizer\": {\n \"referenceLocale\": \"en\",\n \"localeDirectory\": \"messages\"\n }\n}\n\n```" } ]
code_overlay-layout_76f5fbc9
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of overlay-layout/manifest.json from the overlay-layout VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"overlay-layout\",\n \"version\": \"0.1.3\",\n \"title\": \"VTEX Overlay Layout\",\n \"description\": \"A React Overlay component.\",\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.css-handles\": \"0.x\",\n \"vtex.responsive-values\": \"0.x\"\n },\n \"policies\": [],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_product-highlight-by-vtex-segment_ddca4238
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of product-highlight-by-vtex-segment/package.json from the product-highlight-by-vtex-segment VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"product-highligh-by-vtex-segment\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\",\n \"lint:locales\": \"intl-equalizer\",\n \"test\": \"cd ./react && yarn test\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/intl-equalizer\": \"^2.5.0\",\n \"@vtex/prettier-config\": \"^0.3.5\",\n \"eslint\": \"^7.14.0\",\n \"eslint-config-vtex\": \"^12.8.11\",\n \"eslint-config-vtex-react\": \"^6.8.3\",\n \"husky\": \"^4.3.0\",\n \"lint-staged\": \"^10.5.1\",\n \"prettier\": \"^2.2.0\",\n \"typescript\": \"^3.9.6\"\n },\n \"dependencies\": {\n \"@vtex/api\": \"^6.45.0\",\n \"@vtex/clients\": \"^2.13.0\",\n \"atob\": \"^2.1.2\"\n }\n}\n\n```" } ]
code_product-highlight-by-vtex-segment_3b895e7d
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of product-highlight-by-vtex-segment/manifest.json from the product-highlight-by-vtex-segment VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtexarg\",\n \"name\": \"product-highlight-by-vtex-segment\",\n \"version\": \"0.3.2\",\n \"title\": \"Product Highlight by Vtex Segment\",\n \"description\": \"A component that gives a highlights solution for WL Architecture for the new law Ley de Gondolas\",\n \"builders\": {\n \"store\": \"0.x\",\n \"react\": \"3.x\",\n \"docs\": \"0.x\",\n \"node\": \"6.x\",\n \"graphql\": \"1.x\"\n },\n \"billingOptions\": {\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"type\": \"free\",\n \"availableCountries\": [\"*\"]\n },\n \"dependencies\": {\n \"vtex.css-handles\": \"0.x\",\n \"vtex.product-context\": \"0.x\",\n \"vtex.render-runtime\": \"8.x\"\n },\n \"settingsSchema\": {\n \"title\": \"ProductHighlight\",\n \"type\": \"object\",\n \"properties\": {\n \"defaultSellerId\": {\n \"title\": \"Default Seller Id\",\n \"type\": \"string\",\n \"description\": \"Enter the default seller id. For example: jumboargentinav692lanus692\"\n },\n \"defaultNameCollection\": {\n \"title\": \"Default Collection Name\",\n \"type\": \"string\",\n \"description\": \"Enter the default name of the collection. For example: leyDeGondolas\"\n },\n \"imageUrlOfHighlight\": {\n \"title\": \"Image Url of Highlight\",\n \"type\": \"string\",\n \"description\": \"Enter the url of the image that you want to show like Highlight.\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_avatax-br-admin_b7c8f6d6
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of avatax-br-admin/package.json from the avatax-br-admin VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"version\": \"0.0.0\",\n \"name\": \"CHANGE_ME\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\",\n \"lint:locales\": \"intl-equalizer\",\n \"test\": \"cd ./react && yarn test\"\n },\n \"intl-equalizer\": {\n \"referenceLocale\": \"en\",\n \"localeDirectory\": \"messages\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged && intl-equalizer && intl-equalizer --fix\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/intl-equalizer\": \"^2.5.0\",\n \"@vtex/prettier-config\": \"^0.3.5\",\n \"@vtex/tsconfig\": \"^0.5.6\",\n \"eslint\": \"^7.14.0\",\n \"eslint-config-vtex\": \"^12.8.11\",\n \"eslint-config-vtex-react\": \"^6.8.3\",\n \"husky\": \"^4.3.0\",\n \"lint-staged\": \"^10.5.1\",\n \"prettier\": \"^2.2.0\",\n \"typescript\": \"^3.9.6\"\n },\n \"dependencies\": {\n \"git\": \"^0.1.5\",\n \"git-gui\": \"^0.0.7\",\n \"yup\": \"^0.32.9\"\n }\n}\n\n```" } ]
code_avatax-br-admin_c10c0fcf
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of avatax-br-admin/manifest.json from the avatax-br-admin VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"avatax-br\",\n \"version\": \"2.2.0\",\n \"title\": \"Avatax Admin\",\n \"description\": \"Admin part of avatax app\",\n \"builders\": {\n \"react\": \"3.x\",\n \"messages\": \"1.x\",\n \"docs\": \"0.x\",\n \"admin\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.styleguide\": \"9.x\",\n \"vtex.avatax-br-service\": \"1.x\",\n \"vtex.avatax-br-tax-protocol\": \"1.x\"\n },\n \"policies\": [],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_awin_71dab6cf
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of awin/manifest.json from the awin VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"CHANGEME\",\n \"vendor\": \"vtex\",\n \"version\": \"0.0.1\",\n \"title\": \"CHANGEME\",\n \"description\": \"CHANGEME\",\n \"billingOptions\": {\n \"termsURL\": \"\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true\n },\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"pixel\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"settingsSchema\": {\n \"title\": \"APP NAME\",\n \"type\": \"object\",\n \"properties\": {\n \"gtmId\": {\n \"title\": \"SAMPLE FIELD\",\n \"description\": \"Enter the ID (GTM-XXXX) from your Google Tag Manager\",\n \"type\": \"string\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_slider_b3498593
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of slider/README.md from the slider VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# VTEX Slider\n\n## Description\n\nThe VTEX Slider is a slider that aims a good support for SSR and can display one or more slides per page.\n\n:loudspeaker: **Disclaimer:** Don't fork this project; use, contribute, or open issue with your feature request\n\n## Table of Contents\n- [Usage](#usage)\n - [Configuration](#configuration)\n - [Slider](#slider)\n - [Slide](#slide)\n - [SliderContainer](#slidercontainer)\n - [Dots](#dots)\n - [Styles API](#styles-api)\n - [CSS namespaces](#css-namespaces)\n- [Tests](#tests)\n\n## Usage\n\nTo import it you can add to you `manifest.json` the following:\n\n```json\n{\n \"dependencies\": {\n \"vtex.slider\": \"0.x\"\n }\n}\n```\n\nAnd then in your component you can import the components exported from the slider:\n\n```javascript\nimport { Slider, Slide } from 'vtex.slider'\n```\n\nYou can use it in your code like a React component with the jsx tags:\n\n```javascript\n\nhandleChangeSlide = i => {\n this.setState({ currentSlide: i })\n}\n\nrender() {\n const { currentSlide } = this.state\n // ...\n\n const { myProducts } = this.props\n\n return (\n <Slider currentSlide={currentSlide} onChangeSlide={this.handleChangeSlide}>\n {myProducts.map(product => (\n <Slide key={product.id}>\n <DisplayProductComponent product={product} />\n </Slide>\n ))}\n </Slider>\n )\n}\n\n```\n\nIf you want to show multiple items in the same page at the same time you can use the prop `perPage`:\n\n```javascript\nrender() {\n const { currentSlide } = this.state\n const { myProducts } = this.props\n\n // The keys of the object represent the size of the window in px.\n // In this case if the window is 1300px large or bigger it will show 5 items,\n // If it has 900px or any size until 1299px it will show 4 items\n const perPage = {\n 1300: 5,\n 900: 4,\n 700: 2,\n 600: 1,\n }\n\n return (\n <Slider\n currentSlide={currentSlide}\n onChangeSlide={this.handleChangeSlide}\n perPage={perPage}\n >\n {myProducts.map(product => (\n <Slide key={product.id}>\n <DisplayProductComponent product={product} />\n </Slide>\n ))}\n </Slider>\n )\n}\n```\n\nBellow is an example with all the components together:\n\n```javascript\narrowRender = ({ orientation, onClick }) => {\n return (\n <div className=\"arrow-container-class\" onClick={onClick}>\n <MyArrowComponent orientation={orientation} />\n </div>\n )\n}\n\narrowContainerRender = ({ children }) => {\n return (\n <MyContainerComponent>\n {children}\n </MyContainerComponent>\n )\n}\n\nrender() {\n const { currentSlide } = this.state\n const { myProducts } = this.props\n\n const perPage = {\n 1300: 5,\n 1100: 4,\n 900: 3,\n 700: 2,\n 300: 1\n }\n\n return (\n <SliderContainer className=\"mw9\">\n <Slider\n loop\n easing=\"ease\"\n duration={500}\n perPage={perPage}\n currentSlide={currentSlide}\n arrowRender={this.arrowRender}\n onChangeSlide={this.handleChangeSlide}\n arrowsContainerComponent={this.arrowContainerRender}\n >\n {myProducts.map(product => (\n <Slide\n className=\"slide-css-class\"\n sliderTransitionDuration={500}\n key={product.id}\n defaultWidth={280}\n >\n <ProductComponent product={product} />\n </Slide>\n ))}\n </Slider>\n <Dots\n loop\n showDotsPerPage\n perPage={this.perPage}\n currentSlide={currentSlide}\n totalSlides={myProducts.length}\n onChangeSlide={this.handleChangeSlide}\n classes={{\n root: 'pv4',\n notActiveDot: 'bg-muted-3',\n dot: 'dot pointer br-100',\n activeDot: 'bg-emphasis'\n }}\n />\n </SliderContainer>\n )\n}\n```\n\n### Configuration\n\n#### Slider\n\n| Prop name | Type | isRequired | defaultValue | Description |\n| --- | --- | --- | --- | -- |\n| `arrowRender` | `func` | :no_entry_sign: | :no_entry_sign: | A render function that will receive as props an orientation prop and an onClick callback |\n| `arrowsContainerComponent` | `func/string` | :no_entry_sign: | :no_entry_sign: | The component used to contain both arrows. Either a string to use a DOM element or a component |\n| `children` | `element/array` | :heavy_check_mark: | :no_entry_sign: | The slides to render |\n| `classes` | `object` | :no_entry_sign: | No extra classes applied to any element | Classes to apply to the Slider elements |\n| `currentSlide` | `number` | :no_entry_sign: | `0` | Current slide on the screen, if you have perPage > 1, then the current slide is the most left slide on the screen (You should not use this variable to display the index of the slide on the screen if you're using `loop={true}`). |\n| `cursor` | `string` | :no_entry_sign: | `'-webkit-grab'` | Css value of cursor when mouse is hovering the slider frame |\n| `cursorOnMouseDown` | `string` | :no_entry_sign: | `'-webkit-grabbing'` | Css value of cursor when mouse is down |\n| `duration` | `number` | :no_entry_sign: | `250` | Duration of transitions |\n| `easing` | `string` | :no_entry_sign: | `'ease-out'` | Transition function |\n| `loop` | `bool` | :no_entry_sign: | `false` | If the slides should be looping |\n| `onChangeSlide` | `func` | :heavy_check_mark: | :no_entry_sign: | Function to change the value of currentSlide. The function should expect a `number` as it's only parameter |\n| `perPage` | `number/object` | :no_entry_sign: | `1` | Amount of slides to be on the screen, if a number is passed, then that's the number of slides that will be shown, if an object with breakpoints is passed, then the component will check the size of the screen to see how many slides will be on the screen at the same time |\n| `minPerPage` | `number` | :no_entry_sign: | `1` | Minimum amount of slides to be on the screen, can be used to control how many itens will be displayed in the smallest screen size |\n| `resizeDebounce` | `number` | :no_entry_sign: | `250` | Resize debounce timer in milliseconds |\n| `rootTag` | `string` | :no_entry_sign: | `'div'` | Tag to be rendered in the root of the slider |\n| `sliderFrameTag` | `string` | :no_entry_sign: | `'ul'` | Tag to be rendered in the slider frame element |\n| `threshold` | `number` | :no_entry_sign: | `50` | Minimum of pixels to drag until the slider change the `currentSlide` |\n\n#### Slide\n\n| Prop name | Type | isRequired | defaultValue | Description |\n| --- | --- | --- | --- | --- |\n| `children` | `node` | :heavy_check_mark: | :no_entry_sign: | Node to render |\n| `className` | `string` | :no_entry_sign: | :no_entry_sign: | Classes to pass to the root element of the Slide |\n| `defaultWidth` | `number` | :no_entry_sign: | :no_entry_sign: | Default width of the slide (only applied in the first render) |\n| `tag` | `string` | :no_entry_sign: | `li` | Tag to be rendered in the root element |\n| `fitImg` | `bool` | :no_entry_sign: | `true` | If the slide component should try to fit the `img` (only works if children is an `img` element) |\n| `resizeDebounce` | `number` | :no_entry_sign: | `250` | Time of debounce of resize event listener |\n| `sliderTransitionDuration` | `number` | :no_entry_sign: | `250` | Duration of transition passed to Slider (must be the same), if nothing is passed to any of the components it will apply the same default value |\n\n#### SliderContainer\n\n| Prop name | Type | isRequired | defaultValue | Description |\n| --- | --- | --- | --- | --- |\n| `autoplay` | `bool` | :no_entry_sign: | `false` | If the slider should be passing automatically |\n| `autoplayInterval` | `number` | :no_entry_sign: | `5000` | Time in milliseconds of the interval to change the currentSlider |\n| `children` | `node` | :heavy_check_mark: | :no_entry_sign: | Children of the component to render |\n| `className` | `string` | :no_entry_sign: | :no_entry_sign: | Classes to be applied to the root element |\n| `onNextSlide` | `func` | :no_entry_sign: | :no_entry_sign: | Function to be called if `autoplay={true}` |\n| `pauseOnHover` | `bool` | :no_entry_sign: | `true` | If the interval should not be executed when the mouse is hovering the component |\n| `tag` | `string` | :no_entry_sign: | `'div'` | Tag to render the component | \n\n#### Dots\n\n| Prop name | Type | isRequired | defaultValue | Description |\n| --- | --- | --- | --- | --- |\n| `classes` | `object` | :no_entry_sign: | No extra classes applied to any element | Classes to style the elements of the component |\n| `dotProps` | `object` | :no_entry_sign: | :no_entry_sign: | Extra props to be applied to the dot element |\n| `dotSize` | `number/string` | :no_entry_sign: | :no_entry_sign: | The size of the dots, can be a number (in this case it will use px unit), or a string (you have to pass the number with the unit e.g `'3rem'`) |\n| `dotTag` | `string` | :no_entry_sign: | `'li'` | Tag to be rendered in the dot element |\n| `loop` | `bool` | :no_entry_sign: | `false` | If the slides should be looping |\n| `onChangeSlide` | `func` | :heavy_check_mark: | :no_entry_sign: | Function to change the currentSlide |\n| `perPage` | `number/object` | :no_entry_sign: | `1` | This prop works the same way the `perPage` of `Slider` and this component should receive the same value of `Slider` |\n| `resizeDebounce` | `number` | :no_entry_sign: | `250` | Debounce time in milliseconds |\n| `rootTag` | `string` | :no_entry_sign: | `'ul'` | Tag to be rendered as the root element of the component |\n| `totalSlides` | `number` | :heavy_check_mark: | :no_entry_sign: | Total value of sliders that will be rendered |\n| `minPerPage` | `number` | :no_entry_sign: | `1` | This prop works the same way the `minPerPage` of `Slider` and this component should receive the same value of `Slider` |\n| `showDotsPerPage` | `bool` | :no_entry_sign: | `false` | If this frag is true, then every dot represent a page of slides (e.g. if `perPage = 2` and you have 4 elements, then you have 2 dots), if false, then it will render one dot to each slide |\n\n## Styles API\n\nYou can style this app by using the props `classeName` and `classes` of the components. But if you want to style every slider of your app you need to use the [CSS namespaces](#css-namespaces) to do it.\n\n### CSS namespaces\n\n:construction: :construction: :construction:\n\n## Tests\n\n[![Coverage Status](https://coveralls.io/repos/github/vtex-apps/slider/badge.svg?branch=master)](https://coveralls.io/github/vtex-apps/slider?branch=master)\n\n## Travis CI\n\n[![Build Status](https://travis-ci.org/vtex-apps/slider.svg?branch=master)](https://travis-ci.org/vtex-apps/slider)\n\n```" } ]
code_slider_65e4cc55
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of slider/manifest.json from the slider VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"slider\",\n \"vendor\": \"vtex\",\n \"version\": \"0.8.3\",\n \"title\": \"VTEX Slider\",\n \"description\": \"A React Slider component that works well in SPA and SSR\",\n \"mustUpdateAt\": \"2020-01-30\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.device-detector\": \"0.x\"\n },\n \"builders\": {\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_std_efcd9d60
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of std/README.md from the std VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# vtex.land/std\n\nThe core apps of the `vex` platform.\n\nThese apps do not have external dependencies and they are reviewed and maintained by the VTEX IO core team. The intention is to have a standard set of high quality code that all VTEX IO projects can use fearlessly.\n\nContributions are welcome!\n\n### Recognition\n\nThis is heavily inspired by the great work happening at the Deno community.\n```" } ]
code_disclosure-layout_a91d060a
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of disclosure-layout/package.json from the disclosure-layout VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"version\": \"0.0.0\",\n \"name\": \"disclosure-layout\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\",\n \"test\": \"cd ./react && yarn test\"\n },\n \"intl-equalizer\": {\n \"referenceLocale\": \"en\",\n \"localeDirectory\": \"messages\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.3.1\",\n \"eslint\": \"^7.4.0\",\n \"eslint-config-vtex\": \"^12.7.0\",\n \"eslint-config-vtex-react\": \"^6.7.0\",\n \"husky\": \"^4.2.5\",\n \"lint-staged\": \"^10.2.11\",\n \"prettier\": \"^2.0.5\",\n \"typescript\": \"^3.9.6\"\n }\n}\n\n```" } ]
code_disclosure-layout_a9cc96f6
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of disclosure-layout/manifest.json from the disclosure-layout VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"disclosure-layout\",\n \"version\": \"1.0.4\",\n \"title\": \"Disclosure Layout\",\n \"description\": \"\",\n \"builders\": {\n \"react\": \"3.x\",\n \"docs\": \"0.x\",\n \"store\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.css-handles\": \"0.x\"\n },\n \"registries\": [\n \"smartcheckout\"\n ],\n \"policies\": [],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_admin-graphql-ide_fd8e52e8
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of admin-graphql-ide/package.json from the admin-graphql-ide VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"admin-graphql-ide\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^12.12.21\",\n \"@vtex/prettier-config\": \"^0.3.1\",\n \"eslint\": \"^7.4.0\",\n \"eslint-config-vtex\": \"^12.7.0\",\n \"eslint-config-vtex-react\": \"^6.7.0\",\n \"husky\": \"4.2.3\",\n \"lint-staged\": \"10.1.1\",\n \"prettier\": \"2.0.2\",\n \"typescript\": \"3.9.7\"\n }\n}\n\n```" } ]
code_admin-graphql-ide_dcdfad7e
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of admin-graphql-ide/manifest.json from the admin-graphql-ide VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"admin-graphql-ide\",\n \"vendor\": \"vtex\",\n \"version\": \"3.8.0\",\n \"title\": \"Admin GraphQL IDE\",\n \"description\": \"GraphQL IDE for VTEX Admin (GraphiQL)\",\n \"scripts\": {\n \"prereleasy\": \"bash pre.sh\"\n },\n \"builders\": {\n \"admin\": \"0.x\",\n \"node\": \"4.x\",\n \"typedql\": \"0.x\",\n \"messages\": \"1.x\",\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.styleguide\": \"9.x\",\n \"vtex.graphql-server\": \"1.x\"\n },\n \"policies\": [\n {\n \"name\": \"read-workspace-apps\"\n },\n {\n \"name\": \"vtex.graphql-server:resolve-graphiql\"\n },\n {\n \"name\": \"sphinx-is-admin\"\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"vtexid.vtex.com.br\",\n \"path\": \"/api/vtexid/pub/authenticated/user\"\n }\n }\n ],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_landing-pages_64f2995d
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of landing-pages/manifest.json from the landing-pages VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"landing-pages\",\n \"version\": \"2.0.0\",\n \"title\": \"VTEX Landing Pages\",\n \"description\": \"VTEX IO Landing Pages\",\n \"builders\": {\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.tetrix\": \"1.x\",\n \"vtex.docs-ui\": \"0.x\",\n \"vtex.code-cup\": \"1.x\",\n \"vtex.io-landing\": \"1.x\"\n },\n \"mustUpdateAt\": \"2018-09-05\",\n \"categories\": [],\n \"registries\": [\n \"smartcheckout\"\n ],\n \"settingsSchema\": {},\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_affirm-components_6fd3b362
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of affirm-components/package.json from the affirm-components VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"affirm-components\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,js,json}\\\"\",\n \"cy-r\": \"cd ./cy-runner && node cy-runner\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^13.7.0\",\n \"@vtex/prettier-config\": \"0.1.3\",\n \"eslint\": \"6.8.0\",\n \"eslint-config-vtex\": \"12.2.1\",\n \"eslint-config-vtex-react\": \"^6.0.5\",\n \"husky\": \"4.2.0\",\n \"lint-staged\": \"10.0.2\",\n \"prettier\": \"1.19.1\",\n \"typescript\": \"3.7.5\"\n }\n}\n```" } ]
code_affirm-components_615bf7cc
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of affirm-components/manifest.json from the affirm-components VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"affirm-components\",\n \"vendor\": \"vtex\",\n \"version\": \"0.0.9\",\n \"title\": \"Affirm Components\",\n \"description\": \"Frontend components related to Affirm payment method\",\n \"categories\": [],\n \"registries\": [\n \"smartcheckout\"\n ],\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"mustUpdateAt\": \"2018-09-05\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.store\": \"2.x\",\n \"vtex.product-teaser-interfaces\": \"1.x\",\n \"vtex.product-context\": \"0.x\",\n \"vtex.product-summary-context\": \"0.x\",\n \"vtex.affirm-payment\": \"2.x\",\n \"vtex.css-handles\": \"0.x\"\n },\n \"policies\": [\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"{{account}}.vtexcommercestable.com.br\",\n \"path\": \"/*\"\n }\n }\n ],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_responsive-values_c9b057d7
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of responsive-values/package.json from the responsive-values VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"version\": \"0.0.0\",\n \"devDependencies\": {\n \"@vtex/intl-equalizer\": \"^2.5.0\",\n \"@vtex/prettier-config\": \"^0.3.6\",\n \"eslint\": \"^7.15.0\",\n \"eslint-config-vtex\": \"^12.9.1\",\n \"eslint-config-vtex-react\": \"^6.9.1\",\n \"husky\": \"^4.3.5\",\n \"lint-staged\": \"^10.5.3\",\n \"prettier\": \"^2.2.1\",\n \"typescript\": \"^3.9.7\"\n },\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\",\n \"test\": \"yarn --cwd react test\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"intl-equalizer\": {\n \"referenceLocale\": \"en\",\n \"localeDirectory\": \"messages\"\n }\n}\n\n```" } ]
code_responsive-values_f27a9a28
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of responsive-values/manifest.json from the responsive-values VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"responsive-values\",\n \"version\": \"0.4.2\",\n \"title\": \"Responsive Values\",\n \"description\": \"Accept different values for different devices\",\n \"builders\": {\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.device-detector\": \"0.x\"\n },\n \"policies\": [],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_salesforce-oauth-middleware_79aa4cbc
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of salesforce-oauth-middleware/dangerfile.js from the salesforce-oauth-middleware VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```javascript\n// dangerfile.js\nconst { verify } = require('@vtex/danger')\n\nconst config = {\n // Set to true to enforce keepachangelog rules.\n keepachangelog: {\n changeVersion: false,\n },\n rules: {\n description: ['fail', { minLength: 20 }],\n assignee: 'fail',\n reviewers: 'fail',\n pr_size: ['warn', { additionLimit: 800, deletionLimit: -1 }],\n lock_file: 'warn',\n no_ignored_test: ['fail', { pattern: /test|spec/i }],\n no_debugger: ['fail', { pattern: /\\.[tj]sx?$/i }],\n enforce_graphql_provider: 'off',\n },\n}\n\nverify(config)\n\n```" } ]
code_salesforce-oauth-middleware_e2ef0f00
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of salesforce-oauth-middleware/README.md from the salesforce-oauth-middleware VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n## Objective\n\nThe purpose of this document is to detail the implementation of the middleware responsible for communicating with the Salesforce OAuth provider to store the unique access token per user to enable the front end on the ecommerce my account page to retrieve it later.\n\n## Limitations\n\nCurrently, the VTEX ID authentication cookie has a 24 hours lifetime, and the frontend should manage the token refresh. During that process, the VTEX ID will not call the Salesforce OAuth provider to refresh their token.\n\nSo, in specific cases, it will be possible that we have a valid VTEX ID token and an expired Salesforce token. When it happens, until we develop the process to refresh it in the current app and the frontend, we will need to redirect the user to the login page to re-authenticate.\n\n\n## Middleware Workflow\n\nCurrently, the VTEX ID speaks directly with the Salesforce OAuth. With the current implementation, the VTEX ID will talk with the middleware, who will be responsible for communicating with Salesforce.\n\nDuring the user authentication flow, at the moment, the VTEX ID requests to exchange the user's data with Salesforce we will get the user's email and token and store it in a database to be retrieved thru an API exposed by the app.\n\n\n### Frontend Workflow\n\nThe frontend must handle the process of calling the middleware API and then store the access token in the local storage. The response also contains the expiration date, so it is possible to manage when it is about to expire and handle the user behavior.\n\n\n## API Reference\n\n### Proxy Endpoint\n\nEndpoint used as a proxy to the Salesforce OAuth. The path from Salesforce should be exactly the same as in the Salesforce documentation. The only difference is that we need to add the /_v/oauth-proxy in the beginning of each route.\n\n\n##### MΓ©todo GET, POST:\n```\nhttps://{{accountName}}.myvtex.com/_v/oauth-proxy/authorizations/{{salesforce-path}}\n```\n\nHeaders and body should be the same as described in OAuth Provider documentation from Salesforce.\n\n### Retrieve Access Token\n\nEndpoint used to retrieve a user Salesforce access token.\n\n##### MΓ©todo GET:\n```\nhttps://{{accountName}}.myvtex.com/_v/oauth-proxy/autheticated/access-token/\n```\n\n##### Header:\n```\nAccept: application/json \nContent-Type: application/json \nCookie: VtexIdclientAutCookie={{VtexIdclientAutCookie}};\n```\n\n##### Response:\n```Status: 200 OK``` \n\n```\n{\n ...{{UserInfo}},\n \"access_token\": \"00D3X000002LqRE!AR4AQM.PZS_Talk6BcAODgZ3H83LS2CwBo773pAYYHM0017KZSoGfswpEV0q2FifIUEIkU1NRNFyD.RxQW63poEry3EXFsfI\",\n \"end_date\": \"2022-09-27T16:57:03.866Z\"\n}\n```\n\nIf the response has the 401 status code, you should refresh the token following what is described in the limitations section.\n\n### Refresh a Token\n\nEndpoint used to refresh a user Salesforce access token.\n\n##### MΓ©todo GET:\n```\nhttps://{{accountName}}.myvtex.com/_v/oauth-proxy/autheticated/refresh-token/\n```\n\n##### Header:\n```\nAccept: application/json \nContent-Type: application/json \nCookie: VtexIdclientAutCookie={{VtexIdclientAutCookie}};\n```\n\n##### Response:\n```Status: 200 OK``` \n\n```\n{\n ...{{UserInfo}},\n \"access_token\": \"00D3X000002LqRE!AR4AQM.PZS_Talk6BcAODgZ3H83LS2CwBo773pAYYHM0017KZSoGfswpEV0q2FifIUEIkU1NRNFyD.RxQW63poEry3EXFsfI\",\n \"end_date\": \"2022-09-27T16:57:03.866Z\"\n}\n```\n\nIf the response has the 401 status code, you should refresh the token following what is described in the limitations section.\n\n```" } ]
code_salesforce-oauth-middleware_6ae503ce
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of salesforce-oauth-middleware/package.json from the salesforce-oauth-middleware VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"service-example\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^12.12.21\",\n \"@vtex/prettier-config\": \"^0.3.6\",\n \"@vtex/danger\": \"^0.2.7\",\n \"eslint\": \"^7.16.0\",\n \"eslint-config-vtex\": \"^12.9.3\",\n \"husky\": \"^4.3.6\",\n \"lint-staged\": \"^10.5.3\",\n \"prettier\": \"^2.2.1\",\n \"typescript\": \"^3.7.5\"\n }\n}\n\n```" } ]
code_salesforce-oauth-middleware_59871372
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of salesforce-oauth-middleware/manifest.json from the salesforce-oauth-middleware VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"salesforce-oauth-middleware\",\n \"vendor\": \"vtex\",\n \"version\": \"1.0.2\",\n \"title\": \"Salesforce OAuth Middleware\",\n \"description\": \"Middleware to authenticate using Salesforce OAuth and store user access token to be retrieved later\",\n \"mustUpdateAt\": \"2018-01-04\",\n \"categories\": [],\n \"dependencies\": {},\n \"builders\": {\n \"node\": \"6.x\"\n },\n \"credentialType\": \"absolute\",\n \"policies\": [\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"portal.vtexcommercestable.com.br\",\n \"path\": \"*\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"vtexid.vtex.com.br\",\n \"path\": \"*\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"*\",\n \"path\": \"*\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"*.force.com\",\n \"path\": \"*\"\n }\n },\n {\n \"name\": \"vbase-read-write\"\n },\n {\n \"name\": \"colossus-fire-event\"\n },\n {\n \"name\": \"colossus-write-logs\"\n }\n ],\n \"settingsSchema\": {\n \"title\": \"Salesforce Oauth Middleware Settings\",\n \"type\": \"object\",\n \"properties\": {\n \"production\": {\n \"title\": \"Production Settings\",\n \"type\": \"object\",\n \"properties\": {\n \"endpoint\": {\n \"title\": \"Production Endpoint\",\n \"description\": \"(e.g.: https://login.salesforce.com)\",\n \"type\": \"string\"\n },\n \"credentials\": {\n \"title\": \"Production Credentials\",\n \"type\": \"object\",\n \"properties\": {\n \"clientId\": {\n \"title\": \"client_id\",\n \"type\": \"string\"\n },\n \"clientSecret\": {\n \"title\": \"client_secret\",\n \"type\": \"string\"\n }\n }\n }\n }\n },\n \"staging\": {\n \"title\": \"Staging Settings\",\n \"type\": \"object\",\n \"properties\": {\n \"endpoint\": {\n \"title\": \"Staging Endpoint\",\n \"description\": \"(e.g.: https://login.salesforce.com)\",\n \"type\": \"string\"\n },\n \"credentials\": {\n \"title\": \"Staging Credentials\",\n \"type\": \"object\",\n \"properties\": {\n \"clientId\": {\n \"title\": \"client_id\",\n \"type\": \"string\"\n },\n \"clientSecret\": {\n \"title\": \"client_secret\",\n \"type\": \"string\"\n }\n }\n }\n }\n },\n \"configs\": {\n \"title\": \"General Middleware Configuration\",\n \"type\": \"object\",\n \"properties\": {\n \"forceProduction\": {\n \"title\": \"Always use production settings\",\n \"type\": \"boolean\"\n }\n }\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_order-shipping_a6f505e6
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of order-shipping/package.json from the order-shipping VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"order-shipping\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.1.4\",\n \"eslint\": \"^6.8.0\",\n \"eslint-config-vtex\": \"^12.3.2\",\n \"eslint-config-vtex-react\": \"^6.3.2\",\n \"husky\": \"^4.2.0\",\n \"lint-staged\": \"^10.0.2\",\n \"prettier\": \"^1.19.1\",\n \"typescript\": \"^3.7.5\"\n }\n}\n```" } ]
code_order-shipping_88955c21
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of order-shipping/manifest.json from the order-shipping VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"order-shipping\",\n \"version\": \"0.8.0\",\n \"title\": \"Order Shipping\",\n \"description\": \"Order Shipping component\",\n \"defaultLocale\": \"pt-BR\",\n \"builders\": {\n \"react\": \"3.x\",\n \"docs\": \"0.x\"\n },\n \"mustUpdateAt\": \"2019-04-02\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.order-manager\": \"0.x\",\n \"vtex.checkout-resources\": \"0.x\",\n \"vtex.checkout-graphql\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_vtex-scripts_af31e374
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of vtex-scripts/README.md from the vtex-scripts VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# VTEX Scripts\n\nThis package contains the scripts and build configuration for the VTEX modules.\n\n## Usage\n\n1. Add the `@vtex/vtex-scripts` to your devDependencies\n\n```sh\n$ yarn add @vtex/vtex-scripts enzyme enzyme-adapter-react-16 jsdom --dev\n```\n\n2. Add the following scripts to your `package.json`\n\n```json\n{\n \"scripts\": {\n \"build\": \"vtex-scripts build\",\n \"test\": \"vtex-scripts test\"\n }\n}\n```\n\n3. Add the following to a `setupTests.js` in the root of your _source_ directory\n\n```js\nimport Enzyme from 'enzyme'\nimport Adapter from 'enzyme-adapter-react-16'\nimport { JSDOM } from 'jsdom'\n\nconst jsdom = new JSDOM('<!doctype html><html><body></body></html>')\n\nglobal.window = jsdom.window\nglobal.document = window.document\n\nEnzyme.configure({ adapter: new Adapter() })\n```\n\n## Configurations\n\nYou can also customize some default configurations that comes with `vtex-scripts`\n\nThe following properties can be supplied in a `vtexScriptsOverride` property inside your `package.json`\n\n| Name | Type | Description |\n| -------------------- | :------: | ------------------------------------------------------------------ |\n| `srcPath` | `String` | The relative path of your sources directory (e.g. `./src`) |\n| `distPath` | `String` | The relative path of your compiled files directory (e.g. `./dist`) |\n| `setupTestsFilename` | `String` | The filename of the tests setup file (e.g. `setupTests.js`) |\n\n```" } ]
code_vtex-scripts_b6039937
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of vtex-scripts/package.json from the vtex-scripts VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"@vtex/vtex-scripts\",\n \"version\": \"0.4.13\",\n \"description\": \"VTEX miscelaneous build scripts\",\n \"bin\": {\n \"vtex-scripts\": \"./bin/vtex-scripts.js\"\n },\n \"files\": [\n \"bin\",\n \"config\",\n \"scripts\",\n \"utils\",\n \".babelrc\"\n ],\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/vtex-apps/vtex-scripts.git\"\n },\n \"author\": \"VTEX\",\n \"license\": \"ISC\",\n \"dependencies\": {\n \"babel\": \"~6.23.0\",\n \"babel-jest\": \"~22.4.3\",\n \"babel-loader\": \"~7.1.4\",\n \"babel-plugin-dynamic-import-node\": \"^1.2.0\",\n \"babel-plugin-transform-class-properties\": \"^6.24.1\",\n \"babel-preset-es2015\": \"^6.24.1\",\n \"babel-preset-react\": \"^6.24.1\",\n \"chalk\": \"~2.4.0\",\n \"css-loader\": \"^0.28.11\",\n \"enzyme\": \"~3.3.0\",\n \"enzyme-adapter-react-16\": \"~1.1.1\",\n \"enzyme-to-json\": \"~3.3.3\",\n \"fs-extra\": \"~5.0.0\",\n \"graphql\": \"~0.13.2\",\n \"graphql-tag\": \"~2.8.0\",\n \"jest\": \"~22.4.3\",\n \"jest-transform-graphql\": \"~2.1.0\",\n \"node-sass\": \"^4.9.0\",\n \"react\": \"^16.3.2\",\n \"react-dev-utils\": \"~5.0.1\",\n \"react-dom\": \"^16.3.2\",\n \"sass-loader\": \"^7.0.1\",\n \"style-loader\": \"^0.21.0\",\n \"svg-inline-loader\": \"^0.8.0\",\n \"url-loader\": \"^1.0.1\",\n \"webpack\": \"~4.5.0\"\n },\n \"bugs\": {\n \"url\": \"https://github.com/vtex-apps/vtex-scripts/issues\"\n },\n \"homepage\": \"https://github.com/vtex-apps/vtex-scripts#readme\"\n}\n\n```" } ]
code_custom-stock-export_6cb9e91c
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of custom-stock-export/README.md from the custom-stock-export VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n## ⚠️ Maintenance ⚠️\n*Starting September 1st 2022, this application will no longer be maintained by VTEX. Code is released for free under the GNU/PL Agreement for you to use and modify at your convenience. The VTEX repository shall remain unchanged with the original version.*\n\n---\n\nThis app was not ended\n\n```" } ]
code_adserver-resolver_e07a7170
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of adserver-resolver/policies.json from the adserver-resolver VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n[\n {\n \"name\": \"resolve-graphql\",\n \"description\": \"Allows access to resolve a graphql request\",\n \"statements\": [\n {\n \"actions\": [\"post\", \"get\"],\n \"effect\": \"allow\",\n \"resources\": [\n \"vrn:vtex.adserver-resolver:{{region}}:{{account}}:{{workspace}}:/_v/graphql\"\n ]\n }\n ]\n }\n]\n\n```" } ]
code_adserver-resolver_35bd34c2
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of adserver-resolver/README.md from the adserver-resolver VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Ad Server Resolver\n\nThis app is an implementation of VTEX's Ad Server, that wraps the VTEX Ad Server related API calls.\n\nThis protocol is defined by VTEX's [Ad Server GraphQL schema](https://github.com/vtex-apps/adserver-graphql).\n\n```" } ]
code_adserver-resolver_b70b78d4
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of adserver-resolver/tsconfig.eslint.json from the adserver-resolver VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"extends\": \"./node/tsconfig.json\",\n \"include\": [\"**/*.ts\", \"**/*.tsx\", \"**/*.js\"],\n \"exclude\": []\n}\n\n```" } ]
code_adserver-resolver_3328352d
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of adserver-resolver/package.json from the adserver-resolver VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"adserver-resolver\",\n \"version\": \"0.0.1\",\n \"description\": \"The resolver for VTEX's Ad Server GraphQL schema.\",\n \"main\": \"node/index.ts\",\n \"repository\": \"git@github.com:vtex-apps/adserver-resolver.git\",\n \"author\": \"Henrique CaΓΊla <henrique.caula@vtex.com.br>\",\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\",\n \"prepare\": \"husky install\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"prettier --write\",\n \"yarn lint --fix\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/jest\": \"^29.5.3\",\n \"@types/node\": \"^20.5.0\",\n \"@vtex/prettier-config\": \"^1.0.0\",\n \"eslint\": \"^8.47.0\",\n \"eslint-config-vtex\": \"^15.0.2\",\n \"eslint-plugin-prettier\": \"^5.0.0\",\n \"husky\": \"^8.0.3\",\n \"lint-staged\": \"^14.0.0\",\n \"prettier\": \"^3.0.2\",\n \"typescript\": \"^5.1.6\"\n }\n}\n\n```" } ]
code_adserver-resolver_3ea5f91f
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of adserver-resolver/manifest.json from the adserver-resolver VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"adserver-resolver\",\n \"version\": \"2.10.4\",\n \"title\": \"Ad Server Resolver\",\n \"description\": \"Configurations for sponsored products on your store\",\n \"builders\": {\n \"node\": \"6.x\"\n },\n \"dependencies\": {\n \"vtex.adserver-graphql\": \"0.x\"\n },\n \"policies\": [\n {\n \"name\": \"vbase-read-write\"\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"ad-server.vtex.systems\",\n \"path\": \"/api/*\"\n }\n },\n {\n \"attrs\": {\n \"host\": \"portal.vtexcommercestable.com.br\",\n \"path\": \"/api/checkout/regions/*\"\n },\n \"name\": \"outbound-access\"\n },\n {\n \"attrs\": {\n \"host\": \"newtail-media.newtail.com.br\",\n \"path\": \"*\"\n },\n \"name\": \"outbound-access\"\n }\n ],\n \"settingsSchema\": {\n \"title\": \"AdServer Resolver\",\n \"type\": \"object\",\n \"properties\": {\n \"enableAdsOnCollections\": {\n \"title\": \"Enable sponsored products on collections\",\n \"description\": \"If checked, sponsored products will be displayed on product collections.\",\n \"type\": \"boolean\",\n \"default\": true\n },\n \"enableNewtail\": {\n \"title\": \"Enable Newtail\",\n \"description\": \"If checked, Newtail will be used to display sponsored products.\",\n \"type\": \"boolean\",\n \"default\": false\n },\n \"newtailPublisherId\": {\n \"title\": \"Newtail Publisher ID\",\n \"description\": \"The publisher ID provided by Newtail.\",\n \"type\": \"string\",\n \"default\": \"\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_flow-finance-payment_bd75b340
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of flow-finance-payment/package.json from the flow-finance-payment VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"affirm-payment\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,js,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@types/node\": \"^13.7.0\",\n \"@vtex/prettier-config\": \"^0.1.4\",\n \"eslint\": \"6.8.0\",\n \"eslint-config-vtex\": \"12.2.1\",\n \"eslint-config-vtex-react\": \"^6.0.5\",\n \"husky\": \"4.2.0\",\n \"lint-staged\": \"10.0.2\",\n \"prettier\": \"1.19.1\",\n \"typescript\": \"3.7.5\"\n }\n}\n```" } ]
code_flow-finance-payment_e0e957ea
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of flow-finance-payment/manifest.json from the flow-finance-payment VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"flow-finance-payment\",\n \"vendor\": \"vtex\",\n \"version\": \"0.0.4\",\n \"title\": \"Flow Finance Payment\",\n \"description\": \"An implentation of Flow Finance payment method\",\n \"categories\": [],\n \"registries\": [\"smartcheckout\"],\n \"builders\": {\n \"react\": \"2.x\",\n \"pages\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"mustUpdateAt\": \"2018-09-05\",\n \"scripts\": {\n \"postreleasy\": \"vtex publish --verbose\"\n },\n \"dependencies\": {\n \"vtex.styleguide\": \"8.x\"\n },\n \"policies\": [\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"{{account}}.vtexcommercestable.com.br\",\n \"path\": \"/*\"\n }\n },\n {\n \"name\": \"outbound-access\",\n \"attrs\": {\n \"host\": \"{{account}}.vtexpayments.com.br\",\n \"path\": \"/*\"\n }\n }\n ],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_KI-398695_7a8eebf7
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of KI-398695/KI-398695.js from the KI-398695 VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```javascript\n$(document).ready(function () {\n addModalObserver();\n});\nfunction addModalObserver() {\n let open = false;\n const observerPupModal = new MutationObserver((mutations, obsPM) => {\n const pupModal = document.querySelector(\".pkpmodal\");\n\n if (document.contains(pupModal)) {\n if (!open){\n addSeachObserver();\n open = !open\n //obsPM.disconnect();\n return;\n }\n }\n else{\n open = false\n }\n\n });\n\n observerPupModal.observe(document, {\n childList: true,\n subtree: true,\n });\n}\nfunction addSeachObserver() {\n const observerSearch = new MutationObserver((mutations, obsS) => {\n const pkpmodalSearch = document.querySelector(\"#pkpmodal-search\"); \n if (document.contains(pkpmodalSearch)) {\n const input = pkpmodalSearch.querySelector(\"input\");\n input.addEventListener(\"change\", (event) => {\n setTimeout(() => {\n getOrderForm();\n }, 500);\n });\n\n obsS.disconnect();\n }\n });\n\n observerSearch.observe(document, {\n childList: true,\n subtree: true,\n });\n}\n\n\nfunction getOrderForm() {\nvtexjs.checkout.getOrderForm().then((orderForm) => {\n getPupDistance(orderForm);\n});\n}\n\nfunction getPupDistance(orderForm) {\nconst logisticsInfoSlas = orderForm.shippingData.logisticsInfo\n .map((logisticInfo) => {\n return logisticInfo.slas;\n })\n .flat();\n\nconst slasPUP = logisticsInfoSlas.filter((sla) => {\n return sla.deliveryChannel === \"pickup-in-point\";\n});\nconst slas = [];\nslasPUP.forEach((sla) => {\n if (!slas.some((s) => s.id === sla.id)) {\n slas.push({\n id: sla.id,\n value: sla,\n });\n }\n});\nslas.forEach((sla) => {\n const { pickupDistance } = sla.value;\n addSectionObserver(sla.id, sla.value.pickupDistance);\n});\n}\n\nfunction updatePupElements(id, pickupDistance) {\n //validar que exista el elemento\n const parseId = id.replace(\" \", \"-\").replace(\"(\", \"\").replace(\")\", \"\");\n const pkpmodalPointsList = document.querySelector(\".pkpmodal-points-list\");\n if(typeof(pkpmodalPointsList) && pkpmodalPointsList != null){\n const element = pkpmodalPointsList.querySelector(\"#\" + parseId);\n const distanceElement = element.querySelector(\n \".pkpmodal-pickup-point-distance\"\n );\n const actualDistance = distanceElement.textContent;\n const unit = actualDistance.split(\" \")[1];\n const parsePickupDistance = parseFloat(pickupDistance)\n .toFixed(1)\n .replace(\".\", \",\");\n const newDistance = parsePickupDistance + \" \" + unit;\n distanceElement.textContent = newDistance;\n }\n}\n\nfunction addSectionObserver(id, pickupDistance) {\n let open = false;\n const observerSection = new MutationObserver((mutations, obsPM) => {\n const pickupPointDistance = document.querySelector(\".pkpmodal-pickup-point-distance\");\n\n if (document.contains(pickupPointDistance)) {\n if (!open){\n updatePupElements(id, pickupDistance);\n open = !open\n //obsPM.disconnect();\n return;\n }\n }\n else{\n open = false\n }\n\n });\n\n observerSection.observe(document, {\n childList: true,\n subtree: true,\n });\n}\n```" } ]
code_KI-398695_c449346c
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of KI-398695/README.md from the KI-398695 VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# [KI-398695] Distance from pickup stores are not updated on map when entering new address\n\nThis script solves the KI https://vtexhelp.zendesk.com/agent/tickets/398695. \n\nYou need to add the script to the checkout at the `checkout6-custom.js`.\n\n## Contributors ✨\n\nThanks goes to these wonderful people:\n\n<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->\n<!-- prettier-ignore-start -->\n<!-- markdownlint-disable -->\n<table>\n <tr>\n <td align=\"center\"><a href=\"https://github.com/germanBonacchi\"><img src=\"https://avatars.githubusercontent.com/u/55905671?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>GermΓ‘n Bonacchi</b></sub></a><br /><a href=\"https://github.com/vtex-apps/KI-398695/commits?author=germanBonacchi\" title=\"Code\">πŸ’»</a></td>\n <td align=\"center\"><a href=\"https://github.com/watchmakercomeback\"><img src=\"https://avatars.githubusercontent.com/u/102434124?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Carlos AndrΓ©s CastaΓ±o Carrasquilla</b></sub></a><br /><a href=\"https://github.com/vtex-apps/KI-398695/commits?author=watchmakercomeback\" title=\"Code\">πŸ’»</a></td>\n</tr>\n</table>\n\n```" } ]
code_actionpay_14a16ad7
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of actionpay/manifest.json from the actionpay VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"actionpay\",\n \"vendor\": \"vtex\",\n \"version\": \"0.1.3\",\n \"title\": \"Actionpay\",\n \"description\": \"Actionpay VTEX App\",\n \"billingOptions\": {\n \"termsURL\": \"\",\n \"support\": {\n \"url\": \"https://support.vtex.com/hc/requests\"\n },\n \"free\": true\n },\n \"builders\": {\n \"react\": \"3.x\",\n \"store\": \"0.x\",\n \"pixel\": \"0.x\",\n \"docs\": \"0.x\"\n },\n \"dependencies\": {\n \"vtex.pixel-interfaces\": \"1.x\"\n },\n \"settingsSchema\": {\n \"title\": \"Actionpay Settings\",\n \"type\": \"object\",\n \"properties\": {\n \"actionpayPartnerId\": {\n \"title\": \"Partner ID\",\n \"description\": \"Enter your Actionpay Partner ID\",\n \"type\": \"string\"\n },\n \"actionpayPostclick\": {\n \"title\": \"Post-click\",\n \"description\": \"Enter your Actionpay Post-click\",\n \"type\": \"number\"\n },\n \"actionpayCampaignId\": {\n \"title\": \"Campaign ID\",\n \"description\": \"Enter your Actionpay Campaign ID\",\n \"type\": \"string\"\n }\n }\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_add-to-cart-validation_896a379f
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of add-to-cart-validation/README.md from the add-to-cart-validation VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n## ⚠️ Maintenance ⚠️\n*After June 27 of 2022, this application will no longer be maintained by the FPA APUB team or the RPT LATAM team. Maintenance will be the responsibility of the ecosystem, everyone will be able to make a branch with the changes or improvements they want to make, make a pull request and we will approve it.*\n\n---\n\n# Add-to-cart Validation \n\n\n```" } ]
code_add-to-cart-validation_fed9f2cf
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of add-to-cart-validation/package.json from the add-to-cart-validation VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"countdown\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,js,json}\\\"\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.1.4\",\n \"eslint\": \"^7.12.1\",\n \"eslint-config-vtex\": \"^12.3.2\",\n \"eslint-config-vtex-react\": \"^6.2.1\",\n \"husky\": \"^4.2.3\",\n \"lint-staged\": \"^10.1.1\",\n \"prettier\": \"^2.0.2\",\n \"typescript\": \"^3.8.3\"\n }\n}\n\n```" } ]
code_add-to-cart-validation_a14af0bf
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of add-to-cart-validation/manifest.json from the add-to-cart-validation VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtexarg\",\n \"name\": \"add-to-cart-validation\",\n \"version\": \"0.0.1\",\n \"title\": \"Add to cart validation component\",\n \"description\": \"Add to cart validation component\",\n \"defaultLocale\": \"pt-BR\",\n \"builders\": {\n \"messages\": \"1.x\",\n \"store\": \"0.x\",\n \"react\": \"3.x\"\n },\n \"dependencies\": {\n \"vtex.styleguide\": \"9.x\",\n \"vtex.css-handles\": \"0.x\",\n \"vtex.order-manager\": \"0.x\",\n \"vtex.product-context\": \"0.x\",\n \"vtex.order-items\": \"0.x\",\n \"vtex.store-resources\": \"0.x\"\n },\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_product-highlights_af365e55
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of product-highlights/package.json from the product-highlights VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"name\": \"product-highlights\",\n \"private\": true,\n \"license\": \"UNLICENSED\",\n \"scripts\": {\n \"lint\": \"eslint --ext js,jsx,ts,tsx .\",\n \"format\": \"prettier --write \\\"**/*.{ts,tsx,js,jsx,json}\\\"\",\n \"test\": \"cd ./react && yarn test\"\n },\n \"husky\": {\n \"hooks\": {\n \"pre-commit\": \"lint-staged\"\n }\n },\n \"lint-staged\": {\n \"*.{ts,js,tsx,jsx}\": [\n \"eslint --fix\",\n \"prettier --write\"\n ],\n \"*.{json,graphql,gql}\": [\n \"prettier --write\"\n ],\n \"*.json\": [\n \"prettier --write\"\n ]\n },\n \"devDependencies\": {\n \"@vtex/prettier-config\": \"^0.3.1\",\n \"eslint\": \"^7.4.0\",\n \"eslint-config-vtex\": \"^12.7.0\",\n \"eslint-config-vtex-react\": \"^6.7.0\",\n \"husky\": \"^4.2.5\",\n \"lint-staged\": \"^10.2.11\",\n \"prettier\": \"^2.0.5\",\n \"typescript\": \"^3.9.6\"\n },\n \"version\": \"0.0.0\"\n}\n\n```" } ]
code_product-highlights_aee4cb1b
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of product-highlights/manifest.json from the product-highlights VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```json\n{\n \"vendor\": \"vtex\",\n \"name\": \"product-highlights\",\n \"version\": \"2.3.2\",\n \"title\": \"Product Highlights\",\n \"description\": \"\",\n \"builders\": {\n \"react\": \"3.x\",\n \"docs\": \"0.x\",\n \"store\": \"0.x\",\n \"messages\": \"1.x\"\n },\n \"dependencies\": {\n \"vtex.product-context\": \"0.x\",\n \"vtex.native-types\": \"0.x\",\n \"vtex.css-handles\": \"0.x\"\n },\n \"registries\": [\n \"smartcheckout\"\n ],\n \"policies\": [],\n \"$schema\": \"https://raw.githubusercontent.com/vtex/node-vtex-api/master/gen/manifest.schema\"\n}\n\n```" } ]
code_cy-runner_9ac0f67a
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of cy-runner/cy-runner.js from the cy-runner VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```javascript\nconst cfg = require('./node/config')\nconst system = require('./node/system')\nconst logger = require('./node/logger')\nconst cypress = require('./node/cypress')\nconst workspace = require('./node/workspace')\nconst { deprecated } = require('./node/deprecated')\nconst { report } = require('./node/report')\nconst { runTests } = require('./node/test')\nconst { issue } = require('./node/jira')\n\n// Controls test state\nconst control = {\n start: system.tick(),\n timing: {},\n specsFailed: [],\n specsSkipped: [],\n specsDisabled: [],\n specsPassed: [],\n runUrl: null,\n}\n\nasync function main() {\n // Init logger\n logger.init()\n\n // Welcome message\n logger.msgSection('Cypress Runner')\n\n // Read cy-runner.yml configuration\n const config = await cfg.getConfig('cy-runner.yml')\n\n // Init workspace set up\n control.timing.initWorkspace = await workspace.init(config)\n\n // Install apps\n control.timing.installApps = await workspace.installApps(config)\n\n // Uninstall apps\n control.timing.uninstallApps = await workspace.uninstallApps(config)\n\n // Link app\n const link = await workspace.linkApp(config)\n\n control.timing.linkApp = link.time\n\n if (link.success) {\n if (config.base.cypress.devMode) {\n logger.msgWarn('Please, wait the flow when you finish')\n logger.msgPad('This will ensure the release and teardown will run')\n await cypress.open()\n } else {\n const call = await runTests(config)\n\n control.timing.strategy = call.time\n control.specsFailed = call.specsFailed\n control.specsSkipped = call.specsSkipped\n control.specsDisabled = call.specsDisabled\n control.specsPassed = call.specsPassed\n control.runUrl = call.runUrl\n\n // Jira automation\n if (config.base.jira.enabled && control.specsFailed?.length) {\n await issue(config, control.specsFailed, control.runUrl)\n }\n }\n }\n\n // Teardown\n if (link.subprocess) link.subprocess.kill('SIGHUP')\n control.timing.teardown = await workspace.teardown(config, link.success)\n\n // Report deprecated flags\n await deprecated(config)\n\n // Final Report\n control.timing.total = system.tack(control.start)\n await report(control, config)\n}\n\nmain().then((r) => r)\n\n```" } ]
code_cy-runner_9cc15908
[ { "role": "system", "content": "You are an expert VTEX IO developer. You specialize in building VTEX Store Framework apps, React components, GraphQL APIs, and Node.js services for e-commerce platforms." }, { "role": "user", "content": "Show me the implementation of cy-runner/README.md from the cy-runner VTEX app." }, { "role": "assistant", "content": "Here's the implementation:\n\n```markdown\n# Cypress Runner\n\n[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=vtex-apps_cy-runner&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=vtex-apps_cy-runner)\n[![Lines of Code](https://sonarcloud.io/api/project_badges/measure?project=vtex-apps_cy-runner&metric=ncloc)](https://sonarcloud.io/summary/new_code?id=vtex-apps_cy-runner)\n[![Technical Debt](https://sonarcloud.io/api/project_badges/measure?project=vtex-apps_cy-runner&metric=sqale_index)](https://sonarcloud.io/summary/new_code?id=vtex-apps_cy-runner)\n\nTool to orchestrate Cypress tests at VTEX\n\n## Features\n* Automate authentication on VTEX Toolbelt (using [VTEX Toolbelt Action](https://github.com/vtex/action-toolbelt))\n* Manage workspace: installing, uninstalling, creation, and deletion\n* Link the application to be tested\n* Orchestrate tests to run in parallel ([Cypress Dashboard](https://www.cypress.io/dashboard) or [Sorry-Cypress](https://sorry-cypress.dev/))\n* Report execution time and status of each spec\n* Report Cypress Dashboard link\n* Create Jira tickets in case of failure\n* Save artifacts to make easier debug failures\n* Wipe data (needs spec to do it)\n* Full teardown\n\n## Run it on a GitHub Action\n```yaml\nname: '[QE] Quality Engineering'\n\non:\n push:\n \njobs:\n cypress:\n name: Cypress\n runs-on: ubuntu-latest\n timeout-minutes: 30\n concurrency:\n group: ${{ github.workflow }}\n steps:\n - name: Checkout App\n uses: actions/checkout@v3\n - name: Checkout Cy-Runner\n uses: actions/checkout@v3\n with:\n repository: vtex-apps/cy-runner\n ref: main\n path: cy-runner\n - name: Set up Node.js\n uses: actions/setup-node@v3\n with:\n node-version: 16\n cache: yarn\n continue-on-error: true\n - name: Install Cy-Runner packages\n run: |\n yarn install --frozen-lockfile --prod\n yarn cypress info\n working-directory: cy-runner\n - name: Run tests\n run: node cy-runner\n working-directory: cy-runner\n env:\n VTEX_QE: ${{ secrets.cypressJSON }}\n NODE_NO_WARNINGS: 1\n - name: Save test results\n uses: actions/upload-artifact@v3\n if: always()\n with:\n name: cy-runner-logs\n path: |\n cy-runner/logs\n !cy-runner/logs/**/*.mp4\n retention-days: 3\n```\n\n## Run it locally\n1. Clone the app repository to be tested\n2. Add a `cy-runner.yml` configuration file using the configuration template\n3. Create a env or local file with the secrets using the secrets template (`.VTEX_QE.json` in our example)\n3. Add a `cy-r` inside your `package.json` file to make easier call cy-runner or call it directly by `node cy-runner`\n```txt\nscripts {\n ...,\n \"cy-r\": \"cd cy-runner && node cy-runner\",\n ...\n}\n```\n4. If you are developing `cy-r`, maybe can be useful check it before start the tests. To do so, add another line in your `package.json`\n```txt\nscripts {\n ...,\n \"cy-r\": \"cd cy-runner && node cy-runner\",\n \"cy-d\": \"cd cy-runner && git pull && node cy-runner\",\n ...\n}\n```\n\n## Setup\nOne important part of the setup is the installation, uninstallation, and link apps. To generate a name for your new workspace on every run, keep the name of it as `random`. If you want to use a created workspace because you don't need to install, uninstall or link any app, you can fill the name with your workspace:\n\n```yaml\n[...]\nworkspace:\n name: random\n prefix: b2b\n linkApp:\n # In this case, the app to be installed will be read by the manifest.json file\n enabled: true\n installApps:\n - vtex.mySuperCoolApp\n - vtex.myAnotherSuperCoolApp\n removeApps:\n - vtex.defaultTheme\n[...]\n```\n## Tests\nAfter a successful setup, `cypress-runner` will take care of your tests, it will start one by one or in parallel (max 3 jobs in parallel at this point), and make sure that dependent tests only run if the dependencies pass first. If you are planing to run tests in parallel locally, then you can use more than three jobs (if your machine has power to do so), but in this case you'll need to set `base.cypress.sorry` as `true` and make sure that you have a [Sorry Cypress](https://sorry-cypress.dev/) up and running locally. On each strategy you can add as many specs as you need.\n\n### To run all tests without any dependency with local parallelization\n\nTo configure the parallelization with five jobs you can take advantage of the following example. Note the `hardTries`, it is useful when you wan't to try more the one time with a fresh browser start between the tries. If you have `specA`, `specB`, and `specC` and the `specB` fails during the strategy, only the `specB` will be tested on the next retry.\n\n```yaml\n[...]\ncypress:\n maxJobs: 3\n quiet: true\n projectId: myProjectId\n video: true\n videoCompression: false\n browser: chrome\n chromeWebSecurity: false\n\nstrategy:\n # You can call whatever you want\n myTests:\n enabled: true\n sendDashboard: false\n hardTries: 1\n stopOnFail: false\n parallel: true\n specs:\n - cypress/integration/specA.spec.js\n - cypress/integration/specB.spec.js\n - cypress/integration/specC.spec.js\n - cypress/integration/specD.spec.js\n - cypress/integration/specE.spec.js\n # You can use wildcard here:\n # It'll be the same if you have only those three specs on the same folder\n # - cypress/integration/spec?.spec.js\n```\n\n### Fail fast\n\nThe option `strategy.buyItems.stopOnFail` as `true` instruct Cy Runner to stop the test soon as it fails. \n\n```yaml\n[...]\ncypress:\n maxJobs: 3\n quiet: true\n projectId: myProjectId\n video: true\n videoCompression: false\n browser: chrome\n chromeWebSecurity: false\n\nstrategy:\n buyItems:\n enabled: true\n sendDashboard: true\n hardTries: 1\n stopOnFail: true\n parallel: true\n specs:\n - cypress/integration/buyCoffee.spec.js\n - cypress/integration/buyCoffeeMaker.spec.js\n checkInventory:\n enabled: true\n sendDashboard: true\n hardTries: 1\n stopOnFail: false\n parallel: true\n specs:\n - cypress/integration/checkInventory.spec.js\n dependency:\n - cypress/integration/buyCoffee.spec.js\n - cypress/integration/buyCoffeeMaker.spec.js\n checkOrders:\n enabled: true\n sendDashboard: true\n hardTries: 3\n stopOnFail: false\n parallel: true\n specs:\n - cypress/integration/checkOrders.spec.js\n dependency:\n - cypress/integration/checkInventory.spec.js \n\n```\n\n## Results\n\nAll artifacts from the test are saved on the `cy-runner/logs` folder. If you are using GitHub Actions, you can download the logs as artifacts.\n\n1. Detailed report of each run for each test as yaml\n2. The app versions used on the test in txt\n3. The app dependency versions used on the test in json\n4. The state files to with products IDs and invoices\n5. The VTEX Toolbelt debug in json\n6. The verbose linked application log in txt\n7. The screenshots of the failures (if enabled)\n8. The videos with the records (if enabled)\n9. The Cy Runner log as the example bellow\n\nAlso, you have the `cy-runner.log` file, that will show you how the tests were conducted, the main failures and the time to do each task. Next we'll show one example of it:\n```txt\n#### Cypress Runner\n\n [βœ“] Loading cy-runner configuration\n - ./avalara/cy-runner.yml\n [βœ“] Checking toolbelt version\n [βœ“] Defining workspace\n - avalara3967668\n [βœ“] Loading secrets\n - from file ./cy-runner/.VTEX_QE.json\n [!] Auto configuring Cypress flags\n - Set base.skipAutoConfigOnCI to true to avoid auto config\n\n#### Sections to run\n\n [βœ“] base.secrets\n [βœ“] base.jira\n [βœ“] workspace.linkApp\n [βœ“] workspace.wipe\n - wipe.spec.js\n [βœ“] workspace.teardown\n [βœ“] strategy.config\n - 1.0-syncCustomUIConf.spec.js\n [βœ“] strategy.apiTests\n - 1.1-addressVerification.spec.js\n - 1.2-postalCode.spec.js\n - 1.3-sku.spec.js\n - 1.4-taxFallback.spec.js\n ☍ 1.0-syncCustomUIConf.spec.js\n [βœ“] strategy.basicTests\n - 2.1-singleproduct.spec.js\n - 2.2-multiproduct.spec.js\n - 2.5-externalSeller.spec.js\n - 2.6-promotional_product.spec.js\n ☍ 1.0-syncCustomUIConf.spec.js\n [βœ“] strategy.verifyTax\n - 2.3-discountProduct.spec.js\n - 2.4-discountShipping.spec.js\n ☍ 1.0-syncCustomUIConf.spec.js\n [βœ“] strategy.transaction\n - 2.7-transaction.spec.js\n ☍ 2.1-singleproduct.spec.js\n ☍ 2.2-multiproduct.spec.js\n ☍ 2.3-discountProduct.spec.js\n ☍ 2.4-discountShipping.spec.js\n ☍ 2.5-externalSeller.spec.js\n ☍ 2.6-promotional_product.spec.js\n [βœ“] strategy.refund\n - 2.8-fullRefund-transaction.spec.js\n - 2.9-partialRefund-transaction.spec.js\n ☍ 2.1-singleproduct.spec.js\n ☍ 2.2-multiproduct.spec.js\n\n#### Cypress set up\n\n [βœ“] Getting admin cookie\n [βœ“] Getting user cookie\n - vtexappkey-productusqa-OFGEHT\n [βœ“] Creating Cypress environment\n - ./cy-runner/cypress.env.json\n - ./cy-runner/cypress.json\n [βœ“] Creating state file\n - .orders.json\n [βœ“] Linking local Cypress code on Cy-Runner\n - ./cy-runner/cypress-shared/support/common -> ./cypress/support/common\n - ./cypress -> ./cy-runner/cypress\n [βœ“] Exporting envs variables\n - ELECTRON_EXTRA_LAUNCH_ARGS = --disable-gpu --disable-software-rasterizer\n - LIBVA_DRIVER_NAME = --disable-software-rasterizer\n - DISPLAY = :99\n - NODE_NO_WARNINGS = 1\n\n#### Workspace set up\n\n [βœ“] Changing workspace\n - avalara3967668\n [βœ“] Updating ./avalara/.vtexignore\n [βœ“] Reading ./avalara/manifest.json\n [βœ“] Linking vtex.avalara@3.4.0\n - waiting 120 seconds until link gets ready\n - waiting 110 seconds until link gets ready\n - waiting 100 seconds until link gets ready\n [βœ“] App linked successfully\n\n#### [try 1/2] Strategy Config\n\n [βœ“] Specs to run on this try\n - 1.0-syncCustomUIConf.spec.js\n [βœ“] Strategy Config ran successfully\n - Passed: 1.0-syncCustomUIConf.spec.js\n\n#### [try 1/3] Strategy Api Tests\n\n [βœ“] Dashboard URL\n - https://dashboard.cypress.io/projects/9myhsu/runs/364\n [βœ“] Specs to run on this try\n - 1.1-addressVerification.spec.js\n - 1.2-postalCode.spec.js\n - 1.3-sku.spec.js\n - 1.4-taxFallback.spec.js\n [βœ“] Strategy Api Tests ran successfully\n - Passed: 1.0-syncCustomUIConf.spec.js\n - Passed: 1.1-addressVerification.spec.js\n - Passed: 1.2-postalCode.spec.js\n - Passed: 1.3-sku.spec.js\n - Passed: 1.4-taxFallback.spec.js\n\n\n [βœ“] Dashboard URL\n - https://dashboard.cypress.io/projects/9myhsu/runs/364\n [βœ“] Specs to run on this try\n - 2.1-singleproduct.spec.js\n - 2.2-multiproduct.spec.js\n - 2.5-externalSeller.spec.js\n - 2.6-promotional_product.spec.js\n - Passed: 1.0-syncCustomUIConf.spec.js\n - Passed: 1.1-addressVerification.spec.js\n - Passed: 1.2-postalCode.spec.js\n - Passed: 1.3-sku.spec.js\n - Passed: 1.4-taxFallback.spec.js\n - Passed: 2.1-singleproduct.spec.js\n - Passed: 2.2-multiproduct.spec.js\n - Passed: 2.5-externalSeller.spec.js\n - Passed: 2.6-promotional_product.spec.js\n\n#### [try 1/2] Strategy Verify Tax\n\n [βœ“] Dashboard URL\n - https://dashboard.cypress.io/projects/9myhsu/runs/364\n [βœ“] Specs to run on this try\n - 2.3-discountProduct.spec.js\n - 2.4-discountShipping.spec.js\n [βœ“] Strategy Verify Tax ran successfully\n - Passed: 1.0-syncCustomUIConf.spec.js\n - Passed: 1.1-addressVerification.spec.js\n - Passed: 1.2-postalCode.spec.js\n - Passed: 1.3-sku.spec.js\n - Passed: 1.4-taxFallback.spec.js\n - Passed: 2.1-singleproduct.spec.js\n - Passed: 2.2-multiproduct.spec.js\n - Passed: 2.3-discountProduct.spec.js\n - Passed: 2.4-discountShipping.spec.js\n - Passed: 2.5-externalSeller.spec.js\n - Passed: 2.6-promotional_product.spec.js\n\n#### [try 1/2] Strategy Transaction\n\n [βœ“] Dashboard URL\n - https://dashboard.cypress.io/projects/9myhsu/runs/364\n [βœ“] Specs to run on this try\n - 2.7-transaction.spec.js\n [βœ“] Strategy Transaction ran successfully\n - Passed: 1.0-syncCustomUIConf.spec.js\n - Passed: 1.1-addressVerification.spec.js\n - Passed: 1.2-postalCode.spec.js\n - Passed: 1.3-sku.spec.js\n - Passed: 1.4-taxFallback.spec.js\n - Passed: 2.1-singleproduct.spec.js\n - Passed: 2.2-multiproduct.spec.js\n - Passed: 2.3-discountProduct.spec.js\n - Passed: 2.4-discountShipping.spec.js\n - Passed: 2.5-externalSeller.spec.js\n - Passed: 2.6-promotional_product.spec.js\n - Passed: 2.7-transaction.spec.js\n\n#### [try 1/3] Strategy Refund\n\n [βœ“] Dashboard URL\n - https://dashboard.cypress.io/projects/9myhsu/runs/364\n [βœ“] Specs to run on this try\n - 2.8-fullRefund-transaction.spec.js\n - 2.9-partialRefund-transaction.spec.js\n [βœ“] Strategy Refund ran successfully\n - Passed: 1.0-syncCustomUIConf.spec.js\n - Passed: 1.1-addressVerification.spec.js\n - Passed: 1.2-postalCode.spec.js\n - Passed: 1.3-sku.spec.js\n - Passed: 1.4-taxFallback.spec.js\n - Passed: 2.1-singleproduct.spec.js\n - Passed: 2.2-multiproduct.spec.js\n - Passed: 2.3-discountProduct.spec.js\n - Passed: 2.4-discountShipping.spec.js\n - Passed: 2.5-externalSeller.spec.js\n - Passed: 2.6-promotional_product.spec.js\n - Passed: 2.7-transaction.spec.js\n - Passed: 2.8-fullRefund-transaction.spec.js\n - Passed: 2.9-partialRefund-transaction.spec.js\n\n#### Workspace teardown\n\n [βœ“] Dumping environment\n - ./cy-runner/logs/_apps_installed.txt\n - ./cy-runner/logs/_apps_dependency.json\n - /home/runner/.vtex/logs/debug.json -> ./cy-runner/logs/_debug.json\n - Node versions -> ./cy-runner/logs/_node_versions.json\n - Env variables -> ./cy-runner/logs/_env.txt\n [!] Moving state files\n - .orders.json -> ./cy-runner/logs/.orders.json\n [βœ“] State files moved successfully\n [βœ“] Wiping data\n - Disabling parallelism\n - Running wipe\n [βœ“] Data wiped successfully\n [βœ“] Cleaning sensitive data\n - cypress.env.json\n - cypress.json\n [βœ“] Workspace avalara3967668 deleted\n\n#### Deprecation report\n\n [!] Deprecated configuration on your cy-runner.yml\n - base.twilio\n [βœ“] You should remove it as soon as possible\n\n#### Execution report\n\n [βœ“] Execution time\n - initWorkspace................. 3.866 seconds\n - installApps................... 0 seconds\n - uninstallApps................. 0 seconds\n - linkApp....................... 30.037 seconds\n - strategy...................... 331.058 seconds\n - teardown...................... 13.237 seconds\n - total......................... 380.672 seconds\n\n [βœ“] Successful specs\n - 1.0-syncCustomUIConf.spec.js\n - 1.1-addressVerification.spec.js\n - 1.2-postalCode.spec.js\n - 1.3-sku.spec.js\n - 1.4-taxFallback.spec.js\n - 2.1-singleproduct.spec.js\n - 2.2-multiproduct.spec.js\n - 2.3-discountProduct.spec.js\n - 2.4-discountShipping.spec.js\n - 2.5-externalSeller.spec.js\n - 2.6-promotional_product.spec.js\n - 2.7-transaction.spec.js\n - 2.8-fullRefund-transaction.spec.js\n - 2.9-partialRefund-transaction.spec.js\n\n\n#### [Cypress Dashboard](https://dashboard.cypress.io/projects/9myhsu/runs/364)\n\n [βœ“] https://dashboard.cypress.io/projects/9myhsu/runs/364\n\n#### Success\n\n [βœ“] The test ran successfully, well done!\n\n```\n\n## Teardown\n\nAs `cypress runner` was designed to be a multi proposal tool, it's hard to cover all possible cases that need cleaning data, so you can do this task by creating one or more specs to take care of it.\n\n```yaml\n[...]\nworkspace:\n [...]\n wipe:\n enabled: true\n stopOnFail: false\n specs:\n - cypress/integration/cleanMasterData.spec.js\n - cypress/integration/cleanSomethingElse.spec.js\n teardown:\n enabled: true\n [...]\n[...]\n```\n\n# Templates\n\n## Configuration template\n\nConfiguration is required on the root of the repository to be tested with the name `cy-runner.yml`. We are working on a feature to check by this file on main project when working with shared projects (same set of tests to different apps, like **b2b-organizations** and **b2b-organizations-graphql**).\n\n```yaml\n# cy-runner.yml\n---\nbase:\n secrets:\n # In dev secrets can can be a local JSON with the pattern:\n # .VTEX_QE.json\n enabled: true\n name: VTEX_QE\n vtex:\n # Account to be used to login\n account: yourAccount\n domain: myvtex.com\n vtexIdUrl: https://vtexid.vtex.com.br/api/vtexid/pub/authenticate/default\n jira:\n # If you want to report issues on Jira\n enabled: false\n account: config-dev\n board: jira-key\n issueType: task\n slack:\n # If you want to report issues on Slack\n # Not functional yet\n enabled: false\n channel: some-channel\n cypress:\n # Opens Cypress instead of running it\n devMode: false\n # Show the GUI window in run mode\n runHeaded: false\n # Get tokens to use inside tests\n getCookies: true\n # Max number of specs parallelization\n maxJobs: 3 \n # Show less information on logs\n quiet: true\n # Project run with Cypress Dashboard\n projectId: xxzzyy\n video: false\n videoCompression: 32\n videoUploadOnPasses: false\n screenshotOnRunFailure: true\n trashAssetsBeforeRuns: false\n viewportWidth: 1440\n viewportHeight: 900\n defaultCommandTimeout: 25000\n requestTimeout: 25000\n watchForFileChanges: false\n pageLoadTimeout: 45000\n # Can be chrome, firefox or electron\n browser: chrome\n chromeWebSecurity: false\n # If you need to create empty state\n # to use in your tests, for checking transactions\n # or for doing data wipe on the end\n stateFiles: []\n\nworkspace:\n # Set to random to get [prefix][random] (ie b2b1234567)\n # You should use an existent workspace if you disabled \n # base.vtex.deployCly\n name: random\n prefix: b2b\n # The nex configuration avoid apps that need account\n # level resources from running in parallel\n reserveAccount:\n enabled: false\n setup:\n - orderForm\n - vtex.orders-broadcast@0.x\n - vtex.sno@0.x\n # Link the PR app for integration tests\n linkApp:\n enabled: true\n # Apps to be installed\n installApps: []\n # Apps to be removed\n removeApps: []\n # Spec to wipe the data on the end\n wipe:\n enabled: true\n stopOnFail: false\n specs:\n - cypress-shared/integration/workspace/wipe.spec.js\n # Clean workspace and state files on the end\n teardown:\n enabled: true\n\nstrategy:\n # Short name is better\n byFromStore:\n enabled: true\n # Send it to Cypress Dashboard or Sorry-Cypress\n sendDashboard: false\n # How many times to try it\n hardTries: 1\n # Stop the test if it fails\n stopOnFail: false\n # Run in parallel, requires Cypress Dashboard or Sorry-Cypress\n parallel: true\n # Specs to run (order not guaranteed)\n specs:\n - cypress/integration/A01*\n - cypress/integration/A02*\n checkInvoice:\n enabled: true\n sendDashboard: true\n hardTries: 1\n stopOnFail: false\n parallel: false\n specs:\n - cypress/integration/A02*\n # Needs to pass to run this strategy\n # Must be declared on earlier strategy\n dependency:\n - cypress/integration/A02*\n```\n\n## Secrets template\n\nSecrets to store credentials. You can create a file named `.{base.secrets.name}.json` (remember to never commit this file on your Git repository) or export it as env variable like that `export base.secrets.name=$(cat yourSecretsFile.json)`.\n\n```json\n {\n \"vtex\": {\n \"apiKey\": \"\",\n \"apiToken\": \"\",\n \"authCookieName\": \"\",\n \"robotMail\": \"\",\n \"robotPassword\": \"\"\n },\n \"jira\": {\n \"authorization\": \"\"\n },\n \"cypress\": {\n \"dashboardKey\": \"\"\n }\n }\n```\nAt development mode you can use a file called `.[base.secrets.name].json`\n1. Remember to ignore this file on your Git\n2. You can add whatever secrets you want on it\n\n```" } ]