Skip to content

Commit 93baff9

Browse files
committed
Test zone pivots for api versions
1 parent 57c2214 commit 93baff9

File tree

3 files changed

+109
-5
lines changed

3 files changed

+109
-5
lines changed

articles/azure-app-configuration/rest-api-key-value.md

Lines changed: 94 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ author: maud-lv
55
ms.author: malev
66
ms.service: azure-app-configuration
77
ms.topic: reference
8-
ms.date: 08/17/2020
8+
ms.date: 07/23/2024
9+
zone_pivot_groups: data-plane-api-version
10+
911
---
1012

1113
# Key-values
1214

1315
A key-value is a resource identified by unique combination of `key` + `label`. `label` is optional. To explicitly reference a key-value without a label, use "\0" (URL encoded as ``%00``). See details for each operation.
1416

15-
This article applies to API version 1.0.
16-
1717
## Operations
1818

1919
- Get
@@ -109,6 +109,22 @@ HTTP/1.1 200 OK
109109
Optional: ``key`` (If not specified, it implies any key.)
110110
Optional: ``label`` (If not specified, it implies any label.)
111111

112+
:::zone target="docs" pivot="V23_11"
113+
Optional: ``tags`` (If not specified, it implies any tags.)
114+
115+
```http
116+
GET /kv?key=Test*&tags=tag1=value1&tags=tag2=value2&api-version={api-version} HTTP/1.1
117+
```
118+
119+
**Response:**
120+
121+
```http
122+
HTTP/1.1 200 OK
123+
Content-Type: application/vnd.microsoft.appconfig.kvset+json; charset=utf-8
124+
```
125+
:::zone-end
126+
127+
112128
```http
113129
GET /kv?label=*&api-version={api-version} HTTP/1.1
114130
```
@@ -122,6 +138,58 @@ Content-Type: application/vnd.microsoft.appconfig.kvset+json; charset=utf-8
122138

123139
For additional options, see the "Filtering" section later in this article.
124140

141+
142+
:::zone target="docs" pivot="V23_10"
143+
:::zone target="docs" pivot="V23_11"
144+
145+
146+
## List key-values (conditionally)
147+
148+
To improve client caching, use `If-Match` or `If-None-Match` request headers. The `etag` argument is part of the list key-values response body and header.
149+
If `If-Match` or `If-None-Match` are omitted, the operation is unconditional.
150+
151+
The following response gets the key-value only if the current representation matches the specified `etag`:
152+
153+
```http
154+
GET /kv?key={key}label={label}&api-version={api-version} HTTP/1.1
155+
If-Match: "4f6dd610dd5e4deebc7fbaef685fb903"
156+
```
157+
158+
**Responses:**
159+
160+
```http
161+
HTTP/1.1 412 PreconditionFailed
162+
```
163+
164+
or
165+
166+
```http
167+
HTTP/1.1 200 OK
168+
```
169+
170+
The following response gets the key-values only if the current representation doesn't match the specified `etag`:
171+
172+
```http
173+
GET /kv?key={key}label={label}&api-version={api-version} HTTP/1.1
174+
If-None-Match: "4f6dd610dd5e4deebc7fbaef685fb903"
175+
```
176+
177+
**Responses:**
178+
179+
```http
180+
HTTP/1.1 304 NotModified
181+
```
182+
183+
or
184+
185+
```http
186+
HTTP/1.1 200 OK
187+
```
188+
189+
:::zone-end
190+
:::zone-end
191+
192+
125193
## Pagination
126194

127195
The result is paginated if the number of items returned exceeds the response limit. Follow the optional `Link` response headers, and use `rel="next"` for navigation.
@@ -153,6 +221,16 @@ Link: <{relative uri}>; rel="next"
153221
A combination of `key` and `label` filtering is supported.
154222
Use the optional `key` and `label` query string parameters.
155223

224+
:::zone target="docs" pivot="V23_11"
225+
226+
For API Versions greater than `2023-11-01`, filtering by`tags` is also supported. Multiple tag filters can be provided as query string parameters in the `tagName=tagValue` format. Tag filters must be an exact match.
227+
228+
```http
229+
GET /kv?key={key}&label={label}&tags={tagFilter1}&tags={tagFilter2}&api-version={api-version}
230+
```
231+
232+
:::zone-end
233+
156234
```http
157235
GET /kv?key={key}&label={label}&api-version={api-version}
158236
```
@@ -174,6 +252,19 @@ GET /kv?key={key}&label={label}&api-version={api-version}
174252
|`label=prod*`|Matches labels that start with **prod**|
175253
|`label=prod,test`|Matches labels **prod** or **test** (limited to 5 CSV)|
176254

255+
:::zone target="docs" pivot="V23_11"
256+
257+
|Tags filter|Effect|
258+
|--|--|
259+
|`tags` is omitted or `tags=` |Matches **any** tag|
260+
|`tags=group=app1`|Matches KV where the tag name is `group` and tag value is `app1`|
261+
|`tags=group=app1&tags=env=prod`|Matches KV which contain at least 2 tags, where the tag names are `group` and `env` and tag values are `app1` and `prod` respectively (limited to 5 tag filters)|
262+
|`tags=tag1=%00`|Matches KV where the tag name is `tag1` and tag value is `null`|
263+
|`tags=tag1=`|Matches KV where the tag name is `tag1` and tag value is empty|
264+
265+
:::zone-end
266+
267+
177268
***Reserved characters***
178269

179270
`*`, `\`, `,`

articles/azure-app-configuration/rest-api-revisions.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@ For all operations, ``key`` is an optional parameter. If omitted, it implies any
1616

1717
For all operations, ``label`` is an optional parameter. If omitted, it implies any label.
1818

19-
This article applies to API version 1.0.
20-
2119
## Prerequisites
2220

2321
[!INCLUDE [azure-app-configuration-create](../../includes/azure-app-configuration-rest-api-prereqs.md)]

articles/zone-pivot-groups.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2914,6 +2914,21 @@ groups:
29142914
title: Stable release
29152915
- id: preview-version
29162916
title: Preview release
2917+
# Owner: avanigupta
2918+
- id: data-plane-api-version
2919+
title: API version pivots
2920+
prompt: Choose an API version
2921+
pivots:
2922+
- id: v1
2923+
title: "1.0"
2924+
- id: V22_11_preview
2925+
title: "2022-11-01-preview"
2926+
- id: V23_05_preview
2927+
title: "2023-05-01-preview"
2928+
- id: V23_10
2929+
title: "2023-10-01"
2930+
- id: V23_11
2931+
title: "2023-11-01"
29172932
# Owner: nicktrog
29182933
- id: load-testing-config
29192934
title: Experience

0 commit comments

Comments
 (0)