@@ -393,7 +393,7 @@ func CreateOrUpdateFile(getClient GetClientFn, t translations.TranslationHelperF
393393// CreateRepository creates a tool to create a new GitHub repository. 
394394func  CreateRepository (getClient  GetClientFn , t  translations.TranslationHelperFunc ) (tool  mcp.Tool , handler  server.ToolHandlerFunc ) {
395395	return  mcp .NewTool ("create_repository" ,
396- 			mcp .WithDescription (t ("TOOL_CREATE_REPOSITORY_DESCRIPTION" , "Create a new GitHub repository in your account" )),
396+ 			mcp .WithDescription (t ("TOOL_CREATE_REPOSITORY_DESCRIPTION" , "Create a new GitHub repository in your account or specified organization " )),
397397			mcp .WithToolAnnotation (mcp.ToolAnnotation {
398398				Title :        t ("TOOL_CREATE_REPOSITORY_USER_TITLE" , "Create repository" ),
399399				ReadOnlyHint : ToBoolPtr (false ),
@@ -405,6 +405,9 @@ func CreateRepository(getClient GetClientFn, t translations.TranslationHelperFun
405405			mcp .WithString ("description" ,
406406				mcp .Description ("Repository description" ),
407407			),
408+ 			mcp .WithString ("organization" ,
409+ 				mcp .Description ("Organization to create the repository in (omit to create in your personal account)" ),
410+ 			),
408411			mcp .WithBoolean ("private" ,
409412				mcp .Description ("Whether repo should be private" ),
410413			),
@@ -421,6 +424,10 @@ func CreateRepository(getClient GetClientFn, t translations.TranslationHelperFun
421424			if  err  !=  nil  {
422425				return  mcp .NewToolResultError (err .Error ()), nil 
423426			}
427+ 			organization , err  :=  OptionalParam [string ](request , "organization" )
428+ 			if  err  !=  nil  {
429+ 				return  mcp .NewToolResultError (err .Error ()), nil 
430+ 			}
424431			private , err  :=  OptionalParam [bool ](request , "private" )
425432			if  err  !=  nil  {
426433				return  mcp .NewToolResultError (err .Error ()), nil 
@@ -441,7 +448,7 @@ func CreateRepository(getClient GetClientFn, t translations.TranslationHelperFun
441448			if  err  !=  nil  {
442449				return  nil , fmt .Errorf ("failed to get GitHub client: %w" , err )
443450			}
444- 			createdRepo , resp , err  :=  client .Repositories .Create (ctx , "" , repo )
451+ 			createdRepo , resp , err  :=  client .Repositories .Create (ctx , organization , repo )
445452			if  err  !=  nil  {
446453				return  ghErrors .NewGitHubAPIErrorResponse (ctx ,
447454					"failed to create repository" ,
0 commit comments