Skip to content

Commit 53c521b

Browse files
authored
feat(account/v2): default generated project name (#1670)
1 parent 2826ba2 commit 53c521b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

api/account/v2/account_sdk.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,10 @@ func (s *API) CreateProject(req *CreateProjectRequest, opts ...scw.RequestOption
129129
req.OrganizationID = defaultOrganizationID
130130
}
131131

132+
if req.Name == "" {
133+
req.Name = namegenerator.GetRandomName("proj")
134+
}
135+
132136
scwReq := &scw.ScalewayRequest{
133137
Method: "POST",
134138
Path: "/account/v2/projects",

0 commit comments

Comments
 (0)