Class CampaignCreateParams
-
- All Implemented Interfaces:
-
com.growsurf.api.core.Params
public final class CampaignCreateParams implements Params
Creates a new program pre-populated with type-appropriate defaults, plus any optional inline rewards. The new program is created in
DRAFTstatus and owned by the API key's account. Requires a verified account email and a paid plan (referral) or a payment source on file (affiliate); subject to your plan's program limit.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classCampaignCreateParams.BuilderA builder for CampaignCreateParams.
public final classCampaignCreateParams.BodyRequest body for creating a program. Only
typeis required; everything else is server-defaulted.public final classCampaignCreateParams.TypeThe program type. Immutable after creation.
public final classCampaignCreateParams.RewardRequest body for creating a campaign reward.
typeis required and must be compatible with the program type.
-
Method Summary
Modifier and Type Method Description final CampaignCreateParams.Typetype()The program type. final Optional<String>name()The program name. final Optional<String>companyName()final Optional<String>companyLogoImageUrl()final Optional<String>currencyIso()ISO 4217 currency code. final Optional<List<CampaignCreateParams.Reward>>rewards()Optional inline rewards to create with the program. final JsonField<CampaignCreateParams.Type>_type()Returns the raw JSON value of type. final JsonField<String>_name()Returns the raw JSON value of name. final JsonField<String>_companyName()Returns the raw JSON value of companyName. final JsonField<String>_companyLogoImageUrl()Returns the raw JSON value of companyLogoImageUrl. final JsonField<String>_currencyIso()Returns the raw JSON value of currencyIso. final JsonField<List<CampaignCreateParams.Reward>>_rewards()Returns the raw JSON value of rewards. final Map<String, JsonValue>_additionalBodyProperties()final Headers_additionalHeaders()Additional headers to send with the request. final QueryParams_additionalQueryParams()Additional query param to send with the request. final CampaignCreateParams.BuildertoBuilder()final CampaignCreateParams.Body_body()Headers_headers()The full set of headers in the parameters, including both fixed and additional headers. QueryParams_queryParams()The full set of query params in the parameters, including both fixed and additional query params. Booleanequals(Object other)IntegerhashCode()StringtoString()final static CampaignCreateParams.Builderbuilder()Returns a mutable builder for constructing an instance of CampaignCreateParams. -
-
Method Detail
-
type
final CampaignCreateParams.Type type()
The program type. Immutable after creation.
-
companyName
final Optional<String> companyName()
-
companyLogoImageUrl
final Optional<String> companyLogoImageUrl()
-
currencyIso
final Optional<String> currencyIso()
ISO 4217 currency code. Defaults to USD. Chosen when the program is created and immutable afterward — it cannot be changed on update.
-
rewards
final Optional<List<CampaignCreateParams.Reward>> rewards()
Optional inline rewards to create with the program.
-
_type
final JsonField<CampaignCreateParams.Type> _type()
Returns the raw JSON value of type.
Unlike type, this method doesn't throw if the JSON field has an unexpected type.
-
_name
final JsonField<String> _name()
Returns the raw JSON value of name.
Unlike name, this method doesn't throw if the JSON field has an unexpected type.
-
_companyName
final JsonField<String> _companyName()
Returns the raw JSON value of companyName.
Unlike companyName, this method doesn't throw if the JSON field has an unexpected type.
-
_companyLogoImageUrl
final JsonField<String> _companyLogoImageUrl()
Returns the raw JSON value of companyLogoImageUrl.
Unlike companyLogoImageUrl, this method doesn't throw if the JSON field has an unexpected type.
-
_currencyIso
final JsonField<String> _currencyIso()
Returns the raw JSON value of currencyIso.
Unlike currencyIso, this method doesn't throw if the JSON field has an unexpected type.
-
_rewards
final JsonField<List<CampaignCreateParams.Reward>> _rewards()
Returns the raw JSON value of rewards.
Unlike rewards, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalBodyProperties
final Map<String, JsonValue> _additionalBodyProperties()
-
_additionalHeaders
final Headers _additionalHeaders()
Additional headers to send with the request.
-
_additionalQueryParams
final QueryParams _additionalQueryParams()
Additional query param to send with the request.
-
toBuilder
final CampaignCreateParams.Builder toBuilder()
-
_body
final CampaignCreateParams.Body _body()
-
_headers
Headers _headers()
The full set of headers in the parameters, including both fixed and additional headers.
-
_queryParams
QueryParams _queryParams()
The full set of query params in the parameters, including both fixed and additional query params.
-
builder
final static CampaignCreateParams.Builder builder()
Returns a mutable builder for constructing an instance of CampaignCreateParams.
The following fields are required:
.type()
-
-
-
-