Reseller Edit User API

Allow resellers to update user account details and settings by user ID

Reseller

Reseller Edit User API

Update user account details and settings using their user ID. Modify passwords, profile information, and subscription settings for your customers.

Update Users

Modify account settings.

Profile Updates

Change personal information.

Access Control

Adjust login and device limits.


Endpoint Overview

MUTATION/graphql

Update an existing user's account details by their unique ID. Modify account settings, profile information, and subscription parameters.

Authentication:Bearer Token
Required scopes:reseller

Request Parameters

idInt!Required

The unique identifier of the user to update.

resellerUserEdit.passwordString

New password for the user account.

resellerUserEdit.groupIdInt

New subscription group ID.

resellerUserEdit.multiLoginCountInt

Maximum concurrent login sessions.

resellerUserEdit.userProfileEditObject

Profile information to update (firstName, lastName, phone, address, city, country, postalCode, birthDate).


GraphQL Mutation

mutation resellerEditUser($id: Int!, $resellerUserEdit: ResellerUserEdit!) {
  resellerEditUser(id: $id, resellerUserEdit: $resellerUserEdit) {
    id
    email
    username
    resellerId
    role
    enabled
    updatedAt
  }
}

Variables:

{
  "id": 12345,
  "resellerUserEdit": {
    "multiLoginCount": 5,
    "userProfileEdit": {
      "firstName": "John",
      "lastName": "Updated",
      "phone": "+1987654321",
      "city": "New York",
      "country": "US"
    }
  }
}

HTTP Request:

curl -X POST https://api.orbnet.com/graphql \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_RESELLER_TOKEN" \
  -d '{
    "query": "mutation resellerEditUser($id: Int!, $resellerUserEdit: ResellerUserEdit!) { resellerEditUser(id: $id, resellerUserEdit: $resellerUserEdit) { id email username updatedAt } }",
    "variables": {
      "id": 12345,
      "resellerUserEdit": {
        "multiLoginCount": 5
      }
    }
  }'

Response

200User Updated Successfully
{
  "data": {
    "resellerEditUser": {
      "id": "12345",
      "email": "customer@example.com",
      "username": "johncustomer",
      "resellerId": "reseller_789",
      "role": "user",
      "enabled": true,
      "updatedAt": "2024-01-16T14:30:00Z"
    }
  }
}
400User Not Found
{
  "errors": [
    {
      "message": "User with ID 12345 not found or not in your group",
      "path": ["resellerEditUser"],
      "extensions": {
        "code": "NOT_FOUND"
      }
    }
  ],
  "data": null
}

Editable Fields

Password

Reset user's password.

Login Count

Adjust concurrent session limit.

Group

Change subscription plan.

Profile

Update personal details.


Best Practices

Partial Updates

Only include fields to change.

Verify User

Confirm user belongs to your group.

Notify User

Inform of significant changes.

Document Changes

Keep records of modifications.



Group Scope

You can only edit users within your assigned group. Attempting to edit users outside your group will return an error.

Don't Know the User ID?

Use the Edit by Email endpoint if you only have the user's email address.

Edit by Email