type Query{ #get all of root organization roots:RootsData #get all of organization organizations:OrganizationsData #get children organization of specify organization children(id:Int!):ChildrenData #get users of specify organization usersInOrganization(id:Int!):UsersInOrganizationData } type Mutation{ #create organization with name , the parentId is optional createOrganization(name:String!,parentId:Int):Data #update organization with name , the parentId is optional updateOrganization(id:Int!,name:String!,parentId:Int):Data #delete specify id organization deleteOrganization(id:Int!):Data #add user to organization addUserToOrganization(id:Int!,userId:Int!):Data #add users to organization addUsersToOrganization(id:Int!,userIds:[Int!]!):Data #remove user from organization removeUserFromOrganization(id:Int!,userId:Int!):Data #remove users from organization removeUsersFromOrganization(id:Int!,userIds:[Int!]!):Data } #return data type OrganizationsData{ #error code code:Int #error message message:String #array of organization organizations:[Organization] } #return data type RootsData{ #error code code:Int #error message message:String #array of organization roots:[Organization] } #return data type ChildrenData{ #error code code:Int #error message message:String #array of organization children:[Organization] } #Organization type type Organization{ id:Int name:String } #return data type UsersInOrganizationData{ #error code code:Int #error message message:String #array of users users:[User] } type User{ id:Int userName:String status:Boolean }