Class: WhopSDK::Models::BountyCreateParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/whop_sdk/models/bounty_create_params.rb,
sig/whop_sdk/models/bounty_create_params.rbs

Overview

See Also:

  • WhopSDK::Resources::Bounties#create

Defined Under Namespace

Modules: BusinessGoalType, ScheduledFrequency

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(base_unit_amount:, currency:, description:, title:, accepted_submissions_limit: nil, allowed_country_codes: nil, business_goal_type: nil, experience_id: nil, origin_account_id: nil, post_markdown_content: nil, post_title: nil, scheduled_frequency: nil, scheduled_publish_at: nil, scheduled_timezone: nil, request_options: {}) ⇒ Object

Some parameter documentations has been truncated, see WhopSDK::Models::BountyCreateParams for more details.

D

Parameters:

  • base_unit_amount (Float)

    The amount paid to each approved submission. The total bounty pool funded is thi

  • currency (Symbol, WhopSDK::Models::Currency)

    The currency for the bounty pool funding amount.

  • description (String)

    The description of the bounty.

  • title (String)

    The title of the bounty.

  • accepted_submissions_limit (Integer, nil) (defaults to: nil)

    The number of submissions that can be approved before the bounty closes. Default

  • allowed_country_codes (Array<String>, nil) (defaults to: nil)

    The ISO3166 country codes where this bounty should be visible. Empty means globa

  • business_goal_type (Symbol, WhopSDK::Models::BountyCreateParams::BusinessGoalType, nil) (defaults to: nil)

    What the poster is trying to accomplish with a workforce bounty. Used for produc

  • experience_id (String, nil) (defaults to: nil)

    An optional experience to scope the bounty to.

  • origin_account_id (String, nil) (defaults to: nil)

    The user (user*) or company (biz*) tag whose balance funds this bounty pool.

  • post_markdown_content (String, nil) (defaults to: nil)

    Optional markdown body for the anchor forum post. Falls back to the bounty descr

  • post_title (String, nil) (defaults to: nil)

    Optional title for the anchor forum post. Falls back to the bounty title when om

  • scheduled_frequency (Symbol, WhopSDK::Models::BountyCreateParams::ScheduledFrequency, nil) (defaults to: nil)

    How often a scheduled bounty republishes a new bounty.

  • scheduled_publish_at (Time, nil) (defaults to: nil)

    When to publish the bounty. When provided, the bounty is created as a hidden dra

  • scheduled_timezone (String, nil) (defaults to: nil)

    The IANA timezone used for recurring occurrences. Required when scheduled_publis

  • request_options (WhopSDK::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


# File 'lib/whop_sdk/models/bounty_create_params.rb', line 106

Instance Attribute Details

#accepted_submissions_limitInteger?

The number of submissions that can be approved before the bounty closes. Defaults to 1. The total pool (base_unit_amount times this limit) must be at least 5 in the bounty's currency.

Parameters:

  • value (Integer, nil)

Returns:

  • (Integer, nil)


42
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 42

optional :accepted_submissions_limit, Integer, nil?: true

#allowed_country_codesArray<String>?

The ISO3166 country codes where this bounty should be visible. Empty means globally visible.

Parameters:

  • value (::Array[String], nil)

Returns:

  • (Array<String>, nil)


49
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 49

optional :allowed_country_codes, WhopSDK::Internal::Type::ArrayOf[String], nil?: true

#base_unit_amountFloat

The amount paid to each approved submission. The total bounty pool funded is this amount times accepted_submissions_limit, and must be at least 5 in the bounty's currency.

Parameters:

  • value (Float)

Returns:

  • (Float)


16
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 16

required :base_unit_amount, Float

#business_goal_typeSymbol, ...

What the poster is trying to accomplish with a workforce bounty. Used for product taxonomy and analytics, separate from the bounty's implementation type.

Parameters:

  • value (WhopSDK::Models::BountyCreateParams::business_goal_type, nil)

Returns:



56
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 56

optional :business_goal_type, enum: -> { WhopSDK::BountyCreateParams::BusinessGoalType }, nil?: true

#currencySymbol, WhopSDK::Models::Currency

The currency for the bounty pool funding amount.

Parameters:

  • value (WhopSDK::Models::currency)

Returns:



22
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 22

required :currency, enum: -> { WhopSDK::Currency }

#descriptionString

The description of the bounty.

Parameters:

  • value (String)

Returns:

  • (String)


28
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 28

required :description, String

#experience_idString?

An optional experience to scope the bounty to.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


62
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 62

optional :experience_id, String, nil?: true

#origin_account_idString?

The user (user*) or company (biz*) tag whose balance funds this bounty pool. Defaults to the requester's personal balance when omitted. The requester must be the user themself or an owner/admin of the company.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


70
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 70

optional :origin_account_id, String, nil?: true

#post_markdown_contentString?

Optional markdown body for the anchor forum post. Falls back to the bounty description when omitted.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


77
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 77

optional :post_markdown_content, String, nil?: true

#post_titleString?

Optional title for the anchor forum post. Falls back to the bounty title when omitted.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


84
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 84

optional :post_title, String, nil?: true

#scheduled_frequencySymbol, ...

How often a scheduled bounty republishes a new bounty.

Parameters:

  • value (WhopSDK::Models::BountyCreateParams::scheduled_frequency, nil)

Returns:



90
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 90

optional :scheduled_frequency, enum: -> { WhopSDK::BountyCreateParams::ScheduledFrequency }, nil?: true

#scheduled_publish_atTime?

When to publish the bounty. When provided, the bounty is created as a hidden draft and published at this time instead of immediately. Must be in the future.

Parameters:

  • value (Time, nil)

Returns:

  • (Time, nil)


97
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 97

optional :scheduled_publish_at, Time, nil?: true

#scheduled_timezoneString?

The IANA timezone used for recurring occurrences. Required when scheduled_publish_at is provided.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


104
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 104

optional :scheduled_timezone, String, nil?: true

#titleString

The title of the bounty.

Parameters:

  • value (String)

Returns:

  • (String)


34
# File 'lib/whop_sdk/models/bounty_create_params.rb', line 34

required :title, String

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/whop_sdk/models/bounty_create_params.rb', line 153

Instance Method Details

#to_hash{

Returns:

  • ({)


72
# File 'sig/whop_sdk/models/bounty_create_params.rbs', line 72

def to_hash: -> {