Module: Nylas::AdminApiOperations::Create

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

Overview

Creates a Nylas object.

Instance Method Summary collapse

Instance Method Details

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

Creates a Nylas object.

Parameters:

  • 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))

    Created Nylas object and API Request ID.



19
20
21
22
23
24
25
# File 'lib/nylas/handler/admin_api_operations.rb', line 19

def create(query_params: {}, request_body: nil)
  post(
    path: "#{api_uri}/v3/#{resource_name}",
    query_params: query_params,
    request_body: request_body
  )
end