Class: Google::Apis::AndroidmanagementV1::AndroidManagementService
- Inherits:
-
Core::BaseService
- Object
- Core::BaseService
- Google::Apis::AndroidmanagementV1::AndroidManagementService
- Defined in:
- lib/google/apis/androidmanagement_v1/service.rb
Overview
Android Management API
The Android Management API provides remote enterprise management of Android devices and apps.
Instance Attribute Summary collapse
-
#key ⇒ String
API key.
-
#quota_user ⇒ String
Available to use for quota purposes for server-side applications.
Instance Method Summary collapse
-
#cancel_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Starts asynchronous cancellation on a long-running operation.
-
#create_enterprise(enterprise_object = nil, agreement_accepted: nil, enterprise_token: nil, project_id: nil, signup_url_name: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Enterprise
Creates an enterprise.
-
#create_enterprise_enrollment_token(parent, enrollment_token_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::EnrollmentToken
Creates an enrollment token for a given enterprise.
-
#create_enterprise_web_app(parent, web_app_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::WebApp
Creates a web app.
-
#create_enterprise_web_token(parent, web_token_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::WebToken
Creates a web token to access an embeddable managed Google Play web UI for a given enterprise.
-
#create_signup_url(callback_url: nil, project_id: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::SignupUrl
Creates an enterprise signup URL.
-
#delete_enterprise(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes an enterprise.
-
#delete_enterprise_device(name, wipe_data_flags: nil, wipe_reason_message: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes a device.
-
#delete_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes a long-running operation.
-
#delete_enterprise_enrollment_token(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes an enrollment token.
-
#delete_enterprise_policy(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes a policy.
-
#delete_enterprise_web_app(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes a web app.
-
#get_enterprise(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Enterprise
Gets an enterprise.
-
#get_enterprise_application(name, language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Application
Gets info about an application.
-
#get_enterprise_device(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Device
Gets a device.
-
#get_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Operation
Gets the latest state of a long-running operation.
-
#get_enterprise_enrollment_token(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::EnrollmentToken
Gets an active, unexpired enrollment token.
-
#get_enterprise_policy(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Policy
Gets a policy.
-
#get_enterprise_web_app(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::WebApp
Gets a web app.
-
#initialize ⇒ AndroidManagementService
constructor
A new instance of AndroidManagementService.
-
#issue_enterprise_device_command(name, command_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Operation
Issues a command to a device.
-
#list_enterprise_device_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListOperationsResponse
Lists operations that match the specified filter in the request.
-
#list_enterprise_devices(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListDevicesResponse
Lists devices for a given enterprise.
-
#list_enterprise_enrollment_tokens(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListEnrollmentTokensResponse
Lists active, unexpired enrollment tokens for a given enterprise.
-
#list_enterprise_policies(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListPoliciesResponse
Lists policies for a given enterprise.
-
#list_enterprise_web_apps(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListWebAppsResponse
Lists web apps for a given enterprise.
-
#list_enterprises(page_size: nil, page_token: nil, project_id: nil, view: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListEnterprisesResponse
Lists EMM-managed enterprises.
-
#patch_enterprise(name, enterprise_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Enterprise
Updates an enterprise.
-
#patch_enterprise_device(name, device_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Device
Updates a device.
-
#patch_enterprise_policy(name, policy_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Policy
Updates or creates a policy.
-
#patch_enterprise_web_app(name, web_app_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::WebApp
Updates a web app.
Constructor Details
#initialize ⇒ AndroidManagementService
Returns a new instance of AndroidManagementService.
46 47 48 49 50 51 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 46 def initialize super('https://androidmanagement.googleapis.com/', '', client_name: 'google-apis-androidmanagement_v1', client_version: Google::Apis::AndroidmanagementV1::GEM_VERSION) @batch_path = 'batch' end |
Instance Attribute Details
#key ⇒ String
Returns API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
39 40 41 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 39 def key @key end |
#quota_user ⇒ String
Returns Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
44 45 46 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 44 def quota_user @quota_user end |
Instance Method Details
#cancel_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to Code.CANCELLED.
492 493 494 495 496 497 498 499 500 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 492 def cancel_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1/{+name}:cancel', ) command.response_representation = Google::Apis::AndroidmanagementV1::Empty::Representation command.response_class = Google::Apis::AndroidmanagementV1::Empty command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#create_enterprise(enterprise_object = nil, agreement_accepted: nil, enterprise_token: nil, project_id: nil, signup_url_name: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Enterprise
Creates an enterprise. This is the last step in the enterprise signup flow.
93 94 95 96 97 98 99 100 101 102 103 104 105 106 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 93 def create_enterprise(enterprise_object = nil, agreement_accepted: nil, enterprise_token: nil, project_id: nil, signup_url_name: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1/enterprises', ) command.request_representation = Google::Apis::AndroidmanagementV1::Enterprise::Representation command.request_object = enterprise_object command.response_representation = Google::Apis::AndroidmanagementV1::Enterprise::Representation command.response_class = Google::Apis::AndroidmanagementV1::Enterprise command.query['agreementAccepted'] = agreement_accepted unless agreement_accepted.nil? command.query['enterpriseToken'] = enterprise_token unless enterprise_token.nil? command.query['projectId'] = project_id unless project_id.nil? command.query['signupUrlName'] = signup_url_name unless signup_url_name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#create_enterprise_enrollment_token(parent, enrollment_token_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::EnrollmentToken
Creates an enrollment token for a given enterprise. It's up to the caller's responsibility to manage the lifecycle of newly created tokens and deleting them when they're not intended to be used anymore. Once an enrollment token has been created, it's not possible to retrieve the token's content anymore using AM API. It is recommended for EMMs to securely store the token if it's intended to be reused.
638 639 640 641 642 643 644 645 646 647 648 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 638 def create_enterprise_enrollment_token(parent, enrollment_token_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1/{+parent}/enrollmentTokens', ) command.request_representation = Google::Apis::AndroidmanagementV1::EnrollmentToken::Representation command.request_object = enrollment_token_object command.response_representation = Google::Apis::AndroidmanagementV1::EnrollmentToken::Representation command.response_class = Google::Apis::AndroidmanagementV1::EnrollmentToken command.params['parent'] = parent unless parent.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#create_enterprise_web_app(parent, web_app_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::WebApp
Creates a web app.
918 919 920 921 922 923 924 925 926 927 928 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 918 def create_enterprise_web_app(parent, web_app_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1/{+parent}/webApps', ) command.request_representation = Google::Apis::AndroidmanagementV1::WebApp::Representation command.request_object = web_app_object command.response_representation = Google::Apis::AndroidmanagementV1::WebApp::Representation command.response_class = Google::Apis::AndroidmanagementV1::WebApp command.params['parent'] = parent unless parent.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#create_enterprise_web_token(parent, web_token_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::WebToken
Creates a web token to access an embeddable managed Google Play web UI for a given enterprise.
1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 1089 def create_enterprise_web_token(parent, web_token_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1/{+parent}/webTokens', ) command.request_representation = Google::Apis::AndroidmanagementV1::WebToken::Representation command.request_object = web_token_object command.response_representation = Google::Apis::AndroidmanagementV1::WebToken::Representation command.response_class = Google::Apis::AndroidmanagementV1::WebToken command.params['parent'] = parent unless parent.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#create_signup_url(callback_url: nil, project_id: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::SignupUrl
Creates an enterprise signup URL.
1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 1128 def create_signup_url(callback_url: nil, project_id: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1/signupUrls', ) command.response_representation = Google::Apis::AndroidmanagementV1::SignupUrl::Representation command.response_class = Google::Apis::AndroidmanagementV1::SignupUrl command.query['callbackUrl'] = callback_url unless callback_url.nil? command.query['projectId'] = project_id unless project_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_enterprise(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes an enterprise. Only available for EMM-managed enterprises.
128 129 130 131 132 133 134 135 136 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 128 def delete_enterprise(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Empty::Representation command.response_class = Google::Apis::AndroidmanagementV1::Empty command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_enterprise_device(name, wipe_data_flags: nil, wipe_reason_message: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes a device. This operation wipes the device. Deleted devices do not show up in enterprises.devices.list calls and a 404 is returned from enterprises. devices.get.
310 311 312 313 314 315 316 317 318 319 320 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 310 def delete_enterprise_device(name, wipe_data_flags: nil, wipe_reason_message: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Empty::Representation command.response_class = Google::Apis::AndroidmanagementV1::Empty command.params['name'] = name unless name.nil? command.query['wipeDataFlags'] = wipe_data_flags unless wipe_data_flags.nil? command.query['wipeReasonMessage'] = unless .nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns google.rpc.Code. UNIMPLEMENTED.
525 526 527 528 529 530 531 532 533 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 525 def delete_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Empty::Representation command.response_class = Google::Apis::AndroidmanagementV1::Empty command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_enterprise_enrollment_token(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes an enrollment token. This operation invalidates the token, preventing its future use.
672 673 674 675 676 677 678 679 680 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 672 def delete_enterprise_enrollment_token(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Empty::Representation command.response_class = Google::Apis::AndroidmanagementV1::Empty command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_enterprise_policy(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes a policy. This operation is only permitted if no devices are currently referencing the policy.
781 782 783 784 785 786 787 788 789 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 781 def delete_enterprise_policy(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Empty::Representation command.response_class = Google::Apis::AndroidmanagementV1::Empty command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#delete_enterprise_web_app(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Empty
Deletes a web app.
951 952 953 954 955 956 957 958 959 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 951 def delete_enterprise_web_app(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:delete, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Empty::Representation command.response_class = Google::Apis::AndroidmanagementV1::Empty command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_enterprise(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Enterprise
Gets an enterprise.
158 159 160 161 162 163 164 165 166 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 158 def get_enterprise(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Enterprise::Representation command.response_class = Google::Apis::AndroidmanagementV1::Enterprise command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_enterprise_application(name, language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Application
Gets info about an application.
270 271 272 273 274 275 276 277 278 279 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 270 def get_enterprise_application(name, language_code: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Application::Representation command.response_class = Google::Apis::AndroidmanagementV1::Application command.params['name'] = name unless name.nil? command.query['languageCode'] = language_code unless language_code.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_enterprise_device(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Device
Gets a device. Deleted devices will respond with a 404 error.
343 344 345 346 347 348 349 350 351 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 343 def get_enterprise_device(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Device::Representation command.response_class = Google::Apis::AndroidmanagementV1::Device command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Operation
Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.
556 557 558 559 560 561 562 563 564 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 556 def get_enterprise_device_operation(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Operation::Representation command.response_class = Google::Apis::AndroidmanagementV1::Operation command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_enterprise_enrollment_token(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::EnrollmentToken
Gets an active, unexpired enrollment token. Only a partial view of EnrollmentToken is returned: all the fields but name and expiration_timestamp are empty. This method is meant to help manage active enrollment tokens lifecycle. For security reasons, it's recommended to delete active enrollment tokens as soon as they're not intended to be used anymore.
707 708 709 710 711 712 713 714 715 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 707 def get_enterprise_enrollment_token(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::EnrollmentToken::Representation command.response_class = Google::Apis::AndroidmanagementV1::EnrollmentToken command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_enterprise_policy(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Policy
Gets a policy.
812 813 814 815 816 817 818 819 820 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 812 def get_enterprise_policy(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::Policy::Representation command.response_class = Google::Apis::AndroidmanagementV1::Policy command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#get_enterprise_web_app(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::WebApp
Gets a web app.
982 983 984 985 986 987 988 989 990 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 982 def get_enterprise_web_app(name, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::WebApp::Representation command.response_class = Google::Apis::AndroidmanagementV1::WebApp command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#issue_enterprise_device_command(name, command_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Operation
Issues a command to a device. The Operation resource returned contains a Command in its metadata field. Use the get operation method to get the status of the command.
377 378 379 380 381 382 383 384 385 386 387 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 377 def issue_enterprise_device_command(name, command_object = nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1/{+name}:issueCommand', ) command.request_representation = Google::Apis::AndroidmanagementV1::Command::Representation command.request_object = command_object command.response_representation = Google::Apis::AndroidmanagementV1::Operation::Representation command.response_class = Google::Apis::AndroidmanagementV1::Operation command.params['name'] = name unless name.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_enterprise_device_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListOperationsResponse
Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns UNIMPLEMENTED.NOTE: the name binding allows API services to override the binding to use different resource name schemes, such as users//operations. To override the binding, API services can add a binding such as "/v1/`name=users/`/operations" to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.
599 600 601 602 603 604 605 606 607 608 609 610 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 599 def list_enterprise_device_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+name}', ) command.response_representation = Google::Apis::AndroidmanagementV1::ListOperationsResponse::Representation command.response_class = Google::Apis::AndroidmanagementV1::ListOperationsResponse command.params['name'] = name unless name.nil? command.query['filter'] = filter unless filter.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_enterprise_devices(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListDevicesResponse
Lists devices for a given enterprise. Deleted devices are not returned in the response.
415 416 417 418 419 420 421 422 423 424 425 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 415 def list_enterprise_devices(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+parent}/devices', ) command.response_representation = Google::Apis::AndroidmanagementV1::ListDevicesResponse::Representation command.response_class = Google::Apis::AndroidmanagementV1::ListDevicesResponse command.params['parent'] = parent unless parent.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_enterprise_enrollment_tokens(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListEnrollmentTokensResponse
Lists active, unexpired enrollment tokens for a given enterprise. The list items contain only a partial view of EnrollmentToken: all the fields but name and expiration_timestamp are empty. This method is meant to help manage active enrollment tokens lifecycle. For security reasons, it's recommended to delete active enrollment tokens as soon as they're not intended to be used anymore.
747 748 749 750 751 752 753 754 755 756 757 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 747 def list_enterprise_enrollment_tokens(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+parent}/enrollmentTokens', ) command.response_representation = Google::Apis::AndroidmanagementV1::ListEnrollmentTokensResponse::Representation command.response_class = Google::Apis::AndroidmanagementV1::ListEnrollmentTokensResponse command.params['parent'] = parent unless parent.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_enterprise_policies(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListPoliciesResponse
Lists policies for a given enterprise.
847 848 849 850 851 852 853 854 855 856 857 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 847 def list_enterprise_policies(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+parent}/policies', ) command.response_representation = Google::Apis::AndroidmanagementV1::ListPoliciesResponse::Representation command.response_class = Google::Apis::AndroidmanagementV1::ListPoliciesResponse command.params['parent'] = parent unless parent.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_enterprise_web_apps(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListWebAppsResponse
Lists web apps for a given enterprise.
1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 1017 def list_enterprise_web_apps(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/{+parent}/webApps', ) command.response_representation = Google::Apis::AndroidmanagementV1::ListWebAppsResponse::Representation command.response_class = Google::Apis::AndroidmanagementV1::ListWebAppsResponse command.params['parent'] = parent unless parent.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#list_enterprises(page_size: nil, page_token: nil, project_id: nil, view: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::ListEnterprisesResponse
Lists EMM-managed enterprises. Only BASIC fields are returned.
195 196 197 198 199 200 201 202 203 204 205 206 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 195 def list_enterprises(page_size: nil, page_token: nil, project_id: nil, view: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:get, 'v1/enterprises', ) command.response_representation = Google::Apis::AndroidmanagementV1::ListEnterprisesResponse::Representation command.response_class = Google::Apis::AndroidmanagementV1::ListEnterprisesResponse command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['projectId'] = project_id unless project_id.nil? command.query['view'] = view unless view.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#patch_enterprise(name, enterprise_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Enterprise
Updates an enterprise.
232 233 234 235 236 237 238 239 240 241 242 243 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 232 def patch_enterprise(name, enterprise_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:patch, 'v1/{+name}', ) command.request_representation = Google::Apis::AndroidmanagementV1::Enterprise::Representation command.request_object = enterprise_object command.response_representation = Google::Apis::AndroidmanagementV1::Enterprise::Representation command.response_class = Google::Apis::AndroidmanagementV1::Enterprise command.params['name'] = name unless name.nil? command.query['updateMask'] = update_mask unless update_mask.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#patch_enterprise_device(name, device_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Device
Updates a device.
452 453 454 455 456 457 458 459 460 461 462 463 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 452 def patch_enterprise_device(name, device_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:patch, 'v1/{+name}', ) command.request_representation = Google::Apis::AndroidmanagementV1::Device::Representation command.request_object = device_object command.response_representation = Google::Apis::AndroidmanagementV1::Device::Representation command.response_class = Google::Apis::AndroidmanagementV1::Device command.params['name'] = name unless name.nil? command.query['updateMask'] = update_mask unless update_mask.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#patch_enterprise_policy(name, policy_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::Policy
Updates or creates a policy.
884 885 886 887 888 889 890 891 892 893 894 895 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 884 def patch_enterprise_policy(name, policy_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:patch, 'v1/{+name}', ) command.request_representation = Google::Apis::AndroidmanagementV1::Policy::Representation command.request_object = policy_object command.response_representation = Google::Apis::AndroidmanagementV1::Policy::Representation command.response_class = Google::Apis::AndroidmanagementV1::Policy command.params['name'] = name unless name.nil? command.query['updateMask'] = update_mask unless update_mask.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |
#patch_enterprise_web_app(name, web_app_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroidmanagementV1::WebApp
Updates a web app.
1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 |
# File 'lib/google/apis/androidmanagement_v1/service.rb', line 1054 def patch_enterprise_web_app(name, web_app_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:patch, 'v1/{+name}', ) command.request_representation = Google::Apis::AndroidmanagementV1::WebApp::Representation command.request_object = web_app_object command.response_representation = Google::Apis::AndroidmanagementV1::WebApp::Representation command.response_class = Google::Apis::AndroidmanagementV1::WebApp command.params['name'] = name unless name.nil? command.query['updateMask'] = update_mask unless update_mask.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? execute_or_queue_command(command, &block) end |