Calendar & Scheduling

Commission Packages

A CommissionPackage defines the commission rates a practitioner earns. Each package can have multiple rates with individual thresholds, date ranges, and evaluation periods. A rate pays either a percentage of the item's value or a flat amount per item, and a package's weekly or bi_weekly evaluation period can be configured to start on any day of the week.

get/shop/commission-packages

List CommissionPackages

listCommissionPackages

Use this endpoint to retrieve a list of CommissionPackages for a site.

Query parameters

  • pageintegeroptional

    The page to retrieve results from

  • per_pageintegeroptional

    The number of results to return per page

  • site_idstringoptional

    Filter results by the site they belong to

Responses

  • 200

    The CommissionPackages were successfully retrieved.

  • 401

    The user is unauthenticated

  • 404

    The resource couldn't be found

post/shop/commission-packages

Create CommissionPackage

createCommissionPackage

Use this endpoint to create a new CommissionPackage for a site.

Query parameters

  • site_idstringoptional

    Filter results by the site they belong to

Request body

  • namestringoptional

    Display name of the commission package, shown in the admin UI when assigning packages to practitioners and on commission reports. Pick a name that summarises the package's rate structure. 1-120 characters.

  • The default period over which commission earned under this package is aggregated and paid out. Determines whether targets and tiers reset weekly, monthly, etc. Accepts the EvaluationPeriod enum values.

  • The day a weekly or bi_weekly evaluation period starts on. Omit or send null to default to monday.

  • requested_surcharge_percentagenumberoptionalnullable

    An optional surcharge percentage applied to requested practitioner bookings.

  • ratesobject[]optional

    The commission rates for this package.

Responses

  • 201

    The CommissionPackage was successfully retrieved.

  • 401

    The user is unauthenticated

  • 403

    The authenticated user does not have permission.

  • 404

    The resource couldn't be found

  • 422

    The request didn't pass validation

get/shop/commission-packages/{commissionPackageId}

Show CommissionPackage

getCommissionPackage

Use this endpoint to retrieve a single CommissionPackage.

Path parameters

Query parameters

  • site_idstringoptional

    Filter results by the site they belong to

Responses

  • 200

    The CommissionPackage was successfully retrieved.

  • 401

    The user is unauthenticated

  • 404

    The resource couldn't be found

put/shop/commission-packages/{commissionPackageId}

Update CommissionPackage

updateCommissionPackage

Use this endpoint to update a CommissionPackage.

Path parameters

Query parameters

  • site_idstringoptional

    Filter results by the site they belong to

Request body

  • namestringoptional

    Display name of the commission package, shown in the admin UI when assigning packages to practitioners and on commission reports. Pick a name that summarises the package's rate structure. 1-120 characters.

  • The default period over which commission earned under this package is aggregated and paid out. Determines whether targets and tiers reset weekly, monthly, etc. Accepts the EvaluationPeriod enum values.

  • The day a weekly or bi_weekly evaluation period starts on. Omit or send null to default to monday.

  • requested_surcharge_percentagenumberoptionalnullable

    An optional surcharge percentage applied to requested practitioner bookings.

  • ratesobject[]optional

    The commission rates for this package.

Responses

  • 200

    The CommissionPackage was successfully retrieved.

  • 401

    The user is unauthenticated

  • 403

    The authenticated user does not have permission.

  • 404

    The resource couldn't be found

  • 422

    The request didn't pass validation

delete/shop/commission-packages/{commissionPackageId}

Delete CommissionPackage

deleteCommissionPackage

Use this endpoint to delete a CommissionPackage.

Path parameters

Query parameters

  • site_idstringoptional

    Filter results by the site they belong to

Responses

  • 204

    The CommissionPackage was successfully deleted.

  • 401

    The user is unauthenticated

  • 403

    The authenticated user does not have permission.

  • 404

    The resource couldn't be found

get/shop/user-commission-assignments

List UserCommissionAssignments

listUserCommissionAssignments

Use this endpoint to retrieve a list of UserCommissionAssignments, optionally filtered by site or user. Each assignment attaches a CommissionPackage to a plain User at a site, for staff who earn commission but aren't modelled as a Practitioner.

Query parameters

  • site_idstringoptional

    Filter results by the site they belong to

  • user_iduuidoptional

    Restrict results to assignments for a single user.

  • pageintegeroptional

    The page to retrieve results from

  • per_pageintegeroptional

    The number of results to return per page

Responses

  • 200

    The UserCommissionAssignments were successfully retrieved.

  • 401

    The user is unauthenticated

  • 404

    The resource couldn't be found

post/shop/user-commission-assignments

Create UserCommissionAssignment

createUserCommissionAssignment

Use this endpoint to assign a CommissionPackage to a User at a site. Fails with 422 if the user already has an assignment at that site — update the existing UserCommissionAssignment instead.

Request body

  • user_iduuidrequired

    The ID of the User to assign the commission package to.

  • site_idmongo-idrequired

    The ID of the site this assignment applies to.

  • commission_package_idmongo-idrequired

    The ID of the CommissionPackage to assign.

Responses

  • 201

    The UserCommissionAssignment was successfully retrieved.

  • 401

    The user is unauthenticated

  • 403

    The authenticated user does not have permission.

  • 404

    The resource couldn't be found

  • 422

    The request didn't pass validation

get/shop/user-commission-assignments/{userCommissionAssignmentId}

Show UserCommissionAssignment

getUserCommissionAssignment

Use this endpoint to retrieve a single UserCommissionAssignment.

Path parameters

Responses

  • 200

    The UserCommissionAssignment was successfully retrieved.

  • 401

    The user is unauthenticated

  • 404

    The resource couldn't be found

put/shop/user-commission-assignments/{userCommissionAssignmentId}

Update UserCommissionAssignment

updateUserCommissionAssignment

Use this endpoint to change the CommissionPackage assigned to a UserCommissionAssignment. The assignment's user_id and site_id cannot be changed — delete and recreate the assignment instead.

Path parameters

Request body

Responses

  • 200

    The UserCommissionAssignment was successfully retrieved.

  • 401

    The user is unauthenticated

  • 403

    The authenticated user does not have permission.

  • 404

    The resource couldn't be found

  • 422

    The request didn't pass validation

delete/shop/user-commission-assignments/{userCommissionAssignmentId}

Delete UserCommissionAssignment

deleteUserCommissionAssignment

Use this endpoint to remove a UserCommissionAssignment. The user stops earning commission under the assigned package going forward; past commission calculations are unaffected.

Path parameters

Responses

  • 204

    The UserCommissionAssignment was successfully deleted.

  • 401

    The user is unauthenticated

  • 403

    The authenticated user does not have permission.

  • 404

    The resource couldn't be found