Skip to content

Commit e958e28

Browse files
authored
Update index.mdx
1 parent 38e2d7a commit e958e28

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

src/content/docs/kv/index.mdx

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,19 +38,19 @@ Access your Workers KV namespace from Cloudflare Workers using the Workers Bindi
3838
export default {
3939
async fetch(request, env, ctx): Promise<Response> {
4040

41-
//write a key-value pair
41+
// write a key-value pair
4242
await env.KV_BINDING.put('KEY', 'VALUE');
4343

4444
// read a key-value pair
4545
const value = await env.KV_BINDING.get('KEY');
4646

47-
//list all key-value pairs
47+
// list all key-value pairs
4848
const allKeys = await env.KV_BINDING.list();
4949

50-
//delete a key-value pair
50+
// delete a key-value pair
5151
await env.KV_BINDING.delete('KEY');
5252

53-
//return a Workers response
53+
// return a Workers response
5454
return new Response(
5555
JSON.stringify({
5656
value: value,
@@ -82,6 +82,8 @@ Access your Workers KV namespace from Cloudflare Workers using the Workers Bindi
8282
```
8383
</TabItem>
8484
</Tabs>
85+
86+
Learn more about using [Workers KV's binding](/kv/concepts/kv-bindings/ from [Cloudflare Workers](/workers) with the full [binding API reference](/kv/api/read-key-value-pairs/).
8587
</TabItem>
8688
<TabItem label="REST API">
8789
```
@@ -98,10 +100,12 @@ curl https://api.cloudflare.com/client/v4/accounts/$ACCOUNT_ID/storage/kv/namesp
98100
-H "X-Auth-Email: $CLOUDFLARE_EMAIL" \
99101
-H "X-Auth-Key: $CLOUDFLARE_API_KEY"
100102
```
103+
104+
Learn more about using Workers KV's REST API from external services with the full [REST API reference](/api/resources/kv/subresources/namespaces/methods/list/).
101105
</TabItem>
102106
</Tabs>
103107

104-
Learn more about Workers KV [key concepts](/kv/concepts/how-kv-works/), or [get started](/kv/get-started/) with a Workers project.
108+
Learn more about Workers KV [key concepts](/kv/concepts/how-kv-works/), or [get started](/kv/get-started/) with a [Cloudflare Workers](/workers) project.
105109

106110
---
107111

0 commit comments

Comments
 (0)