Edit Service Group API
Modify existing service group settings including discounts, gateways, and geolocation restrictions
Edit Service Group API
Update service group configurations. Modify pricing tiers, discount percentages, gateway assignments, and geolocation restrictions for existing service groups.
Flexible Updates
Modify any service group attribute.
Adjust Discounts
Update pricing and discount tiers.
Geo Controls
Change geographic availability.
Endpoint Overview
/graphqlUpdate an existing service group's attributes including name, description, discount tiers, gateway assignments, and geolocation restrictions.
Request Parameters
idInt!RequiredThe unique identifier of the service group to update.
serviceGroupServiceGroupEdit!RequiredObject containing the fields to update.
nameStringUpdated name for the service group.
descriptionStringUpdated description.
discountFloatBase discount percentage.
discount3Float3-month subscription discount.
discount6Float6-month subscription discount.
discount12FloatAnnual subscription discount.
discount24Float2-year subscription discount.
discount36Float3-year subscription discount.
discountLifetimeFloatLifetime subscription discount.
gateways[Int]Updated gateway assignments.
allowedGeolocations[Int]Updated allowed geographic regions.
disAllowedGeolocations[Int]Updated blocked geographic regions.
GraphQL Mutation
mutation editServiceGroup($id: Int!, $serviceGroup: ServiceGroupEdit!) {
editServiceGroup(id: $id, serviceGroup: $serviceGroup) {
id
name
description
discount
discount12
discount24
}
}Variables:
{
"id": 5,
"serviceGroup": {
"name": "Premium Plans - Updated",
"discount12": 35,
"discount24": 45
}
}HTTP Request:
curl -X POST https://api.orbnet.com/graphql \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_ADMIN_TOKEN" \
-d '{
"query": "mutation editServiceGroup($id: Int!, $serviceGroup: ServiceGroupEdit!) { editServiceGroup(id: $id, serviceGroup: $serviceGroup) { id name discount12 } }",
"variables": {
"id": 5,
"serviceGroup": {
"discount12": 35
}
}
}'Response
{
"data": {
"editServiceGroup": {
"id": "5",
"name": "Premium Plans - Updated",
"description": "Premium VPN service with priority support",
"discount": 0,
"discount12": 35,
"discount24": 45
}
}
}{
"errors": [
{
"message": "Service group not found",
"path": ["editServiceGroup"],
"extensions": {
"code": "NOT_FOUND"
}
}
],
"data": null
}Common Updates
Promotional Discounts
Temporarily increase discount percentages for sales events.
Gateway Expansion
Add new servers to improve coverage and performance.
Region Updates
Modify geographic availability based on demand or licensing.
Pricing Adjustments
Update base prices or discount structures.
Best Practices
Partial Updates
Only include fields that need to change in the request.
Test Changes
Verify updates on staging before applying to production.
Communicate Changes
Notify users of significant pricing or availability changes.
Audit Trail
Keep records of changes for compliance and troubleshooting.
Related Endpoints
Impact on Existing Users
Changes to service groups may affect users on existing plans. Discount changes typically apply to new subscriptions only, not existing renewals.
Review Before Editing
View the current service group configuration before making changes to ensure you understand the impact.