Page tree
Skip to end of metadata
Go to start of metadata


Creating a Space can only be done when authenticated as a user, it cannot be done when authenticated as an application.

The "createSpace" mutation creates a new Space.The new space requires at least a title.

The has simple static helper methods to create a space with just a title, buildCreateSpaceMutationWithSpaceTitle(String), or with a title and members, buildCreateSpaceMutationWithSpaceTitleAndMembers(String, List<String>). Similar methods are also available from WWClient and WWGraphQLEndpoint. These will just return a Space object with the space id as their result.

For greater control, create the InputDataSenderBuilder and ObjectDataSenderBuilder manually. Create an InputDataSenderBuilder for the Space.CREATE_SPACE_MUTATION_NAME object, adding the Space title and the members you wish to assign access for the Space. A CreateSpaceFields enum is available to avoid typos. Create an ObjectDataSenderBuilder for the Space.ONE_SPACE_QUERY_OBJECT_NAME object, passing in Space fields and children. Instantiate a new SpaceCreateGraphQLMutation passing in the InputDataSenderBuilder and ObjectDataSenderBuilder as parameters. Then pass this to WWClient.createSpaceWithQuery().


Basic createSpace
Space space = client.createSpace("Hello World");
assert null != space.getId();
basic createSpace with members
ArrayList<String> members = new ArrayList<String>();
Space space = client.createSpace("Hello World", members);
assert null != space.getId();
ArrayList<String> members = new ArrayList<String>();
InputDataSenderBuilder spaceInput = new InputDataSenderBuilder(Space.CREATE_SPACE_MUTATION_NAME);
spaceInput.addField(CreateSpaceFields.TITLE, title);
spaceInput.addField(CreateSpaceFields.MEMBERS, members);
ObjectDataSenderBuilder returnObject = new ObjectDataSenderBuilder(Space.ONE_SPACE_QUERY_OBJECT_NAME);
SpaceCreateGraphQLMutation mutationObject = new SpaceCreateGraphQLMutation(spaceInput, returnObject);

Space spaceResult = client.createSpaceWithQuery(mutationObject);
assert null != space.getTitle();


  1. Anonymous

    An inquiry is a one-page letter introducing yourself and your novel. Before long, I'd swear off pressing an unreasonable measure of information into your inquiry letter, so single-isolating to make it fit on one page shouldn't be basic. The assignment service provider is good enough to provide data which can be transmitted into the real world.

  2. Anonymous

    I just love to visit this website and I got informative stuff from this website. Keep it up.

    William Riley, Assistant writer at Elite Assignment

  3. Anonymous

    It has basic static partner strategies to make a space, As Adweb Studio brings the most efficient service for Web Design users as get to know more you have to visit the website to know about our exciting deals and updates!

Write a comment…