Class: Believe::Resources::Conflicts

Inherits:
Object
  • Object
show all
Defined in:
lib/believe/resources/conflicts.rb

Overview

Interactive endpoints for motivation and guidance

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ Conflicts

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of Conflicts.

Parameters:



38
39
40
# File 'lib/believe/resources/conflicts.rb', line 38

def initialize(client:)
  @client = client
end

Instance Method Details

#resolve(conflict_type:, description:, parties_involved:, attempts_made: nil, request_options: {}) ⇒ ::Believe::Models::ConflictResolveResponse

Get Ted Lasso-style advice for resolving conflicts.

Parameters:

Returns:

See Also:



24
25
26
27
28
29
30
31
32
33
# File 'lib/believe/resources/conflicts.rb', line 24

def resolve(params)
  parsed, options = ::Believe::ConflictResolveParams.dump_request(params)
  @client.request(
    method: :post,
    path: "conflicts/resolve",
    body: parsed,
    model: ::Believe::Models::ConflictResolveResponse,
    options: options
  )
end