You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/pages/en/deploying/deploying-a-subgraph-to-studio.mdx
+16-16Lines changed: 16 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,26 +11,26 @@ Learn how to deploy your subgraph in Subgraph Studio.
11
11
In [Subgraph Studio](https://thegraph.com/studio/), you can do the following:
12
12
13
13
- Create and manage your API keys for specific subgraphs
14
-
- Create your subgraph through Studio UI
15
-
- Deploy your subgraph using the CLI
14
+
- Create your subgraph through the Studio UI
15
+
- Deploy your subgraph using the The Graph CLI
16
16
- Publish your subgraph with the Studio UI
17
17
- Stage your subgraph in the playground environment
18
18
- Integrate your subgraph in staging using the query URL
19
19
- Restrict your API keys to specific domains and allow only certain Indexers to query with them
20
20
21
-
In [Subgraph Studio](https://thegraph.com/studio/), you can view the following:
21
+
You can also view the following:
22
22
23
23
- Your user account controls
24
24
- A list of subgraphs you've created
25
25
- A section to manage your API keys
26
26
- A section to manage, view details, and visualize the status of a specific subgraph
27
27
- A section to manage your billing
28
28
29
-
## Install the Graph CLI
29
+
## Install The Graph CLI
30
30
31
31
Before deploying, you must install The Graph CLI.
32
32
33
-
You must have [Node.js](https://nodejs.org/) and a package manager of your choice (`npm`, `yarn` or `pnpm`) installed to use the Graph CLI. Check for the [most recent](https://github.com/graphprotocol/graph-tooling/releases?q=%40graphprotocol%2Fgraph-cli&expanded=true) CLI version.
33
+
You must have [Node.js](https://nodejs.org/) and a package manager of your choice (`npm`, `yarn` or `pnpm`) installed to use The Graph CLI. Check for the [most recent](https://github.com/graphprotocol/graph-tooling/releases?q=%40graphprotocol%2Fgraph-cli&expanded=true) CLI version.
34
34
35
35
**Install with yarn:**
36
36
@@ -56,13 +56,13 @@ Before deploying your subgraph you need to create a subgraph in [Subgraph Studio
56
56
3. After you sign in, your unique deploy key will be displayed on your account home page.
57
57
- 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.
58
58
59
-
> Important: You need API keys to query subgraphs
59
+
> Important: You need an API key to query subgraphs
60
60
61
61
#### How to Create a Subgraph in Subgraph Studio
62
62
63
63
<VideoEmbedyoutube="nGIFuC69bSA" />
64
64
65
-
> For additional written detail, review the [quick-start](/quick-start/)
65
+
> For additional written detail, review the [Quick-Start](/quick-start/).
66
66
67
67
#### Subgraph Compatibility with The Graph Network
68
68
@@ -76,7 +76,7 @@ In order to be supported by Indexers on The Graph Network, subgraphs must:
76
76
77
77
## Initialize your Subgraph
78
78
79
-
Once your subgraph has been created in Subgraph Studio, you can initialize the subgraph code through the CLI using this command:
79
+
Once your subgraph has been created in Subgraph Studio, you can initialize its code through the CLI using this command:
80
80
81
81
```bash
82
82
graph init --studio <SUBGRAPH_SLUG>
@@ -90,7 +90,7 @@ After running `graph init`, you will be asked to input the contract address, net
90
90
91
91
## Graph Auth
92
92
93
-
Before you can deploy your subgraph to Subgraph Studio, you need to login into your account within the CLI. To do this, you will need your deploy key, which you can find on your "My Subgraphs" page or under your subgraph details page.
93
+
Before you can deploy your subgraph to Subgraph Studio, you need to login into your account within the CLI. To do this, you will need your deploy key, which you can find under your subgraph details page.
94
94
95
95
Then, use the following command to authenticate from the CLI:
After running this command, the CLI will ask for a version label.
114
114
115
-
- It's strongly recommended to use [semver](https://semver.org/) for versioning like `0.0.1`. That said, you are free to choose any string as version such as:`v1`, `version1`, `asdf`.
115
+
- It's strongly recommended to use [semver](https://semver.org/) for versioning like `0.0.1`. That said, you are free to choose any string as version such as`v1`, `version1`, or`asdf`.
116
116
- The labels you create will be visible in Graph Explorer and can be used by curators to decide if they want to signal on a specific version or not, so choose them wisely.
117
117
118
118
## Testing your Subgraph
119
119
120
-
After deploying, you can test/stage your subgraph in Subgraph Studio, deploy another version, update the metadata, and publish to [Graph Explorer](https://thegraph.com/explorer) when you are ready.
120
+
After deploying, you can test/stage 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](https://thegraph.com/explorer) when you are ready.
121
121
122
122
Use Subgraph Studio’s playground to check your subgraph logs and see where a subgraph fails.
123
123
@@ -129,18 +129,18 @@ In order to publish your subgraph successfully, review [publishing a subgraph](/
129
129
130
130
If you want to update your subgraph, you can do the following:
131
131
132
-
- You can deploy a new version to the Studio using the CLI (it will only be private at this point).
132
+
- You can deploy a new version to Studio using the CLI (it will only be private at this point).
133
133
- Once you're happy with it, you can publish your new deployment to [Graph Explorer](https://thegraph.com/explorer).
134
134
- This action will create a new version of your subgraph that curators can start signaling on and Indexers can index.
135
135
136
-
You can also update your subgraphs' metadata without publishing a new version. You can update your subgraph details in the Studio (under the profile picture, name, description, etc.) by checking an option called **Update Details** in Graph Explorer. If this is checked, an on-chain transaction will be generated that updates subgraph details in the Explorer without having to publish a new version with a new deployment.
136
+
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 on-chain transaction will be generated that updates subgraph details in Explorer without having to publish a new version with a new deployment.
137
137
138
-
> 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 on the risks of curation, please read more [here](/network/curating/).
138
+
> 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 on the risks of curation, please read more [here](/network/curating/).
139
139
140
140
## Automatic Archiving of Subgraph Versions
141
141
142
-
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 the Studio UI.
142
+
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 Studio UI.
143
143
144
-
> Note: Previous versions of non-published subgraphs deployed to the Studio will be automatically archived.
144
+
> Note: Previous versions of non-published subgraphs deployed to Studio will be automatically archived.
145
145
146
146

0 commit comments