Skip to content

Commit a812f48

Browse files
Page-vipulgupta2048
authored andcommitted
Change overview to point at v6 rather than v5
Change-type: patch
1 parent 4897088 commit a812f48

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

pages/reference/api/overview.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,15 @@ To construct an API call, it helps to understand a little about how the underlyi
3232
Knowing the resource you wish to act upon and the method you wish to act with is enough for some requests. For example, if you want to view all fleets you have access to (which includes public fleets), you can use the `GET` method and the `application` resource. Your API call would look like this:
3333

3434
```shell
35-
curl -X GET "{{ $links.apiBase }}/v5/application" \
35+
curl -X GET "{{ $links.apiBase }}/v6/application" \
3636
-H "Content-Type: application/json" \
3737
-H "Authorization: Bearer <AUTH_TOKEN>"
3838
```
3939

4040
If you want to limit this to only return fleets related to the authenticated user, use the `my_application` resource. For example:
4141

4242
```shell
43-
curl -X GET "{{ $links.apiBase }}/v5/my_application" \
43+
curl -X GET "{{ $links.apiBase }}/v6/my_application" \
4444
-H "Content-Type: application/json" \
4545
-H "Authorization: Bearer <AUTH_TOKEN>"
4646
```
@@ -53,31 +53,31 @@ The following API call uses `$select` to only return the name and device type fo
5353

5454
```shell
5555
curl -X GET
56-
"{{ $links.apiBase }}/v5/application?\$select=app_name,device_type" \
56+
"{{ $links.apiBase }}/v6/application?\$select=app_name,device_type" \
5757
-H "Content-Type: application/json" \
5858
-H "Authorization: Bearer <AUTH_TOKEN>"
5959
```
6060

6161
In some cases, you'll want to get information for one specific resource, rather than all resources of that type. If you happen to know the resource ID, you can simply append it to the resource name:
6262

6363
```shell
64-
curl -X GET "{{ $links.apiBase }}/v5/device(<ID>)" \
64+
curl -X GET "{{ $links.apiBase }}/v6/device(<ID>)" \
6565
-H "Content-Type: application/json" \
6666
-H "Authorization: Bearer <AUTH_TOKEN>"
6767
```
6868

6969
This also works for other pieces of unique information as long as you specify them, eg the device uuid for devices:
7070

7171
```shell
72-
curl -X GET "{{ $links.apiBase }}/v5/device(uuid='<UUID>')" \
72+
curl -X GET "{{ $links.apiBase }}/v6/device(uuid='<UUID>')" \
7373
-H "Content-Type: application/json" \
7474
-H "Authorization: Bearer <AUTH_TOKEN>"
7575
```
7676

7777
or for resources where multiple elements combine to be unique, eg for device tags the device and tag key are a unique combination:
7878

7979
```shell
80-
curl -X GET "{{ $links.apiBase }}/v5/device(device=<DEVICE ID>,tag_key='<KEY>')" \
80+
curl -X GET "{{ $links.apiBase }}/v6/device(device=<DEVICE ID>,tag_key='<KEY>')" \
8181
-H "Content-Type: application/json" \
8282
-H "Authorization: Bearer <AUTH_TOKEN>"
8383
```
@@ -87,7 +87,7 @@ Many times, however, you won't know the internal ID or other unique info used by
8787

8888
```shell
8989
curl -X GET \
90-
"{{ $links.apiBase }}/v5/device?\$filter=name%20eq%20'<DEVICE NAME>'" \
90+
"{{ $links.apiBase }}/v6/device?\$filter=name%20eq%20'<DEVICE NAME>'" \
9191
-H "Content-Type: application/json" \
9292
-H "Authorization: Bearer <AUTH_TOKEN>"
9393
```
@@ -98,7 +98,7 @@ A final tip for constructing API calls: for some of the fields in the API respon
9898

9999
```shell
100100
curl -X GET \
101-
"{{ $links.apiBase }}/v5/device(uuid='<UUID>')?\$expand=belongs_to__application" \
101+
"{{ $links.apiBase }}/v6/device(uuid='<UUID>')?\$expand=belongs_to__application" \
102102
-H "Content-Type: application/json" \
103103
-H "Authorization: Bearer <AUTH_TOKEN>"
104104
```
@@ -107,7 +107,7 @@ It's also possible to filter on a field that belongs to a linked resource. To fi
107107

108108
```shell
109109
curl -X GET \
110-
"{{ $links.apiBase }}/v5/device?\$filter=belongs_to__application/app_name%20eq%20'<APP_NAME>'" \
110+
"{{ $links.apiBase }}/v6/device?\$filter=belongs_to__application/app_name%20eq%20'<APP_NAME>'" \
111111
-H "Content-Type: application/json" \
112112
-H "Authorization: Bearer <AUTH_TOKEN>"
113113
```

0 commit comments

Comments
 (0)