Skip to content
createBusinessMutation
createBusiness(name: String!, owner: EntityRef!, organization: EntityRef, locations: [LocationCreateInput!], structures: [ActivityStructure!], activityTypes: [ActivityType!], country: String, plan: PlatformSubscriptionPlan): CreateBusinessResult!

Create a new business owned by the given user. Surfaced on the public (account-subdomain) schema so the post-signup Create a business flow can run before the operator has a business subdomain to call the business-scoped variant against.

Arguments

nameString!
ownerEntityRef!
organizationEntityRef
structures[ActivityStructure!]

Activity structures the business plans to run (classes, leagues, etc.). Captured at creation as a tailoring hint; defaults to [].

activityTypes[ActivityType!]

Activity types (sports, disciplines) the business plans to offer. Captured at creation as a tailoring hint; defaults to [].

countryString

Optional ISO 3166-1 alpha-2 country (e.g. CA, US) the owner declares for the business. Prefilled from the request's inferred location. Used as the regional fallback for discovery and to seed the Stripe Connect account country. Null when not provided; an unsupported code is rejected.

Plan to start the business's trial on. Every new business gets a row in platform_subscriptions at creation with a no-card trial; this picks the tier. Defaults to start when omitted.

Returns

CreateBusinessResult!

See CreateBusinessResult for the full shape.

Try it

Example
Query
mutation CreateBusiness($name: String!, $owner: EntityRef!, $organization: EntityRef, $locations: [LocationCreateInput!], $structures: [ActivityStructure!], $activityTypes: [ActivityType!], $country: String, $plan: PlatformSubscriptionPlan) {
  createBusiness(name: $name, owner: $owner, organization: $organization, locations: $locations, structures: $structures, activityTypes: $activityTypes, country: $country, plan: $plan) {
    __typename
  }
}
Variables
{}
POST https://go.sessions.website/api/graphql
createBusiness