graph_rs_sdk/default_drive/
request.rs

1use crate::api_default_imports::*;
2use crate::default_drive::*;
3use crate::drives::*;
4
5api_client!(DefaultDriveApiClient, ResourceIdentity::Drive);
6
7impl DefaultDriveApiClient {
8    get!(
9       doc: "# Get drive",
10       name: get_drive,
11       path: "/drive"
12    );
13    patch!(
14        doc: "# Update drive",
15        name: update_drive,
16        path: "/drive",
17        body: true
18    );
19    get!(
20        doc: "Get bundles from drives",
21        name: list_bundles,
22        path: "/drive/bundles"
23    );
24    get!(
25        doc: "Get the number of the resource",
26        name: get_bundles_count,
27        path: "/drive/bundles/$count"
28    );
29    get!(
30        doc: "Get bundles from drives",
31        name: get_bundles,
32        path: "/drive/bundles/{{id}}",
33        params: drive_item_id
34    );
35    get!(
36        doc: "Get content for the navigation property bundles from drives",
37        name: get_bundles_content,
38        path: "/drive/bundles/{{id}}/content",
39        params: drive_item_id
40    );
41    put!(
42        doc: "Update content for the navigation property bundles in drives",
43        name: update_bundles_content,
44        path: "/drive/bundles/{{id}}/content",
45        body: true,
46        params: drive_item_id
47    );
48    get!(
49       doc: "# Get following from drive",
50       name: list_following,
51       path: "/drive/following"
52    );
53    post!(
54       doc: "# Create new navigation property to following for drive",
55       name: create_following,
56       path: "/drive/following",
57       body: true
58    );
59    get!(
60        doc: "Get the number of the resource",
61        name: get_following_count,
62        path: "/drives/{{RID}}/following/$count"
63    );
64    get!(
65        doc: "Get following from drive",
66        name: get_following,
67        path: "/drive/following/{{id}}",
68        params: drive_item_id
69    );
70    get!(
71        doc: "Get content for the navigation property following from drive",
72        name: get_following_content,
73        path: "/drive/following/{{id}}/content",
74        params: drive_item_id
75    );
76    put!(
77        doc: "Update content for the navigation property following in drive",
78        name: update_following_content,
79        path: "/drive/following/{{id}}/content",
80        body: true,
81        params: drive_item_id
82    );
83    get!(
84        name: list_root_children,
85        path: "/drive/root/children"
86    );
87    get!(
88       name: list_root_activities,
89       path: "/drive/activities"
90    );
91    get!(
92       doc: "# Get list from drive",
93       name: get_list,
94       path: "/drive/list",
95       body: false
96    );
97    patch!(
98       doc: "# Update the navigation property list in drive",
99       name: update_list,
100       path: "/drive/list",
101       body: true
102    );
103    get!(
104        doc: "# Invoke function recent",
105        name: recent,
106        path: "/drive/recent()"
107    );
108    get!(
109        doc: "# Get root from drive",
110        name: get_root,
111        path: "/drive/root"
112    );
113    patch!(
114        doc: "# Update the navigation property root in drive",
115        name: update_root,
116        path: "/drive/root"
117    );
118    get!(
119        doc: "# Invoke function sharedWithMe",
120        name: shared_with_me,
121        path: "/drive/sharedWithMe()"
122    );
123    get!(
124        doc: "# Get special from drive",
125        name: list_special,
126        path: "/drive/special"
127    );
128    post!(
129        doc: "# Create new navigation property to special for drive",
130        name: create_special,
131        path: "/drive/special",
132        body: true
133    );
134    get!(
135        doc: "# Get special from drive",
136        name: get_special,
137        path: "/drive/special/{{id}}",
138        params: drive_item_id
139    );
140    patch!(
141        doc: "# Update the navigation property special in drive",
142        name: update_special,
143        path: "/drive/special/{{id}}",
144        body: true,
145        params: drive_item_id
146    );
147    get!(
148        doc: "Get content for the navigation property special from drive",
149        name: get_special_content,
150        path: "/drive/special/{{id}}/content",
151        params: drive_item_id
152    );
153    put!(
154        doc: "Update content for the navigation property special in drive",
155        name: update_special_content,
156        path: "/drive/special/{{id}}/content",
157        body: true,
158        params: drive_item_id
159    );
160    get!(
161       name: root_delta,
162       path: "/drive/root/delta"
163    );
164    get!(
165        doc: "Invoke function search",
166        name: search,
167        path: "/drive/search(q='{{id}}')",
168        params: q
169    );
170    get!(
171        doc: "Get content for the navigation property root from drives",
172        name: get_root_content,
173        path: "/drive/root/content"
174    );
175    put!(
176        doc: "Update content for the navigation property root in drives",
177        name: update_root_content,
178        path: "/drive/root/content",
179        body: true
180    );
181    post!(
182        doc: "Create drive item in root of drive",
183        name: create_root_folder,
184        path: "/drive/root/children",
185        body: true
186    );
187
188    api_client_link!(items, DrivesItemsApiClient);
189    api_client_link_id!(item, DrivesItemsIdApiClient);
190    api_client_link_id!(item_by_path, DefaultDrivesItemsPathIdApiClient);
191    api_client_link!(lists, DrivesListApiClient);
192    api_client_link!(worksheets, WorksheetsApiClient);
193    api_client_link!(last_modified_by_user, LastModifiedByUserApiClient);
194    api_client_link_id!(worksheet, WorksheetsIdApiClient);
195    api_client_link!(created_by_user, CreatedByUserApiClient);
196    api_client_link!(workbook, WorkbookApiClient);
197}