Docs
Arama⌘ K
  • Ana sayfa
  • Graph Hakkında
  • Desteklenen Ağlar
  • Protocol Contracts
  • Subgraph'ler
    • Substream'ler
      • Token API
        • AI Suite
          • Endeksleme
            • Kaynaklar
              Subgraph'ler > Geliştirme > Dağıtma

              5 dakika

              Deploying Using Subgraph Studio

              Learn how to deploy your Subgraph to Subgraph Studio.

              Note: When you deploy a Subgraph, you push it to Subgraph Studio, where you’ll be able to test it. It’s important to remember that deploying is not the same as publishing. When you publish a Subgraph, you’re publishing it onchain.

              Subgraph Studio’ya Genel Bakış

              Subgraph Studio’da aşağıdakileri yapabilirsiniz:

              • View a list of Subgraphs you’ve created
              • Manage, view details, and visualize the status of a specific Subgraph
              • Create and manage your API keys for specific Subgraphs
              • API anahtarlarınızı belirli alanlara sınırlamak ve yalnızca belirli Endeksleyicilerin bu anahtarlarla sorgulama yapmasına izin vermek
              • Create your Subgraph
              • Deploy your Subgraph using The Graph CLI
              • Test your Subgraph in the playground environment
              • Integrate your Subgraph in staging using the development query URL
              • Publish your Subgraph to The Graph Network
              • Faturalarınızı yönetmek

              The Graph CLI’yi Yükleme

              Dağıtmadan önce The Graph CLI’yi yüklemeniz gerekmektedir.

              The Graph CLI’yi kullanmak için bilgisayarınızda Node.js⁠ ve tercih ettiğiniz bir paket yöneticisi (npm, yarn veya pnpm) kurulu olmalıdır. CLI’ın en son⁠ sürümünü kontrol edin.

              yarn ile kurulum

              1yarn global add @graphprotocol/graph-cli

              npm ile kurulum

              1npm install -g @graphprotocol/graph-cli

              Başlayalım

              1. Subgraph Studio’yu açın.
              2. Giriş yapmak için cüzdanınızı bağlayın.
                • Cüzdan bağlamak için MetaMask, Conbase Wallet, WalletConnect ya da Safe kullanabilirsiniz.
              3. After you sign in, your unique deploy key will be displayed on your Subgraph details page.
                • The deploy key allows you to publish your Subgraphs or manage your API keys and billing. It is unique but can be regenerated if you think it has been compromised.

              Important: You need an API key to query Subgraphs

              Subgraph Stüdyo’da Subgraph Nasıl Oluşturulur

              How to Deploy a Subgraph - A Step-By-Step Walkthrough

              For additional written detail, review the Quick Start.

              The Graph Ağı ile Subgraph Uyumluluğu

              To be supported by Indexers on The Graph Network, Subgraphs must index a supported network. For a full list of supported and unsupported features, check out the Feature Support Matrix⁠ repo.

              Subgraph’inizi İlklendirme

              Once your Subgraph has been created in Subgraph Studio, you can initialize its code through the CLI using this command:

              1graph init <SUBGRAPH_SLUG>

              You can find the <SUBGRAPH_SLUG> value on your Subgraph details page in Subgraph Studio, see image below:

              Subgraph Studio - Slug

              After running graph init, you will be asked to input the contract address, network, and an ABI that you want to query. This will generate a new folder on your local machine with some basic code to start working on your Subgraph. You can then finalize your Subgraph to make sure it works as expected.

              Graph Auth

              Before you can deploy your Subgraph to Subgraph Studio, you need to log into your account within the CLI. To do this, you will need your deploy key, which you can find under your Subgraph details page.

              CLI üzerinden kimlik doğrulaması yapmak için aşağıdaki komutu kullanın:

              1graph auth <DEPLOY KEY>

              Bir Subgraph’i Dağıtma

              Once you are ready, you can deploy your Subgraph to Subgraph Studio.

              Deploying a Subgraph with the CLI pushes it to the Studio, where you can test it and update the metadata. This action won’t publish your Subgraph to the decentralized network.

              Use the following CLI command to deploy your Subgraph:

              1graph deploy <SUBGRAPH_SLUG>

              Bu komutu çalıştırdıktan sonra CLI sizden bir sürüm etiketi isteyecektir.

              • Sürüm etiketlemede semver⁠ (örn. 0.0.1) kullanmanız tavsiye edilir. Ancak v1, version1 veya asfdf gibi başka bir dize de seçebilirsiniz.
              • Oluşturduğunuz etiketler Graph Gezgini’nde görünür olacak. Küratörler bu etiketlere göre belirli bir sürüme sinyal verip vermemeyi kararlaştırabilirler; bu nedenle seçimlerinizi dikkatle yapın.

              Subgraph’inizi Test Etme

              After deploying, you can test your Subgraph (either in Subgraph Studio or in your own app, with the deployment query URL), deploy another version, update the metadata, and publish to Graph Explorer when you are ready.

              Use Subgraph Studio to check the logs on the dashboard and look for any errors with your Subgraph.

              Subgraph’inizi Yayımlama

              In order to publish your Subgraph successfully, review publishing a Subgraph.

              CLI ile Subgraph’inizi Sürümleme

              If you want to update your Subgraph, you can do the following:

              • CLI kullanarak Studio’da yeni bir sürüm dağıtabilirsiniz (bu sürüm yalnızca özel olarak kalacaktır).
              • Memnun kaldığınızda, yeni dağıtımınızı Graph Gezgini’nde yayımlayabilirsiniz.
              • This action will create a new version of your Subgraph that Curators can start signaling on and Indexers can index.

              You can also update your Subgraph’s metadata without publishing a new version. You can update your Subgraph details in Studio (under the profile picture, name, description, etc.) by checking an option called Update Details in Graph Explorer. If this is checked, an onchain transaction will be generated that updates Subgraph details in Explorer without having to publish a new version with a new deployment.

              Note: There are costs associated with publishing a new version of a Subgraph to the network. In addition to the transaction fees, you must also fund a part of the curation tax on the auto-migrating signal. You cannot publish a new version of your Subgraph if Curators have not signaled on it. For more information, please read more here.

              Subgraph Sürümlerinin Otomatik Arşivlenmesi

              Whenever you deploy a new Subgraph version in Subgraph Studio, the previous version will be archived. Archived versions won’t be indexed/synced and therefore cannot be queried. You can unarchive an archived version of your Subgraph in Subgraph Studio.

              Note: Previous versions of non-published Subgraphs deployed to Studio will be automatically archived.

              Subgraph Studio - Arşivden Çıkarma
              ⁠GitHub'da Düzenle⁠

              Birim Testi Framework'üDeploying to Multiple Networks
              Bu sayfada
              • Subgraph Studio’ya Genel Bakış
              • The Graph CLI’yi Yükleme
              • yarn ile kurulum
              • npm ile kurulum
              • Başlayalım
              • Subgraph Stüdyo’da Subgraph Nasıl Oluşturulur
              • The Graph Ağı ile Subgraph Uyumluluğu
              • Subgraph’inizi İlklendirme
              • Graph Auth
              • Bir Subgraph’i Dağıtma
              • Subgraph’inizi Test Etme
              • Subgraph’inizi Yayımlama
              • CLI ile Subgraph’inizi Sürümleme
              • Subgraph Sürümlerinin Otomatik Arşivlenmesi
              The GraphStatusTestnetBrand AssetsForumSecurityPrivacy PolicyTerms of Service