Skip to content

Commit 9b6ff93

Browse files
authored
docs(applesilicon): revamp of the documentation (#520)
1 parent ea47e53 commit 9b6ff93

File tree

2 files changed

+49
-33
lines changed

2 files changed

+49
-33
lines changed

packages/clients/src/api/applesilicon/v1alpha1/api.gen.ts

Lines changed: 28 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ const jsonContentHeaders = {
4646
/**
4747
* Apple silicon.
4848
*
49-
* Scaleway Apple silicon M1 as-a-Service is built using the latest generation
50-
* of Apple Mac mini hardware (fifth generation).
49+
* Scaleway Apple silicon as-a-Service is built using the latest generation of
50+
* Apple Mac mini hardware (fifth generation).
5151
*
5252
* These dedicated Mac mini M1s are designed for developing, building, testing,
5353
* and signing applications for Apple devices, including iPhones, iPads, Mac
@@ -69,7 +69,9 @@ export class API extends ParentAPI {
6969
public static readonly LOCALITIES: Zone[] = ['fr-par-3']
7070

7171
/**
72-
* List all server types technical details.
72+
* List all technical details about Apple silicon server types available in
73+
* the specified zone. Since there is only one Availability Zone for Apple
74+
* silicon servers, the targeted value is `fr-par-3`.
7375
*
7476
* @param request - The request {@link ListServerTypesRequest}
7577
* @returns A Promise of ListServerTypesResponse
@@ -105,7 +107,8 @@ export class API extends ParentAPI {
105107
)
106108

107109
/**
108-
* Create a server.
110+
* Create a new server in the targeted zone, specifying its configuration
111+
* including name and type.
109112
*
110113
* @param request - The request {@link CreateServerRequest}
111114
* @returns A Promise of Server
@@ -149,7 +152,9 @@ export class API extends ParentAPI {
149152
)
150153

151154
/**
152-
* List all servers.
155+
* List all servers in the specified zone. By default, returned servers in the
156+
* list are ordered by creation date in ascending order, though this can be
157+
* modified via the `order_by` field.
153158
*
154159
* @param request - The request {@link ListServersRequest}
155160
* @returns A Promise of ListServersResponse
@@ -179,7 +184,8 @@ export class API extends ParentAPI {
179184
)
180185

181186
/**
182-
* List all Operating System (OS).
187+
* List all Operating System (OS). The response will include the total number
188+
* of OS as well as their associated IDs, names and labels.
183189
*
184190
* @param request - The request {@link ListOSRequest}
185191
* @returns A Promise of ListOSResponse
@@ -188,7 +194,8 @@ export class API extends ParentAPI {
188194
enrichForPagination('os', this.pageOfListOS, request)
189195

190196
/**
191-
* Get an Operating System (OS).
197+
* Get an Operating System (OS). The response will include the OS's unique ID
198+
* as well as its name and label.
192199
*
193200
* @param request - The request {@link GetOSRequest}
194201
* @returns A Promise of OS
@@ -206,7 +213,9 @@ export class API extends ParentAPI {
206213
)
207214

208215
/**
209-
* Get a server.
216+
* Retrieve information about an existing Apple silicon server, specified by
217+
* its server ID. Its full details, including name, status and IP address, are
218+
* returned in the response object.
210219
*
211220
* @param request - The request {@link GetServerRequest}
212221
* @returns A Promise of Server
@@ -244,7 +253,8 @@ export class API extends ParentAPI {
244253
)
245254

246255
/**
247-
* Update a server.
256+
* Update the parameters of an existing Apple silicon server, specified by its
257+
* server ID.
248258
*
249259
* @param request - The request {@link UpdateServerRequest}
250260
* @returns A Promise of Server
@@ -266,7 +276,10 @@ export class API extends ParentAPI {
266276
)
267277

268278
/**
269-
* Delete a server.
279+
* Delete an existing Apple silicon server, specified by its server ID.
280+
* Deleting a server is permanent, and cannot be undone. Note that the minimum
281+
* allocation period for Apple silicon-as-a-service is 24 hours, meaning you
282+
* cannot delete your server prior to that.
270283
*
271284
* @param request - The request {@link DeleteServerRequest}
272285
*/
@@ -280,7 +293,7 @@ export class API extends ParentAPI {
280293
})
281294

282295
/**
283-
* Reboot a server.
296+
* Reboot an existing Apple silicon server, specified by its server ID.
284297
*
285298
* @param request - The request {@link RebootServerRequest}
286299
* @returns A Promise of Server
@@ -300,7 +313,10 @@ export class API extends ParentAPI {
300313
)
301314

302315
/**
303-
* Reinstall a server.
316+
* Reinstall an existing Apple silicon server (specified by its server ID)
317+
* from a new image (OS). All the data on the disk is deleted and all
318+
* configuration is reset to the defailt configuration values of the image
319+
* (OS).
304320
*
305321
* @param request - The request {@link ReinstallServerRequest}
306322
* @returns A Promise of Server

packages/clients/src/api/applesilicon/v1alpha1/types.gen.ts

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -24,33 +24,33 @@ export type ServerTypeStock =
2424

2525
/** List os response. */
2626
export interface ListOSResponse {
27-
/** Total number of os. */
27+
/** Total number of OS. */
2828
totalCount: number
2929
/** List of OS. */
3030
os: OS[]
3131
}
3232

3333
/** List server types response. */
3434
export interface ListServerTypesResponse {
35-
/** The available server types. */
35+
/** Available server types. */
3636
serverTypes: ServerType[]
3737
}
3838

3939
/** List servers response. */
4040
export interface ListServersResponse {
41-
/** The total number of servers. */
41+
/** Total number of servers. */
4242
totalCount: number
43-
/** The paginated returned servers. */
43+
/** Paginated returned servers. */
4444
servers: Server[]
4545
}
4646

4747
/** Os. */
4848
export interface OS {
49-
/** The OS unique ID. */
49+
/** Unique ID of the OS. */
5050
id: string
51-
/** The OS name. */
51+
/** OS name. */
5252
name: string
53-
/** The OS name as it should be displayed. */
53+
/** OS name as it should be displayed. */
5454
label: string
5555
/** URL of the image. */
5656
imageUrl: string
@@ -76,13 +76,13 @@ export interface Server {
7676
vncUrl: string
7777
/** Current status of the server. */
7878
status: ServerStatus
79-
/** The date at which the server was created. */
79+
/** Date on which the server was created. */
8080
createdAt?: Date
81-
/** The date at which the server was last updated. */
81+
/** Date on which the server was last updated. */
8282
updatedAt?: Date
83-
/** The date at which the server was last deleted. */
83+
/** Date on which the server was last deleted. */
8484
deletableAt?: Date
85-
/** The zone of the server. */
85+
/** Zone of the server. */
8686
zone: Zone
8787
}
8888

@@ -143,16 +143,16 @@ export type CreateServerRequest = {
143143
export type ListServersRequest = {
144144
/** Zone to target. If none is passed will use default zone from the config. */
145145
zone?: Zone
146-
/** The sort order of the returned servers. */
146+
/** Sort order of the returned servers. */
147147
orderBy?: ListServersRequestOrderBy
148-
/** List only servers of this project ID. */
148+
/** Only list servers of this project ID. */
149149
projectId?: string
150-
/** List only servers of this organization ID. */
150+
/** Only list servers of this Organization ID. */
151151
organizationId?: string
152-
/** A positive integer to choose the page to return. */
152+
/** Positive integer to choose the page to return. */
153153
page?: number
154154
/**
155-
* A positive integer lower or equal to 100 to select the number of items to
155+
* Positive integer lower or equal to 100 to select the number of items to
156156
* return.
157157
*/
158158
pageSize?: number
@@ -161,18 +161,18 @@ export type ListServersRequest = {
161161
export type ListOSRequest = {
162162
/** Zone to target. If none is passed will use default zone from the config. */
163163
zone?: Zone
164-
/** A positive integer to choose the page to return. */
164+
/** Positive integer to choose the page to return. */
165165
page?: number
166166
/**
167-
* A positive integer lower or equal to 100 to select the number of items to
167+
* Positive integer lower or equal to 100 to select the number of items to
168168
* return.
169169
*/
170170
pageSize?: number
171-
/** List of compatible server type. */
171+
/** List of compatible server types. */
172172
serverType?: string
173173
/**
174-
* Filter os by name (for eg. "11.1" will return "11.1.2" and "11.1" but not
175-
* "12").
174+
* Filter OS by name (note that "11.1" will return "11.1.2" and "11.1" but not
175+
* "12")).
176176
*/
177177
name?: string
178178
}

0 commit comments

Comments
 (0)