client_modify

This modifies the Client.

Netsweeper recommends you use the format that best suits your requirements. If you want to expire a client 10 minutes from when the API call is run, you may want to use the +10 minutes. However, if you want the account to expire on a specific date at a specific time, using that exact date and time is recommended.

Concept Link IconSee Also

Parameters:

Argument

Required

Type

Description

currentclientname

yes

string

This is the current client name.

currentip

yes

string

This is the current IP.

currentsubnet

yes

string

This is the current subnet.

type

yes

string

The current type of the client.

clientname

yes

string

The name of the Client

groupname

yes

string

The groupname for the Client.

password

no

string

The password for the user.

ip

no

string

The ip for the Client.

subnet

no

string

The subnet for the Client

catlist

no

string

The Category list for the client.

ttl

no

date

·       now

·       +1 day

·       +10 months

·       -12 years

·       +1 week 2 days 4 hours 2 seconds

·       next wednesday

·       last monday

·       26 October 1998

·       @946684800 (specific EPOCH time)

·       19791013 (yyyymmdd)

·       1979/10/13 13:26:41 (yyyy/mm/dd hh:mm:ss)

·       1979/10/13 13:26:41 GMT (yyyy/mm/dd hh:mm:ss tz)

comment

no

string

Enter a comment.

workstation

no

string

Enter the Workstation name.

firstname

no

string

The first name of the Client.

lastname

no

string

The last name of the Client.

email

no

string

The email for the Client.

callback

no

string

This only works with Direct APIs. This is a JavaScript function that should be called after the API is completed. This function will be called with the response of the API.  Please note: It can only be used when requesting this API via AJAX request.

Example

servername/webadmin/api/client_modify.php?currentclientname=VALUE&currentip=VALUE&currentsubnet=VALUE&type=VALUE&clientname=VALUE&groupname=VALUE

Output:

OK: Client modified: clientname

ERROR: Your new password must be between 5 and 16 characters.

ERROR: The IP address you specified is not a valid address

ERROR: IP Address and Subnet already used.

ERROR: The client name clientname already exists.

ERROR: Please specify a client name.

ERROR: The CDIR subnet mask you specified is not a valid subnet mask.

ERROR: The IP address you specified is not a valid address

ERROR: Invalid client type 'sometype' specified.

ERROR: Invalid client type '' specified.

ERROR: Group does not exist: groupname

ERROR: The IP address you entered is not a network address. Please specify a valid network address or change the subnet mask to 255.255.255.255

ERROR: The subnet mask you specified is not a valid subnet mask.

ERROR: Invalid Expiration Date

ERROR: List of categories is invalid

ERROR: Permission Denied: Unauthorized access.

ERROR: Permission denied: requires 'Modify Clients' permission

ERROR: Permission denied

ERROR: Permission denied: user accountname not assigned to manage group of client clientname.

ERROR: Permission denied: user accountname is not a member of group clientname

Netsweeper Version: 2.6.24.7