File tree Expand file tree Collapse file tree 3 files changed +4
-3
lines changed
packages/clients/src/api/account/v2 Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ export class API extends ParentAPI {
3939 * @param request - The request {@link CreateProjectRequest}
4040 * @returns A Promise of Project
4141 */
42- createProject = ( request : Readonly < CreateProjectRequest > ) =>
42+ createProject = ( request : Readonly < CreateProjectRequest > = { } ) =>
4343 this . client . fetch < Project > (
4444 {
4545 body : JSON . stringify (
Original file line number Diff line number Diff line change 11// This file was automatically generated. DO NOT EDIT.
22// If you have any remark or suggestion do not hesitate to open an issue.
3+ import randomName from '@scaleway/random-name'
34import {
45 isJSONObject ,
56 unmarshalArrayOfObject ,
@@ -48,7 +49,7 @@ export const marshalCreateProjectRequest = (
4849 defaults : DefaultValues ,
4950) : Record < string , unknown > => ( {
5051 description : request . description ,
51- name : request . name ,
52+ name : request . name || randomName ( 'proj' ) ,
5253 organization_id : request . organizationId ?? defaults . defaultOrganizationId ,
5354} )
5455
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ export interface Project {
3333
3434export type CreateProjectRequest = {
3535 /** Name of the Project. */
36- name : string
36+ name ? : string
3737 /** Organization ID of the Project. */
3838 organizationId ?: string
3939 /** Description of the Project. */
You can’t perform that action at this time.
0 commit comments