Module: Nylas::AdminApiOperations::Update

Includes:
ApiOperations::Put
Included in:
Grants, RedirectUris
Defined in:
lib/nylas/handler/admin_api_operations.rb

Overview

Updates a Nylas object.

Instance Method Summary collapse

Instance Method Details

#update(object_id:, query_params: {}, request_body: nil) ⇒ Array(Hash, String)

Updates a Nylas object.

Parameters:

  • object_id (String)

    Object ID.

  • query_params (Hash, {}) (defaults to: {})

    Query params to pass to the request.

  • request_body (Hash, nil) (defaults to: nil)

    Request body to pass to the request.

Returns:

  • (Array(Hash, String))

    Updated Nylas object and API Request ID.



68
69
70
71
72
73
74
# File 'lib/nylas/handler/admin_api_operations.rb', line 68

def update(object_id:, query_params: {}, request_body: nil)
  put(
    path: "#{api_uri}/v3/#{resource_name}/#{object_id}",
    query_params: query_params,
    request_body: request_body
  )
end