Skip to main content

print_servers

Creates, updates, deletes, gets or lists a print_servers resource.

Overview

Nameprint_servers
TypeResource
Idgoogleadmin.directory.print_servers

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
idstringImmutable. ID of the print server. Leave empty when creating.
namestringIdentifier. Resource name of the print server. Leave empty when creating. Format: customers/{customer.id}/printServers/{print_server.id}
createTimestring (google-datetime)Output only. Time when the print server was created.
descriptionstringEditable. Description of the print server (as shown in the Admin console).
displayNamestringEditable. Display name of the print server (as shown in the Admin console).
orgUnitIdstringID of the organization unit (OU) that owns this print server. This value can only be set when the print server is initially created. If it's not populated, the print server is placed under the root OU. The org_unit_id can be retrieved using the Directory API.
uristringEditable. Print server URI.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectcustomersId, printServersIdReturns a print server's configuration.
listselectcustomersIdpageSize, pageToken, orgUnitId, filter, orderByLists print server configurations.
createinsertcustomersIdCreates a print server.
batch_create_print_serversinsertcustomersIdCreates multiple print servers.
patchupdatecustomersId, printServersIdupdateMaskUpdates a print server's configuration.
deletedeletecustomersId, printServersIdDeletes a print server.
batch_delete_print_serversdeletecustomersIdDeletes multiple print servers.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
customersIdstring
printServersIdstring
filterstring
orderBystring
orgUnitIdstring
pageSizeinteger (int32)
pageTokenstring
updateMaskstring (google-fieldmask)

SELECT examples

Returns a print server's configuration.

SELECT
id,
name,
createTime,
description,
displayName,
orgUnitId,
uri
FROM googleadmin.directory.print_servers
WHERE customersId = '{{ customersId }}' -- required
AND printServersId = '{{ printServersId }}' -- required;

INSERT examples

Creates a print server.

INSERT INTO googleadmin.directory.print_servers (
data__name,
data__id,
data__displayName,
data__description,
data__uri,
data__orgUnitId,
customersId
)
SELECT
'{{ name }}',
'{{ id }}',
'{{ displayName }}',
'{{ description }}',
'{{ uri }}',
'{{ orgUnitId }}',
'{{ customersId }}'
RETURNING
id,
name,
createTime,
description,
displayName,
orgUnitId,
uri
;

UPDATE examples

Updates a print server's configuration.

UPDATE googleadmin.directory.print_servers
SET
data__name = '{{ name }}',
data__id = '{{ id }}',
data__displayName = '{{ displayName }}',
data__description = '{{ description }}',
data__uri = '{{ uri }}',
data__orgUnitId = '{{ orgUnitId }}'
WHERE
customersId = '{{ customersId }}' --required
AND printServersId = '{{ printServersId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
id,
name,
createTime,
description,
displayName,
orgUnitId,
uri;

DELETE examples

Deletes a print server.

DELETE FROM googleadmin.directory.print_servers
WHERE customersId = '{{ customersId }}' --required
AND printServersId = '{{ printServersId }}' --required;