{"_id":"@albiyu/shopify-api","_rev":"1-c3b94d1377bcbcebbddf2b35559af50f","name":"@albiyu/shopify-api","dist-tags":{"latest":"0.0.2"},"versions":{"0.0.1":{"name":"@albiyu/shopify-api","version":"0.0.1","description":"Forkerd from Shopify API Library for Node (cookies samesite option changed) - accelerate development with support for authentication, graphql proxy, webhooks","main":"./lib/index.js","types":"./lib/index.d.ts","exports":{".":{"require":"./lib/index.js","types":"./lib/index.d.ts","default":"./lib/index.js"},"./rest/admin/*":{"import":"./rest/admin/*/index.js","require":"./rest/admin/*/index.js","types":"./rest/admin/*/index.d.ts"},"./runtime":{"import":"./runtime/index.js","require":"./runtime/index.js","types":"./runtime/index.d.ts"},"./adapters/node":{"import":"./adapters/node/index.js","require":"./adapters/node/index.js","types":"./adapters/node/index.d.ts"},"./adapters/cf-worker":{"import":"./adapters/cf-worker/index.js","require":"./adapters/cf-worker/index.js","types":"./adapters/cf-worker/index.d.ts"}},"prettier":"@shopify/prettier-config","scripts":{"test:all":"yarn pretest:adapters && jest && yarn posttest:adapters","test":"jest --selectProjects library","pretest:adapters":"yarn build && yarn rollup -c adapters/__e2etests__/rollup.test-cf-worker-app.config.js","posttest:adapters":"yarn clean","test:adapters":"jest --selectProjects adapters:mock adapters:node adapters:cf-worker","test:rest_resources":"jest --selectProjects rest_resources","lint":"jest --selectProjects lint","test:dev":"jest --selectProjects library lint","clean":"yarn tsc --build --clean","prebuild":"yarn tsc --build --clean","build":"tsc","release":"yarn build && changeset publish"},"publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/yusupova/shopify-api-js.git#same-site-cookies-none"},"bugs":{"url":"https://github.com/yusupova/shopify-api-js/issues"},"homepage":"https://github.com/yusupova/shopify-api-js/tree/same-site-cookies-none","author":{"name":"Shopify Inc."},"license":"MIT","keywords":["shopify","node","jwt","app","graphql","rest","webhook","Admin API","Storefront API"],"resolutions":{"node-fetch":"^2.6.7"},"dependencies":{"@shopify/network":"^1.5.1","@types/node-fetch":"^2.5.7","@types/supertest":"^2.0.10","jose":"^4.9.1","node-fetch":"^2.6.1","semver":"^7.3.8","tslib":"^2.0.3","uuid":"^9.0.0"},"devDependencies":{"@changesets/cli":"^2.26.0","@cloudflare/workers-types":"^3.16.0","@rollup/plugin-alias":"^3.1.9","@rollup/plugin-commonjs":"^22.0.2","@rollup/plugin-node-resolve":"^14.1.0","@shopify/eslint-plugin":"^42.0.1","@shopify/prettier-config":"^1.1.2","@swc/core":"^1.3.3","@types/express":"^4.17.13","@types/jest":"^26.0.15","@types/node":"^14.18.12","@types/semver":"^7.3.12","@types/uuid":"^9.0.0","eslint":"^7.30.0","eslint-plugin-prettier":"^4.0.0","express":"^4.17.13","jest":"^29.1.2","jest-environment-miniflare":"^2.6.0","jest-fetch-mock":"^3.0.3","jest-runner-eslint":"^1.0.1","miniflare":"^2.6.0","prettier":"^2.5.1","rollup":"^2.79.1","rollup-plugin-swc":"^0.2.1","supertest":"^6.1.3","ts-jest":"^29.0.3","ts-node":"^10.9.1","typescript":"^4.6.3"},"licenseText":"MIT License\n\nCopyright (c) 2020-present, Shopify Inc.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n","_id":"@albiyu/shopify-api@0.0.1","dist":{"shasum":"7d7121778f768434ff3077e5f7a8f05bc7f3e7c2","integrity":"sha512-vb6Y8jEUcvEUQzpsGzl0FWap+miJlDQxMXS/YpQz+Vw28t7vrWAqQjDm9mw+9UiDyhgROI3E77xEl+eXLYKv9w==","tarball":"https://registry.npmjs.org/@albiyu/shopify-api/-/shopify-api-0.0.1.tgz","fileCount":1035,"unpackedSize":11196273,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEVk63hvCOXwWKb/ZH6LaM5lz4ySFYphwygmhDs8ezjlAiEA9Zix6DON9eq+7yqGLHK0Gg0Vi1oF4lWNzbvR/EVy5Sc="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj+iejACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqEAQ//VFtv5nAn+zG4HREtrEQPtTq2mZbbhee49mj1Bsxzc00b7RGO\r\n2oBInpmEOy1Pa/dSMUepbiudEoRIVZ2jSBYB7MKIpUBt1gNOkywiiseJbYXx\r\np8RVA33SuSivI2xdp7TzQcSdtVC3NQhsurwhxnueYfoIEqCKtEmJC8YG7mG5\r\nwBT3Y2+GkI2JqwgGPjXSThp4rs7om6Iw4xTeB2d9dj0aJXFz0eZEgWF5aRDy\r\nLMzUXRzrGm02/Qzhr5zanox9jAOo84GuSe0g20nuhDZI8xto8VKLLmk1MEyi\r\nKuSJhb7zeFW0ToMHZYDOobV1qeY8MmGQ64faXNEnfdKHIVkxnQOLKrPLefPp\r\n5JhAB0CT2/AnF88LvCO58LoIIFht0sWtrFjAS1fCrV9So6UkAuClGyciX681\r\n3DiOTIkpAJ/4n1u8txJ+tWYR6GW6TY2FgJsqu3moIkodWXKxe7mFNpB2o+/D\r\nWcTZNw1Q16tT28W3SHq6q8TJiOfnMPwtL5G/nTAgj0iG6jugb/sDxzPglSOc\r\nim9BW+nLIQE/relTogRKs+MTZcK+hhwRr7cjSHEtzNeAd8RsrGRMLKV4VZze\r\nJKlA4rax2KoFT1PrP/g/ttYIWtv8bCe6EYdaw6PqnNewdo07i9DdfyG/T7oo\r\n6pxJoeN/eWxQ68vO3aSAhlb5qauIZR6C/cE=\r\n=wmwo\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"yualbi","email":"yusupova.albina@gmail.com"},"directories":{},"maintainers":[{"name":"yualbi","email":"yusupova.albina@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/shopify-api_0.0.1_1677338531645_0.21605442435311928"},"_hasShrinkwrap":false},"0.0.2":{"name":"@albiyu/shopify-api","version":"0.0.2","description":"Forkerd from Shopify API Library for Node (cookies samesite option changed) - accelerate development with support for authentication, graphql proxy, webhooks","main":"./lib/index.js","types":"./lib/index.d.ts","exports":{".":{"require":"./lib/index.js","types":"./lib/index.d.ts","default":"./lib/index.js"},"./rest/admin/*":{"import":"./rest/admin/*/index.js","require":"./rest/admin/*/index.js","types":"./rest/admin/*/index.d.ts"},"./runtime":{"import":"./runtime/index.js","require":"./runtime/index.js","types":"./runtime/index.d.ts"},"./adapters/node":{"import":"./adapters/node/index.js","require":"./adapters/node/index.js","types":"./adapters/node/index.d.ts"},"./adapters/cf-worker":{"import":"./adapters/cf-worker/index.js","require":"./adapters/cf-worker/index.js","types":"./adapters/cf-worker/index.d.ts"}},"prettier":"@shopify/prettier-config","scripts":{"test:all":"yarn pretest:adapters && jest && yarn posttest:adapters","test":"jest --selectProjects library","pretest:adapters":"yarn build && yarn rollup -c adapters/__e2etests__/rollup.test-cf-worker-app.config.js","posttest:adapters":"yarn clean","test:adapters":"jest --selectProjects adapters:mock adapters:node adapters:cf-worker","test:rest_resources":"jest --selectProjects rest_resources","lint":"jest --selectProjects lint","test:dev":"jest --selectProjects library lint","clean":"yarn tsc --build --clean","prebuild":"yarn tsc --build --clean","build":"tsc","release":"yarn build && changeset publish"},"publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/yusupova/shopify-api-js.git#same-site-cookies-none"},"bugs":{"url":"https://github.com/yusupova/shopify-api-js/issues"},"homepage":"https://github.com/yusupova/shopify-api-js/tree/same-site-cookies-none","author":{"name":"Shopify Inc."},"license":"MIT","keywords":["shopify","node","jwt","app","graphql","rest","webhook","Admin API","Storefront API"],"resolutions":{"node-fetch":"^2.6.7"},"dependencies":{"@shopify/network":"^1.5.1","@types/node-fetch":"^2.5.7","@types/supertest":"^2.0.10","jose":"^4.9.1","node-fetch":"^2.6.1","semver":"^7.3.8","tslib":"^2.0.3","uuid":"^9.0.0"},"devDependencies":{"@changesets/cli":"^2.26.0","@cloudflare/workers-types":"^3.16.0","@rollup/plugin-alias":"^3.1.9","@rollup/plugin-commonjs":"^22.0.2","@rollup/plugin-node-resolve":"^14.1.0","@shopify/eslint-plugin":"^42.0.1","@shopify/prettier-config":"^1.1.2","@swc/core":"^1.3.3","@types/express":"^4.17.13","@types/jest":"^26.0.15","@types/node":"^14.18.12","@types/semver":"^7.3.12","@types/uuid":"^9.0.0","eslint":"^7.30.0","eslint-plugin-prettier":"^4.0.0","express":"^4.17.13","jest":"^29.1.2","jest-environment-miniflare":"^2.6.0","jest-fetch-mock":"^3.0.3","jest-runner-eslint":"^1.0.1","miniflare":"^2.6.0","prettier":"^2.5.1","rollup":"^2.79.1","rollup-plugin-swc":"^0.2.1","supertest":"^6.1.3","ts-jest":"^29.0.3","ts-node":"^10.9.1","typescript":"^4.6.3"},"gitHead":"0008fc0145d50ddf40a1afe0bdb7c4e2070662b9","_id":"@albiyu/shopify-api@0.0.2","_nodeVersion":"16.14.0","_npmVersion":"9.4.1","dist":{"integrity":"sha512-HR/ztMEHVu9mWldzZMrO+EI9r92DVWMwNWmBpDdT7ZTqj7oBbZVUZMXpcQ1O0tSMlwE59L8wvOzOlYjKOwKH/A==","shasum":"49f2f00d4821297789962d5bc4b5027fcc1f7a4d","tarball":"https://registry.npmjs.org/@albiyu/shopify-api/-/shopify-api-0.0.2.tgz","fileCount":1859,"unpackedSize":4352485,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFwytOnyF2M3GyTauvWOSFWt9/4Na2rQ/ac1bz4efD+LAiEAxYM5No9nyn6prFYJ7+hHYMiv+T5zTqxpRyug6o8VCqg="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj+jo8ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpI4g//WWG75EpW+8BN6I4dhF6BNy9y28e+vxPI3b0hMO+kOwKddZpE\r\nj0PjxWv1iTe3amj1qpn0vKNIHWq4Js3xwqPMhZlXdYElUTyKlb+Md+AhQbo0\r\ngJgvBUt7XkCPmcw6kPJu6Th8/LbHjrHPOYGNBfpemDjGNV01pZn+sgfaY0p8\r\n9V4/zia9ytsviypggEytt/KeL/JHyn/UYWDaqYEepTWa4jnsE/wc52SgcfjV\r\nnmoS6RcKlmIB1D/iWQJkIXGpFAQdxINOxG1MDGP8vFqfYCxitXwVTct63fn8\r\nrgHtioSVKugXHXUXlgjY45wkA99uJGIXx9Bg3IjF5/u3J108Vo9fyOwC67yj\r\nQdEgXhTxToRyScHvdEaTNXzafkJBRbzWo8dLi0eUMAqgwX4i1Et89y1UWOGW\r\nQrgM3nLduhVnLY67VZcJv+YGoxMq1XaAzqfNIemYSrzDUzDcGaMo7fkamH8K\r\nit+XhaY8VCtvnoIU6Ih8EsrkTcp2QYxLMUJccYM8r2T2IxG+R6LjJohO/+jd\r\nmhkRfLuUScJm77v2TyDyFQOVIXTjxMargbxh4EiqRgSQ/mA0qdpz+Ty/ZEPL\r\nS+RvILHDF1+C63CtCzulxSN6vQCuczwjTay4FxDIPg7L2U2ChmeLrsSqiZ9s\r\nrUOKuJjGy9CwnNS6EYP0wMoVlYWpvtwEj7c=\r\n=Hm+j\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"yualbi","email":"yusupova.albina@gmail.com"},"directories":{},"maintainers":[{"name":"yualbi","email":"yusupova.albina@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/shopify-api_0.0.2_1677343292188_0.9671734332186164"},"_hasShrinkwrap":false}},"time":{"created":"2023-02-25T15:22:11.466Z","0.0.1":"2023-02-25T15:22:11.851Z","modified":"2023-02-25T16:41:32.594Z","0.0.2":"2023-02-25T16:41:32.405Z"},"maintainers":[{"name":"yualbi","email":"yusupova.albina@gmail.com"}],"description":"Forkerd from Shopify API Library for Node (cookies samesite option changed) - accelerate development with support for authentication, graphql proxy, webhooks","homepage":"https://github.com/yusupova/shopify-api-js/tree/same-site-cookies-none","keywords":["shopify","node","jwt","app","graphql","rest","webhook","Admin API","Storefront API"],"repository":{"type":"git","url":"git+https://github.com/yusupova/shopify-api-js.git#same-site-cookies-none"},"author":{"name":"Shopify Inc."},"bugs":{"url":"https://github.com/yusupova/shopify-api-js/issues"},"license":"MIT","readme":"# `@albiyu/shopify-api`\n\n<!-- ![Build Status]() -->\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](LICENSE.md)\n[![npm version](https://badge.fury.io/js/%40albiyu%2Fshopify-api.svg)](https://badge.fury.io/js/%40albiyu%2Fshopify-api)\n\nThis library is a fork of [@shopify/shopify-api-js](https://www.npmjs.com/package/@shopify/shopify-api).\nThe main change is to set `sameSite` cookies options to `none` during OAuth methods.\n\nThis library provides support for the backends of TypeScript/JavaScript [Shopify](https://www.shopify.com) apps to access the [Shopify Admin API](https://shopify.dev/docs/api/admin), by making it easier to perform the following actions:\n\n- Creating [online](https://shopify.dev/docs/apps/auth#online-access) or [offline](https://shopify.dev/docs/apps/auth#offline-access) access tokens for the Admin API via OAuth\n- Making requests to the [REST API](https://shopify.dev/docs/api/admin/rest/reference)\n- Making requests to the [GraphQL API](https://shopify.dev/docs/api/admin/graphql/reference)\n- Register/process webhooks\n\nOnce your app has access to the Admin API, you can also access the [Shopify Storefront API](https://shopify.dev/docs/api/storefront) to run GraphQL queries using the `unauthenticated_*` access scopes.\n\nThis library can be used in any application that runs on one of the supported runtimes. It doesn't rely on any specific framework, so you can include it alongside your preferred stack and only use the features that you need to build your app.\n\n**Note**: this package will enable your app's backend to work with Shopify APIs, but you'll need to use [Shopify App Bridge](https://shopify.dev/docs/apps/tools/app-bridge) in your frontend if you're planning on embedding your app into the Shopify Admin.\n\n## Requirements\n\nTo follow these usage guides, you will need to:\n\n- have a basic understanding of [TypeScript](https://www.typescriptlang.org/)\n- have a Shopify Partner account and development store\n- _OR_ have a test store where you can create a private app\n- have a private or custom app already set up in your test store or partner account\n- use [ngrok](https://ngrok.com), in order to create a secure tunnel to your app running on your localhost\n- add the `ngrok` URL and the appropriate redirect for your OAuth callback route to your app settings\n- have a JavaScript package manager such as [yarn](https://yarnpkg.com) installed\n\n## Getting started\n\nTo install this package, you can run this on your terminal:\n\n```bash\n# You can use your preferred Node package manager\nyarn add @shopify/shopify-api\n```\n\n**Note**: throughout these docs, we'll provide some examples of how this library may be used in an app using the [Express.js](https://expressjs.com/) framework for simplicity, but you can use it with any framework you prefer, as mentioned before.\n\nThe first thing you need to import is the adapter for your app's runtime. This will internally set up the library to use the right defaults and behaviours for the runtime.\n\n<div>Node.js\n\n```ts\nimport '@shopify/shopify-api/adapters/node';\n```\n\n</div><div>CloudFlare Worker\n\n```ts\nimport '@shopify/shopify-api/adapters/cf-worker';\n```\n\n</div>\n\nNext, configure the library - you'll need some values in advance:\n\n- Your app's API key from [Partners dashboard](https://www.shopify.com/partners)\n- Your app's API secret from Partners dashboard\n- The [scopes](https://shopify.dev/docs/api/usage/access-scopes) you need for your app\n\nCall `shopifyApi` ([see reference](./docs/reference/shopifyApi.md)) to create your library object before setting up your app itself:\n\n```ts\nimport '@shopify/shopify-api/adapters/node';\nimport {shopifyApi, LATEST_API_VERSION} from '@shopify/shopify-api';\nimport express from 'express';\n\nconst shopify = shopifyApi({\n  // The next 4 values are typically read from environment variables for added security\n  apiKey: 'APIKeyFromPartnersDashboard',\n  apiSecretKey: 'APISecretFromPartnersDashboard',\n  scopes: ['read_products'],\n  hostName: 'ngrok-tunnel-address',\n  ...\n});\n\nconst app = express();\n```\n\n### Next steps\n\nOnce you configure your app, you can use this package to access the Shopify APIs.\nSee the [reference documentation](./docs/reference/README.md) for details on all the methods provided by this package.\n\nSee the specific documentation in the [Guides section](#guides) for high-level instructions on how to get API access tokens and use them to query the APIs.\n\nAs a general rule, apps will want to interact with the Admin API to fetch / submit data to Shopify.\nTo do that, apps will need to:\n\n1. Create an Admin API access token by going through [the OAuth flow](docs/guides/oauth.md).\n1. Set up its own endpoints to:\n   1. [Fetch the current session](docs/guides/oauth.md#using-sessions) created in the OAuth process.\n   1. Create a [REST](docs/reference/clients/Rest.md) or [GraphQL](docs/reference/clients/Graphql.md) API client.\n   1. Use the client to query the appropriate [Admin API](https://shopify.dev/api/admin).\n\n## Guides\n\n- [Performing OAuth](docs/guides/oauth.md)\n- [Storing sessions](docs/guides/session-storage.md)\n- [Setting up webhooks](docs/guides/webhooks.md)\n- [Using REST resources](docs/guides/rest-resources.md)\n- [Configuring Billing](docs/guides/billing.md)\n- [Adding custom runtimes](docs/guides/runtimes.md)\n- [Customizing logging configuration](docs/guides/logger.md)\n- [Setting up a custom store app](docs/guides/custom-store-app.md)\n\n## Migrating to v6\n\nBefore v6, this library only worked on Node.js runtimes. It now supports multiple runtimes through the use of adapters, more of which can be added over time.\nIf an adapter for the runtime you wish to use doesn't exist, you can create your own adapter by implementing some key functions, or contribute a PR to this repository.\n\nIn addition to updating the library to work on different runtimes, we've also improved its public interface to make it easier for apps to load only the features they need from the library.\nIf you're upgrading an existing app on v5 or earlier, please see [the migration guide for v6](docs/migrating-to-v6.md).\n","readmeFilename":"README.md"}